diff --git a/.buildkite/ftr_configs.yml b/.buildkite/ftr_configs.yml index 7a563f067a0f9..83408d2121c56 100644 --- a/.buildkite/ftr_configs.yml +++ b/.buildkite/ftr_configs.yml @@ -262,9 +262,11 @@ enabled: - x-pack/test/security_api_integration/oidc.config.ts - x-pack/test/security_api_integration/pki.config.ts - x-pack/test/security_api_integration/saml.config.ts + - x-pack/test/security_api_integration/saml_cloud.config.ts - x-pack/test/security_api_integration/session_idle.config.ts - x-pack/test/security_api_integration/session_invalidate.config.ts - x-pack/test/security_api_integration/session_lifespan.config.ts + - x-pack/test/security_api_integration/session_concurrent_limit.config.ts - x-pack/test/security_api_integration/token.config.ts - x-pack/test/security_api_integration/user_profiles.config.ts - x-pack/test/security_functional/login_selector.config.ts diff --git a/.buildkite/package-lock.json b/.buildkite/package-lock.json index cc303035b972e..d28509d0de482 100644 --- a/.buildkite/package-lock.json +++ b/.buildkite/package-lock.json @@ -16,12 +16,12 @@ "tslib": "*" }, "devDependencies": { - "@types/chai": "^4.2.10", + "@types/chai": "^4.3.3", "@types/js-yaml": "^4.0.5", "@types/minimatch": "^3.0.5", "@types/mocha": "^10.0.1", "@types/node": "^15.12.2", - "chai": "^4.2.0", + "chai": "^4.3.6", "mocha": "^10.2.0", "nock": "^12.0.2", "ts-node": "^10.7.0", @@ -242,9 +242,9 @@ "dev": true }, "node_modules/@types/chai": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.1.tgz", - "integrity": "sha512-/zPMqDkzSZ8t3VtxOa4KPq7uzzW978M9Tvh+j7GHKuo6k6GTLxPJ4J5gE5cjfJ26pnXst0N5Hax8Sr0T2Mi9zQ==", + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.3.tgz", + "integrity": "sha512-hC7OMnszpxhZPduX+m+nrx+uFoLkWOMiR4oa/AZF3MuSETYTZmFfJAHqZEM8MVlvfG7BEUcgvtwoCTxBp6hm3g==", "dev": true }, "node_modules/@types/js-yaml": { @@ -1847,9 +1847,9 @@ "dev": true }, "@types/chai": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.1.tgz", - "integrity": "sha512-/zPMqDkzSZ8t3VtxOa4KPq7uzzW978M9Tvh+j7GHKuo6k6GTLxPJ4J5gE5cjfJ26pnXst0N5Hax8Sr0T2Mi9zQ==", + "version": "4.3.3", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-4.3.3.tgz", + "integrity": "sha512-hC7OMnszpxhZPduX+m+nrx+uFoLkWOMiR4oa/AZF3MuSETYTZmFfJAHqZEM8MVlvfG7BEUcgvtwoCTxBp6hm3g==", "dev": true }, "@types/js-yaml": { diff --git a/.buildkite/package.json b/.buildkite/package.json index 620345b081410..2dbcbc3c0082f 100644 --- a/.buildkite/package.json +++ b/.buildkite/package.json @@ -15,12 +15,12 @@ "tslib": "*" }, "devDependencies": { - "@types/chai": "^4.2.10", + "@types/chai": "^4.3.3", "@types/js-yaml": "^4.0.5", "@types/minimatch": "^3.0.5", "@types/mocha": "^10.0.1", "@types/node": "^15.12.2", - "chai": "^4.2.0", + "chai": "^4.3.6", "mocha": "^10.2.0", "nock": "^12.0.2", "ts-node": "^10.7.0", diff --git a/.buildkite/scripts/steps/artifacts/docker_image.sh b/.buildkite/scripts/steps/artifacts/docker_image.sh index 2e561fd519769..edd82152aae2a 100755 --- a/.buildkite/scripts/steps/artifacts/docker_image.sh +++ b/.buildkite/scripts/steps/artifacts/docker_image.sh @@ -9,16 +9,16 @@ source .buildkite/scripts/steps/artifacts/env.sh GIT_ABBREV_COMMIT=${BUILDKITE_COMMIT:0:7} KIBANA_IMAGE="docker.elastic.co/kibana-ci/kibana:$GIT_ABBREV_COMMIT" -echo "--- Verify image does not already exist" +echo "--- Verify manifest does not already exist" echo "$KIBANA_DOCKER_PASSWORD" | docker login -u "$KIBANA_DOCKER_USERNAME" --password-stdin docker.elastic.co trap 'docker logout docker.elastic.co' EXIT if docker manifest inspect $KIBANA_IMAGE &> /dev/null; then - echo "Image already exists, exiting" + echo "Manifest already exists, exiting" exit 1 fi -echo "--- Build image" +echo "--- Build images" node scripts/build \ --debug \ --release \ @@ -29,6 +29,29 @@ node scripts/build \ --skip-docker-ubi \ --skip-docker-cloud \ --skip-docker-contexts + +echo "--- Tag images" +docker rmi "$KIBANA_IMAGE" +docker load < "target/kibana-$BASE_VERSION-docker-image.tar.gz" +docker tag "$KIBANA_IMAGE" "$KIBANA_IMAGE-amd64" + +docker rmi "$KIBANA_IMAGE" +docker load < "target/kibana-$BASE_VERSION-docker-image-aarch64.tar.gz" +docker tag "$KIBANA_IMAGE" "$KIBANA_IMAGE-arm64" + +echo "--- Push images" +docker image push "$KIBANA_IMAGE-arm64" +docker image push "$KIBANA_IMAGE-amd64" + +echo "--- Create manifest" +docker rmi "$KIBANA_IMAGE" +docker manifest create \ + "$KIBANA_IMAGE" \ + --amend "$KIBANA_IMAGE-arm64" \ + --amend "$KIBANA_IMAGE-amd64" + +echo "--- Push manifest" +docker manifest push "$KIBANA_IMAGE" docker logout docker.elastic.co echo "--- Build dependencies report" diff --git a/.buildkite/scripts/steps/storybooks/build_and_upload.ts b/.buildkite/scripts/steps/storybooks/build_and_upload.ts index d15e15800821a..f56e9bdab8529 100644 --- a/.buildkite/scripts/steps/storybooks/build_and_upload.ts +++ b/.buildkite/scripts/steps/storybooks/build_and_upload.ts @@ -14,6 +14,7 @@ import path from 'path'; const STORYBOOKS = [ 'apm', 'canvas', + 'cases', 'ci_composite', 'cloud_chat', 'coloring', diff --git a/.ci/Dockerfile b/.ci/Dockerfile index 88966aa5062ac..4f5236c733bc3 100644 --- a/.ci/Dockerfile +++ b/.ci/Dockerfile @@ -1,7 +1,7 @@ # NOTE: This Dockerfile is ONLY used to run certain tasks in CI. It is not used to run Kibana or as a distributable. # If you're looking for the Kibana Docker image distributable, please see: src/dev/build/tasks/os_packages/docker_generator/templates/dockerfile.template.ts -ARG NODE_VERSION=16.18.1 +ARG NODE_VERSION=18.13.0 FROM node:${NODE_VERSION} AS base diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 7910259e84122..310371a8cef8e 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -67,65 +67,65 @@ # Global Experience -/src/plugins/bfetch/ @elastic/kibana-global-experience -/src/plugins/files @elastic/kibana-global-experience -/src/plugins/screenshot_mode @elastic/kibana-global-experience -/src/plugins/share/ @elastic/kibana-global-experience -/src/plugins/ui_actions/ @elastic/kibana-global-experience -/src/plugins/ui_actions_enhanced/ @elastic/kibana-global-experience -/src/plugins/navigation/ @elastic/kibana-global-experience -/src/plugins/image_embeddable/ @elastic/kibana-global-experience -/x-pack/plugins/notifications/ @elastic/kibana-global-experience +/src/plugins/bfetch/ @elastic/appex-sharedux +/src/plugins/files @elastic/appex-sharedux +/src/plugins/screenshot_mode @elastic/appex-sharedux +/src/plugins/share/ @elastic/appex-sharedux +/src/plugins/ui_actions/ @elastic/appex-sharedux +/src/plugins/ui_actions_enhanced/ @elastic/appex-sharedux +/src/plugins/navigation/ @elastic/appex-sharedux +/src/plugins/image_embeddable/ @elastic/appex-sharedux +/x-pack/plugins/notifications/ @elastic/appex-sharedux ## Examples -/examples/bfetch_explorer/ @elastic/kibana-global-experience -/examples/files_example @elastic/kibana-global-experience -/examples/state_containers_examples/ @elastic/kibana-global-experience -/examples/ui_action_examples/ @elastic/kibana-global-experience -/examples/ui_actions_explorer/ @elastic/kibana-global-experience -/examples/developer_examples/ @elastic/kibana-global-experience -/x-pack/examples/ui_actions_enhanced_examples/ @elastic/kibana-global-experience +/examples/bfetch_explorer/ @elastic/appex-sharedux +/examples/files_example @elastic/appex-sharedux +/examples/state_containers_examples/ @elastic/appex-sharedux +/examples/ui_action_examples/ @elastic/appex-sharedux +/examples/ui_actions_explorer/ @elastic/appex-sharedux +/examples/developer_examples/ @elastic/appex-sharedux +/x-pack/examples/ui_actions_enhanced_examples/ @elastic/appex-sharedux ### Overview Plugin and Packages -/src/plugins/kibana_overview/ @elastic/kibana-global-experience +/src/plugins/kibana_overview/ @elastic/appex-sharedux ### Global Experience Reporting -/x-pack/examples/reporting_example/ @elastic/kibana-global-experience -/x-pack/examples/screenshotting_example/ @elastic/kibana-global-experience -/x-pack/plugins/reporting/ @elastic/kibana-global-experience -/x-pack/test/functional/apps/dashboard/reporting/ @elastic/kibana-global-experience -/x-pack/test/functional/apps/reporting/ @elastic/kibana-global-experience -/x-pack/test/functional/apps/reporting_management/ @elastic/kibana-global-experience -/x-pack/test/examples/screenshotting/ @elastic/kibana-global-experience -/x-pack/test/functional/es_archives/lens/reporting/ @elastic/kibana-global-experience -/x-pack/test/functional/es_archives/reporting/ @elastic/kibana-global-experience -/x-pack/test/functional/fixtures/kbn_archiver/reporting/ @elastic/kibana-global-experience -/x-pack/test/reporting_api_integration/ @elastic/kibana-global-experience -/x-pack/test/reporting_functional/ @elastic/kibana-global-experience -/x-pack/test/stack_functional_integration/apps/reporting/ @elastic/kibana-global-experience -/docs/user/reporting @elastic/kibana-global-experience -/docs/settings/reporting-settings.asciidoc @elastic/kibana-global-experience -/docs/setup/configuring-reporting.asciidoc @elastic/kibana-global-experience +/x-pack/examples/reporting_example/ @elastic/appex-sharedux +/x-pack/examples/screenshotting_example/ @elastic/appex-sharedux +/x-pack/plugins/reporting/ @elastic/appex-sharedux +/x-pack/test/functional/apps/dashboard/reporting/ @elastic/appex-sharedux +/x-pack/test/functional/apps/reporting/ @elastic/appex-sharedux +/x-pack/test/functional/apps/reporting_management/ @elastic/appex-sharedux +/x-pack/test/examples/screenshotting/ @elastic/appex-sharedux +/x-pack/test/functional/es_archives/lens/reporting/ @elastic/appex-sharedux +/x-pack/test/functional/es_archives/reporting/ @elastic/appex-sharedux +/x-pack/test/functional/fixtures/kbn_archiver/reporting/ @elastic/appex-sharedux +/x-pack/test/reporting_api_integration/ @elastic/appex-sharedux +/x-pack/test/reporting_functional/ @elastic/appex-sharedux +/x-pack/test/stack_functional_integration/apps/reporting/ @elastic/appex-sharedux +/docs/user/reporting @elastic/appex-sharedux +/docs/settings/reporting-settings.asciidoc @elastic/appex-sharedux +/docs/setup/configuring-reporting.asciidoc @elastic/appex-sharedux ### Global Experience Tagging -/src/plugins/saved_objects_tagging_oss @elastic/kibana-global-experience -/x-pack/plugins/saved_objects_tagging/ @elastic/kibana-global-experience -/x-pack/test/saved_object_tagging/ @elastic/kibana-global-experience +/src/plugins/saved_objects_tagging_oss @elastic/appex-sharedux +/x-pack/plugins/saved_objects_tagging/ @elastic/appex-sharedux +/x-pack/test/saved_object_tagging/ @elastic/appex-sharedux ### Kibana React (to be deprecated) -/src/plugins/kibana_react/ @elastic/kibana-global-experience -/src/plugins/kibana_react/public/code_editor @elastic/kibana-global-experience @elastic/kibana-presentation +/src/plugins/kibana_react/ @elastic/appex-sharedux +/src/plugins/kibana_react/public/code_editor @elastic/appex-sharedux @elastic/kibana-presentation ### Home Plugin and Packages -/src/plugins/home/public @elastic/kibana-global-experience -/src/plugins/home/server/*.ts @elastic/kibana-global-experience -/src/plugins/home/server/services/ @elastic/kibana-global-experience +/src/plugins/home/public @elastic/appex-sharedux +/src/plugins/home/server/*.ts @elastic/appex-sharedux +/src/plugins/home/server/services/ @elastic/appex-sharedux ### Code Coverage -#CC# /src/plugins/home/public @elastic/kibana-global-experience -#CC# /src/plugins/home/server/services/ @elastic/kibana-global-experience -#CC# /src/plugins/home/ @elastic/kibana-global-experience -#CC# /x-pack/plugins/reporting/ @elastic/kibana-global-experience +#CC# /src/plugins/home/public @elastic/appex-sharedux +#CC# /src/plugins/home/server/services/ @elastic/appex-sharedux +#CC# /src/plugins/home/ @elastic/appex-sharedux +#CC# /x-pack/plugins/reporting/ @elastic/appex-sharedux ### Observability Plugins @@ -674,7 +674,7 @@ x-pack/test/threat_intelligence_cypress @elastic/protections-experience #CC# /x-pack/plugins/logstash/ @elastic/logstash # EUI design -/src/plugins/kibana_react/public/page_template/ @elastic/eui-design @elastic/kibana-global-experience +/src/plugins/kibana_react/public/page_template/ @elastic/eui-design @elastic/appex-sharedux # Application Experience @@ -694,8 +694,8 @@ packages/analytics/shippers/elastic_v3/common @elastic/kibana-core packages/analytics/shippers/elastic_v3/server @elastic/kibana-core packages/analytics/shippers/fullstory @elastic/kibana-core packages/analytics/shippers/gainsight @elastic/kibana-core -packages/content-management/content_editor @elastic/kibana-global-experience -packages/content-management/table_list @elastic/kibana-global-experience +packages/content-management/content_editor @elastic/appex-sharedux +packages/content-management/table_list @elastic/appex-sharedux packages/core/analytics/core-analytics-browser @elastic/kibana-core packages/core/analytics/core-analytics-browser-internal @elastic/kibana-core packages/core/analytics/core-analytics-browser-mocks @elastic/kibana-core @@ -725,13 +725,13 @@ packages/core/chrome/core-chrome-browser @elastic/kibana-core packages/core/chrome/core-chrome-browser-internal @elastic/kibana-core packages/core/chrome/core-chrome-browser-mocks @elastic/kibana-core packages/core/config/core-config-server-internal @elastic/kibana-core -packages/core/custom-branding/core-custom-branding-browser @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-browser-internal @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-browser-mocks @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-common @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-server @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-server-internal @elastic/kibana-global-experience -packages/core/custom-branding/core-custom-branding-server-mocks @elastic/kibana-global-experience +packages/core/custom-branding/core-custom-branding-browser @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-browser-internal @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-browser-mocks @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-common @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-server @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-server-internal @elastic/appex-sharedux +packages/core/custom-branding/core-custom-branding-server-mocks @elastic/appex-sharedux packages/core/deprecations/core-deprecations-browser @elastic/kibana-core packages/core/deprecations/core-deprecations-browser-internal @elastic/kibana-core packages/core/deprecations/core-deprecations-browser-mocks @elastic/kibana-core @@ -875,9 +875,9 @@ packages/core/usage-data/core-usage-data-base-server-internal @elastic/kibana-co packages/core/usage-data/core-usage-data-server @elastic/kibana-core packages/core/usage-data/core-usage-data-server-internal @elastic/kibana-core packages/core/usage-data/core-usage-data-server-mocks @elastic/kibana-core -packages/home/sample_data_card @elastic/kibana-global-experience -packages/home/sample_data_tab @elastic/kibana-global-experience -packages/home/sample_data_types @elastic/kibana-global-experience +packages/home/sample_data_card @elastic/appex-sharedux +packages/home/sample_data_tab @elastic/appex-sharedux +packages/home/sample_data_types @elastic/appex-sharedux packages/kbn-ace @elastic/platform-deployment-management packages/kbn-alerts @elastic/security-solution packages/kbn-ambient-common-types @elastic/kibana-operations @@ -896,6 +896,7 @@ packages/kbn-babel-register @elastic/kibana-operations packages/kbn-babel-transform @elastic/kibana-operations packages/kbn-bazel-runner @elastic/kibana-operations packages/kbn-cases-components @elastic/response-ops +packages/kbn-cell-actions @elastic/security-threat-hunting-explore packages/kbn-chart-icons @elastic/kibana-visualizations packages/kbn-ci-stats-core @elastic/kibana-operations packages/kbn-ci-stats-performance-metrics @elastic/kibana-operations @@ -908,7 +909,7 @@ packages/kbn-config-schema @elastic/kibana-core packages/kbn-crypto @elastic/kibana-security packages/kbn-crypto-browser @elastic/kibana-core packages/kbn-cypress-config @elastic/kibana-operations -packages/kbn-datemath @elastic/kibana-app-services +packages/kbn-datemath @elastic/kibana-data-discovery packages/kbn-dev-cli-errors @elastic/kibana-operations packages/kbn-dev-cli-runner @elastic/kibana-operations packages/kbn-dev-proc-runner @elastic/kibana-operations @@ -920,7 +921,7 @@ packages/kbn-ecs @elastic/kibana-core packages/kbn-es @elastic/kibana-operations packages/kbn-es-archiver @elastic/kibana-operations packages/kbn-es-errors @elastic/kibana-core -packages/kbn-es-query @elastic/kibana-app-services +packages/kbn-es-query @elastic/kibana-data-discovery packages/kbn-es-types @elastic/kibana-core @elastic/apm-ui packages/kbn-eslint-config @elastic/kibana-operations packages/kbn-eslint-plugin-disable @elastic/kibana-operations @@ -928,7 +929,7 @@ packages/kbn-eslint-plugin-eslint @elastic/kibana-operations packages/kbn-eslint-plugin-imports @elastic/kibana-operations packages/kbn-expect @elastic/kibana-operations packages/kbn-failed-test-reporter-cli @elastic/kibana-operations -packages/kbn-field-types @elastic/kibana-app-services +packages/kbn-field-types @elastic/kibana-data-discovery packages/kbn-find-used-node-modules @elastic/kibana-operations packages/kbn-flot-charts @elastic/kibana-operations packages/kbn-ftr-common-functional-services @elastic/kibana-operations @@ -957,7 +958,7 @@ packages/kbn-logging-mocks @elastic/kibana-core packages/kbn-managed-vscode-config @elastic/kibana-operations packages/kbn-managed-vscode-config-cli @elastic/kibana-operations packages/kbn-mapbox-gl @elastic/kibana-gis -packages/kbn-monaco @elastic/kibana-global-experience +packages/kbn-monaco @elastic/appex-sharedux packages/kbn-optimizer @elastic/kibana-operations packages/kbn-optimizer-webpack-helpers @elastic/kibana-operations packages/kbn-osquery-io-ts-types @elastic/security-asset-management @@ -968,7 +969,7 @@ packages/kbn-picomatcher @elastic/kibana-operations packages/kbn-plugin-discovery @elastic/kibana-operations packages/kbn-plugin-generator @elastic/kibana-operations packages/kbn-plugin-helpers @elastic/kibana-operations -packages/kbn-react-field @elastic/kibana-app-services +packages/kbn-react-field @elastic/kibana-data-discovery packages/kbn-repo-file-maps @elastic/kibana-operations packages/kbn-repo-info @elastic/kibana-operations packages/kbn-repo-linter @elastic/kibana-operations @@ -998,7 +999,7 @@ packages/kbn-server-http-tools @elastic/kibana-core packages/kbn-server-route-repository @elastic/apm-ui packages/kbn-set-map @elastic/kibana-operations packages/kbn-shared-svg @elastic/apm-ui -packages/kbn-shared-ux-utility @elastic/kibana-global-experience +packages/kbn-shared-ux-utility @elastic/appex-sharedux packages/kbn-slo-schema @elastic/actionable-observability packages/kbn-some-dev-log @elastic/kibana-operations packages/kbn-sort-package-json @elastic/kibana-operations @@ -1016,6 +1017,7 @@ packages/kbn-tooling-log @elastic/kibana-operations packages/kbn-ts-projects @elastic/kibana-operations packages/kbn-ts-type-check-cli @elastic/kibana-operations packages/kbn-typed-react-router-config @elastic/apm-ui +packages/kbn-ui-actions-browser @elastic/appex-sharedux packages/kbn-ui-framework @elastic/kibana-design packages/kbn-ui-shared-deps-npm @elastic/kibana-operations packages/kbn-ui-shared-deps-src @elastic/kibana-operations @@ -1027,54 +1029,54 @@ packages/kbn-utils @elastic/kibana-operations packages/kbn-web-worker-stub @elastic/kibana-operations packages/kbn-whereis-pkg-cli @elastic/kibana-operations packages/kbn-yarn-lock-validator @elastic/kibana-operations -packages/shared-ux/avatar/solution @elastic/kibana-global-experience -packages/shared-ux/avatar/user_profile/impl @elastic/kibana-global-experience -packages/shared-ux/button_toolbar @elastic/kibana-global-experience -packages/shared-ux/button/exit_full_screen/impl @elastic/kibana-global-experience -packages/shared-ux/button/exit_full_screen/mocks @elastic/kibana-global-experience -packages/shared-ux/button/exit_full_screen/types @elastic/kibana-global-experience -packages/shared-ux/card/no_data/impl @elastic/kibana-global-experience -packages/shared-ux/card/no_data/mocks @elastic/kibana-global-experience -packages/shared-ux/card/no_data/types @elastic/kibana-global-experience -packages/shared-ux/file/context @elastic/kibana-global-experience -packages/shared-ux/file/file_picker/impl @elastic/kibana-global-experience -packages/shared-ux/file/file_upload/impl @elastic/kibana-global-experience -packages/shared-ux/file/image/impl @elastic/kibana-global-experience -packages/shared-ux/file/image/mocks @elastic/kibana-global-experience -packages/shared-ux/file/mocks @elastic/kibana-global-experience -packages/shared-ux/file/types @elastic/kibana-global-experience -packages/shared-ux/file/util @elastic/kibana-global-experience -packages/shared-ux/link/redirect_app/impl @elastic/kibana-global-experience -packages/shared-ux/link/redirect_app/mocks @elastic/kibana-global-experience -packages/shared-ux/link/redirect_app/types @elastic/kibana-global-experience -packages/shared-ux/markdown/impl @elastic/kibana-global-experience -packages/shared-ux/markdown/mocks @elastic/kibana-global-experience -packages/shared-ux/markdown/types @elastic/kibana-global-experience -packages/shared-ux/page/analytics_no_data/impl @elastic/kibana-global-experience -packages/shared-ux/page/analytics_no_data/mocks @elastic/kibana-global-experience -packages/shared-ux/page/analytics_no_data/types @elastic/kibana-global-experience -packages/shared-ux/page/kibana_no_data/impl @elastic/kibana-global-experience -packages/shared-ux/page/kibana_no_data/mocks @elastic/kibana-global-experience -packages/shared-ux/page/kibana_no_data/types @elastic/kibana-global-experience -packages/shared-ux/page/kibana_template/impl @elastic/kibana-global-experience -packages/shared-ux/page/kibana_template/mocks @elastic/kibana-global-experience -packages/shared-ux/page/kibana_template/types @elastic/kibana-global-experience -packages/shared-ux/page/no_data_config/impl @elastic/kibana-global-experience -packages/shared-ux/page/no_data_config/mocks @elastic/kibana-global-experience -packages/shared-ux/page/no_data_config/types @elastic/kibana-global-experience -packages/shared-ux/page/no_data/impl @elastic/kibana-global-experience -packages/shared-ux/page/no_data/mocks @elastic/kibana-global-experience -packages/shared-ux/page/no_data/types @elastic/kibana-global-experience -packages/shared-ux/page/solution_nav @elastic/kibana-global-experience -packages/shared-ux/prompt/no_data_views/impl @elastic/kibana-global-experience -packages/shared-ux/prompt/no_data_views/mocks @elastic/kibana-global-experience -packages/shared-ux/prompt/no_data_views/types @elastic/kibana-global-experience -packages/shared-ux/prompt/not_found @elastic/kibana-global-experience -packages/shared-ux/router/impl @elastic/kibana-global-experience -packages/shared-ux/router/mocks @elastic/kibana-global-experience -packages/shared-ux/router/types @elastic/kibana-global-experience -packages/shared-ux/storybook/config @elastic/kibana-global-experience -packages/shared-ux/storybook/mock @elastic/kibana-global-experience +packages/shared-ux/avatar/solution @elastic/appex-sharedux +packages/shared-ux/avatar/user_profile/impl @elastic/appex-sharedux +packages/shared-ux/button_toolbar @elastic/appex-sharedux +packages/shared-ux/button/exit_full_screen/impl @elastic/appex-sharedux +packages/shared-ux/button/exit_full_screen/mocks @elastic/appex-sharedux +packages/shared-ux/button/exit_full_screen/types @elastic/appex-sharedux +packages/shared-ux/card/no_data/impl @elastic/appex-sharedux +packages/shared-ux/card/no_data/mocks @elastic/appex-sharedux +packages/shared-ux/card/no_data/types @elastic/appex-sharedux +packages/shared-ux/file/context @elastic/appex-sharedux +packages/shared-ux/file/file_picker/impl @elastic/appex-sharedux +packages/shared-ux/file/file_upload/impl @elastic/appex-sharedux +packages/shared-ux/file/image/impl @elastic/appex-sharedux +packages/shared-ux/file/image/mocks @elastic/appex-sharedux +packages/shared-ux/file/mocks @elastic/appex-sharedux +packages/shared-ux/file/types @elastic/appex-sharedux +packages/shared-ux/file/util @elastic/appex-sharedux +packages/shared-ux/link/redirect_app/impl @elastic/appex-sharedux +packages/shared-ux/link/redirect_app/mocks @elastic/appex-sharedux +packages/shared-ux/link/redirect_app/types @elastic/appex-sharedux +packages/shared-ux/markdown/impl @elastic/appex-sharedux +packages/shared-ux/markdown/mocks @elastic/appex-sharedux +packages/shared-ux/markdown/types @elastic/appex-sharedux +packages/shared-ux/page/analytics_no_data/impl @elastic/appex-sharedux +packages/shared-ux/page/analytics_no_data/mocks @elastic/appex-sharedux +packages/shared-ux/page/analytics_no_data/types @elastic/appex-sharedux +packages/shared-ux/page/kibana_no_data/impl @elastic/appex-sharedux +packages/shared-ux/page/kibana_no_data/mocks @elastic/appex-sharedux +packages/shared-ux/page/kibana_no_data/types @elastic/appex-sharedux +packages/shared-ux/page/kibana_template/impl @elastic/appex-sharedux +packages/shared-ux/page/kibana_template/mocks @elastic/appex-sharedux +packages/shared-ux/page/kibana_template/types @elastic/appex-sharedux +packages/shared-ux/page/no_data_config/impl @elastic/appex-sharedux +packages/shared-ux/page/no_data_config/mocks @elastic/appex-sharedux +packages/shared-ux/page/no_data_config/types @elastic/appex-sharedux +packages/shared-ux/page/no_data/impl @elastic/appex-sharedux +packages/shared-ux/page/no_data/mocks @elastic/appex-sharedux +packages/shared-ux/page/no_data/types @elastic/appex-sharedux +packages/shared-ux/page/solution_nav @elastic/appex-sharedux +packages/shared-ux/prompt/no_data_views/impl @elastic/appex-sharedux +packages/shared-ux/prompt/no_data_views/mocks @elastic/appex-sharedux +packages/shared-ux/prompt/no_data_views/types @elastic/appex-sharedux +packages/shared-ux/prompt/not_found @elastic/appex-sharedux +packages/shared-ux/router/impl @elastic/appex-sharedux +packages/shared-ux/router/mocks @elastic/appex-sharedux +packages/shared-ux/router/types @elastic/appex-sharedux +packages/shared-ux/storybook/config @elastic/appex-sharedux +packages/shared-ux/storybook/mock @elastic/appex-sharedux src/plugins/chart_expressions/common @elastic/kibana-visualizations x-pack/packages/ml/agg_utils @elastic/ml-ui x-pack/packages/ml/aiops_components @elastic/ml-ui diff --git a/.i18nrc.json b/.i18nrc.json index 3c95e9b514484..319c3e45aca47 100644 --- a/.i18nrc.json +++ b/.i18nrc.json @@ -6,6 +6,7 @@ "autocomplete": "packages/kbn-securitysolution-autocomplete/src", "bfetch": "src/plugins/bfetch", "cases": ["packages/kbn-cases-components"], + "cellActions": "packages/kbn-cell-actions", "charts": "src/plugins/charts", "console": "src/plugins/console", "contentManagement": "packages/content-management", diff --git a/.node-version b/.node-version index 5397c87fabfd3..d939939b25962 100644 --- a/.node-version +++ b/.node-version @@ -1 +1 @@ -16.18.1 +18.13.0 diff --git a/.nvmrc b/.nvmrc index 5397c87fabfd3..d939939b25962 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -16.18.1 +18.13.0 diff --git a/WORKSPACE.bazel b/WORKSPACE.bazel index 0a7f9596abdd8..2e0916692591a 100644 --- a/WORKSPACE.bazel +++ b/WORKSPACE.bazel @@ -22,13 +22,13 @@ load("@build_bazel_rules_nodejs//:index.bzl", "node_repositories", "yarn_install # Setup the Node.js toolchain for the architectures we want to support node_repositories( node_repositories = { - "16.18.1-darwin_amd64": ("node-v16.18.1-darwin-x64.tar.gz", "node-v16.18.1-darwin-x64", "c190e106d4ac6177d1db3a5a739d39dd68bd276ba17f3d3c84039a93717e081e"), - "16.18.1-darwin_arm64": ("node-v16.18.1-darwin-arm64.tar.gz", "node-v16.18.1-darwin-arm64", "71720bb0a80cf158d8fdf492def08048befd953ad45e2458b1d095e32c612ba7"), - "16.18.1-linux_arm64": ("node-v16.18.1-linux-arm64.tar.xz", "node-v16.18.1-linux-arm64", "98d81a2d08f88646541d282b7ccc32429f8706ddcb30943fc3779ef9674ebb93"), - "16.18.1-linux_amd64": ("node-v16.18.1-linux-x64.tar.xz", "node-v16.18.1-linux-x64", "de2c694e7081c37022817d27a65b02f69ecf4c49699d65585e8e24431b7bc920"), - "16.18.1-windows_amd64": ("node-v16.18.1-win-x64.zip", "node-v16.18.1-win-x64", "db6a81de8e8ca3444495f1bcf04a883c076b4325d0fbaa032a190f88b38b30c5"), + "18.13.0-darwin_amd64": ("node-v18.13.0-darwin-x64.tar.gz", "node-v18.13.0-darwin-x64", "8b57c4da4ff6cca19d5ef7953f8816e3406d1508a2e4ee7f997984b3b1d11b77"), + "18.13.0-darwin_arm64": ("node-v18.13.0-darwin-arm64.tar.gz", "node-v18.13.0-darwin-arm64", "418d535e64dbcbd628715180c2de4ffcecb8a84b81f233c60e6ab9f0d795c249"), + "18.13.0-linux_arm64": ("node-v18.13.0-linux-arm64.tar.xz", "node-v18.13.0-linux-arm64", "5b338667822341d1ea3b18d5b37d442a655829b9eafdc5f9008f00b8451ac148"), + "18.13.0-linux_amd64": ("node-v18.13.0-linux-x64.tar.xz", "node-v18.13.0-linux-x64", "7f5d6922a91986ef059ba8a4396aa435440adacfe6fc6fab60a857c8f2cf5e7a"), + "18.13.0-windows_amd64": ("node-v18.13.0-win-x64.zip", "node-v18.13.0-win-x64", "29c99ad1167ddbd72f2b15e91b560e36ac785b1873ba6791ab50d9d62f1957e2"), }, - node_version = "16.18.1", + node_version = "18.13.0", node_urls = [ "https://nodejs.org/dist/v{version}/{filename}", ], diff --git a/api_docs/actions.mdx b/api_docs/actions.mdx index 22458142df3e2..882757a213a9f 100644 --- a/api_docs/actions.mdx +++ b/api_docs/actions.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/actions title: "actions" image: https://source.unsplash.com/400x175/?github description: API docs for the actions plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'actions'] --- import actionsObj from './actions.devdocs.json'; diff --git a/api_docs/advanced_settings.mdx b/api_docs/advanced_settings.mdx index 7fb6230346bc9..d502783f4a86b 100644 --- a/api_docs/advanced_settings.mdx +++ b/api_docs/advanced_settings.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/advancedSettings title: "advancedSettings" image: https://source.unsplash.com/400x175/?github description: API docs for the advancedSettings plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'advancedSettings'] --- import advancedSettingsObj from './advanced_settings.devdocs.json'; diff --git a/api_docs/aiops.mdx b/api_docs/aiops.mdx index 729ef85c549c1..b7fca969b6214 100644 --- a/api_docs/aiops.mdx +++ b/api_docs/aiops.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/aiops title: "aiops" image: https://source.unsplash.com/400x175/?github description: API docs for the aiops plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'aiops'] --- import aiopsObj from './aiops.devdocs.json'; diff --git a/api_docs/alerting.devdocs.json b/api_docs/alerting.devdocs.json index 83f0ad7016c38..f3f981432d60d 100644 --- a/api_docs/alerting.devdocs.json +++ b/api_docs/alerting.devdocs.json @@ -1054,6 +1054,23 @@ "children": [], "returnComment": [] }, + { + "parentPluginId": "alerting", + "id": "def-server.AlertingApiRequestHandlerContext.getRulesSettingsClient", + "type": "Function", + "tags": [], + "label": "getRulesSettingsClient", + "description": [], + "signature": [ + "() => ", + "RulesSettingsClient" + ], + "path": "x-pack/plugins/alerting/server/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, { "parentPluginId": "alerting", "id": "def-server.AlertingApiRequestHandlerContext.listTypes", @@ -5906,7 +5923,7 @@ "label": "status", "description": [], "signature": [ - "\"error\" | \"warning\" | \"unknown\" | \"pending\" | \"active\" | \"ok\"" + "\"error\" | \"warning\" | \"unknown\" | \"pending\" | \"ok\" | \"active\"" ], "path": "x-pack/plugins/alerting/common/rule.ts", "deprecated": false, @@ -6549,6 +6566,159 @@ ], "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettings", + "type": "Interface", + "tags": [], + "label": "RulesSettings", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettings.flapping", + "type": "CompoundType", + "tags": [], + "label": "flapping", + "description": [], + "signature": [ + { + "pluginId": "alerting", + "scope": "common", + "docId": "kibAlertingPluginApi", + "section": "def-common.RulesSettingsFlappingProperties", + "text": "RulesSettingsFlappingProperties" + }, + " & ", + { + "pluginId": "alerting", + "scope": "common", + "docId": "kibAlertingPluginApi", + "section": "def-common.RulesSettingsModificationMetadata", + "text": "RulesSettingsModificationMetadata" + } + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsFlappingProperties", + "type": "Interface", + "tags": [], + "label": "RulesSettingsFlappingProperties", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsFlappingProperties.enabled", + "type": "boolean", + "tags": [], + "label": "enabled", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsFlappingProperties.lookBackWindow", + "type": "number", + "tags": [], + "label": "lookBackWindow", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsFlappingProperties.statusChangeThreshold", + "type": "number", + "tags": [], + "label": "statusChangeThreshold", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsModificationMetadata", + "type": "Interface", + "tags": [], + "label": "RulesSettingsModificationMetadata", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsModificationMetadata.createdBy", + "type": "CompoundType", + "tags": [], + "label": "createdBy", + "description": [], + "signature": [ + "string | null" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsModificationMetadata.updatedBy", + "type": "CompoundType", + "tags": [], + "label": "updatedBy", + "description": [], + "signature": [ + "string | null" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsModificationMetadata.createdAt", + "type": "string", + "tags": [], + "label": "createdAt", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsModificationMetadata.updatedAt", + "type": "string", + "tags": [], + "label": "updatedAt", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.RuleStateNavigation", @@ -7027,6 +7197,21 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID", + "type": "string", + "tags": [], + "label": "ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID", + "description": [], + "signature": [ + "\"allFlappingSettings\"" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.BASE_ALERTING_API_PATH", @@ -7057,6 +7242,36 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_LOOK_BACK_WINDOW", + "type": "number", + "tags": [], + "label": "DEFAULT_LOOK_BACK_WINDOW", + "description": [], + "signature": [ + "20" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_STATUS_CHANGE_THRESHOLD", + "type": "number", + "tags": [], + "label": "DEFAULT_STATUS_CHANGE_THRESHOLD", + "description": [], + "signature": [ + "4" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.DefaultActionGroupId", @@ -7176,6 +7391,66 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.MAX_LOOK_BACK_WINDOW", + "type": "number", + "tags": [], + "label": "MAX_LOOK_BACK_WINDOW", + "description": [], + "signature": [ + "20" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.MAX_STATUS_CHANGE_THRESHOLD", + "type": "number", + "tags": [], + "label": "MAX_STATUS_CHANGE_THRESHOLD", + "description": [], + "signature": [ + "20" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.MIN_LOOK_BACK_WINDOW", + "type": "number", + "tags": [], + "label": "MIN_LOOK_BACK_WINDOW", + "description": [], + "signature": [ + "2" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.MIN_STATUS_CHANGE_THRESHOLD", + "type": "number", + "tags": [], + "label": "MIN_STATUS_CHANGE_THRESHOLD", + "description": [], + "signature": [ + "2" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.MONITORING_HISTORY_LIMIT", @@ -7206,6 +7481,21 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.READ_FLAPPING_SETTINGS_SUB_FEATURE_ID", + "type": "string", + "tags": [], + "label": "READ_FLAPPING_SETTINGS_SUB_FEATURE_ID", + "description": [], + "signature": [ + "\"readFlappingSettings\"" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.RecoveredActionGroupId", @@ -7340,7 +7630,7 @@ "label": "RuleExecutionStatuses", "description": [], "signature": [ - "\"error\" | \"warning\" | \"unknown\" | \"pending\" | \"active\" | \"ok\"" + "\"error\" | \"warning\" | \"unknown\" | \"pending\" | \"ok\" | \"active\"" ], "path": "x-pack/plugins/alerting/common/rule.ts", "deprecated": false, @@ -7406,6 +7696,51 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.RULES_SETTINGS_FEATURE_ID", + "type": "string", + "tags": [], + "label": "RULES_SETTINGS_FEATURE_ID", + "description": [], + "signature": [ + "\"rulesSettings\"" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RULES_SETTINGS_SAVED_OBJECT_ID", + "type": "string", + "tags": [], + "label": "RULES_SETTINGS_SAVED_OBJECT_ID", + "description": [], + "signature": [ + "\"rules-settings\"" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.RULES_SETTINGS_SAVED_OBJECT_TYPE", + "type": "string", + "tags": [], + "label": "RULES_SETTINGS_SAVED_OBJECT_TYPE", + "description": [], + "signature": [ + "\"rules-settings\"" + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.RuleSnooze", @@ -7421,6 +7756,35 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "alerting", + "id": "def-common.RulesSettingsFlapping", + "type": "Type", + "tags": [], + "label": "RulesSettingsFlapping", + "description": [], + "signature": [ + { + "pluginId": "alerting", + "scope": "common", + "docId": "kibAlertingPluginApi", + "section": "def-common.RulesSettingsFlappingProperties", + "text": "RulesSettingsFlappingProperties" + }, + " & ", + { + "pluginId": "alerting", + "scope": "common", + "docId": "kibAlertingPluginApi", + "section": "def-common.RulesSettingsModificationMetadata", + "text": "RulesSettingsModificationMetadata" + } + ], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.RuleStatusValues", @@ -7630,6 +7994,89 @@ } ], "objects": [ + { + "parentPluginId": "alerting", + "id": "def-common.API_PRIVILEGES", + "type": "Object", + "tags": [], + "label": "API_PRIVILEGES", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "alerting", + "id": "def-common.API_PRIVILEGES.READ_FLAPPING_SETTINGS", + "type": "string", + "tags": [], + "label": "READ_FLAPPING_SETTINGS", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.API_PRIVILEGES.WRITE_FLAPPING_SETTINGS", + "type": "string", + "tags": [], + "label": "WRITE_FLAPPING_SETTINGS", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_FLAPPING_SETTINGS", + "type": "Object", + "tags": [], + "label": "DEFAULT_FLAPPING_SETTINGS", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_FLAPPING_SETTINGS.enabled", + "type": "boolean", + "tags": [], + "label": "enabled", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_FLAPPING_SETTINGS.lookBackWindow", + "type": "number", + "tags": [], + "label": "lookBackWindow", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "alerting", + "id": "def-common.DEFAULT_FLAPPING_SETTINGS.statusChangeThreshold", + "type": "number", + "tags": [], + "label": "statusChangeThreshold", + "description": [], + "path": "x-pack/plugins/alerting/common/rules_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "alerting", "id": "def-common.DisabledActionTypeIdsForActionGroup", diff --git a/api_docs/alerting.mdx b/api_docs/alerting.mdx index f16e15e18e7dd..4b8d8e6b88320 100644 --- a/api_docs/alerting.mdx +++ b/api_docs/alerting.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/alerting title: "alerting" image: https://source.unsplash.com/400x175/?github description: API docs for the alerting plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'alerting'] --- import alertingObj from './alerting.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Response Ops](https://github.com/orgs/elastic/teams/response-ops) for q | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 434 | 0 | 425 | 37 | +| 465 | 0 | 456 | 38 | ## Client diff --git a/api_docs/apm.devdocs.json b/api_docs/apm.devdocs.json index f54c208941119..c56b5f9550718 100644 --- a/api_docs/apm.devdocs.json +++ b/api_docs/apm.devdocs.json @@ -810,7 +810,7 @@ "label": "APIEndpoint", "description": [], "signature": [ - "\"POST /internal/apm/data_view/static\" | \"GET /internal/apm/data_view/title\" | \"GET /internal/apm/environments\" | \"GET /internal/apm/services/{serviceName}/errors/groups/main_statistics\" | \"GET /internal/apm/services/{serviceName}/errors/groups/main_statistics_by_transaction_name\" | \"POST /internal/apm/services/{serviceName}/errors/groups/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/samples\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/error/{errorId}\" | \"GET /internal/apm/services/{serviceName}/errors/distribution\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/top_erroneous_transactions\" | \"POST /internal/apm/latency/overall_distribution/transactions\" | \"GET /internal/apm/services/{serviceName}/metrics/charts\" | \"GET /internal/apm/services/{serviceName}/metrics/nodes\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/charts\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/summary\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/functions_overview\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/active_instances\" | \"GET /internal/apm/observability_overview\" | \"GET /internal/apm/observability_overview/has_data\" | \"GET /internal/apm/service-map\" | \"GET /internal/apm/service-map/service/{serviceName}\" | \"GET /internal/apm/service-map/dependency\" | \"GET /internal/apm/services\" | \"POST /internal/apm/services/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/metadata/details\" | \"GET /internal/apm/services/{serviceName}/metadata/icons\" | \"GET /internal/apm/services/{serviceName}/agent\" | \"GET /internal/apm/services/{serviceName}/transaction_types\" | \"GET /internal/apm/services/{serviceName}/node/{serviceNodeName}/metadata\" | \"GET /api/apm/services/{serviceName}/annotation/search\" | \"POST /api/apm/services/{serviceName}/annotation\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/details/{serviceNodeName}\" | \"GET /internal/apm/services/{serviceName}/throughput\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/main_statistics\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/dependencies\" | \"GET /internal/apm/services/{serviceName}/dependencies/breakdown\" | \"GET /internal/apm/services/{serviceName}/anomaly_charts\" | \"GET /internal/apm/sorted_and_filtered_services\" | \"GET /internal/apm/services/{serviceName}/alerts_count\" | \"GET /internal/apm/service-groups\" | \"GET /internal/apm/service-group\" | \"POST /internal/apm/service-group\" | \"DELETE /internal/apm/service-group\" | \"GET /internal/apm/service-group/services\" | \"GET /internal/apm/service-group/counts\" | \"GET /internal/apm/suggestions\" | \"GET /internal/apm/traces/{traceId}\" | \"GET /internal/apm/traces\" | \"GET /internal/apm/traces/{traceId}/root_transaction\" | \"GET /internal/apm/transactions/{transactionId}\" | \"GET /internal/apm/traces/find\" | \"POST /internal/apm/traces/aggregated_critical_path\" | \"GET /internal/apm/traces/{traceId}/transactions/{transactionId}\" | \"GET /internal/apm/traces/{traceId}/spans/{spanId}\" | \"GET /internal/apm/services/{serviceName}/transactions/groups/main_statistics\" | \"GET /internal/apm/services/{serviceName}/transactions/groups/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/latency\" | \"GET /internal/apm/services/{serviceName}/transactions/traces/samples\" | \"GET /internal/apm/services/{serviceName}/transaction/charts/breakdown\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/error_rate\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/coldstart_rate\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/coldstart_rate_by_transaction_name\" | \"GET /internal/apm/rule_types/transaction_error_rate/chart_preview\" | \"GET /internal/apm/rule_types/transaction_duration/chart_preview\" | \"GET /internal/apm/rule_types/error_count/chart_preview\" | \"GET /api/apm/settings/agent-configuration\" | \"GET /api/apm/settings/agent-configuration/view\" | \"DELETE /api/apm/settings/agent-configuration\" | \"PUT /api/apm/settings/agent-configuration\" | \"POST /api/apm/settings/agent-configuration/search\" | \"GET /api/apm/settings/agent-configuration/environments\" | \"GET /api/apm/settings/agent-configuration/agent_name\" | \"GET /internal/apm/settings/anomaly-detection/jobs\" | \"POST /internal/apm/settings/anomaly-detection/jobs\" | \"GET /internal/apm/settings/anomaly-detection/environments\" | \"POST /internal/apm/settings/anomaly-detection/update_to_v3\" | \"GET /internal/apm/settings/apm-index-settings\" | \"GET /internal/apm/settings/apm-indices\" | \"POST /internal/apm/settings/apm-indices/save\" | \"GET /internal/apm/settings/custom_links/transaction\" | \"GET /internal/apm/settings/custom_links\" | \"POST /internal/apm/settings/custom_links\" | \"PUT /internal/apm/settings/custom_links/{id}\" | \"DELETE /internal/apm/settings/custom_links/{id}\" | \"GET /api/apm/sourcemaps\" | \"POST /api/apm/sourcemaps\" | \"DELETE /api/apm/sourcemaps/{id}\" | \"POST /internal/apm/sourcemaps/migrate_fleet_artifacts\" | \"GET /internal/apm/fleet/has_apm_policies\" | \"GET /internal/apm/fleet/agents\" | \"POST /api/apm/fleet/apm_server_schema\" | \"GET /internal/apm/fleet/apm_server_schema/unsupported\" | \"GET /internal/apm/fleet/migration_check\" | \"POST /internal/apm/fleet/cloud_apm_package_policy\" | \"GET /internal/apm/fleet/java_agent_versions\" | \"GET /internal/apm/dependencies/top_dependencies\" | \"GET /internal/apm/dependencies/upstream_services\" | \"GET /internal/apm/dependencies/metadata\" | \"GET /internal/apm/dependencies/charts/latency\" | \"GET /internal/apm/dependencies/charts/throughput\" | \"GET /internal/apm/dependencies/charts/error_rate\" | \"GET /internal/apm/dependencies/operations\" | \"GET /internal/apm/dependencies/charts/distribution\" | \"GET /internal/apm/dependencies/operations/spans\" | \"GET /internal/apm/correlations/field_candidates/transactions\" | \"GET /internal/apm/correlations/field_value_stats/transactions\" | \"POST /internal/apm/correlations/field_value_pairs/transactions\" | \"POST /internal/apm/correlations/significant_correlations/transactions\" | \"POST /internal/apm/correlations/p_values/transactions\" | \"GET /internal/apm/fallback_to_transactions\" | \"GET /internal/apm/has_data\" | \"GET /internal/apm/event_metadata/{processorEvent}/{id}\" | \"GET /internal/apm/agent_keys\" | \"GET /internal/apm/agent_keys/privileges\" | \"POST /internal/apm/api_key/invalidate\" | \"POST /api/apm/agent_keys\" | \"GET /internal/apm/storage_explorer\" | \"GET /internal/apm/services/{serviceName}/storage_details\" | \"GET /internal/apm/storage_chart\" | \"GET /internal/apm/storage_explorer/privileges\" | \"GET /internal/apm/storage_explorer_summary_stats\" | \"GET /internal/apm/storage_explorer/is_cross_cluster_search\" | \"GET /internal/apm/storage_explorer/get_services\" | \"GET /internal/apm/traces/{traceId}/span_links/{spanId}/parents\" | \"GET /internal/apm/traces/{traceId}/span_links/{spanId}/children\" | \"GET /internal/apm/services/{serviceName}/infrastructure_attributes\" | \"GET /internal/apm/debug-telemetry\" | \"GET /internal/apm/time_range_metadata\" | \"GET /internal/apm/settings/labs\" | \"GET /internal/apm/get_agents_per_service\" | \"GET /internal/apm/services/{serviceName}/agent_instances\" | \"GET /internal/apm/services/{serviceName}/mobile/filters\" | \"GET /internal/apm/mobile-services/{serviceName}/stats\"" + "\"POST /internal/apm/data_view/static\" | \"GET /internal/apm/data_view/title\" | \"GET /internal/apm/environments\" | \"GET /internal/apm/services/{serviceName}/errors/groups/main_statistics\" | \"GET /internal/apm/services/{serviceName}/errors/groups/main_statistics_by_transaction_name\" | \"POST /internal/apm/services/{serviceName}/errors/groups/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/samples\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/error/{errorId}\" | \"GET /internal/apm/services/{serviceName}/errors/distribution\" | \"GET /internal/apm/services/{serviceName}/errors/{groupId}/top_erroneous_transactions\" | \"POST /internal/apm/latency/overall_distribution/transactions\" | \"GET /internal/apm/services/{serviceName}/metrics/charts\" | \"GET /internal/apm/services/{serviceName}/metrics/nodes\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/charts\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/summary\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/functions_overview\" | \"GET /internal/apm/services/{serviceName}/metrics/serverless/active_instances\" | \"GET /internal/apm/observability_overview\" | \"GET /internal/apm/observability_overview/has_data\" | \"GET /internal/apm/service-map\" | \"GET /internal/apm/service-map/service/{serviceName}\" | \"GET /internal/apm/service-map/dependency\" | \"GET /internal/apm/services\" | \"POST /internal/apm/services/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/metadata/details\" | \"GET /internal/apm/services/{serviceName}/metadata/icons\" | \"GET /internal/apm/services/{serviceName}/agent\" | \"GET /internal/apm/services/{serviceName}/transaction_types\" | \"GET /internal/apm/services/{serviceName}/node/{serviceNodeName}/metadata\" | \"GET /api/apm/services/{serviceName}/annotation/search\" | \"POST /api/apm/services/{serviceName}/annotation\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/details/{serviceNodeName}\" | \"GET /internal/apm/services/{serviceName}/throughput\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/main_statistics\" | \"GET /internal/apm/services/{serviceName}/service_overview_instances/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/dependencies\" | \"GET /internal/apm/services/{serviceName}/dependencies/breakdown\" | \"GET /internal/apm/services/{serviceName}/anomaly_charts\" | \"GET /internal/apm/sorted_and_filtered_services\" | \"GET /internal/apm/services/{serviceName}/alerts_count\" | \"GET /internal/apm/service-groups\" | \"GET /internal/apm/service-group\" | \"POST /internal/apm/service-group\" | \"DELETE /internal/apm/service-group\" | \"GET /internal/apm/service-group/services\" | \"GET /internal/apm/service-group/counts\" | \"GET /internal/apm/suggestions\" | \"GET /internal/apm/traces/{traceId}\" | \"GET /internal/apm/traces\" | \"GET /internal/apm/traces/{traceId}/root_transaction\" | \"GET /internal/apm/transactions/{transactionId}\" | \"GET /internal/apm/traces/find\" | \"POST /internal/apm/traces/aggregated_critical_path\" | \"GET /internal/apm/traces/{traceId}/transactions/{transactionId}\" | \"GET /internal/apm/traces/{traceId}/spans/{spanId}\" | \"GET /internal/apm/services/{serviceName}/transactions/groups/main_statistics\" | \"GET /internal/apm/services/{serviceName}/transactions/groups/detailed_statistics\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/latency\" | \"GET /internal/apm/services/{serviceName}/transactions/traces/samples\" | \"GET /internal/apm/services/{serviceName}/transaction/charts/breakdown\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/error_rate\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/coldstart_rate\" | \"GET /internal/apm/services/{serviceName}/transactions/charts/coldstart_rate_by_transaction_name\" | \"GET /internal/apm/rule_types/transaction_error_rate/chart_preview\" | \"GET /internal/apm/rule_types/transaction_duration/chart_preview\" | \"GET /internal/apm/rule_types/error_count/chart_preview\" | \"GET /api/apm/settings/agent-configuration\" | \"GET /api/apm/settings/agent-configuration/view\" | \"DELETE /api/apm/settings/agent-configuration\" | \"PUT /api/apm/settings/agent-configuration\" | \"POST /api/apm/settings/agent-configuration/search\" | \"GET /api/apm/settings/agent-configuration/environments\" | \"GET /api/apm/settings/agent-configuration/agent_name\" | \"GET /internal/apm/settings/anomaly-detection/jobs\" | \"POST /internal/apm/settings/anomaly-detection/jobs\" | \"GET /internal/apm/settings/anomaly-detection/environments\" | \"POST /internal/apm/settings/anomaly-detection/update_to_v3\" | \"GET /internal/apm/settings/apm-index-settings\" | \"GET /internal/apm/settings/apm-indices\" | \"POST /internal/apm/settings/apm-indices/save\" | \"GET /internal/apm/settings/custom_links/transaction\" | \"GET /internal/apm/settings/custom_links\" | \"POST /internal/apm/settings/custom_links\" | \"PUT /internal/apm/settings/custom_links/{id}\" | \"DELETE /internal/apm/settings/custom_links/{id}\" | \"GET /api/apm/sourcemaps\" | \"POST /api/apm/sourcemaps\" | \"DELETE /api/apm/sourcemaps/{id}\" | \"POST /internal/apm/sourcemaps/migrate_fleet_artifacts\" | \"GET /internal/apm/fleet/has_apm_policies\" | \"GET /internal/apm/fleet/agents\" | \"POST /api/apm/fleet/apm_server_schema\" | \"GET /internal/apm/fleet/apm_server_schema/unsupported\" | \"GET /internal/apm/fleet/migration_check\" | \"POST /internal/apm/fleet/cloud_apm_package_policy\" | \"GET /internal/apm/fleet/java_agent_versions\" | \"GET /internal/apm/dependencies/top_dependencies\" | \"GET /internal/apm/dependencies/upstream_services\" | \"GET /internal/apm/dependencies/metadata\" | \"GET /internal/apm/dependencies/charts/latency\" | \"GET /internal/apm/dependencies/charts/throughput\" | \"GET /internal/apm/dependencies/charts/error_rate\" | \"GET /internal/apm/dependencies/operations\" | \"GET /internal/apm/dependencies/charts/distribution\" | \"GET /internal/apm/dependencies/operations/spans\" | \"GET /internal/apm/correlations/field_candidates/transactions\" | \"GET /internal/apm/correlations/field_value_stats/transactions\" | \"POST /internal/apm/correlations/field_value_pairs/transactions\" | \"POST /internal/apm/correlations/significant_correlations/transactions\" | \"POST /internal/apm/correlations/p_values/transactions\" | \"GET /internal/apm/fallback_to_transactions\" | \"GET /internal/apm/has_data\" | \"GET /internal/apm/event_metadata/{processorEvent}/{id}\" | \"GET /internal/apm/agent_keys\" | \"GET /internal/apm/agent_keys/privileges\" | \"POST /internal/apm/api_key/invalidate\" | \"POST /api/apm/agent_keys\" | \"GET /internal/apm/storage_explorer\" | \"GET /internal/apm/services/{serviceName}/storage_details\" | \"GET /internal/apm/storage_chart\" | \"GET /internal/apm/storage_explorer/privileges\" | \"GET /internal/apm/storage_explorer_summary_stats\" | \"GET /internal/apm/storage_explorer/is_cross_cluster_search\" | \"GET /internal/apm/storage_explorer/get_services\" | \"GET /internal/apm/traces/{traceId}/span_links/{spanId}/parents\" | \"GET /internal/apm/traces/{traceId}/span_links/{spanId}/children\" | \"GET /internal/apm/services/{serviceName}/infrastructure_attributes\" | \"GET /internal/apm/debug-telemetry\" | \"GET /internal/apm/time_range_metadata\" | \"GET /internal/apm/settings/labs\" | \"GET /internal/apm/get_agents_per_service\" | \"GET /internal/apm/services/{serviceName}/agent_instances\" | \"GET /internal/apm/services/{serviceName}/mobile/filters\" | \"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions\" | \"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests\" | \"GET /internal/apm/mobile-services/{serviceName}/stats\"" ], "path": "x-pack/plugins/apm/server/routes/apm_routes/get_global_apm_server_route_repository.ts", "deprecated": false, @@ -934,6 +934,142 @@ "MobileStats", ", ", "APMRouteCreateOptions", + ">; \"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests\": ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests\", ", + "TypeC", + "<{ path: ", + "TypeC", + "<{ serviceName: ", + "StringC", + "; }>; query: ", + "IntersectionC", + "<[", + "TypeC", + "<{ kuery: ", + "StringC", + "; }>, ", + "TypeC", + "<{ start: ", + "Type", + "; end: ", + "Type", + "; }>, ", + "TypeC", + "<{ environment: ", + "UnionC", + "<[", + "LiteralC", + "<\"ENVIRONMENT_NOT_DEFINED\">, ", + "LiteralC", + "<\"ENVIRONMENT_ALL\">, ", + "BrandC", + "<", + "StringC", + ", ", + { + "pluginId": "@kbn/io-ts-utils", + "scope": "common", + "docId": "kibKbnIoTsUtilsPluginApi", + "section": "def-common.NonEmptyStringBrand", + "text": "NonEmptyStringBrand" + }, + ">]>; }>, ", + "PartialC", + "<{ offset: ", + "StringC", + "; }>, ", + "PartialC", + "<{ transactionType: ", + "StringC", + "; transactionName: ", + "StringC", + "; }>]>; }>, ", + { + "pluginId": "apm", + "scope": "server", + "docId": "kibApmPluginApi", + "section": "def-server.APMRouteHandlerResources", + "text": "APMRouteHandlerResources" + }, + ", ", + "HttpRequestsTimeseries", + ", ", + "APMRouteCreateOptions", + ">; \"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions\": ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions\", ", + "TypeC", + "<{ path: ", + "TypeC", + "<{ serviceName: ", + "StringC", + "; }>; query: ", + "IntersectionC", + "<[", + "TypeC", + "<{ kuery: ", + "StringC", + "; }>, ", + "TypeC", + "<{ start: ", + "Type", + "; end: ", + "Type", + "; }>, ", + "TypeC", + "<{ environment: ", + "UnionC", + "<[", + "LiteralC", + "<\"ENVIRONMENT_NOT_DEFINED\">, ", + "LiteralC", + "<\"ENVIRONMENT_ALL\">, ", + "BrandC", + "<", + "StringC", + ", ", + { + "pluginId": "@kbn/io-ts-utils", + "scope": "common", + "docId": "kibKbnIoTsUtilsPluginApi", + "section": "def-common.NonEmptyStringBrand", + "text": "NonEmptyStringBrand" + }, + ">]>; }>, ", + "PartialC", + "<{ offset: ", + "StringC", + "; }>, ", + "PartialC", + "<{ transactionType: ", + "StringC", + "; transactionName: ", + "StringC", + "; }>]>; }>, ", + { + "pluginId": "apm", + "scope": "server", + "docId": "kibApmPluginApi", + "section": "def-server.APMRouteHandlerResources", + "text": "APMRouteHandlerResources" + }, + ", ", + "SessionsTimeseries", + ", ", + "APMRouteCreateOptions", ">; \"GET /internal/apm/services/{serviceName}/mobile/filters\": ", { "pluginId": "@kbn/server-route-repository", diff --git a/api_docs/apm.mdx b/api_docs/apm.mdx index bebb7bffbd217..b575f13b49d63 100644 --- a/api_docs/apm.mdx +++ b/api_docs/apm.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/apm title: "apm" image: https://source.unsplash.com/400x175/?github description: API docs for the apm plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'apm'] --- import apmObj from './apm.devdocs.json'; @@ -21,7 +21,7 @@ Contact [APM UI](https://github.com/orgs/elastic/teams/apm-ui) for questions reg | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 42 | 0 | 42 | 59 | +| 42 | 0 | 42 | 61 | ## Client diff --git a/api_docs/banners.mdx b/api_docs/banners.mdx index 2c25218d3f988..a6372c2ec5f9b 100644 --- a/api_docs/banners.mdx +++ b/api_docs/banners.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/banners title: "banners" image: https://source.unsplash.com/400x175/?github description: API docs for the banners plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'banners'] --- import bannersObj from './banners.devdocs.json'; diff --git a/api_docs/bfetch.mdx b/api_docs/bfetch.mdx index 1f20888214c7e..b8d69c68892bf 100644 --- a/api_docs/bfetch.mdx +++ b/api_docs/bfetch.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/bfetch title: "bfetch" image: https://source.unsplash.com/400x175/?github description: API docs for the bfetch plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'bfetch'] --- import bfetchObj from './bfetch.devdocs.json'; diff --git a/api_docs/canvas.mdx b/api_docs/canvas.mdx index fbafdb9e94696..ea4a8dbdd7112 100644 --- a/api_docs/canvas.mdx +++ b/api_docs/canvas.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/canvas title: "canvas" image: https://source.unsplash.com/400x175/?github description: API docs for the canvas plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'canvas'] --- import canvasObj from './canvas.devdocs.json'; diff --git a/api_docs/cases.mdx b/api_docs/cases.mdx index 6e5650586e1a5..32c6dfabc0308 100644 --- a/api_docs/cases.mdx +++ b/api_docs/cases.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cases title: "cases" image: https://source.unsplash.com/400x175/?github description: API docs for the cases plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cases'] --- import casesObj from './cases.devdocs.json'; diff --git a/api_docs/charts.mdx b/api_docs/charts.mdx index 6eafd5de4de51..7c47818af3acb 100644 --- a/api_docs/charts.mdx +++ b/api_docs/charts.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/charts title: "charts" image: https://source.unsplash.com/400x175/?github description: API docs for the charts plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'charts'] --- import chartsObj from './charts.devdocs.json'; diff --git a/api_docs/cloud.devdocs.json b/api_docs/cloud.devdocs.json index e86310156f1c1..6be7a82d3d31c 100644 --- a/api_docs/cloud.devdocs.json +++ b/api_docs/cloud.devdocs.json @@ -613,6 +613,36 @@ ], "lifecycle": "setup", "initialIsOpen": true + }, + "start": { + "parentPluginId": "cloud", + "id": "def-server.CloudStart", + "type": "Interface", + "tags": [], + "label": "CloudStart", + "description": [ + "\nStart contract" + ], + "path": "x-pack/plugins/cloud/server/plugin.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "cloud", + "id": "def-server.CloudStart.isCloudEnabled", + "type": "boolean", + "tags": [], + "label": "isCloudEnabled", + "description": [ + "\n`true` when running on Elastic Cloud." + ], + "path": "x-pack/plugins/cloud/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "lifecycle": "start", + "initialIsOpen": true } }, "common": { diff --git a/api_docs/cloud.mdx b/api_docs/cloud.mdx index 15a5d3360c9b5..be71624edcd06 100644 --- a/api_docs/cloud.mdx +++ b/api_docs/cloud.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloud title: "cloud" image: https://source.unsplash.com/400x175/?github description: API docs for the cloud plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloud'] --- import cloudObj from './cloud.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) for que | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 39 | 0 | 11 | 0 | +| 41 | 0 | 11 | 0 | ## Client @@ -36,3 +36,6 @@ Contact [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) for que ### Setup +### Start + + diff --git a/api_docs/cloud_chat.mdx b/api_docs/cloud_chat.mdx index 195d0a6f16857..c10c892a4b31c 100644 --- a/api_docs/cloud_chat.mdx +++ b/api_docs/cloud_chat.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloudChat title: "cloudChat" image: https://source.unsplash.com/400x175/?github description: API docs for the cloudChat plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloudChat'] --- import cloudChatObj from './cloud_chat.devdocs.json'; diff --git a/api_docs/cloud_data_migration.devdocs.json b/api_docs/cloud_data_migration.devdocs.json index be8d01e527096..46a118a592a92 100644 --- a/api_docs/cloud_data_migration.devdocs.json +++ b/api_docs/cloud_data_migration.devdocs.json @@ -71,25 +71,46 @@ } ], "initialIsOpen": false + }, + { + "parentPluginId": "cloudDataMigration", + "id": "def-public.CloudDataMigrationPluginStart", + "type": "Interface", + "tags": [], + "label": "CloudDataMigrationPluginStart", + "description": [], + "path": "x-pack/plugins/cloud_integrations/cloud_data_migration/public/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "cloudDataMigration", + "id": "def-public.CloudDataMigrationPluginStart.cloud", + "type": "Object", + "tags": [], + "label": "cloud", + "description": [], + "signature": [ + { + "pluginId": "cloud", + "scope": "public", + "docId": "kibCloudPluginApi", + "section": "def-public.CloudStart", + "text": "CloudStart" + }, + " | undefined" + ], + "path": "x-pack/plugins/cloud_integrations/cloud_data_migration/public/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false } ], "enums": [], "misc": [], - "objects": [], - "start": { - "parentPluginId": "cloudDataMigration", - "id": "def-public.CloudDataMigrationPluginStart", - "type": "Interface", - "tags": [], - "label": "CloudDataMigrationPluginStart", - "description": [], - "path": "x-pack/plugins/cloud_integrations/cloud_data_migration/public/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "lifecycle": "start", - "initialIsOpen": true - } + "objects": [] }, "server": { "classes": [], diff --git a/api_docs/cloud_data_migration.mdx b/api_docs/cloud_data_migration.mdx index 732e97890fac4..9bf47c37698c2 100644 --- a/api_docs/cloud_data_migration.mdx +++ b/api_docs/cloud_data_migration.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloudDataMigration title: "cloudDataMigration" image: https://source.unsplash.com/400x175/?github description: API docs for the cloudDataMigration plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloudDataMigration'] --- import cloudDataMigrationObj from './cloud_data_migration.devdocs.json'; @@ -21,13 +21,10 @@ Contact [Platform Onboarding](https://github.com/orgs/elastic/teams/platform-onb | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 7 | 1 | 7 | 1 | +| 8 | 1 | 8 | 1 | ## Client -### Start - - ### Interfaces diff --git a/api_docs/cloud_defend.mdx b/api_docs/cloud_defend.mdx index 17f45d00ca8f9..39e865fca5b5d 100644 --- a/api_docs/cloud_defend.mdx +++ b/api_docs/cloud_defend.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloudDefend title: "cloudDefend" image: https://source.unsplash.com/400x175/?github description: API docs for the cloudDefend plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloudDefend'] --- import cloudDefendObj from './cloud_defend.devdocs.json'; diff --git a/api_docs/cloud_experiments.mdx b/api_docs/cloud_experiments.mdx index 7b0672a816405..50eaedaa2b4f2 100644 --- a/api_docs/cloud_experiments.mdx +++ b/api_docs/cloud_experiments.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloudExperiments title: "cloudExperiments" image: https://source.unsplash.com/400x175/?github description: API docs for the cloudExperiments plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloudExperiments'] --- import cloudExperimentsObj from './cloud_experiments.devdocs.json'; diff --git a/api_docs/cloud_security_posture.mdx b/api_docs/cloud_security_posture.mdx index 758ac128ce921..83610a7d6125c 100644 --- a/api_docs/cloud_security_posture.mdx +++ b/api_docs/cloud_security_posture.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/cloudSecurityPosture title: "cloudSecurityPosture" image: https://source.unsplash.com/400x175/?github description: API docs for the cloudSecurityPosture plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloudSecurityPosture'] --- import cloudSecurityPostureObj from './cloud_security_posture.devdocs.json'; diff --git a/api_docs/console.mdx b/api_docs/console.mdx index c6d3bc5063a2c..4e396919c5d5a 100644 --- a/api_docs/console.mdx +++ b/api_docs/console.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/console title: "console" image: https://source.unsplash.com/400x175/?github description: API docs for the console plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'console'] --- import consoleObj from './console.devdocs.json'; diff --git a/api_docs/controls.mdx b/api_docs/controls.mdx index c353896d4134a..6071894e19c6b 100644 --- a/api_docs/controls.mdx +++ b/api_docs/controls.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/controls title: "controls" image: https://source.unsplash.com/400x175/?github description: API docs for the controls plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'controls'] --- import controlsObj from './controls.devdocs.json'; diff --git a/api_docs/core.devdocs.json b/api_docs/core.devdocs.json index ea00a8c879bd2..f8065754bc020 100644 --- a/api_docs/core.devdocs.json +++ b/api_docs/core.devdocs.json @@ -1777,12 +1777,10 @@ "parentPluginId": "core", "id": "def-public.AppMountParameters.onAppLeave", "type": "Function", - "tags": [ - "deprecated" - ], + "tags": [], "label": "onAppLeave", "description": [ - "\nA function that can be used to register a handler that will be called\nwhen the user is leaving the current application, allowing to\nprompt a confirmation message before actually changing the page.\n\nThis will be called either when the user goes to another application, or when\ntrying to close the tab or manually changing the url.\n" + "\nA function that can be used to register a handler that will be called\nwhen the user is leaving the current application, allowing to\nprompt a confirmation message before actually changing the page.\n\nThis will be called either when the user goes to another application, or when\ntrying to close the tab or manually changing the url.\n\n" ], "signature": [ "(handler: ", @@ -1796,83 +1794,8 @@ ") => void" ], "path": "packages/core/application/core-application-browser/src/app_mount.ts", - "deprecated": true, - "removeBy": "8.8.0", + "deprecated": false, "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" - }, - { - "plugin": "@kbn/core-application-browser-mocks", - "path": "packages/core/application/core-application-browser-mocks/src/application_service.mock.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/app.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/index.tsx" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/dashboard_app/types.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/plugin.tsx" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/types.ts" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/types.ts" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/mounter.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/render_app.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/routes/map_page/map_page.tsx" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/app.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/plugin.tsx" - }, - { - "plugin": "security", - "path": "x-pack/plugins/security/public/authentication/logout/logout_app.test.ts" - } - ], "children": [ { "parentPluginId": "core", @@ -2441,6 +2364,22 @@ "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.ChromeHelpExtensionMenuCustomLink.external", + "type": "CompoundType", + "tags": [], + "label": "external", + "description": [ + "\nOpens link in new tab" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -4885,10 +4824,12 @@ "parentPluginId": "core", "id": "def-public.CoreStart.savedObjects", "type": "Object", - "tags": [], + "tags": [ + "deprecated" + ], "label": "savedObjects", "description": [ - "{@link SavedObjectsStart}" + "\n{@link SavedObjectsStart}" ], "signature": [ { @@ -4900,8 +4841,362 @@ } ], "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts", - "deprecated": false, - "trackAdoption": false + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts" + }, + { + "plugin": "@kbn/core-root-browser-internal", + "path": "packages/core/root/core-root-browser-internal/src/core_system.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/plugin.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/public/plugin.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/expressions/kibana_context.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/plugin.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/plugin.tsx" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object_service.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/index.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/index.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/lens_attribute_service.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/lens_attribute_service.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/visualization.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/visualization.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/mounter.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/embeddable/search_embeddable_factory.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/top_nav/open_search_panel.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/utils/persist_saved_search.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/hooks/use_discover_state.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/discover_main_route.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/discover_main_route.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "fileUpload", + "path": "x-pack/plugins/file_upload/public/kibana_services.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/kibana_services.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/app.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/platform.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/source_picker.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/source_modal.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/plugin.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_locations_api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_locations_api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/plugin.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/mount_management_section.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/plugin.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/plugin.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/search_bar.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/guidance_panel/guidance_panel.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_create_security_dashboard_link.ts" + } + ] }, { "parentPluginId": "core", @@ -12381,7 +12676,9 @@ "parentPluginId": "core", "id": "def-public.ResolvedSimpleSavedObject", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "ResolvedSimpleSavedObject", "description": [ "\nThis interface is a very simple wrapper for SavedObjects resolved from the server\nwith the {@link SavedObjectsClientContract}.\n" @@ -12397,8 +12694,198 @@ "" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/legacy_urls/types.ts" + }, + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/legacy_urls/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -12526,229 +13013,399 @@ }, { "parentPluginId": "core", - "id": "def-public.SavedObject", + "id": "def-public.SavedObjectError", "type": "Interface", "tags": [], - "label": "SavedObject", + "label": "SavedObjectError", "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "" - ], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObject.id", + "id": "def-public.SavedObjectError.error", "type": "string", "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], + "label": "error", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-public.SavedObject.type", + "id": "def-public.SavedObjectError.message", "type": "string", "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], + "label": "message", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-public.SavedObject.version", - "type": "string", + "id": "def-public.SavedObjectError.statusCode", + "type": "number", "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" - ], + "label": "statusCode", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-public.SavedObject.created_at", - "type": "string", + "id": "def-public.SavedObjectError.metadata", + "type": "Object", "tags": [], - "label": "created_at", - "description": [ - "Timestamp of the time this document had been created." - ], + "label": "metadata", + "description": [], "signature": [ - "string | undefined" + "Record | undefined" ], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsBatchResponse", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsBatchResponse", + "description": [ + "\nBatch response for simple saved objects\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBatchResponse", + "text": "SavedObjectsBatchResponse" }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObject.updated_at", - "type": "string", - "tags": [], - "label": "updated_at", - "description": [ - "Timestamp of the last time this document had been updated." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObject.error", - "type": "Object", - "tags": [], - "label": "error", - "description": [ - "Error associated with this object, populated if an operation failed for this object." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + } + ], + "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObject.references", + "id": "def-public.SavedObjectsBatchResponse.savedObjects", "type": "Array", "tags": [], - "label": "references", + "label": "savedObjects", "description": [ - "{@inheritdoc SavedObjectReference}" + "Array of simple saved objects" ], "signature": [ { - "pluginId": "@kbn/core-saved-objects-common", + "pluginId": "@kbn/core-saved-objects-api-browser", "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" }, - "[]" + "[]" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts", "deprecated": false, "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkCreateObject", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsBulkCreateObject", + "description": [ + "\nPer-object parameters for bulk create operation\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBulkCreateObject", + "text": "SavedObjectsBulkCreateObject" + }, + " extends ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsCreateOptions", + "text": "SavedObjectsCreateOptions" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], + "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObject.migrationVersion", - "type": "Object", + "id": "def-public.SavedObjectsBulkCreateObject.type", + "type": "string", "tags": [], - "label": "migrationVersion", + "label": "type", "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" + "Create a SavedObject of this type." ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-public.SavedObject.coreMigrationVersion", - "type": "string", + "id": "def-public.SavedObjectsBulkCreateObject.attributes", + "type": "Uncategorized", "tags": [], - "label": "coreMigrationVersion", + "label": "attributes", "description": [ - "A semver value that is used when upgrading objects between Kibana versions." + "Attributes for the saved object to be created." ], "signature": [ - "string | undefined" + "T" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", "deprecated": false, "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkCreateOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsBulkCreateOptions", + "description": [ + "\nOptions for bulk create operation\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], + "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObject.namespaces", - "type": "Array", + "id": "def-public.SavedObjectsBulkCreateOptions.overwrite", + "type": "CompoundType", "tags": [], - "label": "namespaces", + "label": "overwrite", "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." + "If a document with the given `id` already exists, overwrite its contents (default=false)." ], "signature": [ - "string[] | undefined" + "boolean | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", "deprecated": false, "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkResolveResponse", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsBulkResolveResponse", + "description": [ + "\nReturn type of the Saved Objects `bulkResolve()` method.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBulkResolveResponse", + "text": "SavedObjectsBulkResolveResponse" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + } + ], + "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObject.originId", - "type": "string", + "id": "def-public.SavedObjectsBulkResolveResponse.resolved_objects", + "type": "Array", "tags": [], - "label": "originId", + "label": "resolved_objects", "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." + "Array of {@link ResolvedSimpleSavedObject} that were resolved" ], "signature": [ - "string | undefined" + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.ResolvedSimpleSavedObject", + "text": "ResolvedSimpleSavedObject" + }, + "[]" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts", "deprecated": false, "trackAdoption": false } @@ -12757,808 +13414,737 @@ }, { "parentPluginId": "core", - "id": "def-public.SavedObjectAttributes", + "id": "def-public.SavedObjectsBulkUpdateObject", "type": "Interface", "tags": [ "deprecated" ], - "label": "SavedObjectAttributes", + "label": "SavedObjectsBulkUpdateObject", "description": [ - "\nThe data for a Saved Object is stored as an object in the `attributes`\nproperty.\n" + "\nPer-object parameters for bulk update operation\n" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBulkUpdateObject", + "text": "SavedObjectsBulkUpdateObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", "deprecated": true, "trackAdoption": false, "references": [ { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" }, { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" }, { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], + "children": [ { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateObject.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "Type of the saved object to update" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateObject.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "ID of the saved object to update" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateObject.attributes", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "The attributes to update" + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateObject.version", + "type": "string", + "tags": [], + "label": "version", + "description": [ + "The version string for the saved object" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" - }, + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateObject.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "Array of references to other saved objects" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsBulkUpdateOptions", + "description": [ + "\nOptions for bulk update operation\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" - }, + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + } + ], + "children": [ { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" - }, + "parentPluginId": "core", + "id": "def-public.SavedObjectsBulkUpdateOptions.namespace", + "type": "string", + "tags": [], + "label": "namespace", + "description": [ + "\nThe namespace from which to apply the bulk update operation\nNot permitted if spaces extension is enabled" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsClientContract", + "description": [ + "\nThe client-side SavedObjectsClient is a thin convenience library around the SavedObjects\nHTTP API for interacting with Saved Objects.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "home", + "path": "src/plugins/home/public/application/kibana_services.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "home", + "path": "src/plugins/home/public/application/kibana_services.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" }, { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" }, { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" }, { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" }, { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/types.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/types.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/plugin.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/plugin.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/dependency_cache.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/dependency_cache.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/save_modal.tsx" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/save_modal.tsx" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/store.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/store.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/application.tsx" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/application.tsx" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/index.tsx" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/index.tsx" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/mocks.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/mocks.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.test.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.test.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts" }, { - "plugin": "taskManager", - "path": "x-pack/plugins/task_manager/server/task_store.test.ts" - }, - { - "plugin": "taskManager", - "path": "x-pack/plugins/task_manager/server/task_store.test.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" }, { - "plugin": "savedSearch", - "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" }, { - "plugin": "savedSearch", - "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" }, { "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" }, { "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" - }, - { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" - }, - { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" - } - ], - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectAttributes.Unnamed", - "type": "IndexSignature", - "tags": [], - "label": "[key: string]: SavedObjectAttribute", - "description": [], - "signature": [ - "[key: string]: ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttribute", - "text": "SavedObjectAttribute" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" } ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectError", - "type": "Interface", - "tags": [], - "label": "SavedObjectError", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, "children": [ { "parentPluginId": "core", - "id": "def-public.SavedObjectError.error", - "type": "string", - "tags": [], - "label": "error", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectError.message", - "type": "string", - "tags": [], - "label": "message", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectError.statusCode", - "type": "number", - "tags": [], - "label": "statusCode", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectError.metadata", - "type": "Object", - "tags": [], - "label": "metadata", - "description": [], - "signature": [ - "Record | undefined" + "id": "def-public.SavedObjectsClientContract.create", + "type": "Function", + "tags": [ + "deprecated" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectReference", - "type": "Interface", - "tags": [], - "label": "SavedObjectReference", - "description": [ - "\nA reference to another saved object.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectReference.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectReference.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectReference.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBatchResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBatchResponse", - "description": [ - "\nBatch response for simple saved objects\n" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBatchResponse", - "text": "SavedObjectsBatchResponse" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBatchResponse.savedObjects", - "type": "Array", - "tags": [], - "label": "savedObjects", + "label": "create", "description": [ - "Array of simple saved objects" + "\nCreates an object\n" ], "signature": [ + "(type: string, attributes: T, options?: ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsCreateOptions", + "text": "SavedObjectsCreateOptions" + }, + " | undefined) => Promise<", { "pluginId": "@kbn/core-saved-objects-api-browser", "scope": "common", @@ -13566,444 +14152,372 @@ "section": "def-common.SimpleSavedObject", "text": "SimpleSavedObject" }, - "[]" + ">" ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkCreateObject", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBulkCreateObject", - "description": [ - "\nPer-object parameters for bulk create operation\n" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBulkCreateObject", - "text": "SavedObjectsBulkCreateObject" - }, - " extends ", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsCreateOptions", - "text": "SavedObjectsCreateOptions" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkCreateObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "Create a SavedObject of this type." + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_saved_object.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, - "trackAdoption": false + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.create.$1", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "- the type of object to create" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.create.$2", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "- the attributes of the object" + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.create.$3", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "{@link SavedObjectsCreateOptions }" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsCreateOptions", + "text": "SavedObjectsCreateOptions" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [ + "The result of the create operation - the created saved object" + ] }, { "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkCreateObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", + "id": "def-public.SavedObjectsClientContract.bulkCreate", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "bulkCreate", "description": [ - "Attributes for the saved object to be created." + "\nCreates multiple objects at once\n" ], "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkCreateOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBulkCreateOptions", - "description": [ - "\nOptions for bulk create operation\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkCreateOptions.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "If a document with the given `id` already exists, overwrite its contents (default=false)." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkResolveResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBulkResolveResponse", - "description": [ - "\nReturn type of the Saved Objects `bulkResolve()` method.\n" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBulkResolveResponse", - "text": "SavedObjectsBulkResolveResponse" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkResolveResponse.resolved_objects", - "type": "Array", - "tags": [], - "label": "resolved_objects", - "description": [ - "Array of {@link ResolvedSimpleSavedObject} that were resolved" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.ResolvedSimpleSavedObject", - "text": "ResolvedSimpleSavedObject" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBulkUpdateObject", - "description": [ - "\nPer-object parameters for bulk update operation\n" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBulkUpdateObject", - "text": "SavedObjectsBulkUpdateObject" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "Type of the saved object to update" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "ID of the saved object to update" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "The attributes to update" - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "The version string for the saved object" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateObject.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "Array of references to other saved objects" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsBulkUpdateOptions", - "description": [ - "\nOptions for bulk update operation\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsBulkUpdateOptions.namespace", - "type": "string", - "tags": [], - "label": "namespace", - "description": [ - "\nThe namespace from which to apply the bulk update operation\nNot permitted if spaces extension is enabled" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract", - "type": "Interface", - "tags": [], - "label": "SavedObjectsClientContract", - "description": [ - "\nThe client-side SavedObjectsClient is a thin convenience library around the SavedObjects\nHTTP API for interacting with Saved Objects.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.create", - "type": "Function", - "tags": [], - "label": "create", - "description": [ - "\nCreates an object\n" - ], - "signature": [ - "(type: string, attributes: T, options?: ", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsCreateOptions", - "text": "SavedObjectsCreateOptions" - }, - " | undefined) => Promise<", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" - }, - ">" + "(objects: ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBulkCreateObject", + "text": "SavedObjectsBulkCreateObject" + }, + "[], options?: ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBulkCreateOptions", + "text": "SavedObjectsBulkCreateOptions" + }, + " | undefined) => Promise<", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBatchResponse", + "text": "SavedObjectsBatchResponse" + }, + ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.create.$1", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "- the type of object to create" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.create.$2", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "- the attributes of the object" - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "home", + "path": "src/plugins/home/public/application/components/home_app.js" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.create.$3", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "{@link SavedObjectsCreateOptions }" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsCreateOptions", - "text": "SavedObjectsCreateOptions" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [ - "The result of the create operation - the created saved object" - ] - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.bulkCreate", - "type": "Function", - "tags": [], - "label": "bulkCreate", - "description": [ - "\nCreates multiple objects at once\n" - ], - "signature": [ - "(objects: ", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBulkCreateObject", - "text": "SavedObjectsBulkCreateObject" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, - "[], options?: ", { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBulkCreateOptions", - "text": "SavedObjectsBulkCreateOptions" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" }, - " | undefined) => Promise<", { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBatchResponse", - "text": "SavedObjectsBatchResponse" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" }, - ">" + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, "children": [ { "parentPluginId": "core", @@ -14062,7 +14576,9 @@ "parentPluginId": "core", "id": "def-public.SavedObjectsClientContract.delete", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "delete", "description": [ "\nDeletes an object\n" @@ -14079,8 +14595,62 @@ " | undefined) => Promise<{}>" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/build_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14147,7 +14717,9 @@ "parentPluginId": "core", "id": "def-public.SavedObjectsClientContract.bulkDelete", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkDelete", "description": [ "\nDeletes multiple documents at once" @@ -14180,8 +14752,30 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14247,7 +14841,8 @@ "property", "property", "property", - "property" + "property", + "deprecated" ], "label": "find", "description": [ @@ -14273,105 +14868,485 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.find.$1", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "{@link SavedObjectsFindOptions }" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsFindOptions", - "text": "SavedObjectsFindOptions" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "A find result with objects matching the specified search." - ] - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.get", - "type": "Function", - "tags": [], - "label": "get", - "description": [ - "\nFetches a single object\n" - ], - "signature": [ - "(type: string, id: string) => Promise<", + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" }, - ">" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.get.$1", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "- the type of the object to get" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsClientContract.get.$2", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "- the ID of the object to get" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "The saved object for the given type and id." - ] + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/index_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/recognize/resolvers.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.test.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.find.$1", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "{@link SavedObjectsFindOptions }" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsFindOptions", + "text": "SavedObjectsFindOptions" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "A find result with objects matching the specified search." + ] + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.get", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "get", + "description": [ + "\nFetches a single object\n" + ], + "signature": [ + "(type: string, id: string) => Promise<", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + ">" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/index_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/job_from_lens/route_resolver.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.get.$1", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "- the type of the object to get" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsClientContract.get.$2", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "- the ID of the object to get" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "The saved object for the given type and id." + ] }, { "parentPluginId": "core", "id": "def-public.SavedObjectsClientContract.bulkGet", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkGet", "description": [ "\nReturns an array of objects by id\n" @@ -14396,8 +15371,26 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14433,7 +15426,8 @@ "id": "def-public.SavedObjectsClientContract.resolve", "type": "Function", "tags": [ - "note" + "note", + "deprecated" ], "label": "resolve", "description": [ @@ -14451,8 +15445,138 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14498,7 +15622,8 @@ "id": "def-public.SavedObjectsClientContract.bulkResolve", "type": "Function", "tags": [ - "note" + "note", + "deprecated" ], "label": "bulkResolve", "description": [ @@ -14524,8 +15649,30 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14562,7 +15709,8 @@ "type": "Function", "tags": [ "prop", - "prop" + "prop", + "deprecated" ], "label": "update", "description": [ @@ -14588,8 +15736,82 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14675,7 +15897,9 @@ "parentPluginId": "core", "id": "def-public.SavedObjectsClientContract.bulkUpdate", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkUpdate", "description": [ "\nUpdate multiple documents at once\n" @@ -14700,8 +15924,26 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -14739,20 +15981,128 @@ "parentPluginId": "core", "id": "def-public.SavedObjectsCreateOptions", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsCreateOptions", "description": [ "\nOptions for creating a saved object.\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsCreateOptions.id", - "type": "string", - "tags": [], + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsCreateOptions.id", + "type": "string", + "tags": [], "label": "id", "description": [ "\n(Not recommended) Specify an id instead of having the saved objects service generate one for you." @@ -14765,3595 +16115,7590 @@ "trackAdoption": false }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsCreateOptions.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "If a document with the given `id` already exists, overwrite it's contents (default=false)." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, - "trackAdoption": false + "parentPluginId": "core", + "id": "def-public.SavedObjectsCreateOptions.overwrite", + "type": "CompoundType", + "tags": [], + "label": "overwrite", + "description": [ + "If a document with the given `id` already exists, overwrite it's contents (default=false)." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsCreateOptions.migrationVersion", + "type": "Object", + "tags": [], + "label": "migrationVersion", + "description": [ + "{@inheritDoc SavedObjectsMigrationVersion}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsMigrationVersion", + "text": "SavedObjectsMigrationVersion" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsCreateOptions.coreMigrationVersion", + "type": "string", + "tags": [], + "label": "coreMigrationVersion", + "description": [ + "A semver value that is used when upgrading objects between Kibana versions." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsCreateOptions.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "Array of referenced saved objects." + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsDeleteOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsDeleteOptions", + "description": [ + "\nOptions for deleting a saved object.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsDeleteOptions.force", + "type": "CompoundType", + "tags": [], + "label": "force", + "description": [ + "Force deletion of an object that exists in multiple namespaces (default=false)" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindOptionsReference", + "type": "Interface", + "tags": [], + "label": "SavedObjectsFindOptionsReference", + "description": [ + "\nAn object reference for use in find operation options\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindOptionsReference.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "The type of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindOptionsReference.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The ID of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindResponse", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsFindResponse", + "description": [ + "\nReturn type of the Saved Objects `find()` method.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsFindResponse", + "text": "SavedObjectsFindResponse" + }, + " extends ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBatchResponse", + "text": "SavedObjectsBatchResponse" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/use_packs.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/use_packs.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindResponse.aggregations", + "type": "Uncategorized", + "tags": [], + "label": "aggregations", + "description": [ + "aggregations from the search query" + ], + "signature": [ + "A | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindResponse.total", + "type": "number", + "tags": [], + "label": "total", + "description": [ + "total number of results" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindResponse.perPage", + "type": "number", + "tags": [], + "label": "perPage", + "description": [ + "number of results per page" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsFindResponse.page", + "type": "number", + "tags": [], + "label": "page", + "description": [ + "current page in results" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportActionRequiredWarning", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportActionRequiredWarning", + "description": [ + "\nA warning meant to notify that a specific user action is required to finalize the import\nof some type of object.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportActionRequiredWarning.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"action_required\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportActionRequiredWarning.message", + "type": "string", + "tags": [], + "label": "message", + "description": [ + "The translated message to display to the user." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportActionRequiredWarning.actionPath", + "type": "string", + "tags": [], + "label": "actionPath", + "description": [ + "The path (without the basePath) that the user should be redirect to address this warning." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportActionRequiredWarning.buttonLabel", + "type": "string", + "tags": [], + "label": "buttonLabel", + "description": [ + "An optional label to use for the link button. If unspecified, a default label will be used." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportAmbiguousConflictError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportAmbiguousConflictError", + "description": [ + "\nRepresents a failure to import due to a conflict, which can be resolved in different ways with an overwrite." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportAmbiguousConflictError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"ambiguous_conflict\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportAmbiguousConflictError.destinations", + "type": "Array", + "tags": [], + "label": "destinations", + "description": [], + "signature": [ + "{ id: string; title?: string | undefined; updatedAt?: string | undefined; }[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportConflictError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportConflictError", + "description": [ + "\nRepresents a failure to import due to a conflict." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportConflictError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"conflict\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportConflictError.destinationId", + "type": "string", + "tags": [], + "label": "destinationId", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportFailure", + "description": [ + "\nRepresents a failure to import." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure.meta", + "type": "Object", + "tags": [], + "label": "meta", + "description": [], + "signature": [ + "{ title?: string | undefined; icon?: string | undefined; }" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure.overwrite", + "type": "CompoundType", + "tags": [], + "label": "overwrite", + "description": [ + "\nIf `overwrite` is specified, an attempt was made to overwrite an existing object." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportFailure.error", + "type": "CompoundType", + "tags": [], + "label": "error", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportConflictError", + "text": "SavedObjectsImportConflictError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportAmbiguousConflictError", + "text": "SavedObjectsImportAmbiguousConflictError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportUnsupportedTypeError", + "text": "SavedObjectsImportUnsupportedTypeError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportMissingReferencesError", + "text": "SavedObjectsImportMissingReferencesError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportUnknownError", + "text": "SavedObjectsImportUnknownError" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportMissingReferencesError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportMissingReferencesError", + "description": [ + "\nRepresents a failure to import due to missing references." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportMissingReferencesError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"missing_references\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportMissingReferencesError.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [], + "signature": [ + "{ type: string; id: string; }[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportResponse", + "description": [ + "\nThe response describing the result of an import." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse.success", + "type": "boolean", + "tags": [], + "label": "success", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse.successCount", + "type": "number", + "tags": [], + "label": "successCount", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse.successResults", + "type": "Array", + "tags": [], + "label": "successResults", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportSuccess", + "text": "SavedObjectsImportSuccess" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse.warnings", + "type": "Array", + "tags": [], + "label": "warnings", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportWarning", + "text": "SavedObjectsImportWarning" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportResponse.errors", + "type": "Array", + "tags": [], + "label": "errors", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportFailure", + "text": "SavedObjectsImportFailure" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportRetry", + "description": [ + "\nDescribes a retry operation for importing a saved object." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.overwrite", + "type": "boolean", + "tags": [], + "label": "overwrite", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.destinationId", + "type": "string", + "tags": [], + "label": "destinationId", + "description": [ + "\nThe object ID that will be created or overwritten. If not specified, the `id` field will be used." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.replaceReferences", + "type": "Array", + "tags": [], + "label": "replaceReferences", + "description": [], + "signature": [ + "{ type: string; from: string; to: string; }[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.createNewCopy", + "type": "CompoundType", + "tags": [], + "label": "createNewCopy", + "description": [ + "\nIf `createNewCopy` is specified, the new object has a new (undefined) origin ID. This is only needed for the case where\n`createNewCopies` mode is disabled and ambiguous source conflicts are detected." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportRetry.ignoreMissingReferences", + "type": "CompoundType", + "tags": [], + "label": "ignoreMissingReferences", + "description": [ + "\nIf `ignoreMissingReferences` is specified, reference validation will be skipped for this object." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSimpleWarning", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportSimpleWarning", + "description": [ + "\nA simple informative warning that will be displayed to the user.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSimpleWarning.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"simple\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSimpleWarning.message", + "type": "string", + "tags": [], + "label": "message", + "description": [ + "The translated message to display to the user" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportSuccess", + "description": [ + "\nRepresents a successful import." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.destinationId", + "type": "string", + "tags": [], + "label": "destinationId", + "description": [ + "\nIf `destinationId` is specified, the new object has a new ID that is different from the import ID." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.createNewCopy", + "type": "CompoundType", + "tags": [ + "deprecated" + ], + "label": "createNewCopy", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts" + } + ] + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.meta", + "type": "Object", + "tags": [], + "label": "meta", + "description": [], + "signature": [ + "{ title?: string | undefined; icon?: string | undefined; }" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportSuccess.overwrite", + "type": "CompoundType", + "tags": [], + "label": "overwrite", + "description": [ + "\nIf `overwrite` is specified, this object overwrote an existing one (or will do so, in the case of a pending resolution)." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnknownError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportUnknownError", + "description": [ + "\nRepresents a failure to import due to an unknown reason." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnknownError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"unknown\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnknownError.message", + "type": "string", + "tags": [], + "label": "message", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnknownError.statusCode", + "type": "number", + "tags": [], + "label": "statusCode", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnsupportedTypeError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportUnsupportedTypeError", + "description": [ + "\nRepresents a failure to import due to having an unsupported saved object type." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsImportUnsupportedTypeError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"unsupported_type\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsMigrationVersion", + "type": "Interface", + "tags": [], + "label": "SavedObjectsMigrationVersion", + "description": [ + "\nInformation about the migrations that have been applied to this SavedObject.\nWhen Kibana starts up, KibanaMigrator detects outdated documents and\nmigrates them based on this value. For each migration that has been applied,\nthe plugin's name is used as a key and the latest migration version as the\nvalue.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsMigrationVersion.Unnamed", + "type": "IndexSignature", + "tags": [], + "label": "[pluginName: string]: string", + "description": [ + "The plugin name and version string" + ], + "signature": [ + "[pluginName: string]: string" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsStart", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsStart", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/index.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsStart.client", + "type": "Object", + "tags": [], + "label": "client", + "description": [ + "{@link SavedObjectsClientContract}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsClientContract", + "text": "SavedObjectsClientContract" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsUpdateOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsUpdateOptions", + "description": [ + "\nOptions for updating a saved object\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsUpdateOptions", + "text": "SavedObjectsUpdateOptions" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsUpdateOptions.version", + "type": "string", + "tags": [], + "label": "version", + "description": [ + "version of the saved object" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsUpdateOptions.upsert", + "type": "Uncategorized", + "tags": [], + "label": "upsert", + "description": [ + "Alternative attributes for the saved object if upserting" + ], + "signature": [ + "Attributes | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectsUpdateOptions.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "Array of references to other saved objects" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectTypeIdTuple", + "type": "Interface", + "tags": [], + "label": "SavedObjectTypeIdTuple", + "description": [ + "\nAn identifier for a saved object within a space.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SavedObjectTypeIdTuple.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The id of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectTypeIdTuple.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "The type of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory", + "type": "Interface", + "tags": [], + "label": "ScopedHistory", + "description": [ + "\nA wrapper around a `History` instance that is scoped to a particular base path of the history stack. Behaves\nsimilarly to the `basename` option except that this wrapper hides any history stack entries from outside the scope\nof this base path.\n\nThis wrapper also allows Core and Plugins to share a single underlying global `History` instance without exposing\nthe history of other applications.\n\nThe {@link ScopedHistory.createSubHistory | createSubHistory} method is particularly useful for applications that\ncontain any number of \"sub-apps\" which should not have access to the main application's history or basePath.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.ScopedHistory", + "text": "ScopedHistory" + }, + " extends ", + "History", + "" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createSubHistory", + "type": "Function", + "tags": [], + "label": "createSubHistory", + "description": [ + "\nCreates a `ScopedHistory` for a subpath of this `ScopedHistory`. Useful for applications that may have sub-apps\nthat do not need access to the containing application's history.\n" + ], + "signature": [ + "(basePath: string) => ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.ScopedHistory", + "text": "ScopedHistory" + }, + "" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createSubHistory.$1", + "type": "string", + "tags": [], + "label": "basePath", + "description": [ + "the URL path scope for the sub history" + ], + "signature": [ + "string" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createHref", + "type": "Function", + "tags": [], + "label": "createHref", + "description": [ + "\nCreates an href (string) to the location.\nIf `prependBasePath` is true (default), it will prepend the location's path with the scoped history basePath.\n" + ], + "signature": [ + "(location: ", + "LocationDescriptorObject", + ", options?: { prependBasePath?: boolean | undefined; } | undefined) => string" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createHref.$1", + "type": "Object", + "tags": [], + "label": "location", + "description": [], + "signature": [ + "LocationDescriptorObject", + "" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createHref.$2", + "type": "Object", + "tags": [], + "label": "options", + "description": [], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ScopedHistory.createHref.$2.prependBasePath", + "type": "CompoundType", + "tags": [], + "label": "prependBasePath", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/application/core-application-browser/src/scoped_history.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ShipperClassConstructor", + "type": "Interface", + "tags": [], + "label": "ShipperClassConstructor", + "description": [ + "\nConstructor of a {@link IShipper}" + ], + "signature": [ + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.ShipperClassConstructor", + "text": "ShipperClassConstructor" + }, + "" + ], + "path": "packages/analytics/client/src/analytics_client/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ShipperClassConstructor.shipperName", + "type": "string", + "tags": [], + "label": "shipperName", + "description": [ + "\nThe shipper's unique name" + ], + "path": "packages/analytics/client/src/analytics_client/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.ShipperClassConstructor.new", + "type": "Function", + "tags": [], + "label": "new", + "description": [ + "\nThe constructor" + ], + "signature": [ + "any" + ], + "path": "packages/analytics/client/src/analytics_client/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ShipperClassConstructor.new.$1", + "type": "Uncategorized", + "tags": [], + "label": "config", + "description": [ + "The shipper's custom config" + ], + "signature": [ + "Config" + ], + "path": "packages/analytics/client/src/analytics_client/types.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.ShipperClassConstructor.new.$2", + "type": "Object", + "tags": [], + "label": "initContext", + "description": [ + "Common context {@link AnalyticsClientInitContext }" + ], + "signature": [ + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.AnalyticsClientInitContext", + "text": "AnalyticsClientInitContext" + } + ], + "path": "packages/analytics/client/src/analytics_client/types.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SimpleSavedObject", + "description": [ + "\nVery simple wrapper for SavedObjects loaded from the server\nwith the {@link SavedObjectsClientContract}.\n\nIt provides basic functionality for creating/saving/deleting saved objects,\nbut doesn't include any type-specific implementations.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "aiops", + "path": "x-pack/plugins/aiops/public/application/utils/search_utils.ts" + }, + { + "plugin": "aiops", + "path": "x-pack/plugins/aiops/public/application/utils/search_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/kibana.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/kibana.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/common/types/index.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/common/types/index.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/app_state.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/app_state.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/types.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + } + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.attributes", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "attributes of the object, templated" + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject._version", + "type": "string", + "tags": [], + "label": "_version", + "description": [ + " version of the saved object" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "ID of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "Type of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.migrationVersion", + "type": "Object", + "tags": [], + "label": "migrationVersion", + "description": [ + "Migration version of the saved object" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsMigrationVersion", + "text": "SavedObjectsMigrationVersion" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.coreMigrationVersion", + "type": "string", + "tags": [], + "label": "coreMigrationVersion", + "description": [ + "Core migration version of the saved object" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.error", + "type": "Object", + "tags": [], + "label": "error", + "description": [ + "Error associated with this object, undefined if no error" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectError", + "text": "SavedObjectError" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "References to other saved objects" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.updatedAt", + "type": "string", + "tags": [], + "label": "updatedAt", + "description": [ + "The date this object was last updated" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.createdAt", + "type": "string", + "tags": [], + "label": "createdAt", + "description": [ + "The date this object was created" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.namespaces", + "type": "Array", + "tags": [], + "label": "namespaces", + "description": [ + "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." + ], + "signature": [ + "string[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.get", + "type": "Function", + "tags": [], + "label": "get", + "description": [ + "\nGets an attribute of this object\n" + ], + "signature": [ + "(key: string) => any" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.get.$1", + "type": "string", + "tags": [], + "label": "key", + "description": [ + "- the name of the attribute" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "The value of the attribute." + ] + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.set", + "type": "Function", + "tags": [], + "label": "set", + "description": [ + "\nSets an attribute of this object\n" + ], + "signature": [ + "(key: string, value: any) => T" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.set.$1", + "type": "string", + "tags": [], + "label": "key", + "description": [ + "- the name of the attribute" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.set.$2", + "type": "Any", + "tags": [], + "label": "value", + "description": [ + "- the value for the attribute" + ], + "signature": [ + "any" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "The updated attributes of this object." + ] + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.has", + "type": "Function", + "tags": [], + "label": "has", + "description": [ + "\nChecks if this object has an attribute\n" + ], + "signature": [ + "(key: string) => boolean" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.has.$1", + "type": "string", + "tags": [], + "label": "key", + "description": [ + "- the name of the attribute" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "true if the attribute exists." + ] + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.save", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "save", + "description": [ + "\nSaves this object" + ], + "signature": [ + "() => Promise<", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + ">" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + } + ], + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "core", + "id": "def-public.SimpleSavedObject.delete", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "delete", + "description": [ + "\nDeletes this object" + ], + "signature": [ + "() => Promise<{}>" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + } + ], + "children": [], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter", + "type": "Interface", + "tags": [], + "label": "TelemetryCounter", + "description": [ + "\nShape of the events emitted by the telemetryCounter$ observable" + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter.type", + "type": "CompoundType", + "tags": [], + "label": "type", + "description": [ + "\n{@link TelemetryCounterType}" + ], + "signature": [ + "\"succeeded\" | \"failed\" | \"enqueued\" | \"sent_to_shipper\" | \"dropped\"" + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter.source", + "type": "string", + "tags": [], + "label": "source", + "description": [ + "\nWho emitted the event? It can be \"client\" or the name of the shipper." + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter.event_type", + "type": "string", + "tags": [], + "label": "event_type", + "description": [ + "\nThe event type the success/failure/drop event refers to." + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter.code", + "type": "string", + "tags": [], + "label": "code", + "description": [ + "\nCode to provide additional information about the success or failure. Examples are 200/400/504/ValidationError/UnknownError" + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.TelemetryCounter.count", + "type": "number", + "tags": [], + "label": "count", + "description": [ + "\nThe number of events that this counter refers to." + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ThemeServiceSetup", + "type": "Interface", + "tags": [], + "label": "ThemeServiceSetup", + "description": [], + "path": "packages/core/theme/core-theme-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ThemeServiceSetup.theme$", + "type": "Object", + "tags": [], + "label": "theme$", + "description": [], + "signature": [ + "Observable", + "<", + { + "pluginId": "@kbn/core-theme-browser", + "scope": "common", + "docId": "kibKbnCoreThemeBrowserPluginApi", + "section": "def-common.CoreTheme", + "text": "CoreTheme" + }, + ">" + ], + "path": "packages/core/theme/core-theme-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ThemeServiceStart", + "type": "Interface", + "tags": [], + "label": "ThemeServiceStart", + "description": [], + "path": "packages/core/theme/core-theme-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ThemeServiceStart.theme$", + "type": "Object", + "tags": [], + "label": "theme$", + "description": [], + "signature": [ + "Observable", + "<", + { + "pluginId": "@kbn/core-theme-browser", + "scope": "common", + "docId": "kibKbnCoreThemeBrowserPluginApi", + "section": "def-common.CoreTheme", + "text": "CoreTheme" + }, + ">" + ], + "path": "packages/core/theme/core-theme-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ToastOptions", + "type": "Interface", + "tags": [], + "label": "ToastOptions", + "description": [ + "\nOptions available for {@link IToasts} APIs." + ], + "path": "packages/core/notifications/core-notifications-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.ToastOptions.toastLifeTimeMs", + "type": "number", + "tags": [], + "label": "toastLifeTimeMs", + "description": [ + "\nHow long should the toast remain on screen." + ], + "signature": [ + "number | undefined" + ], + "path": "packages/core/notifications/core-notifications-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams", + "type": "Interface", + "tags": [], + "label": "UiSettingsParams", + "description": [ + "\nUiSettings parameters defined by the plugins." + ], + "signature": [ + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UiSettingsParams", + "text": "UiSettingsParams" + }, + "" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.name", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "title in the UI" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.value", + "type": "Uncategorized", + "tags": [], + "label": "value", + "description": [ + "default value to fall back to if a user doesn't provide any" + ], + "signature": [ + "T | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "description provided to a user in UI" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.category", + "type": "Array", + "tags": [], + "label": "category", + "description": [ + "used to group the configured setting in the UI" + ], + "signature": [ + "string[] | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.options", + "type": "CompoundType", + "tags": [], + "label": "options", + "description": [ + "array of permitted values for this setting" + ], + "signature": [ + "string[] | number[] | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.optionLabels", + "type": "Object", + "tags": [], + "label": "optionLabels", + "description": [ + "text labels for 'select' type UI element" + ], + "signature": [ + "Record | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.requiresPageReload", + "type": "CompoundType", + "tags": [], + "label": "requiresPageReload", + "description": [ + "a flag indicating whether new value applying requires page reloading" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.readonly", + "type": "CompoundType", + "tags": [], + "label": "readonly", + "description": [ + "a flag indicating that value cannot be changed" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.sensitive", + "type": "CompoundType", + "tags": [], + "label": "sensitive", + "description": [ + "\na flag indicating that value might contain user sensitive data.\nused by telemetry to mask the value of the setting when sent." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.type", + "type": "CompoundType", + "tags": [], + "label": "type", + "description": [ + "defines a type of UI element {@link UiSettingsType}" + ], + "signature": [ + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UiSettingsType", + "text": "UiSettingsType" + }, + " | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.deprecation", + "type": "Object", + "tags": [], + "label": "deprecation", + "description": [ + "optional deprecation information. Used to generate a deprecation warning." + ], + "signature": [ + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.DeprecationSettings", + "text": "DeprecationSettings" + }, + " | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.order", + "type": "number", + "tags": [], + "label": "order", + "description": [ + "\nindex of the settings within its category (ascending order, smallest will be displayed first).\nUsed for ordering in the UI.\n" + ], + "signature": [ + "number | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.schema", + "type": "Object", + "tags": [], + "label": "schema", + "description": [], + "signature": [ + { + "pluginId": "@kbn/config-schema", + "scope": "common", + "docId": "kibKbnConfigSchemaPluginApi", + "section": "def-common.Type", + "text": "Type" + }, + "" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.metric", + "type": "Object", + "tags": [ + "deprecated" + ], + "label": "metric", + "description": [ + "\nMetric to track once this property changes" + ], + "signature": [ + "{ type: string; name: string; } | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "advancedSettings", + "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/server/ui_settings.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/server/ui_settings.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/server/ui_settings.ts" + } + ] + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsParams.scope", + "type": "CompoundType", + "tags": [], + "label": "scope", + "description": [ + "\nScope of the setting. `Global` denotes a setting globally available across namespaces. `Namespace` denotes a setting\nscoped to a namespace. The default value is 'namespace'" + ], + "signature": [ + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UiSettingsScope", + "text": "UiSettingsScope" + }, + " | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.UiSettingsState", + "type": "Interface", + "tags": [], + "label": "UiSettingsState", + "description": [], + "path": "packages/core/ui-settings/core-ui-settings-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.UiSettingsState.Unnamed", + "type": "IndexSignature", + "tags": [], + "label": "[key: string]: PublicUiSettingsParams & UserProvidedValues", + "description": [], + "signature": [ + "[key: string]: ", + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.PublicUiSettingsParams", + "text": "PublicUiSettingsParams" + }, + " & ", + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UserProvidedValues", + "text": "UserProvidedValues" + }, + "" + ], + "path": "packages/core/ui-settings/core-ui-settings-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.UserProvidedValues", + "type": "Interface", + "tags": [], + "label": "UserProvidedValues", + "description": [ + "\nDescribes the values explicitly set by user." + ], + "signature": [ + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UserProvidedValues", + "text": "UserProvidedValues" + }, + "" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-public.UserProvidedValues.userValue", + "type": "Uncategorized", + "tags": [], + "label": "userValue", + "description": [], + "signature": [ + "T | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.UserProvidedValues.isOverridden", + "type": "CompoundType", + "tags": [], + "label": "isOverridden", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "enums": [ + { + "parentPluginId": "core", + "id": "def-public.AppLeaveActionType", + "type": "Enum", + "tags": [], + "label": "AppLeaveActionType", + "description": [ + "\nPossible type of actions on application leave.\n" + ], + "path": "packages/core/application/core-application-browser/src/app_leave.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppNavLinkStatus", + "type": "Enum", + "tags": [], + "label": "AppNavLinkStatus", + "description": [ + "\nStatus of the application's navLink.\n" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppStatus", + "type": "Enum", + "tags": [], + "label": "AppStatus", + "description": [ + "\nAccessibility status of an application.\n" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "misc": [ + { + "parentPluginId": "core", + "id": "def-public.AnalyticsServiceSetup", + "type": "Type", + "tags": [], + "label": "AnalyticsServiceSetup", + "description": [ + "\nExposes the public APIs of the AnalyticsClient during the setup phase.\n{@link AnalyticsClient}" + ], + "signature": [ + "{ optIn: (optInConfig: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.OptInConfig", + "text": "OptInConfig" + }, + ") => void; reportEvent: (eventType: string, eventData: EventTypeData) => void; readonly telemetryCounter$: ", + "Observable", + "<", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.TelemetryCounter", + "text": "TelemetryCounter" + }, + ">; registerEventType: (eventTypeOps: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.EventTypeOpts", + "text": "EventTypeOpts" + }, + ") => void; registerShipper: (Shipper: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.ShipperClassConstructor", + "text": "ShipperClassConstructor" + }, + ", shipperConfig: ShipperConfig, opts?: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.RegisterShipperOpts", + "text": "RegisterShipperOpts" + }, + " | undefined) => void; registerContextProvider: (contextProviderOpts: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.ContextProviderOpts", + "text": "ContextProviderOpts" + }, + ") => void; removeContextProvider: (contextProviderName: string) => void; }" + ], + "path": "packages/core/analytics/core-analytics-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AnalyticsServiceStart", + "type": "Type", + "tags": [], + "label": "AnalyticsServiceStart", + "description": [ + "\nExposes the public APIs of the AnalyticsClient during the start phase\n{@link AnalyticsClient}" + ], + "signature": [ + "{ optIn: (optInConfig: ", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.OptInConfig", + "text": "OptInConfig" + }, + ") => void; reportEvent: (eventType: string, eventData: EventTypeData) => void; readonly telemetryCounter$: ", + "Observable", + "<", + { + "pluginId": "@kbn/analytics-client", + "scope": "common", + "docId": "kibKbnAnalyticsClientPluginApi", + "section": "def-common.TelemetryCounter", + "text": "TelemetryCounter" + }, + ">; }" + ], + "path": "packages/core/analytics/core-analytics-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.APP_WRAPPER_CLASS", + "type": "string", + "tags": [], + "label": "APP_WRAPPER_CLASS", + "description": [ + "\nThe class name for top level *and* nested application wrappers to ensure proper layout" + ], + "signature": [ + "\"kbnAppWrapper\"" + ], + "path": "packages/core/application/core-application-common/src/app_wrapper_class.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppDeepLink", + "type": "Type", + "tags": [], + "label": "AppDeepLink", + "description": [ + "\nInput type for registering secondary in-app locations for an application.\n\nDeep links must include at least one of `path` or `deepLinks`. A deep link that does not have a `path`\nrepresents a topological level in the application's hierarchy, but does not have a destination URL that is\nuser-accessible." + ], + "signature": [ + "{ id: string; title: string; keywords?: string[] | undefined; navLinkStatus?: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppNavLinkStatus", + "text": "AppNavLinkStatus" + }, + " | undefined; searchable?: boolean | undefined; } & ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppNavOptions", + "text": "AppNavOptions" + }, + " & ({ path: string; deepLinks?: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppDeepLink", + "text": "AppDeepLink" + }, + "[] | undefined; } | { path?: string | undefined; deepLinks: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppDeepLink", + "text": "AppDeepLink" + }, + "[]; })" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppLeaveAction", + "type": "Type", + "tags": [], + "label": "AppLeaveAction", + "description": [ + "\nPossible actions to return from a {@link AppLeaveHandler}\n\nSee {@link AppLeaveConfirmAction} and {@link AppLeaveDefaultAction}\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppLeaveDefaultAction", + "text": "AppLeaveDefaultAction" + }, + " | ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppLeaveConfirmAction", + "text": "AppLeaveConfirmAction" + } + ], + "path": "packages/core/application/core-application-browser/src/app_leave.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppLeaveHandler", + "type": "Type", + "tags": [], + "label": "AppLeaveHandler", + "description": [ + "\nA handler that will be executed before leaving the application, either when\ngoing to another application or when closing the browser tab or manually changing\nthe url.\nShould return `confirm` to prompt a message to the user before leaving the page, or `default`\nto keep the default behavior (doing nothing).\n\nSee {@link AppMountParameters} for detailed usage examples.\n" + ], + "signature": [ + "(factory: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppLeaveActionFactory", + "text": "AppLeaveActionFactory" + }, + ", nextAppId?: string | undefined) => ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppLeaveAction", + "text": "AppLeaveAction" + } + ], + "path": "packages/core/application/core-application-browser/src/app_leave.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.AppLeaveHandler.$1", + "type": "Object", + "tags": [], + "label": "factory", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppLeaveActionFactory", + "text": "AppLeaveActionFactory" + } + ], + "path": "packages/core/application/core-application-browser/src/app_leave.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppLeaveHandler.$2", + "type": "string", + "tags": [], + "label": "nextAppId", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/core/application/core-application-browser/src/app_leave.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppMount", + "type": "Type", + "tags": [], + "label": "AppMount", + "description": [ + "\nA mount function called when the user navigates to this app's route.\n" + ], + "signature": [ + "(params: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppMountParameters", + "text": "AppMountParameters" + }, + ") => ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppUnmount", + "text": "AppUnmount" + }, + " | Promise<", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppUnmount", + "text": "AppUnmount" + }, + ">" + ], + "path": "packages/core/application/core-application-browser/src/app_mount.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [ + "An unmounting function that will be called to unmount the application. See {@link AppUnmount }." + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.AppMount.$1", + "type": "Object", + "tags": [], + "label": "params", + "description": [ + "{@link AppMountParameters }" + ], + "signature": [ + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppMountParameters", + "text": "AppMountParameters" + }, + "" + ], + "path": "packages/core/application/core-application-browser/src/app_mount.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppUnmount", + "type": "Type", + "tags": [], + "label": "AppUnmount", + "description": [ + "\nA function called when an application should be unmounted from the page. This function should be synchronous." + ], + "signature": [ + "() => void" + ], + "path": "packages/core/application/core-application-browser/src/app_mount.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppUpdatableFields", + "type": "Type", + "tags": [], + "label": "AppUpdatableFields", + "description": [ + "\nDefines the list of fields that can be updated via an {@link AppUpdater}." + ], + "signature": [ + "{ status?: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppStatus", + "text": "AppStatus" + }, + " | undefined; tooltip?: string | undefined; searchable?: boolean | undefined; deepLinks?: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppDeepLink", + "text": "AppDeepLink" + }, + "[] | undefined; navLinkStatus?: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppNavLinkStatus", + "text": "AppNavLinkStatus" + }, + " | undefined; defaultPath?: string | undefined; }" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.AppUpdater", + "type": "Type", + "tags": [], + "label": "AppUpdater", + "description": [ + "\nUpdater for applications.\nsee {@link ApplicationSetup}" + ], + "signature": [ + "(app: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.App", + "text": "App" + }, + ") => Partial<", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppUpdatableFields", + "text": "AppUpdatableFields" + }, + "> | undefined" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.AppUpdater.$1", + "type": "Object", + "tags": [], + "label": "app", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.App", + "text": "App" + }, + "" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ChromeBreadcrumb", + "type": "Type", + "tags": [], + "label": "ChromeBreadcrumb", + "description": [], + "signature": [ + "Omit, \"color\" | \"aria-current\"> & ", + "CommonProps", + " & { href?: string | undefined; rel?: string | undefined; onClick?: React.MouseEventHandler | undefined; text: React.ReactNode; truncate?: boolean | undefined; color?: \"warning\" | \"subdued\" | \"primary\" | \"accent\" | \"success\" | \"danger\" | \"text\" | \"ghost\" | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; }" + ], + "path": "packages/core/chrome/core-chrome-browser/src/breadcrumb.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ChromeHelpExtensionLinkBase", + "type": "Type", + "tags": [], + "label": "ChromeHelpExtensionLinkBase", + "description": [], + "signature": [ + "{ iconType?: ", + "IconType", + " | undefined; 'data-test-subj'?: string | undefined; rel?: string | undefined; target?: string | (string & {}) | undefined; }" + ], + "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ChromeHelpExtensionMenuLink", + "type": "Type", + "tags": [], + "label": "ChromeHelpExtensionMenuLink", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-chrome-browser", + "scope": "common", + "docId": "kibKbnCoreChromeBrowserPluginApi", + "section": "def-common.ChromeHelpExtensionMenuGitHubLink", + "text": "ChromeHelpExtensionMenuGitHubLink" + }, + " | ", + { + "pluginId": "@kbn/core-chrome-browser", + "scope": "common", + "docId": "kibKbnCoreChromeBrowserPluginApi", + "section": "def-common.ChromeHelpExtensionMenuDiscussLink", + "text": "ChromeHelpExtensionMenuDiscussLink" + }, + " | ", + { + "pluginId": "@kbn/core-chrome-browser", + "scope": "common", + "docId": "kibKbnCoreChromeBrowserPluginApi", + "section": "def-common.ChromeHelpExtensionMenuDocumentationLink", + "text": "ChromeHelpExtensionMenuDocumentationLink" + }, + " | ", + { + "pluginId": "@kbn/core-chrome-browser", + "scope": "common", + "docId": "kibKbnCoreChromeBrowserPluginApi", + "section": "def-common.ChromeHelpExtensionMenuCustomLink", + "text": "ChromeHelpExtensionMenuCustomLink" + } + ], + "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.DomainDeprecationDetails", + "type": "Type", + "tags": [], + "label": "DomainDeprecationDetails", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-deprecations-common", + "scope": "common", + "docId": "kibKbnCoreDeprecationsCommonPluginApi", + "section": "def-common.DeprecationsDetails", + "text": "DeprecationsDetails" + }, + " & { domainId: string; }" + ], + "path": "packages/core/deprecations/core-deprecations-common/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.EventType", + "type": "Type", + "tags": [], + "label": "EventType", + "description": [ + "\nEvent Type used for indexed structures. Only used to improve the readability of the types" + ], + "signature": [ + "string" + ], + "path": "packages/analytics/client/src/events/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ExecutionContextStart", + "type": "Type", + "tags": [], + "label": "ExecutionContextStart", + "description": [ + "\nSee {@link ExecutionContextSetup}." + ], + "signature": [ + { + "pluginId": "@kbn/core-execution-context-browser", + "scope": "common", + "docId": "kibKbnCoreExecutionContextBrowserPluginApi", + "section": "def-common.ExecutionContextSetup", + "text": "ExecutionContextSetup" + } + ], + "path": "packages/core/execution-context/core-execution-context-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.FatalErrorsStart", + "type": "Type", + "tags": [], + "label": "FatalErrorsStart", + "description": [ + "\nFatalErrors stop the Kibana Public Core and displays a fatal error screen\nwith details about the Kibana build and the error.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-fatal-errors-browser", + "scope": "common", + "docId": "kibKbnCoreFatalErrorsBrowserPluginApi", + "section": "def-common.FatalErrorsSetup", + "text": "FatalErrorsSetup" + } + ], + "path": "packages/core/fatal-errors/core-fatal-errors-browser/src/contract.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.HttpStart", + "type": "Type", + "tags": [], + "label": "HttpStart", + "description": [ + "\nSee {@link HttpSetup}" + ], + "signature": [ + { + "pluginId": "@kbn/core-http-browser", + "scope": "common", + "docId": "kibKbnCoreHttpBrowserPluginApi", + "section": "def-common.HttpSetup", + "text": "HttpSetup" + } + ], + "path": "packages/core/http/core-http-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.KibanaExecutionContext", + "type": "Type", + "tags": [], + "label": "KibanaExecutionContext", + "description": [], + "signature": [ + "{ readonly type?: string | undefined; readonly name?: string | undefined; readonly page?: string | undefined; readonly id?: string | undefined; readonly description?: string | undefined; readonly url?: string | undefined; readonly meta?: { [key: string]: string | number | boolean | undefined; } | undefined; child?: ", + { + "pluginId": "@kbn/core-execution-context-common", + "scope": "common", + "docId": "kibKbnCoreExecutionContextCommonPluginApi", + "section": "def-common.KibanaExecutionContext", + "text": "KibanaExecutionContext" + }, + " | undefined; }" + ], + "path": "packages/core/execution-context/core-execution-context-common/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.MountPoint", + "type": "Type", + "tags": [], + "label": "MountPoint", + "description": [ + "\nA function that should mount DOM content inside the provided container element\nand return a handler to unmount it.\n" + ], + "signature": [ + "(element: T) => ", + { + "pluginId": "@kbn/core-mount-utils-browser", + "scope": "common", + "docId": "kibKbnCoreMountUtilsBrowserPluginApi", + "section": "def-common.UnmountCallback", + "text": "UnmountCallback" + } + ], + "path": "packages/core/mount-utils/core-mount-utils-browser/src/mount_point.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [ + "a {@link UnmountCallback } that unmount the element on call." + ], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.MountPoint.$1", + "type": "Uncategorized", + "tags": [], + "label": "element", + "description": [ + "the container element to render into" + ], + "signature": [ + "T" + ], + "path": "packages/core/mount-utils/core-mount-utils-browser/src/mount_point.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.PluginInitializer", + "type": "Type", + "tags": [], + "label": "PluginInitializer", + "description": [ + "\nThe `plugin` export at the root of a plugin's `public` directory should conform\nto this interface.\n" + ], + "signature": [ + "(core: ", + { + "pluginId": "@kbn/core-plugins-browser", + "scope": "common", + "docId": "kibKbnCorePluginsBrowserPluginApi", + "section": "def-common.PluginInitializerContext", + "text": "PluginInitializerContext" + }, + ") => ", + { + "pluginId": "@kbn/core-plugins-browser", + "scope": "common", + "docId": "kibKbnCorePluginsBrowserPluginApi", + "section": "def-common.Plugin", + "text": "Plugin" + }, + "" + ], + "path": "packages/core/plugins/core-plugins-browser/src/plugin_initializer.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "core", + "id": "def-public.PluginInitializer.$1", + "type": "Object", + "tags": [], + "label": "core", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-plugins-browser", + "scope": "common", + "docId": "kibKbnCorePluginsBrowserPluginApi", + "section": "def-common.PluginInitializerContext", + "text": "PluginInitializerContext" + }, + "" + ], + "path": "packages/core/plugins/core-plugins-browser/src/plugin_initializer.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.PluginOpaqueId", + "type": "Type", + "tags": [], + "label": "PluginOpaqueId", + "description": [], + "signature": [ + "symbol" + ], + "path": "packages/core/base/core-base-common/src/plugins.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.PublicAppDeepLinkInfo", + "type": "Type", + "tags": [], + "label": "PublicAppDeepLinkInfo", + "description": [ + "\nPublic information about a registered app's {@link AppDeepLink | deepLinks}\n" + ], + "signature": [ + "Omit<", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppDeepLink", + "text": "AppDeepLink" + }, + ", \"searchable\" | \"keywords\" | \"deepLinks\" | \"navLinkStatus\"> & { deepLinks: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.PublicAppDeepLinkInfo", + "text": "PublicAppDeepLinkInfo" + }, + "[]; keywords: string[]; navLinkStatus: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppNavLinkStatus", + "text": "AppNavLinkStatus" + }, + "; searchable: boolean; }" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.PublicAppInfo", + "type": "Type", + "tags": [], + "label": "PublicAppInfo", + "description": [ + "\nPublic information about a registered {@link App | application}\n" + ], + "signature": [ + "Omit<", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.App", + "text": "App" + }, + ", \"searchable\" | \"mount\" | \"updater$\" | \"keywords\" | \"deepLinks\"> & { status: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppStatus", + "text": "AppStatus" + }, + "; navLinkStatus: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.AppNavLinkStatus", + "text": "AppNavLinkStatus" + }, + "; appRoute: string; keywords: string[]; deepLinks: ", + { + "pluginId": "@kbn/core-application-browser", + "scope": "common", + "docId": "kibKbnCoreApplicationBrowserPluginApi", + "section": "def-common.PublicAppDeepLinkInfo", + "text": "PublicAppDeepLinkInfo" + }, + "[]; searchable: boolean; }" + ], + "path": "packages/core/application/core-application-browser/src/application.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.PublicUiSettingsParams", + "type": "Type", + "tags": [], + "label": "PublicUiSettingsParams", + "description": [ + "\nA sub-set of {@link UiSettingsParams} exposed to the client-side." + ], + "signature": [ + "{ name?: string | undefined; value?: unknown; description?: string | undefined; category?: string[] | undefined; options?: string[] | number[] | undefined; optionLabels?: Record | undefined; requiresPageReload?: boolean | undefined; readonly?: boolean | undefined; sensitive?: boolean | undefined; type?: ", + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UiSettingsType", + "text": "UiSettingsType" + }, + " | undefined; deprecation?: ", + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.DeprecationSettings", + "text": "DeprecationSettings" + }, + " | undefined; order?: number | undefined; metric?: { type: string; name: string; } | undefined; scope?: ", + { + "pluginId": "@kbn/core-ui-settings-common", + "scope": "common", + "docId": "kibKbnCoreUiSettingsCommonPluginApi", + "section": "def-common.UiSettingsScope", + "text": "UiSettingsScope" + }, + " | undefined; }" + ], + "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.ResolveDeprecationResponse", + "type": "Type", + "tags": [], + "label": "ResolveDeprecationResponse", + "description": [ + "\nResponse from correctiveActions.api call from automatically resolving the deprecation" + ], + "signature": [ + "{ status: \"ok\"; } | { status: \"fail\"; reason: string; }" + ], + "path": "packages/core/deprecations/core-deprecations-browser/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObject", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObject", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/common/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectAttribute", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttribute", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" + }, + { + "plugin": "advancedSettings", + "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" + }, + { + "plugin": "advancedSettings", + "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-public.SavedObjectAttributes", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttributes", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/types.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/common/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/common/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/modules.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/modules.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsCreateOptions.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritDoc SavedObjectsMigrationVersion}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsCreateOptions.coreMigrationVersion", - "type": "string", - "tags": [], - "label": "coreMigrationVersion", - "description": [ - "A semver value that is used when upgrading objects between Kibana versions." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsCreateOptions.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "Array of referenced saved objects." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" } ], "initialIsOpen": false }, { "parentPluginId": "core", - "id": "def-public.SavedObjectsDeleteOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsDeleteOptions", - "description": [ - "\nOptions for deleting a saved object.\n" + "id": "def-public.SavedObjectAttributeSingle", + "type": "Type", + "tags": [ + "deprecated" ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", - "deprecated": false, + "label": "SavedObjectAttributeSingle", + "description": [], + "signature": [ + "string | number | boolean | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributes", + "text": "SavedObjectAttributes" + }, + " | null | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsDeleteOptions.force", - "type": "CompoundType", - "tags": [], - "label": "force", - "description": [ - "Force deletion of an object that exists in multiple namespaces (default=false)" - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" } ], "initialIsOpen": false }, { "parentPluginId": "core", - "id": "def-public.SavedObjectsFindOptionsReference", - "type": "Interface", - "tags": [], - "label": "SavedObjectsFindOptionsReference", - "description": [ - "\nAn object reference for use in find operation options\n" + "id": "def-public.SavedObjectReference", + "type": "Type", + "tags": [ + "deprecated" ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, + "label": "SavedObjectReference", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindOptionsReference.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "The type of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindOptionsReference.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsFindResponse", - "description": [ - "\nReturn type of the Saved Objects `find()` method.\n" - ], - "signature": [ + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsFindResponse", - "text": "SavedObjectsFindResponse" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts" }, - " extends ", { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBatchResponse", - "text": "SavedObjectsBatchResponse" + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindResponse.aggregations", - "type": "Uncategorized", - "tags": [], - "label": "aggregations", - "description": [ - "aggregations from the search query" - ], - "signature": [ - "A | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindResponse.total", - "type": "number", - "tags": [], - "label": "total", - "description": [ - "total number of results" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindResponse.perPage", - "type": "number", - "tags": [], - "label": "perPage", - "description": [ - "number of results per page" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsFindResponse.page", - "type": "number", - "tags": [], - "label": "page", - "description": [ - "current page in results" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportActionRequiredWarning", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportActionRequiredWarning", - "description": [ - "\nA warning meant to notify that a specific user action is required to finalize the import\nof some type of object.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportActionRequiredWarning.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"action_required\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportActionRequiredWarning.message", - "type": "string", - "tags": [], - "label": "message", - "description": [ - "The translated message to display to the user." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportActionRequiredWarning.actionPath", - "type": "string", - "tags": [], - "label": "actionPath", - "description": [ - "The path (without the basePath) that the user should be redirect to address this warning." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportActionRequiredWarning.buttonLabel", - "type": "string", - "tags": [], - "label": "buttonLabel", - "description": [ - "An optional label to use for the link button. If unspecified, a default label will be used." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportAmbiguousConflictError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportAmbiguousConflictError", - "description": [ - "\nRepresents a failure to import due to a conflict, which can be resolved in different ways with an overwrite." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportAmbiguousConflictError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"ambiguous_conflict\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportAmbiguousConflictError.destinations", - "type": "Array", - "tags": [], - "label": "destinations", - "description": [], - "signature": [ - "{ id: string; title?: string | undefined; updatedAt?: string | undefined; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportConflictError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportConflictError", - "description": [ - "\nRepresents a failure to import due to a conflict." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportConflictError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"conflict\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportConflictError.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportFailure", - "description": [ - "\nRepresents a failure to import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/services/types/record.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/services/types/record.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure.meta", - "type": "Object", - "tags": [], - "label": "meta", - "description": [], - "signature": [ - "{ title?: string | undefined; icon?: string | undefined; }" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "\nIf `overwrite` is specified, an attempt was made to overwrite an existing object." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportFailure.error", - "type": "CompoundType", - "tags": [], - "label": "error", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportConflictError", - "text": "SavedObjectsImportConflictError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportAmbiguousConflictError", - "text": "SavedObjectsImportAmbiguousConflictError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportUnsupportedTypeError", - "text": "SavedObjectsImportUnsupportedTypeError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportMissingReferencesError", - "text": "SavedObjectsImportMissingReferencesError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportUnknownError", - "text": "SavedObjectsImportUnknownError" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportMissingReferencesError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportMissingReferencesError", - "description": [ - "\nRepresents a failure to import due to missing references." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportMissingReferencesError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"missing_references\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportMissingReferencesError.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [], - "signature": [ - "{ type: string; id: string; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportResponse", - "description": [ - "\nThe response describing the result of an import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse.success", - "type": "boolean", - "tags": [], - "label": "success", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse.successCount", - "type": "number", - "tags": [], - "label": "successCount", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse.successResults", - "type": "Array", - "tags": [], - "label": "successResults", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportSuccess", - "text": "SavedObjectsImportSuccess" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse.warnings", - "type": "Array", - "tags": [], - "label": "warnings", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportWarning", - "text": "SavedObjectsImportWarning" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportResponse.errors", - "type": "Array", - "tags": [], - "label": "errors", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportFailure", - "text": "SavedObjectsImportFailure" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportRetry", - "description": [ - "\nDescribes a retry operation for importing a saved object." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.overwrite", - "type": "boolean", - "tags": [], - "label": "overwrite", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [ - "\nThe object ID that will be created or overwritten. If not specified, the `id` field will be used." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.replaceReferences", - "type": "Array", - "tags": [], - "label": "replaceReferences", - "description": [], - "signature": [ - "{ type: string; from: string; to: string; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.createNewCopy", - "type": "CompoundType", - "tags": [], - "label": "createNewCopy", - "description": [ - "\nIf `createNewCopy` is specified, the new object has a new (undefined) origin ID. This is only needed for the case where\n`createNewCopies` mode is disabled and ambiguous source conflicts are detected." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportRetry.ignoreMissingReferences", - "type": "CompoundType", - "tags": [], - "label": "ignoreMissingReferences", - "description": [ - "\nIf `ignoreMissingReferences` is specified, reference validation will be skipped for this object." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSimpleWarning", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportSimpleWarning", - "description": [ - "\nA simple informative warning that will be displayed to the user.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSimpleWarning.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"simple\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSimpleWarning.message", - "type": "string", - "tags": [], - "label": "message", - "description": [ - "The translated message to display to the user" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportSuccess", - "description": [ - "\nRepresents a successful import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/text_based/text_based_languages.tsx" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/text_based/text_based_languages.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/save_modal_container.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [ - "\nIf `destinationId` is specified, the new object has a new ID that is different from the import ID." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/save_modal_container.tsx" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.createNewCopy", - "type": "CompoundType", - "tags": [ - "deprecated" - ], - "label": "createNewCopy", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "spaces", - "path": "x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx" - }, - { - "plugin": "savedObjectsManagement", - "path": "src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts" - } - ] + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.meta", - "type": "Object", - "tags": [], - "label": "meta", - "description": [], - "signature": [ - "{ title?: string | undefined; icon?: string | undefined; }" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportSuccess.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "\nIf `overwrite` is specified, this object overwrote an existing one (or will do so, in the case of a pending resolution)." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnknownError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportUnknownError", - "description": [ - "\nRepresents a failure to import due to an unknown reason." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnknownError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"unknown\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnknownError.message", - "type": "string", - "tags": [], - "label": "message", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/persistence.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnknownError.statusCode", - "type": "number", - "tags": [], - "label": "statusCode", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnsupportedTypeError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportUnsupportedTypeError", - "description": [ - "\nRepresents a failure to import due to having an unsupported saved object type." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/persistence.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsImportUnsupportedTypeError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"unsupported_type\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsMigrationVersion", - "type": "Interface", - "tags": [], - "label": "SavedObjectsMigrationVersion", - "description": [ - "\nInformation about the migrations that have been applied to this SavedObject.\nWhen Kibana starts up, KibanaMigrator detects outdated documents and\nmigrates them based on this value. For each migration that has been applied,\nthe plugin's name is used as a key and the latest migration version as the\nvalue.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsMigrationVersion.Unnamed", - "type": "IndexSignature", - "tags": [], - "label": "[pluginName: string]: string", - "description": [ - "The plugin name and version string" - ], - "signature": [ - "[pluginName: string]: string" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsStart", - "type": "Interface", - "tags": [], - "label": "SavedObjectsStart", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsStart.client", - "type": "Object", - "tags": [], - "label": "client", - "description": [ - "{@link SavedObjectsClientContract}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsClientContract", - "text": "SavedObjectsClientContract" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectsUpdateOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsUpdateOptions", - "description": [ - "\nOptions for updating a saved object\n" - ], - "signature": [ + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsUpdateOptions", - "text": "SavedObjectsUpdateOptions" + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/bwc/types.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.SavedObjectsUpdateOptions.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "version of the saved object" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/bwc/types.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsUpdateOptions.upsert", - "type": "Uncategorized", - "tags": [], - "label": "upsert", - "description": [ - "Alternative attributes for the saved object if upserting" - ], - "signature": [ - "Attributes | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectsUpdateOptions.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "Array of references to other saved objects" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectTypeIdTuple", - "type": "Interface", - "tags": [], - "label": "SavedObjectTypeIdTuple", - "description": [ - "\nAn identifier for a saved object within a space.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" + }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectTypeIdTuple.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The id of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "parentPluginId": "core", - "id": "def-public.SavedObjectTypeIdTuple.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "The type of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ScopedHistory", - "type": "Interface", - "tags": [], - "label": "ScopedHistory", - "description": [ - "\nA wrapper around a `History` instance that is scoped to a particular base path of the history stack. Behaves\nsimilarly to the `basename` option except that this wrapper hides any history stack entries from outside the scope\nof this base path.\n\nThis wrapper also allows Core and Plugins to share a single underlying global `History` instance without exposing\nthe history of other applications.\n\nThe {@link ScopedHistory.createSubHistory | createSubHistory} method is particularly useful for applications that\ncontain any number of \"sub-apps\" which should not have access to the main application's history or basePath.\n" - ], - "signature": [ + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" + }, { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.ScopedHistory", - "text": "ScopedHistory" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, - " extends ", - "History", - "" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createSubHistory", - "type": "Function", - "tags": [], - "label": "createSubHistory", - "description": [ - "\nCreates a `ScopedHistory` for a subpath of this `ScopedHistory`. Useful for applications that may have sub-apps\nthat do not need access to the containing application's history.\n" - ], - "signature": [ - "(basePath: string) => ", - { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.ScopedHistory", - "text": "ScopedHistory" - }, - "" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createSubHistory.$1", - "type": "string", - "tags": [], - "label": "basePath", - "description": [ - "the URL path scope for the sub history" - ], - "signature": [ - "string" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createHref", - "type": "Function", - "tags": [], - "label": "createHref", - "description": [ - "\nCreates an href (string) to the location.\nIf `prependBasePath` is true (default), it will prepend the location's path with the scoped history basePath.\n" - ], - "signature": [ - "(location: ", - "LocationDescriptorObject", - ", options?: { prependBasePath?: boolean | undefined; } | undefined) => string" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createHref.$1", - "type": "Object", - "tags": [], - "label": "location", - "description": [], - "signature": [ - "LocationDescriptorObject", - "" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createHref.$2", - "type": "Object", - "tags": [], - "label": "options", - "description": [], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.ScopedHistory.createHref.$2.prependBasePath", - "type": "CompoundType", - "tags": [], - "label": "prependBasePath", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/application/core-application-browser/src/scoped_history.ts", - "deprecated": false, - "trackAdoption": false - } - ] - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ShipperClassConstructor", - "type": "Interface", - "tags": [], - "label": "ShipperClassConstructor", - "description": [ - "\nConstructor of a {@link IShipper}" - ], - "signature": [ + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts" + }, { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.ShipperClassConstructor", - "text": "ShipperClassConstructor" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts" }, - "" - ], - "path": "packages/analytics/client/src/analytics_client/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.ShipperClassConstructor.shipperName", - "type": "string", - "tags": [], - "label": "shipperName", - "description": [ - "\nThe shipper's unique name" - ], - "path": "packages/analytics/client/src/analytics_client/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" }, { - "parentPluginId": "core", - "id": "def-public.ShipperClassConstructor.new", - "type": "Function", - "tags": [], - "label": "new", - "description": [ - "\nThe constructor" - ], - "signature": [ - "any" - ], - "path": "packages/analytics/client/src/analytics_client/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.ShipperClassConstructor.new.$1", - "type": "Uncategorized", - "tags": [], - "label": "config", - "description": [ - "The shipper's custom config" - ], - "signature": [ - "Config" - ], - "path": "packages/analytics/client/src/analytics_client/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "core", - "id": "def-public.ShipperClassConstructor.new.$2", - "type": "Object", - "tags": [], - "label": "initContext", - "description": [ - "Common context {@link AnalyticsClientInitContext }" - ], - "signature": [ - { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.AnalyticsClientInitContext", - "text": "AnalyticsClientInitContext" - } - ], - "path": "packages/analytics/client/src/analytics_client/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject", - "type": "Interface", - "tags": [], - "label": "SimpleSavedObject", - "description": [ - "\nVery simple wrapper for SavedObjects loaded from the server\nwith the {@link SavedObjectsClientContract}.\n\nIt provides basic functionality for creating/saving/deleting saved objects,\nbut doesn't include any type-specific implementations.\n" - ], - "signature": [ + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" + }, + { + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" + }, + { + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" + }, + { + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" + }, + { + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" + }, + { + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" + }, + { + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" + }, + { + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" + }, + { + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" + }, + { + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "attributes of the object, templated" - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject._version", - "type": "string", - "tags": [], - "label": "_version", - "description": [ - " version of the saved object" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "ID of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "Type of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "Migration version of the saved object" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.coreMigrationVersion", - "type": "string", - "tags": [], - "label": "coreMigrationVersion", - "description": [ - "Core migration version of the saved object" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.error", - "type": "Object", - "tags": [], - "label": "error", - "description": [ - "Error associated with this object, undefined if no error" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "References to other saved objects" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/search/expressions/kibana_context.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.updatedAt", - "type": "string", - "tags": [], - "label": "updatedAt", - "description": [ - "The date this object was last updated" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/search/expressions/kibana_context.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.createdAt", - "type": "string", - "tags": [], - "label": "createdAt", - "description": [ - "The date this object was created" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.namespaces", - "type": "Array", - "tags": [], - "label": "namespaces", - "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." - ], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.get", - "type": "Function", - "tags": [], - "label": "get", - "description": [ - "\nGets an attribute of this object\n" - ], - "signature": [ - "(key: string) => any" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.get.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "- the name of the attribute" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "The value of the attribute." - ] + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.set", - "type": "Function", - "tags": [], - "label": "set", - "description": [ - "\nSets an attribute of this object\n" - ], - "signature": [ - "(key: string, value: any) => T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.set.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "- the name of the attribute" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.set.$2", - "type": "Any", - "tags": [], - "label": "value", - "description": [ - "- the value for the attribute" - ], - "signature": [ - "any" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "The updated attributes of this object." - ] + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.has", - "type": "Function", - "tags": [], - "label": "has", - "description": [ - "\nChecks if this object has an attribute\n" - ], - "signature": [ - "(key: string) => boolean" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.has.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "- the name of the attribute" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "true if the attribute exists." - ] + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.save", - "type": "Function", - "tags": [], - "label": "save", - "description": [ - "\nSaves this object" - ], - "signature": [ - "() => Promise<", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" - }, - ">" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.SimpleSavedObject.delete", - "type": "Function", - "tags": [], - "label": "delete", - "description": [ - "\nDeletes this object" - ], - "signature": [ - "() => Promise<{}>" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter", - "type": "Interface", - "tags": [], - "label": "TelemetryCounter", - "description": [ - "\nShape of the events emitted by the telemetryCounter$ observable" - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" + }, { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter.type", - "type": "CompoundType", - "tags": [], - "label": "type", - "description": [ - "\n{@link TelemetryCounterType}" - ], - "signature": [ - "\"succeeded\" | \"failed\" | \"enqueued\" | \"sent_to_shipper\" | \"dropped\"" - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter.source", - "type": "string", - "tags": [], - "label": "source", - "description": [ - "\nWho emitted the event? It can be \"client\" or the name of the shipper." - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter.event_type", - "type": "string", - "tags": [], - "label": "event_type", - "description": [ - "\nThe event type the success/failure/drop event refers to." - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter.code", - "type": "string", - "tags": [], - "label": "code", - "description": [ - "\nCode to provide additional information about the success or failure. Examples are 200/400/504/ValidationError/UnknownError" - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.TelemetryCounter.count", - "type": "number", - "tags": [], - "label": "count", - "description": [ - "\nThe number of events that this counter refers to." - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ThemeServiceSetup", - "type": "Interface", - "tags": [], - "label": "ThemeServiceSetup", - "description": [], - "path": "packages/core/theme/core-theme-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" + }, { - "parentPluginId": "core", - "id": "def-public.ThemeServiceSetup.theme$", - "type": "Object", - "tags": [], - "label": "theme$", - "description": [], - "signature": [ - "Observable", - "<", - { - "pluginId": "@kbn/core-theme-browser", - "scope": "common", - "docId": "kibKbnCoreThemeBrowserPluginApi", - "section": "def-common.CoreTheme", - "text": "CoreTheme" - }, - ">" - ], - "path": "packages/core/theme/core-theme-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ThemeServiceStart", - "type": "Interface", - "tags": [], - "label": "ThemeServiceStart", - "description": [], - "path": "packages/core/theme/core-theme-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/inject.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/inject.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, { - "parentPluginId": "core", - "id": "def-public.ThemeServiceStart.theme$", - "type": "Object", - "tags": [], - "label": "theme$", - "description": [], - "signature": [ - "Observable", - "<", - { - "pluginId": "@kbn/core-theme-browser", - "scope": "common", - "docId": "kibKbnCoreThemeBrowserPluginApi", - "section": "def-common.CoreTheme", - "text": "CoreTheme" - }, - ">" - ], - "path": "packages/core/theme/core-theme-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ToastOptions", - "type": "Interface", - "tags": [], - "label": "ToastOptions", - "description": [ - "\nOptions available for {@link IToasts} APIs." - ], - "path": "packages/core/notifications/core-notifications-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, { - "parentPluginId": "core", - "id": "def-public.ToastOptions.toastLifeTimeMs", - "type": "number", - "tags": [], - "label": "toastLifeTimeMs", - "description": [ - "\nHow long should the toast remain on screen." - ], - "signature": [ - "number | undefined" - ], - "path": "packages/core/notifications/core-notifications-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams", - "type": "Interface", - "tags": [], - "label": "UiSettingsParams", - "description": [ - "\nUiSettings parameters defined by the plugins." - ], - "signature": [ + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UiSettingsParams", - "text": "UiSettingsParams" + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, - "" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.name", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "title in the UI" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.value", - "type": "Uncategorized", - "tags": [], - "label": "value", - "description": [ - "default value to fall back to if a user doesn't provide any" - ], - "signature": [ - "T | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.description", - "type": "string", - "tags": [], - "label": "description", - "description": [ - "description provided to a user in UI" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.category", - "type": "Array", - "tags": [], - "label": "category", - "description": [ - "used to group the configured setting in the UI" - ], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.options", - "type": "CompoundType", - "tags": [], - "label": "options", - "description": [ - "array of permitted values for this setting" - ], - "signature": [ - "string[] | number[] | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.optionLabels", - "type": "Object", - "tags": [], - "label": "optionLabels", - "description": [ - "text labels for 'select' type UI element" - ], - "signature": [ - "Record | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.requiresPageReload", - "type": "CompoundType", - "tags": [], - "label": "requiresPageReload", - "description": [ - "a flag indicating whether new value applying requires page reloading" - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.readonly", - "type": "CompoundType", - "tags": [], - "label": "readonly", - "description": [ - "a flag indicating that value cannot be changed" - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.sensitive", - "type": "CompoundType", - "tags": [], - "label": "sensitive", - "description": [ - "\na flag indicating that value might contain user sensitive data.\nused by telemetry to mask the value of the setting when sent." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.type", - "type": "CompoundType", - "tags": [], - "label": "type", - "description": [ - "defines a type of UI element {@link UiSettingsType}" - ], - "signature": [ - { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UiSettingsType", - "text": "UiSettingsType" - }, - " | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.deprecation", - "type": "Object", - "tags": [], - "label": "deprecation", - "description": [ - "optional deprecation information. Used to generate a deprecation warning." - ], - "signature": [ - { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.DeprecationSettings", - "text": "DeprecationSettings" - }, - " | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.order", - "type": "number", - "tags": [], - "label": "order", - "description": [ - "\nindex of the settings within its category (ascending order, smallest will be displayed first).\nUsed for ordering in the UI.\n" - ], - "signature": [ - "number | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.schema", - "type": "Object", - "tags": [], - "label": "schema", - "description": [], - "signature": [ - { - "pluginId": "@kbn/config-schema", - "scope": "common", - "docId": "kibKbnConfigSchemaPluginApi", - "section": "def-common.Type", - "text": "Type" - }, - "" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.metric", - "type": "Object", - "tags": [ - "deprecated" - ], - "label": "metric", - "description": [ - "\nMetric to track once this property changes" - ], - "signature": [ - "{ type: string; name: string; } | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "advancedSettings", - "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" - }, - { - "plugin": "discover", - "path": "src/plugins/discover/server/ui_settings.ts" - }, - { - "plugin": "discover", - "path": "src/plugins/discover/server/ui_settings.ts" - }, - { - "plugin": "discover", - "path": "src/plugins/discover/server/ui_settings.ts" - } - ] + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsParams.scope", - "type": "CompoundType", - "tags": [], - "label": "scope", - "description": [ - "\nScope of the setting. `Global` denotes a setting globally available across namespaces. `Namespace` denotes a setting\nscoped to a namespace. The default value is 'namespace'" - ], - "signature": [ - { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UiSettingsScope", - "text": "UiSettingsScope" - }, - " | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.UiSettingsState", - "type": "Interface", - "tags": [], - "label": "UiSettingsState", - "description": [], - "path": "packages/core/ui-settings/core-ui-settings-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" + }, { - "parentPluginId": "core", - "id": "def-public.UiSettingsState.Unnamed", - "type": "IndexSignature", - "tags": [], - "label": "[key: string]: PublicUiSettingsParams & UserProvidedValues", - "description": [], - "signature": [ - "[key: string]: ", - { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.PublicUiSettingsParams", - "text": "PublicUiSettingsParams" - }, - " & ", - { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UserProvidedValues", - "text": "UserProvidedValues" - }, - "" - ], - "path": "packages/core/ui-settings/core-ui-settings-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.UserProvidedValues", - "type": "Interface", - "tags": [], - "label": "UserProvidedValues", - "description": [ - "\nDescribes the values explicitly set by user." - ], - "signature": [ + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" + }, { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UserProvidedValues", - "text": "UserProvidedValues" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, - "" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "core", - "id": "def-public.UserProvidedValues.userValue", - "type": "Uncategorized", - "tags": [], - "label": "userValue", - "description": [], - "signature": [ - "T | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "parentPluginId": "core", - "id": "def-public.UserProvidedValues.isOverridden", - "type": "CompoundType", - "tags": [], - "label": "isOverridden", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - } - ], - "enums": [ - { - "parentPluginId": "core", - "id": "def-public.AppLeaveActionType", - "type": "Enum", - "tags": [], - "label": "AppLeaveActionType", - "description": [ - "\nPossible type of actions on application leave.\n" - ], - "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppNavLinkStatus", - "type": "Enum", - "tags": [], - "label": "AppNavLinkStatus", - "description": [ - "\nStatus of the application's navLink.\n" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppStatus", - "type": "Enum", - "tags": [], - "label": "AppStatus", - "description": [ - "\nAccessibility status of an application.\n" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "misc": [ - { - "parentPluginId": "core", - "id": "def-public.AnalyticsServiceSetup", - "type": "Type", - "tags": [], - "label": "AnalyticsServiceSetup", - "description": [ - "\nExposes the public APIs of the AnalyticsClient during the setup phase.\n{@link AnalyticsClient}" - ], - "signature": [ - "{ optIn: (optInConfig: ", + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/components/connected/tag_list.tsx" + }, { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.OptInConfig", - "text": "OptInConfig" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/components/connected/tag_list.tsx" }, - ") => void; reportEvent: (eventType: string, eventData: EventTypeData) => void; readonly telemetryCounter$: ", - "Observable", - "<", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.TelemetryCounter", - "text": "TelemetryCounter" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts" }, - ">; registerEventType: (eventTypeOps: ", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.EventTypeOpts", - "text": "EventTypeOpts" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts" }, - ") => void; registerShipper: (Shipper: ", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.ShipperClassConstructor", - "text": "ShipperClassConstructor" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts" }, - ", shipperConfig: ShipperConfig, opts?: ", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.RegisterShipperOpts", - "text": "RegisterShipperOpts" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts" }, - " | undefined) => void; registerContextProvider: (contextProviderOpts: ", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.ContextProviderOpts", - "text": "ContextProviderOpts" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts" }, - ") => void; removeContextProvider: (contextProviderName: string) => void; }" - ], - "path": "packages/core/analytics/core-analytics-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AnalyticsServiceStart", - "type": "Type", - "tags": [], - "label": "AnalyticsServiceStart", - "description": [ - "\nExposes the public APIs of the AnalyticsClient during the start phase\n{@link AnalyticsClient}" - ], - "signature": [ - "{ optIn: (optInConfig: ", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.OptInConfig", - "text": "OptInConfig" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts" }, - ") => void; reportEvent: (eventType: string, eventData: EventTypeData) => void; readonly telemetryCounter$: ", - "Observable", - "<", { - "pluginId": "@kbn/analytics-client", - "scope": "common", - "docId": "kibKbnAnalyticsClientPluginApi", - "section": "def-common.TelemetryCounter", - "text": "TelemetryCounter" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, - ">; }" - ], - "path": "packages/core/analytics/core-analytics-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.APP_WRAPPER_CLASS", - "type": "string", - "tags": [], - "label": "APP_WRAPPER_CLASS", - "description": [ - "\nThe class name for top level *and* nested application wrappers to ensure proper layout" - ], - "signature": [ - "\"kbnAppWrapper\"" - ], - "path": "packages/core/application/core-application-common/src/app_wrapper_class.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppDeepLink", - "type": "Type", - "tags": [], - "label": "AppDeepLink", - "description": [ - "\nInput type for registering secondary in-app locations for an application.\n\nDeep links must include at least one of `path` or `deepLinks`. A deep link that does not have a `path`\nrepresents a topological level in the application's hierarchy, but does not have a destination URL that is\nuser-accessible." - ], - "signature": [ - "{ id: string; title: string; keywords?: string[] | undefined; navLinkStatus?: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppNavLinkStatus", - "text": "AppNavLinkStatus" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, - " | undefined; searchable?: boolean | undefined; } & ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppNavOptions", - "text": "AppNavOptions" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, - " & ({ path: string; deepLinks?: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppDeepLink", - "text": "AppDeepLink" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, - "[] | undefined; } | { path?: string | undefined; deepLinks: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppDeepLink", - "text": "AppDeepLink" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, - "[]; })" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppLeaveAction", - "type": "Type", - "tags": [], - "label": "AppLeaveAction", - "description": [ - "\nPossible actions to return from a {@link AppLeaveHandler}\n\nSee {@link AppLeaveConfirmAction} and {@link AppLeaveDefaultAction}\n" - ], - "signature": [ { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppLeaveDefaultAction", - "text": "AppLeaveDefaultAction" + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, - " | ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppLeaveConfirmAction", - "text": "AppLeaveConfirmAction" - } - ], - "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppLeaveHandler", - "type": "Type", - "tags": [ - "deprecated" - ], - "label": "AppLeaveHandler", - "description": [ - "\nA handler that will be executed before leaving the application, either when\ngoing to another application or when closing the browser tab or manually changing\nthe url.\nShould return `confirm` to prompt a message to the user before leaving the page, or `default`\nto keep the default behavior (doing nothing).\n\nSee {@link AppMountParameters} for detailed usage examples.\n" - ], - "signature": [ - "(factory: ", + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" + }, { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppLeaveActionFactory", - "text": "AppLeaveActionFactory" + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, - ", nextAppId?: string | undefined) => ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppLeaveAction", - "text": "AppLeaveAction" - } - ], - "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": true, - "removeBy": "8.8.0", - "trackAdoption": false, - "references": [ + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" + }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_leave.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_leave.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_leave.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_leave.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_mount.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/src/app_mount.ts" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts" }, { - "plugin": "@kbn/core-application-browser", - "path": "packages/core/application/core-application-browser/index.ts" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_router.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_router.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_leave.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_leave.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts" }, { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/types.ts" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/types.ts" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/routes.tsx" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/routes.tsx" + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts" + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts" - } - ], - "returnComment": [], - "children": [ + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" + }, { - "parentPluginId": "core", - "id": "def-public.AppLeaveHandler.$1", - "type": "Object", - "tags": [], - "label": "factory", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppLeaveActionFactory", - "text": "AppLeaveActionFactory" - } - ], - "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" }, { - "parentPluginId": "core", - "id": "def-public.AppLeaveHandler.$2", - "type": "string", - "tags": [], - "label": "nextAppId", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppMount", - "type": "Type", - "tags": [], - "label": "AppMount", - "description": [ - "\nA mount function called when the user navigates to this app's route.\n" - ], - "signature": [ - "(params: ", + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.test.ts" + }, { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppMountParameters", - "text": "AppMountParameters" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.test.ts" }, - ") => ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppUnmount", - "text": "AppUnmount" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" }, - " | Promise<", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppUnmount", - "text": "AppUnmount" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" }, - ">" - ], - "path": "packages/core/application/core-application-browser/src/app_mount.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [ - "An unmounting function that will be called to unmount the application. See {@link AppUnmount }." - ], - "children": [ { - "parentPluginId": "core", - "id": "def-public.AppMount.$1", - "type": "Object", - "tags": [], - "label": "params", - "description": [ - "{@link AppMountParameters }" - ], - "signature": [ - { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppMountParameters", - "text": "AppMountParameters" - }, - "" - ], - "path": "packages/core/application/core-application-browser/src/app_mount.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppUnmount", - "type": "Type", - "tags": [], - "label": "AppUnmount", - "description": [ - "\nA function called when an application should be unmounted from the page. This function should be synchronous." - ], - "signature": [ - "() => void" - ], - "path": "packages/core/application/core-application-browser/src/app_mount.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppUpdatableFields", - "type": "Type", - "tags": [], - "label": "AppUpdatableFields", - "description": [ - "\nDefines the list of fields that can be updated via an {@link AppUpdater}." - ], - "signature": [ - "{ status?: ", + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppStatus", - "text": "AppStatus" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, - " | undefined; tooltip?: string | undefined; searchable?: boolean | undefined; deepLinks?: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppDeepLink", - "text": "AppDeepLink" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, - "[] | undefined; navLinkStatus?: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppNavLinkStatus", - "text": "AppNavLinkStatus" + "plugin": "globalSearchProviders", + "path": "x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts" }, - " | undefined; defaultPath?: string | undefined; }" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.AppUpdater", - "type": "Type", - "tags": [], - "label": "AppUpdater", - "description": [ - "\nUpdater for applications.\nsee {@link ApplicationSetup}" - ], - "signature": [ - "(app: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.App", - "text": "App" + "plugin": "globalSearchProviders", + "path": "x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts" }, - ") => Partial<", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppUpdatableFields", - "text": "AppUpdatableFields" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/persistable_state.test.ts" }, - "> | undefined" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ { - "parentPluginId": "core", - "id": "def-public.AppUpdater.$1", - "type": "Object", - "tags": [], - "label": "app", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.App", - "text": "App" - }, - "" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ChromeBreadcrumb", - "type": "Type", - "tags": [], - "label": "ChromeBreadcrumb", - "description": [], - "signature": [ - "Omit, \"color\" | \"aria-current\"> & ", - "CommonProps", - " & { href?: string | undefined; rel?: string | undefined; onClick?: React.MouseEventHandler | undefined; text: React.ReactNode; truncate?: boolean | undefined; color?: \"warning\" | \"subdued\" | \"primary\" | \"accent\" | \"success\" | \"danger\" | \"text\" | \"ghost\" | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; }" - ], - "path": "packages/core/chrome/core-chrome-browser/src/breadcrumb.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ChromeHelpExtensionLinkBase", - "type": "Type", - "tags": [], - "label": "ChromeHelpExtensionLinkBase", - "description": [], - "signature": [ - "{ iconType?: ", - "IconType", - " | undefined; 'data-test-subj'?: string | undefined; rel?: string | undefined; target?: string | (string & {}) | undefined; }" - ], - "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ChromeHelpExtensionMenuLink", - "type": "Type", - "tags": [], - "label": "ChromeHelpExtensionMenuLink", - "description": [], - "signature": [ + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/persistable_state.test.ts" + }, { - "pluginId": "@kbn/core-chrome-browser", - "scope": "common", - "docId": "kibKbnCoreChromeBrowserPluginApi", - "section": "def-common.ChromeHelpExtensionMenuGitHubLink", - "text": "ChromeHelpExtensionMenuGitHubLink" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" }, - " | ", { - "pluginId": "@kbn/core-chrome-browser", - "scope": "common", - "docId": "kibKbnCoreChromeBrowserPluginApi", - "section": "def-common.ChromeHelpExtensionMenuDiscussLink", - "text": "ChromeHelpExtensionMenuDiscussLink" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" }, - " | ", { - "pluginId": "@kbn/core-chrome-browser", - "scope": "common", - "docId": "kibKbnCoreChromeBrowserPluginApi", - "section": "def-common.ChromeHelpExtensionMenuDocumentationLink", - "text": "ChromeHelpExtensionMenuDocumentationLink" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" }, - " | ", { - "pluginId": "@kbn/core-chrome-browser", - "scope": "common", - "docId": "kibKbnCoreChromeBrowserPluginApi", - "section": "def-common.ChromeHelpExtensionMenuCustomLink", - "text": "ChromeHelpExtensionMenuCustomLink" - } - ], - "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.DomainDeprecationDetails", - "type": "Type", - "tags": [], - "label": "DomainDeprecationDetails", - "description": [], - "signature": [ + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.test.ts" + }, { - "pluginId": "@kbn/core-deprecations-common", - "scope": "common", - "docId": "kibKbnCoreDeprecationsCommonPluginApi", - "section": "def-common.DeprecationsDetails", - "text": "DeprecationsDetails" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.test.ts" }, - " & { domainId: string; }" - ], - "path": "packages/core/deprecations/core-deprecations-common/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.EventType", - "type": "Type", - "tags": [], - "label": "EventType", - "description": [ - "\nEvent Type used for indexed structures. Only used to improve the readability of the types" - ], - "signature": [ - "string" - ], - "path": "packages/analytics/client/src/events/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ExecutionContextStart", - "type": "Type", - "tags": [], - "label": "ExecutionContextStart", - "description": [ - "\nSee {@link ExecutionContextSetup}." - ], - "signature": [ { - "pluginId": "@kbn/core-execution-context-browser", - "scope": "common", - "docId": "kibKbnCoreExecutionContextBrowserPluginApi", - "section": "def-common.ExecutionContextSetup", - "text": "ExecutionContextSetup" - } - ], - "path": "packages/core/execution-context/core-execution-context-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.FatalErrorsStart", - "type": "Type", - "tags": [], - "label": "FatalErrorsStart", - "description": [ - "\nFatalErrors stop the Kibana Public Core and displays a fatal error screen\nwith details about the Kibana build and the error.\n" - ], - "signature": [ + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, { - "pluginId": "@kbn/core-fatal-errors-browser", - "scope": "common", - "docId": "kibKbnCoreFatalErrorsBrowserPluginApi", - "section": "def-common.FatalErrorsSetup", - "text": "FatalErrorsSetup" - } - ], - "path": "packages/core/fatal-errors/core-fatal-errors-browser/src/contract.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.HttpStart", - "type": "Type", - "tags": [], - "label": "HttpStart", - "description": [ - "\nSee {@link HttpSetup}" - ], - "signature": [ + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, { - "pluginId": "@kbn/core-http-browser", - "scope": "common", - "docId": "kibKbnCoreHttpBrowserPluginApi", - "section": "def-common.HttpSetup", - "text": "HttpSetup" - } - ], - "path": "packages/core/http/core-http-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.KibanaExecutionContext", - "type": "Type", - "tags": [], - "label": "KibanaExecutionContext", - "description": [], - "signature": [ - "{ readonly type?: string | undefined; readonly name?: string | undefined; readonly page?: string | undefined; readonly id?: string | undefined; readonly description?: string | undefined; readonly url?: string | undefined; readonly meta?: { [key: string]: string | number | boolean | undefined; } | undefined; child?: ", + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, { - "pluginId": "@kbn/core-execution-context-common", - "scope": "common", - "docId": "kibKbnCoreExecutionContextCommonPluginApi", - "section": "def-common.KibanaExecutionContext", - "text": "KibanaExecutionContext" + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" }, - " | undefined; }" - ], - "path": "packages/core/execution-context/core-execution-context-common/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.MountPoint", - "type": "Type", - "tags": [], - "label": "MountPoint", - "description": [ - "\nA function that should mount DOM content inside the provided container element\nand return a handler to unmount it.\n" - ], - "signature": [ - "(element: T) => ", { - "pluginId": "@kbn/core-mount-utils-browser", - "scope": "common", - "docId": "kibKbnCoreMountUtilsBrowserPluginApi", - "section": "def-common.UnmountCallback", - "text": "UnmountCallback" - } - ], - "path": "packages/core/mount-utils/core-mount-utils-browser/src/mount_point.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [ - "a {@link UnmountCallback } that unmount the element on call." - ], - "children": [ + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, { - "parentPluginId": "core", - "id": "def-public.MountPoint.$1", - "type": "Uncategorized", - "tags": [], - "label": "element", - "description": [ - "the container element to render into" - ], - "signature": [ - "T" - ], - "path": "packages/core/mount-utils/core-mount-utils-browser/src/mount_point.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.PluginInitializer", - "type": "Type", - "tags": [], - "label": "PluginInitializer", - "description": [ - "\nThe `plugin` export at the root of a plugin's `public` directory should conform\nto this interface.\n" - ], - "signature": [ - "(core: ", + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, { - "pluginId": "@kbn/core-plugins-browser", - "scope": "common", - "docId": "kibKbnCorePluginsBrowserPluginApi", - "section": "def-common.PluginInitializerContext", - "text": "PluginInitializerContext" + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" }, - ") => ", { - "pluginId": "@kbn/core-plugins-browser", - "scope": "common", - "docId": "kibKbnCorePluginsBrowserPluginApi", - "section": "def-common.Plugin", - "text": "Plugin" + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" }, - "" - ], - "path": "packages/core/plugins/core-plugins-browser/src/plugin_initializer.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ { - "parentPluginId": "core", - "id": "def-public.PluginInitializer.$1", - "type": "Object", - "tags": [], - "label": "core", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-plugins-browser", - "scope": "common", - "docId": "kibKbnCorePluginsBrowserPluginApi", - "section": "def-common.PluginInitializerContext", - "text": "PluginInitializerContext" - }, - "" - ], - "path": "packages/core/plugins/core-plugins-browser/src/plugin_initializer.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.PluginOpaqueId", - "type": "Type", - "tags": [], - "label": "PluginOpaqueId", - "description": [], - "signature": [ - "symbol" - ], - "path": "packages/core/base/core-base-common/src/plugins.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.PublicAppDeepLinkInfo", - "type": "Type", - "tags": [], - "label": "PublicAppDeepLinkInfo", - "description": [ - "\nPublic information about a registered app's {@link AppDeepLink | deepLinks}\n" - ], - "signature": [ - "Omit<", + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" + }, { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppDeepLink", - "text": "AppDeepLink" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" }, - ", \"searchable\" | \"keywords\" | \"deepLinks\" | \"navLinkStatus\"> & { deepLinks: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.PublicAppDeepLinkInfo", - "text": "PublicAppDeepLinkInfo" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" }, - "[]; keywords: string[]; navLinkStatus: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppNavLinkStatus", - "text": "AppNavLinkStatus" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/share_action.ts" }, - "; searchable: boolean; }" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.PublicAppInfo", - "type": "Type", - "tags": [], - "label": "PublicAppInfo", - "description": [ - "\nPublic information about a registered {@link App | application}\n" - ], - "signature": [ - "Omit<", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.App", - "text": "App" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/share_action.ts" }, - ", \"searchable\" | \"mount\" | \"updater$\" | \"keywords\" | \"deepLinks\"> & { status: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppStatus", - "text": "AppStatus" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" }, - "; navLinkStatus: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.AppNavLinkStatus", - "text": "AppNavLinkStatus" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" }, - "; appRoute: string; keywords: string[]; deepLinks: ", { - "pluginId": "@kbn/core-application-browser", - "scope": "common", - "docId": "kibKbnCoreApplicationBrowserPluginApi", - "section": "def-common.PublicAppDeepLinkInfo", - "text": "PublicAppDeepLinkInfo" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - "[]; searchable: boolean; }" - ], - "path": "packages/core/application/core-application-browser/src/application.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.PublicUiSettingsParams", - "type": "Type", - "tags": [], - "label": "PublicUiSettingsParams", - "description": [ - "\nA sub-set of {@link UiSettingsParams} exposed to the client-side." - ], - "signature": [ - "{ name?: string | undefined; value?: unknown; description?: string | undefined; category?: string[] | undefined; options?: string[] | number[] | undefined; optionLabels?: Record | undefined; requiresPageReload?: boolean | undefined; readonly?: boolean | undefined; sensitive?: boolean | undefined; type?: ", { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UiSettingsType", - "text": "UiSettingsType" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - " | undefined; deprecation?: ", { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.DeprecationSettings", - "text": "DeprecationSettings" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - " | undefined; order?: number | undefined; metric?: { type: string; name: string; } | undefined; scope?: ", { - "pluginId": "@kbn/core-ui-settings-common", - "scope": "common", - "docId": "kibKbnCoreUiSettingsCommonPluginApi", - "section": "def-common.UiSettingsScope", - "text": "UiSettingsScope" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - " | undefined; }" - ], - "path": "packages/core/ui-settings/core-ui-settings-common/src/ui_settings.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.ResolveDeprecationResponse", - "type": "Type", - "tags": [], - "label": "ResolveDeprecationResponse", - "description": [ - "\nResponse from correctiveActions.api call from automatically resolving the deprecation" - ], - "signature": [ - "{ status: \"ok\"; } | { status: \"fail\"; reason: string; }" - ], - "path": "packages/core/deprecations/core-deprecations-browser/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectAttribute", - "type": "Type", - "tags": [], - "label": "SavedObjectAttribute", - "description": [ - "\nType definition for a Saved Object attribute value\n" - ], - "signature": [ { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributeSingle", - "text": "SavedObjectAttributeSingle" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - " | ", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributeSingle", - "text": "SavedObjectAttributeSingle" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-public.SavedObjectAttributeSingle", - "type": "Type", - "tags": [], - "label": "SavedObjectAttributeSingle", - "description": [ - "\nDon't use this type, it's simply a helper type for {@link SavedObjectAttribute}\n" - ], - "signature": [ - "string | number | boolean | ", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributes", - "text": "SavedObjectAttributes" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" }, - " | null | undefined" + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, "initialIsOpen": false }, { "parentPluginId": "core", "id": "def-public.SavedObjectsFindOptions", "type": "Type", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsFindOptions", "description": [ "\nBrowser options for finding saved objects\n" @@ -18396,8 +23741,62 @@ "[] | undefined; hasNoReferenceOperator?: \"AND\" | \"OR\" | undefined; defaultSearchOperator?: \"AND\" | \"OR\" | undefined; namespaces?: string[] | undefined; preference?: string | undefined; }" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/find_objects.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/find_objects.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + } + ], "initialIsOpen": false }, { @@ -44963,9 +50362,7 @@ "parentPluginId": "core", "id": "def-server.OpsMetrics.process", "type": "Object", - "tags": [ - "deprecated" - ], + "tags": [], "label": "process", "description": [ "\nProcess related metrics." @@ -44980,79 +50377,8 @@ } ], "path": "packages/core/metrics/core-metrics-server/src/metrics.ts", - "deprecated": true, - "removeBy": "8.8.0", - "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts" - }, - { - "plugin": "@kbn/core-status-server-internal", - "path": "packages/core/status/core-status-server-internal/src/routes/status.ts" - }, - { - "plugin": "@kbn/core-status-server-internal", - "path": "packages/core/status/core-status-server-internal/src/routes/status.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "monitoring", - "path": "x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts" - }, - { - "plugin": "kibanaUsageCollection", - "path": "src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts" - } - ] + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "core", @@ -48389,850 +53715,554 @@ "section": "def-common.RouteContentType", "text": "RouteContentType" }, - "[] | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteConfigOptionsBody.maxBytes", - "type": "number", - "tags": [], - "label": "maxBytes", - "description": [ - "\nLimits the size of incoming payloads to the specified byte count. Allowing very large payloads may cause the server to run out of memory.\n\nDefault value: The one set in the kibana.yml config file under the parameter `server.maxPayload`." - ], - "signature": [ - "number | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteConfigOptionsBody.output", - "type": "CompoundType", - "tags": [], - "label": "output", - "description": [ - "\nThe processed payload format. The value must be one of:\n* 'data' - the incoming payload is read fully into memory. If parse is true, the payload is parsed (JSON, form-decoded, multipart) based on the 'Content-Type' header. If parse is false, a raw\nBuffer is returned.\n* 'stream' - the incoming payload is made available via a Stream.Readable interface. If the payload is 'multipart/form-data' and parse is true, field values are presented as text while files\nare provided as streams. File streams from a 'multipart/form-data' upload will also have a hapi property containing the filename and headers properties. Note that payload streams for multipart\npayloads are a synthetic interface created on top of the entire multipart content loaded into memory. To avoid loading large multipart payloads into memory, set parse to false and handle the\nmultipart payload in the handler using a streaming parser (e.g. pez).\n\nDefault value: 'data', unless no validation.body is provided in the route definition. In that case the default is 'stream' to alleviate memory pressure." - ], - "signature": [ - "\"data\" | \"stream\" | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteConfigOptionsBody.parse", - "type": "CompoundType", - "tags": [], - "label": "parse", - "description": [ - "\nDetermines if the incoming payload is processed or presented raw. Available values:\n* true - if the request 'Content-Type' matches the allowed mime types set by allow (for the whole payload as well as parts), the payload is converted into an object when possible. If the\nformat is unknown, a Bad Request (400) error response is sent. Any known content encoding is decoded.\n* false - the raw payload is returned unmodified.\n* 'gunzip' - the raw payload is returned unmodified after any known content encoding is decoded.\n\nDefault value: true, unless no validation.body is provided in the route definition. In that case the default is false to alleviate memory pressure." - ], - "signature": [ - "boolean | \"gunzip\" | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory", - "type": "Interface", - "tags": [], - "label": "RouteValidationResultFactory", - "description": [ - "\nValidation result factory to be used in the custom validation function to return the valid data or validation errors\n\nSee {@link RouteValidationFunction}.\n" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory.ok", - "type": "Function", - "tags": [], - "label": "ok", - "description": [], - "signature": [ - "(value: T) => { value: T; }" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory.ok.$1", - "type": "Uncategorized", - "tags": [], - "label": "value", - "description": [], - "signature": [ - "T" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory.badRequest", - "type": "Function", - "tags": [], - "label": "badRequest", - "description": [], - "signature": [ - "(error: string | Error, path?: string[] | undefined) => { error: ", - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.RouteValidationError", - "text": "RouteValidationError" - }, - "; }" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory.badRequest.$1", - "type": "CompoundType", - "tags": [], - "label": "error", - "description": [], - "signature": [ - "string | Error" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidationResultFactory.badRequest.$2", - "type": "Array", - "tags": [], - "label": "path", - "description": [], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorConfig", - "type": "Interface", - "tags": [], - "label": "RouteValidatorConfig", - "description": [ - "\nThe configuration object to the RouteValidator class.\nSet `params`, `query` and/or `body` to specify the validation logic to follow for that property.\n" - ], - "signature": [ - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.RouteValidatorConfig", - "text": "RouteValidatorConfig" - }, - "" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorConfig.params", - "type": "CompoundType", - "tags": [], - "label": "params", - "description": [ - "\nValidation logic for the URL params" - ], - "signature": [ - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.RouteValidationSpec", - "text": "RouteValidationSpec" - }, - "

| undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorConfig.query", - "type": "CompoundType", - "tags": [], - "label": "query", - "description": [ - "\nValidation logic for the Query params" - ], - "signature": [ - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.RouteValidationSpec", - "text": "RouteValidationSpec" - }, - " | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorConfig.body", - "type": "CompoundType", - "tags": [], - "label": "body", - "description": [ - "\nValidation logic for the body payload" - ], - "signature": [ - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.RouteValidationSpec", - "text": "RouteValidationSpec" - }, - " | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorOptions", - "type": "Interface", - "tags": [], - "label": "RouteValidatorOptions", - "description": [ - "\nAdditional options for the RouteValidator class to modify its default behaviour.\n" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.RouteValidatorOptions.unsafe", - "type": "Object", - "tags": [], - "label": "unsafe", - "description": [ - "\nSet the `unsafe` config to avoid running some additional internal *safe* validations on top of your custom validation" - ], - "signature": [ - "{ params?: boolean | undefined; query?: boolean | undefined; body?: boolean | undefined; } | undefined" - ], - "path": "packages/core/http/core-http-server/src/router/route_validator.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-server.SavedObject", - "type": "Interface", - "tags": [], - "label": "SavedObject", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "core", - "id": "def-server.SavedObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.SavedObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.SavedObject.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" + "[] | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-server.SavedObject.created_at", - "type": "string", + "id": "def-server.RouteConfigOptionsBody.maxBytes", + "type": "number", "tags": [], - "label": "created_at", + "label": "maxBytes", "description": [ - "Timestamp of the time this document had been created." + "\nLimits the size of incoming payloads to the specified byte count. Allowing very large payloads may cause the server to run out of memory.\n\nDefault value: The one set in the kibana.yml config file under the parameter `server.maxPayload`." ], "signature": [ - "string | undefined" + "number | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-server.SavedObject.updated_at", - "type": "string", + "id": "def-server.RouteConfigOptionsBody.output", + "type": "CompoundType", "tags": [], - "label": "updated_at", + "label": "output", "description": [ - "Timestamp of the last time this document had been updated." + "\nThe processed payload format. The value must be one of:\n* 'data' - the incoming payload is read fully into memory. If parse is true, the payload is parsed (JSON, form-decoded, multipart) based on the 'Content-Type' header. If parse is false, a raw\nBuffer is returned.\n* 'stream' - the incoming payload is made available via a Stream.Readable interface. If the payload is 'multipart/form-data' and parse is true, field values are presented as text while files\nare provided as streams. File streams from a 'multipart/form-data' upload will also have a hapi property containing the filename and headers properties. Note that payload streams for multipart\npayloads are a synthetic interface created on top of the entire multipart content loaded into memory. To avoid loading large multipart payloads into memory, set parse to false and handle the\nmultipart payload in the handler using a streaming parser (e.g. pez).\n\nDefault value: 'data', unless no validation.body is provided in the route definition. In that case the default is 'stream' to alleviate memory pressure." ], "signature": [ - "string | undefined" + "\"data\" | \"stream\" | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-server.SavedObject.error", - "type": "Object", + "id": "def-server.RouteConfigOptionsBody.parse", + "type": "CompoundType", "tags": [], - "label": "error", + "label": "parse", "description": [ - "Error associated with this object, populated if an operation failed for this object." + "\nDetermines if the incoming payload is processed or presented raw. Available values:\n* true - if the request 'Content-Type' matches the allowed mime types set by allow (for the whole payload as well as parts), the payload is converted into an object when possible. If the\nformat is unknown, a Bad Request (400) error response is sent. Any known content encoding is decoded.\n* false - the raw payload is returned unmodified.\n* 'gunzip' - the raw payload is returned unmodified after any known content encoding is decoded.\n\nDefault value: true, unless no validation.body is provided in the route definition. In that case the default is false to alleviate memory pressure." ], "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" + "boolean | \"gunzip\" | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-server.RouteValidationResultFactory", + "type": "Interface", + "tags": [], + "label": "RouteValidationResultFactory", + "description": [ + "\nValidation result factory to be used in the custom validation function to return the valid data or validation errors\n\nSee {@link RouteValidationFunction}.\n" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "core", - "id": "def-server.SavedObject.attributes", - "type": "Uncategorized", + "id": "def-server.RouteValidationResultFactory.ok", + "type": "Function", "tags": [], - "label": "attributes", - "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], + "label": "ok", + "description": [], "signature": [ - "T" + "(value: T) => { value: T; }" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "core", + "id": "def-server.RouteValidationResultFactory.ok.$1", + "type": "Uncategorized", + "tags": [], + "label": "value", + "description": [], + "signature": [ + "T" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "core", - "id": "def-server.SavedObject.references", - "type": "Array", + "id": "def-server.RouteValidationResultFactory.badRequest", + "type": "Function", "tags": [], - "label": "references", - "description": [ - "{@inheritdoc SavedObjectReference}" - ], + "label": "badRequest", + "description": [], "signature": [ + "(error: string | Error, path?: string[] | undefined) => { error: ", { - "pluginId": "@kbn/core-saved-objects-common", + "pluginId": "@kbn/core-http-server", "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.RouteValidationError", + "text": "RouteValidationError" }, - "[]" + "; }" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "core", - "id": "def-server.SavedObject.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], - "signature": [ + "trackAdoption": false, + "children": [ { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" + "parentPluginId": "core", + "id": "def-server.RouteValidationResultFactory.badRequest.$1", + "type": "CompoundType", + "tags": [], + "label": "error", + "description": [], + "signature": [ + "string | Error" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, - " | undefined" + { + "parentPluginId": "core", + "id": "def-server.RouteValidationResultFactory.badRequest.$2", + "type": "Array", + "tags": [], + "label": "path", + "description": [], + "signature": [ + "string[] | undefined" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-server.RouteValidatorConfig", + "type": "Interface", + "tags": [], + "label": "RouteValidatorConfig", + "description": [ + "\nThe configuration object to the RouteValidator class.\nSet `params`, `query` and/or `body` to specify the validation logic to follow for that property.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-http-server", + "scope": "common", + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.RouteValidatorConfig", + "text": "RouteValidatorConfig" }, + "" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "core", - "id": "def-server.SavedObject.coreMigrationVersion", - "type": "string", + "id": "def-server.RouteValidatorConfig.params", + "type": "CompoundType", "tags": [], - "label": "coreMigrationVersion", + "label": "params", "description": [ - "A semver value that is used when upgrading objects between Kibana versions." + "\nValidation logic for the URL params" ], "signature": [ - "string | undefined" + { + "pluginId": "@kbn/core-http-server", + "scope": "common", + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.RouteValidationSpec", + "text": "RouteValidationSpec" + }, + "

| undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-server.SavedObject.namespaces", - "type": "Array", + "id": "def-server.RouteValidatorConfig.query", + "type": "CompoundType", "tags": [], - "label": "namespaces", + "label": "query", "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." + "\nValidation logic for the Query params" ], "signature": [ - "string[] | undefined" + { + "pluginId": "@kbn/core-http-server", + "scope": "common", + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.RouteValidationSpec", + "text": "RouteValidationSpec" + }, + " | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "core", - "id": "def-server.SavedObject.originId", - "type": "string", + "id": "def-server.RouteValidatorConfig.body", + "type": "CompoundType", "tags": [], - "label": "originId", + "label": "body", "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." + "\nValidation logic for the body payload" ], "signature": [ - "string | undefined" + { + "pluginId": "@kbn/core-http-server", + "scope": "common", + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.RouteValidationSpec", + "text": "RouteValidationSpec" + }, + " | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", "deprecated": false, "trackAdoption": false } ], "initialIsOpen": false - }, - { - "parentPluginId": "core", - "id": "def-server.SavedObjectAttributes", - "type": "Interface", - "tags": [ - "deprecated" - ], - "label": "SavedObjectAttributes", - "description": [ - "\nThe data for a Saved Object is stored as an object in the `attributes`\nproperty.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" - }, - { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" - }, - { - "plugin": "@kbn/core-saved-objects-common", - "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" - }, - { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" - }, - { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" - }, - { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" - }, - { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" - }, - { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" - }, - { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" - }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" - }, - { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" - }, - { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" - }, + }, + { + "parentPluginId": "core", + "id": "def-server.RouteValidatorOptions", + "type": "Interface", + "tags": [], + "label": "RouteValidatorOptions", + "description": [ + "\nAdditional options for the RouteValidator class to modify its default behaviour.\n" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" - }, + "parentPluginId": "core", + "id": "def-server.RouteValidatorOptions.unsafe", + "type": "Object", + "tags": [], + "label": "unsafe", + "description": [ + "\nSet the `unsafe` config to avoid running some additional internal *safe* validations on top of your custom validation" + ], + "signature": [ + "{ params?: boolean | undefined; query?: boolean | undefined; body?: boolean | undefined; } | undefined" + ], + "path": "packages/core/http/core-http-server/src/router/route_validator.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-server.SavedObject", + "type": "Interface", + "tags": [], + "label": "SavedObject", + "description": [], + "signature": [ { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + " The type of Saved Object. Each plugin can define it's own custom Saved Object types." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.version", + "type": "string", + "tags": [], + "label": "version", + "description": [ + "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.created_at", + "type": "string", + "tags": [], + "label": "created_at", + "description": [ + "Timestamp of the time this document had been created." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.updated_at", + "type": "string", + "tags": [], + "label": "updated_at", + "description": [ + "Timestamp of the last time this document had been updated." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.error", + "type": "Object", + "tags": [], + "label": "error", + "description": [ + "Error associated with this object, populated if an operation failed for this object." + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectError", + "text": "SavedObjectError" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.attributes", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "The data for a Saved Object is stored as an object in the `attributes` property." + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "{@inheritdoc SavedObjectReference}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.migrationVersion", + "type": "Object", + "tags": [], + "label": "migrationVersion", + "description": [ + "{@inheritdoc SavedObjectsMigrationVersion}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsMigrationVersion", + "text": "SavedObjectsMigrationVersion" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.coreMigrationVersion", + "type": "string", + "tags": [], + "label": "coreMigrationVersion", + "description": [ + "A semver value that is used when upgrading objects between Kibana versions." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "parentPluginId": "core", + "id": "def-server.SavedObject.namespaces", + "type": "Array", + "tags": [], + "label": "namespaces", + "description": [ + "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." + ], + "signature": [ + "string[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" - }, + "parentPluginId": "core", + "id": "def-server.SavedObject.originId", + "type": "string", + "tags": [], + "label": "originId", + "description": [ + "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "core", + "id": "def-server.SavedObjectAttributes", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttributes", + "description": [ + "\nThe data for a Saved Object is stored as an object in the `attributes`\nproperty.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/index.ts" }, { "plugin": "actions", @@ -49461,86 +54491,6 @@ { "plugin": "savedSearch", "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" - }, - { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" - }, - { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" - }, - { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" } ], "children": [ @@ -49561,7 +54511,7 @@ "text": "SavedObjectAttribute" } ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false } @@ -49808,7 +54758,7 @@ "description": [ "\nA reference to another saved object.\n" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -49819,7 +54769,7 @@ "tags": [], "label": "name", "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false }, @@ -49830,7 +54780,7 @@ "tags": [], "label": "type", "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false }, @@ -49841,7 +54791,7 @@ "tags": [], "label": "id", "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false } @@ -55433,63 +60383,6 @@ ], "returnComment": [] }, - { - "parentPluginId": "core", - "id": "def-server.SavedObjectsMigrationLogger.warning", - "type": "Function", - "tags": [ - "deprecated" - ], - "label": "warning", - "description": [], - "signature": [ - "(msg: string) => void" - ], - "path": "packages/core/saved-objects/core-saved-objects-server/src/migration.ts", - "deprecated": true, - "removeBy": "8.8.0", - "trackAdoption": false, - "references": [ - { - "plugin": "maps", - "path": "x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts" - }, - { - "plugin": "@kbn/core-saved-objects-migration-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts" - }, - { - "plugin": "@kbn/core-saved-objects-migration-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts" - } - ], - "children": [ - { - "parentPluginId": "core", - "id": "def-server.SavedObjectsMigrationLogger.warning.$1", - "type": "string", - "tags": [], - "label": "msg", - "description": [], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-server/src/migration.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - }, { "parentPluginId": "core", "id": "def-server.SavedObjectsMigrationLogger.warn", @@ -57445,12 +62338,152 @@ "parentPluginId": "core", "id": "def-server.SavedObjectsStart", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsStart", "description": [], "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/index.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + } + ], "children": [ { "parentPluginId": "core", @@ -65587,7 +70620,7 @@ }, "[]" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false, "initialIsOpen": false @@ -65612,7 +70645,7 @@ }, " | null | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", "deprecated": false, "trackAdoption": false, "initialIsOpen": false diff --git a/api_docs/core.mdx b/api_docs/core.mdx index 803dc9268b0ea..11fb66e31cd8b 100644 --- a/api_docs/core.mdx +++ b/api_docs/core.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/core title: "core" image: https://source.unsplash.com/400x175/?github description: API docs for the core plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'core'] --- import coreObj from './core.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) for que | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 2823 | 17 | 1019 | 0 | +| 2806 | 17 | 1017 | 0 | ## Client diff --git a/api_docs/custom_integrations.mdx b/api_docs/custom_integrations.mdx index 5fe93a968ee4d..c07872138ad68 100644 --- a/api_docs/custom_integrations.mdx +++ b/api_docs/custom_integrations.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/customIntegrations title: "customIntegrations" image: https://source.unsplash.com/400x175/?github description: API docs for the customIntegrations plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'customIntegrations'] --- import customIntegrationsObj from './custom_integrations.devdocs.json'; diff --git a/api_docs/dashboard.mdx b/api_docs/dashboard.mdx index a6b917d452f1f..703856322f24f 100644 --- a/api_docs/dashboard.mdx +++ b/api_docs/dashboard.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dashboard title: "dashboard" image: https://source.unsplash.com/400x175/?github description: API docs for the dashboard plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dashboard'] --- import dashboardObj from './dashboard.devdocs.json'; diff --git a/api_docs/dashboard_enhanced.mdx b/api_docs/dashboard_enhanced.mdx index 0cae3443af300..4492855f0c83e 100644 --- a/api_docs/dashboard_enhanced.mdx +++ b/api_docs/dashboard_enhanced.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dashboardEnhanced title: "dashboardEnhanced" image: https://source.unsplash.com/400x175/?github description: API docs for the dashboardEnhanced plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dashboardEnhanced'] --- import dashboardEnhancedObj from './dashboard_enhanced.devdocs.json'; diff --git a/api_docs/data.devdocs.json b/api_docs/data.devdocs.json index aff809de3a2b0..54ed4d3dcfef1 100644 --- a/api_docs/data.devdocs.json +++ b/api_docs/data.devdocs.json @@ -8559,237 +8559,6 @@ ], "initialIsOpen": false }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject", - "type": "Interface", - "tags": [], - "label": "SavedObject", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-public.SavedObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.created_at", - "type": "string", - "tags": [], - "label": "created_at", - "description": [ - "Timestamp of the time this document had been created." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.updated_at", - "type": "string", - "tags": [], - "label": "updated_at", - "description": [ - "Timestamp of the last time this document had been updated." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.error", - "type": "Object", - "tags": [], - "label": "error", - "description": [ - "Error associated with this object, populated if an operation failed for this object." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "{@inheritdoc SavedObjectReference}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.coreMigrationVersion", - "type": "string", - "tags": [], - "label": "coreMigrationVersion", - "description": [ - "A semver value that is used when upgrading objects between Kibana versions." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.namespaces", - "type": "Array", - "tags": [], - "label": "namespaces", - "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." - ], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.SavedObject.originId", - "type": "string", - "tags": [], - "label": "originId", - "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, { "parentPluginId": "data", "id": "def-public.SearchSourceFields", @@ -10699,888 +10468,2574 @@ }, { "parentPluginId": "data", - "id": "def-public.SerializedSearchSourceFields", + "id": "def-public.SavedObject", "type": "Type", - "tags": [], - "label": "SerializedSearchSourceFields", + "tags": [ + "deprecated" + ], + "label": "SavedObject", "description": [], "signature": [ - "{ type?: string | undefined; query?: ", { - "pluginId": "@kbn/es-query", + "pluginId": "@kbn/core-saved-objects-common", "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.Query", - "text": "Query" + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" }, - " | ", + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.AggregateQuery", - "text": "AggregateQuery" + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" }, - " | undefined; filter?: ", { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.Filter", - "text": "Filter" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - "[] | undefined; sort?: ", { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.EsQuerySortValue", - "text": "EsQuerySortValue" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, - "[] | undefined; highlight?: ", { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - " | undefined; highlightAll?: boolean | undefined; trackTotalHits?: number | boolean | undefined; aggs?: { type: string; enabled?: boolean | undefined; id?: string | undefined; params?: {} | ", { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - " | undefined; schema?: string | undefined; }[] | undefined; from?: number | undefined; size?: number | undefined; source?: boolean | ", - "Fields", - " | undefined; version?: boolean | undefined; fields?: ", { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.SearchFieldValue", - "text": "SearchFieldValue" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - "[] | undefined; fieldsFromSource?: ", - "Fields", - " | undefined; index?: string | ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - " | undefined; searchAfter?: ", - "SortResults", - " | undefined; timeout?: string | undefined; terminate_after?: number | undefined; parent?: ", { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.SerializedSearchSourceFields", - "text": "SerializedSearchSourceFields" + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, - " | undefined; }" - ], - "path": "src/plugins/data/common/search/search_source/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-public.TypeMeta", - "type": "Type", - "tags": [], - "label": "TypeMeta", - "description": [ - "\nInterface for metadata about rollup indices" - ], - "signature": [ - "{ aggs?: Record | undefined; params?: { rollup_index: string; } | undefined; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "objects": [ - { - "parentPluginId": "data", - "id": "def-public.AggGroupLabels", - "type": "Object", - "tags": [], - "label": "AggGroupLabels", - "description": [], - "path": "src/plugins/data/common/search/aggs/agg_groups.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-public.AggGroupLabels.AggGroupNames.Buckets", - "type": "Any", - "tags": [], - "label": "[AggGroupNames.Buckets]", - "description": [], - "signature": [ - "any" - ], - "path": "src/plugins/data/common/search/aggs/agg_groups.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-public.AggGroupLabels.AggGroupNames.Metrics", - "type": "Any", - "tags": [], - "label": "[AggGroupNames.Metrics]", - "description": [], - "signature": [ - "any" - ], - "path": "src/plugins/data/common/search/aggs/agg_groups.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-public.AggGroupLabels.AggGroupNames.None", - "type": "Any", - "tags": [], - "label": "[AggGroupNames.None]", - "description": [], - "signature": [ - "any" - ], - "path": "src/plugins/data/common/search/aggs/agg_groups.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-public.AggGroupNames", - "type": "Object", - "tags": [], - "label": "AggGroupNames", - "description": [], - "signature": [ - "{ readonly Buckets: \"buckets\"; readonly Metrics: \"metrics\"; readonly None: \"none\"; }" - ], - "path": "src/plugins/data/common/search/aggs/agg_groups.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-public.exporters", - "type": "Object", - "tags": [], - "label": "exporters", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, { - "parentPluginId": "data", - "id": "def-public.exporters.datatableToCSV", - "type": "Function", - "tags": [], - "label": "datatableToCSV", - "description": [], - "signature": [ - "({ columns, rows }: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" - }, - ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.exporters.datatableToCSV.$1", - "type": "Object", - "tags": [], - "label": "__0", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" - } - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.exporters.datatableToCSV.$2", - "type": "Object", - "tags": [], - "label": "__1", - "description": [], - "signature": [ - "CSVOptions" - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-public.exporters.CSV_MIME_TYPE", - "type": "string", - "tags": [], - "label": "CSV_MIME_TYPE", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-public.exporters.cellHasFormulas", - "type": "Function", - "tags": [], - "label": "cellHasFormulas", - "description": [], - "signature": [ - "(val: string) => boolean" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.exporters.cellHasFormulas.$1", - "type": "string", - "tags": [], - "label": "val", - "description": [], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" }, { - "parentPluginId": "data", - "id": "def-public.exporters.tableHasFormulas", - "type": "Function", - "tags": [], - "label": "tableHasFormulas", - "description": [], - "signature": [ - "(columns: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - "[], rows: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableRow", - "text": "DatatableRow" - }, - "[]) => boolean" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.exporters.tableHasFormulas.$1", - "type": "Array", - "tags": [], - "label": "columns", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - "[]" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.exporters.tableHasFormulas.$2", - "type": "Array", - "tags": [], - "label": "rows", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableRow", - "text": "DatatableRow" - }, - "[]" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false - } - ] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-public.indexPatterns", - "type": "Object", - "tags": [], - "label": "indexPatterns", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS_KEY", - "type": "string", - "tags": [], - "label": "ILLEGAL_CHARACTERS_KEY", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.CONTAINS_SPACES_KEY", - "type": "string", - "tags": [], - "label": "CONTAINS_SPACES_KEY", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS_VISIBLE", - "type": "Array", - "tags": [], - "label": "ILLEGAL_CHARACTERS_VISIBLE", - "description": [], - "signature": [ - "string[]" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS", - "type": "Array", - "tags": [], - "label": "ILLEGAL_CHARACTERS", - "description": [], - "signature": [ - "string[]" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isFilterable", - "type": "Function", - "tags": [], - "label": "isFilterable", - "description": [], - "signature": [ - "(field: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - ") => boolean" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isFilterable.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - } - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isNestedField", - "type": "Function", - "tags": [], - "label": "isNestedField", - "description": [], - "signature": [ - "(field: HasSubtype) => boolean" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isNestedField.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isMultiField", - "type": "Function", - "tags": [], - "label": "isMultiField", - "description": [], - "signature": [ - "(field: HasSubtype) => boolean" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.isMultiField.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.getFieldSubtypeMulti", - "type": "Function", - "tags": [], - "label": "getFieldSubtypeMulti", - "description": [], - "signature": [ - "(field: HasSubtype) => ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeMulti", - "text": "IFieldSubTypeMulti" - }, - " | undefined" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.getFieldSubtypeMulti.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.getFieldSubtypeNested", - "type": "Function", - "tags": [], - "label": "getFieldSubtypeNested", - "description": [], - "signature": [ - "(field: HasSubtype) => ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeNested", - "text": "IFieldSubTypeNested" - }, - " | undefined" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.getFieldSubtypeNested.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" }, { - "parentPluginId": "data", - "id": "def-public.indexPatterns.validate", - "type": "Function", - "tags": [], - "label": "validate", - "description": [], - "signature": [ - "(indexPattern: string) => { ILLEGAL_CHARACTERS?: string[] | undefined; CONTAINS_SPACES?: boolean | undefined; }" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.indexPatterns.validate.$1", - "type": "string", - "tags": [], - "label": "indexPattern", - "description": [], - "path": "src/plugins/data_views/common/lib/validate_data_view.ts", - "deprecated": false, - "trackAdoption": false - } - ] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-public.search", - "type": "Object", - "tags": [], - "label": "search", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, { - "parentPluginId": "data", - "id": "def-public.search.aggs", - "type": "Object", - "tags": [], - "label": "aggs", - "description": [], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-public.search.aggs.CidrMask", - "type": "Object", - "tags": [], - "label": "CidrMask", - "description": [], - "signature": [ - "typeof ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.CidrMask", - "text": "CidrMask" - } - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.dateHistogramInterval", - "type": "Function", - "tags": [], - "label": "dateHistogramInterval", - "description": [], - "signature": [ - "(interval: string, shouldForceFixed?: boolean | undefined) => Interval" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.search.aggs.dateHistogramInterval.$1", - "type": "string", - "tags": [], - "label": "interval", - "description": [], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.dateHistogramInterval.$2", - "type": "CompoundType", - "tags": [], - "label": "shouldForceFixed", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", - "deprecated": false, - "trackAdoption": false - } - ] - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.intervalOptions", - "type": "Array", - "tags": [], - "label": "intervalOptions", - "description": [], - "signature": [ - "({ display: any; val: string; enabled(agg: ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IBucketAggConfig", - "text": "IBucketAggConfig" - }, - "): boolean; } | { display: any; val: string; })[]" - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.InvalidEsCalendarIntervalError", - "type": "Object", - "tags": [], - "label": "InvalidEsCalendarIntervalError", - "description": [], - "signature": [ - "typeof ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.InvalidEsCalendarIntervalError", - "text": "InvalidEsCalendarIntervalError" - } - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.InvalidEsIntervalFormatError", - "type": "Object", - "tags": [], - "label": "InvalidEsIntervalFormatError", - "description": [], - "signature": [ - "typeof ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.InvalidEsIntervalFormatError", - "text": "InvalidEsIntervalFormatError" - } - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.IpAddress", - "type": "Object", - "tags": [], - "label": "IpAddress", - "description": [], - "signature": [ - "typeof ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IpAddress", - "text": "IpAddress" - } - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-public.search.aggs.isDateHistogramBucketAggConfig", - "type": "Function", - "tags": [], - "label": "isDateHistogramBucketAggConfig", - "description": [], - "signature": [ - "(agg: any) => agg is ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IBucketDateHistogramAggConfig", - "text": "IBucketDateHistogramAggConfig" - } - ], - "path": "src/plugins/data/public/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-public.search.aggs.isDateHistogramBucketAggConfig.$1", - "type": "Any", - "tags": [], + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + }, + { + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.SerializedSearchSourceFields", + "type": "Type", + "tags": [], + "label": "SerializedSearchSourceFields", + "description": [], + "signature": [ + "{ type?: string | undefined; query?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Query", + "text": "Query" + }, + " | ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.AggregateQuery", + "text": "AggregateQuery" + }, + " | undefined; filter?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + }, + "[] | undefined; sort?: ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.EsQuerySortValue", + "text": "EsQuerySortValue" + }, + "[] | undefined; highlight?: ", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + " | undefined; highlightAll?: boolean | undefined; trackTotalHits?: number | boolean | undefined; aggs?: { type: string; enabled?: boolean | undefined; id?: string | undefined; params?: {} | ", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + " | undefined; schema?: string | undefined; }[] | undefined; from?: number | undefined; size?: number | undefined; source?: boolean | ", + "Fields", + " | undefined; version?: boolean | undefined; fields?: ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.SearchFieldValue", + "text": "SearchFieldValue" + }, + "[] | undefined; fieldsFromSource?: ", + "Fields", + " | undefined; index?: string | ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + }, + " | undefined; searchAfter?: ", + "SortResults", + " | undefined; timeout?: string | undefined; terminate_after?: number | undefined; parent?: ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.SerializedSearchSourceFields", + "text": "SerializedSearchSourceFields" + }, + " | undefined; }" + ], + "path": "src/plugins/data/common/search/search_source/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.TypeMeta", + "type": "Type", + "tags": [], + "label": "TypeMeta", + "description": [ + "\nInterface for metadata about rollup indices" + ], + "signature": [ + "{ aggs?: Record | undefined; params?: { rollup_index: string; } | undefined; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "objects": [ + { + "parentPluginId": "data", + "id": "def-public.AggGroupLabels", + "type": "Object", + "tags": [], + "label": "AggGroupLabels", + "description": [], + "path": "src/plugins/data/common/search/aggs/agg_groups.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-public.AggGroupLabels.AggGroupNames.Buckets", + "type": "Any", + "tags": [], + "label": "[AggGroupNames.Buckets]", + "description": [], + "signature": [ + "any" + ], + "path": "src/plugins/data/common/search/aggs/agg_groups.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.AggGroupLabels.AggGroupNames.Metrics", + "type": "Any", + "tags": [], + "label": "[AggGroupNames.Metrics]", + "description": [], + "signature": [ + "any" + ], + "path": "src/plugins/data/common/search/aggs/agg_groups.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.AggGroupLabels.AggGroupNames.None", + "type": "Any", + "tags": [], + "label": "[AggGroupNames.None]", + "description": [], + "signature": [ + "any" + ], + "path": "src/plugins/data/common/search/aggs/agg_groups.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.AggGroupNames", + "type": "Object", + "tags": [], + "label": "AggGroupNames", + "description": [], + "signature": [ + "{ readonly Buckets: \"buckets\"; readonly Metrics: \"metrics\"; readonly None: \"none\"; }" + ], + "path": "src/plugins/data/common/search/aggs/agg_groups.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.exporters", + "type": "Object", + "tags": [], + "label": "exporters", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-public.exporters.datatableToCSV", + "type": "Function", + "tags": [], + "label": "datatableToCSV", + "description": [], + "signature": [ + "({ columns, rows }: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + }, + ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.exporters.datatableToCSV.$1", + "type": "Object", + "tags": [], + "label": "__0", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + } + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.exporters.datatableToCSV.$2", + "type": "Object", + "tags": [], + "label": "__1", + "description": [], + "signature": [ + "CSVOptions" + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.exporters.CSV_MIME_TYPE", + "type": "string", + "tags": [], + "label": "CSV_MIME_TYPE", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.exporters.cellHasFormulas", + "type": "Function", + "tags": [], + "label": "cellHasFormulas", + "description": [], + "signature": [ + "(val: string) => boolean" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.exporters.cellHasFormulas.$1", + "type": "string", + "tags": [], + "label": "val", + "description": [], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.exporters.tableHasFormulas", + "type": "Function", + "tags": [], + "label": "tableHasFormulas", + "description": [], + "signature": [ + "(columns: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + "[], rows: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableRow", + "text": "DatatableRow" + }, + "[]) => boolean" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.exporters.tableHasFormulas.$1", + "type": "Array", + "tags": [], + "label": "columns", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + "[]" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.exporters.tableHasFormulas.$2", + "type": "Array", + "tags": [], + "label": "rows", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableRow", + "text": "DatatableRow" + }, + "[]" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns", + "type": "Object", + "tags": [], + "label": "indexPatterns", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS_KEY", + "type": "string", + "tags": [], + "label": "ILLEGAL_CHARACTERS_KEY", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.CONTAINS_SPACES_KEY", + "type": "string", + "tags": [], + "label": "CONTAINS_SPACES_KEY", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS_VISIBLE", + "type": "Array", + "tags": [], + "label": "ILLEGAL_CHARACTERS_VISIBLE", + "description": [], + "signature": [ + "string[]" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.ILLEGAL_CHARACTERS", + "type": "Array", + "tags": [], + "label": "ILLEGAL_CHARACTERS", + "description": [], + "signature": [ + "string[]" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isFilterable", + "type": "Function", + "tags": [], + "label": "isFilterable", + "description": [], + "signature": [ + "(field: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + }, + ") => boolean" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isFilterable.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + } + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isNestedField", + "type": "Function", + "tags": [], + "label": "isNestedField", + "description": [], + "signature": [ + "(field: HasSubtype) => boolean" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isNestedField.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" + }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isMultiField", + "type": "Function", + "tags": [], + "label": "isMultiField", + "description": [], + "signature": [ + "(field: HasSubtype) => boolean" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.isMultiField.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" + }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.getFieldSubtypeMulti", + "type": "Function", + "tags": [], + "label": "getFieldSubtypeMulti", + "description": [], + "signature": [ + "(field: HasSubtype) => ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeMulti", + "text": "IFieldSubTypeMulti" + }, + " | undefined" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.getFieldSubtypeMulti.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" + }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.getFieldSubtypeNested", + "type": "Function", + "tags": [], + "label": "getFieldSubtypeNested", + "description": [], + "signature": [ + "(field: HasSubtype) => ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeNested", + "text": "IFieldSubTypeNested" + }, + " | undefined" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.getFieldSubtypeNested.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" + }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.validate", + "type": "Function", + "tags": [], + "label": "validate", + "description": [], + "signature": [ + "(indexPattern: string) => { ILLEGAL_CHARACTERS?: string[] | undefined; CONTAINS_SPACES?: boolean | undefined; }" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.indexPatterns.validate.$1", + "type": "string", + "tags": [], + "label": "indexPattern", + "description": [], + "path": "src/plugins/data_views/common/lib/validate_data_view.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-public.search", + "type": "Object", + "tags": [], + "label": "search", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-public.search.aggs", + "type": "Object", + "tags": [], + "label": "aggs", + "description": [], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-public.search.aggs.CidrMask", + "type": "Object", + "tags": [], + "label": "CidrMask", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.CidrMask", + "text": "CidrMask" + } + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.dateHistogramInterval", + "type": "Function", + "tags": [], + "label": "dateHistogramInterval", + "description": [], + "signature": [ + "(interval: string, shouldForceFixed?: boolean | undefined) => Interval" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.search.aggs.dateHistogramInterval.$1", + "type": "string", + "tags": [], + "label": "interval", + "description": [], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.dateHistogramInterval.$2", + "type": "CompoundType", + "tags": [], + "label": "shouldForceFixed", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.intervalOptions", + "type": "Array", + "tags": [], + "label": "intervalOptions", + "description": [], + "signature": [ + "({ display: any; val: string; enabled(agg: ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IBucketAggConfig", + "text": "IBucketAggConfig" + }, + "): boolean; } | { display: any; val: string; })[]" + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.InvalidEsCalendarIntervalError", + "type": "Object", + "tags": [], + "label": "InvalidEsCalendarIntervalError", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.InvalidEsCalendarIntervalError", + "text": "InvalidEsCalendarIntervalError" + } + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.InvalidEsIntervalFormatError", + "type": "Object", + "tags": [], + "label": "InvalidEsIntervalFormatError", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.InvalidEsIntervalFormatError", + "text": "InvalidEsIntervalFormatError" + } + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.IpAddress", + "type": "Object", + "tags": [], + "label": "IpAddress", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IpAddress", + "text": "IpAddress" + } + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-public.search.aggs.isDateHistogramBucketAggConfig", + "type": "Function", + "tags": [], + "label": "isDateHistogramBucketAggConfig", + "description": [], + "signature": [ + "(agg: any) => agg is ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IBucketDateHistogramAggConfig", + "text": "IBucketDateHistogramAggConfig" + } + ], + "path": "src/plugins/data/public/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-public.search.aggs.isDateHistogramBucketAggConfig.$1", + "type": "Any", + "tags": [], "label": "agg", "description": [], "signature": [ @@ -13504,19 +14959,23 @@ }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" }, { "plugin": "timelines", @@ -13766,14 +15225,6 @@ "plugin": "discover", "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, { "plugin": "infra", "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" @@ -18759,596 +20210,1593 @@ }, { "parentPluginId": "data", - "id": "def-server.DataViewsServerPluginStart.dataViewsServiceFactory.$3", + "id": "def-server.DataViewsServerPluginStart.dataViewsServiceFactory.$3", + "type": "Object", + "tags": [], + "label": "request", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-http-server", + "scope": "common", + "docId": "kibKbnCoreHttpServerPluginApi", + "section": "def-common.KibanaRequest", + "text": "KibanaRequest" + }, + " | undefined" + ], + "path": "src/plugins/data_views/server/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.DataViewsServerPluginStart.dataViewsServiceFactory.$4", + "type": "CompoundType", + "tags": [], + "label": "byPassCapabilities", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/server/types.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor", + "type": "Interface", + "tags": [], + "label": "FieldDescriptor", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.aggregatable", + "type": "boolean", + "tags": [], + "label": "aggregatable", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.name", + "type": "string", + "tags": [], + "label": "name", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.readFromDocValues", + "type": "boolean", + "tags": [], + "label": "readFromDocValues", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.searchable", + "type": "boolean", + "tags": [], + "label": "searchable", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.esTypes", + "type": "Array", + "tags": [], + "label": "esTypes", + "description": [], + "signature": [ + "string[]" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.subType", + "type": "Object", + "tags": [], + "label": "subType", + "description": [], + "signature": [ + "FieldSubType | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.metadata_field", + "type": "CompoundType", + "tags": [], + "label": "metadata_field", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.fixedInterval", + "type": "Array", + "tags": [], + "label": "fixedInterval", + "description": [], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.timeZone", + "type": "Array", + "tags": [], + "label": "timeZone", + "description": [], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.timeSeriesMetric", + "type": "CompoundType", + "tags": [], + "label": "timeSeriesMetric", + "description": [], + "signature": [ + "\"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.FieldDescriptor.timeSeriesDimension", + "type": "CompoundType", + "tags": [], + "label": "timeSeriesDimension", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.IEsSearchRequest", + "type": "Interface", + "tags": [], + "label": "IEsSearchRequest", + "description": [], + "signature": [ + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IEsSearchRequest", + "text": "IEsSearchRequest" + }, + " extends ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IKibanaSearchRequest", + "text": "IKibanaSearchRequest" + }, + "<", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.ISearchRequestParams", + "text": "ISearchRequestParams" + }, + ">" + ], + "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.IEsSearchRequest.indexType", + "type": "string", + "tags": [], + "label": "indexType", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions", + "type": "Interface", + "tags": [], + "label": "ISearchOptions", + "description": [], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.abortSignal", + "type": "Object", + "tags": [], + "label": "abortSignal", + "description": [ + "\nAn `AbortSignal` that allows the caller of `search` to abort a search request." + ], + "signature": [ + "AbortSignal | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.strategy", + "type": "string", + "tags": [], + "label": "strategy", + "description": [ + "\nUse this option to force using a specific server side search strategy. Leave empty to use the default strategy." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.legacyHitsTotal", + "type": "CompoundType", + "tags": [], + "label": "legacyHitsTotal", + "description": [ + "\nRequest the legacy format for the total number of hits. If sending `rest_total_hits_as_int` to\nsomething other than `true`, this should be set to `false`." + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.sessionId", + "type": "string", + "tags": [], + "label": "sessionId", + "description": [ + "\nA session ID, grouping multiple search requests into a single session." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.isStored", + "type": "CompoundType", + "tags": [], + "label": "isStored", + "description": [ + "\nWhether the session is already saved (i.e. sent to background)" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.isSearchStored", + "type": "CompoundType", + "tags": [], + "label": "isSearchStored", + "description": [ + "\nWhether the search was successfully polled after session was saved. Search was added to a session saved object and keepAlive extended." + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.isRestore", + "type": "CompoundType", + "tags": [], + "label": "isRestore", + "description": [ + "\nWhether the session is restored (i.e. search requests should re-use the stored search IDs,\nrather than starting from scratch)" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.executionContext", + "type": "Object", + "tags": [], + "label": "executionContext", + "description": [ + "\nRepresents a meta-information about a Kibana entity intitating a saerch request." + ], + "signature": [ + { + "pluginId": "@kbn/core-execution-context-common", + "scope": "common", + "docId": "kibKbnCoreExecutionContextCommonPluginApi", + "section": "def-common.KibanaExecutionContext", + "text": "KibanaExecutionContext" + }, + " | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.indexPattern", + "type": "Object", + "tags": [], + "label": "indexPattern", + "description": [ + "\nIndex pattern reference is used for better error messages" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + " | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.ISearchOptions.transport", + "type": "Object", + "tags": [], + "label": "transport", + "description": [ + "\nTransportRequestOptions, other than `signal`, to pass through to the ES client.\nTo pass an abort signal, use {@link ISearchOptions.abortSignal}" + ], + "signature": [ + "Omit<", + "TransportRequestOptions", + ", \"signal\"> | undefined" + ], + "path": "src/plugins/data/common/search/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "enums": [ + { + "parentPluginId": "data", + "id": "def-server.ES_FIELD_TYPES", + "type": "Enum", + "tags": [], + "label": "ES_FIELD_TYPES", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.KBN_FIELD_TYPES", + "type": "Enum", + "tags": [], + "label": "KBN_FIELD_TYPES", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.METRIC_TYPES", + "type": "Enum", + "tags": [], + "label": "METRIC_TYPES", + "description": [], + "path": "src/plugins/data/common/search/aggs/metrics/metric_agg_types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "misc": [ + { + "parentPluginId": "data", + "id": "def-server.DEFAULT_QUERY_LANGUAGE", + "type": "string", + "tags": [], + "label": "DEFAULT_QUERY_LANGUAGE", + "description": [], + "signature": [ + "\"kuery\"" + ], + "path": "src/plugins/data/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.ES_SEARCH_STRATEGY", + "type": "string", + "tags": [], + "label": "ES_SEARCH_STRATEGY", + "description": [], + "signature": [ + "\"es\"" + ], + "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.IEsSearchResponse", + "type": "Type", + "tags": [], + "label": "IEsSearchResponse", + "description": [], + "signature": [ + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IKibanaSearchResponse", + "text": "IKibanaSearchResponse" + }, + "<", + "SearchResponse", + ">>" + ], + "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-server.ParsedInterval", + "type": "Type", + "tags": [], + "label": "ParsedInterval", + "description": [], + "signature": [ + "{ value: number; unit: ", + { + "pluginId": "@kbn/datemath", + "scope": "common", + "docId": "kibKbnDatemathPluginApi", + "section": "def-common.Unit", + "text": "Unit" + }, + "; type: \"fixed\" | \"calendar\"; }" + ], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/parse_es_interval.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "objects": [ + { + "parentPluginId": "data", + "id": "def-server.exporters", + "type": "Object", + "tags": [], + "label": "exporters", + "description": [], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.exporters.datatableToCSV", + "type": "Function", + "tags": [], + "label": "datatableToCSV", + "description": [], + "signature": [ + "({ columns, rows }: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + }, + ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-server.exporters.datatableToCSV.$1", "type": "Object", "tags": [], - "label": "request", + "label": "__0", "description": [], "signature": [ { - "pluginId": "@kbn/core-http-server", + "pluginId": "expressions", "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.KibanaRequest", - "text": "KibanaRequest" - }, - " | undefined" + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + } ], - "path": "src/plugins/data_views/server/types.ts", + "path": "src/plugins/data/common/exports/export_csv.tsx", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-server.DataViewsServerPluginStart.dataViewsServiceFactory.$4", - "type": "CompoundType", + "id": "def-server.exporters.datatableToCSV.$2", + "type": "Object", "tags": [], - "label": "byPassCapabilities", + "label": "__1", "description": [], "signature": [ - "boolean | undefined" + "CSVOptions" ], - "path": "src/plugins/data_views/server/types.ts", + "path": "src/plugins/data/common/exports/export_csv.tsx", "deprecated": false, "trackAdoption": false } ] + }, + { + "parentPluginId": "data", + "id": "def-server.exporters.CSV_MIME_TYPE", + "type": "string", + "tags": [], + "label": "CSV_MIME_TYPE", + "description": [], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false }, { "parentPluginId": "data", - "id": "def-server.FieldDescriptor", - "type": "Interface", + "id": "def-server.search", + "type": "Object", "tags": [], - "label": "FieldDescriptor", + "label": "search", "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "path": "src/plugins/data/server/index.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-server.FieldDescriptor.aggregatable", - "type": "boolean", - "tags": [], - "label": "aggregatable", - "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.readFromDocValues", - "type": "boolean", - "tags": [], - "label": "readFromDocValues", - "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.searchable", - "type": "boolean", - "tags": [], - "label": "searchable", - "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.esTypes", - "type": "Array", - "tags": [], - "label": "esTypes", - "description": [], - "signature": [ - "string[]" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.subType", + "id": "def-server.search.aggs", "type": "Object", "tags": [], - "label": "subType", - "description": [], - "signature": [ - "FieldSubType | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.metadata_field", - "type": "CompoundType", - "tags": [], - "label": "metadata_field", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.fixedInterval", - "type": "Array", - "tags": [], - "label": "fixedInterval", - "description": [], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.timeZone", - "type": "Array", - "tags": [], - "label": "timeZone", - "description": [], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.timeSeriesMetric", - "type": "CompoundType", - "tags": [], - "label": "timeSeriesMetric", - "description": [], - "signature": [ - "\"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.FieldDescriptor.timeSeriesDimension", - "type": "CompoundType", - "tags": [], - "label": "timeSeriesDimension", + "label": "aggs", "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/server/fetcher/index_patterns_fetcher.ts", + "path": "src/plugins/data/server/index.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.search.aggs.CidrMask", + "type": "Object", + "tags": [], + "label": "CidrMask", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.CidrMask", + "text": "CidrMask" + } + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.dateHistogramInterval", + "type": "Function", + "tags": [], + "label": "dateHistogramInterval", + "description": [], + "signature": [ + "(interval: string, shouldForceFixed?: boolean | undefined) => Interval" + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-server.search.aggs.dateHistogramInterval.$1", + "type": "string", + "tags": [], + "label": "interval", + "description": [], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.dateHistogramInterval.$2", + "type": "CompoundType", + "tags": [], + "label": "shouldForceFixed", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.IpAddress", + "type": "Object", + "tags": [], + "label": "IpAddress", + "description": [], + "signature": [ + "typeof ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IpAddress", + "text": "IpAddress" + } + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.parseInterval", + "type": "Function", + "tags": [], + "label": "parseInterval", + "description": [], + "signature": [ + "(interval: string) => moment.Duration | null" + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-server.search.aggs.parseInterval.$1", + "type": "string", + "tags": [], + "label": "interval", + "description": [], + "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/parse_interval.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.calcAutoIntervalLessThan", + "type": "Function", + "tags": [], + "label": "calcAutoIntervalLessThan", + "description": [], + "signature": [ + "(maxBucketCount: number, duration: number) => moment.Duration" + ], + "path": "src/plugins/data/server/index.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-server.search.aggs.calcAutoIntervalLessThan.$1", + "type": "number", + "tags": [], + "label": "maxBucketCount", + "description": [], + "path": "src/plugins/data/common/search/aggs/buckets/lib/time_buckets/calc_auto_interval.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.search.aggs.calcAutoIntervalLessThan.$2", + "type": "number", + "tags": [], + "label": "duration", + "description": [], + "path": "src/plugins/data/common/search/aggs/buckets/lib/time_buckets/calc_auto_interval.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ] } ], "initialIsOpen": false }, { "parentPluginId": "data", - "id": "def-server.IEsSearchRequest", - "type": "Interface", + "id": "def-server.UI_SETTINGS", + "type": "Object", + "tags": [], + "label": "UI_SETTINGS", + "description": [], + "signature": [ + "{ readonly META_FIELDS: \"metaFields\"; readonly DOC_HIGHLIGHT: \"doc_table:highlight\"; readonly QUERY_STRING_OPTIONS: \"query:queryString:options\"; readonly QUERY_ALLOW_LEADING_WILDCARDS: \"query:allowLeadingWildcards\"; readonly SEARCH_QUERY_LANGUAGE: \"search:queryLanguage\"; readonly SORT_OPTIONS: \"sort:options\"; readonly COURIER_IGNORE_FILTER_IF_FIELD_NOT_IN_INDEX: \"courier:ignoreFilterIfFieldNotInIndex\"; readonly COURIER_SET_REQUEST_PREFERENCE: \"courier:setRequestPreference\"; readonly COURIER_CUSTOM_REQUEST_PREFERENCE: \"courier:customRequestPreference\"; readonly COURIER_MAX_CONCURRENT_SHARD_REQUESTS: \"courier:maxConcurrentShardRequests\"; readonly SEARCH_INCLUDE_FROZEN: \"search:includeFrozen\"; readonly SEARCH_TIMEOUT: \"search:timeout\"; readonly HISTOGRAM_BAR_TARGET: \"histogram:barTarget\"; readonly HISTOGRAM_MAX_BARS: \"histogram:maxBars\"; readonly HISTORY_LIMIT: \"history:limit\"; readonly TIMEPICKER_REFRESH_INTERVAL_DEFAULTS: \"timepicker:refreshIntervalDefaults\"; readonly TIMEPICKER_QUICK_RANGES: \"timepicker:quickRanges\"; readonly TIMEPICKER_TIME_DEFAULTS: \"timepicker:timeDefaults\"; readonly FILTERS_PINNED_BY_DEFAULT: \"filters:pinnedByDefault\"; readonly FILTERS_EDITOR_SUGGEST_VALUES: \"filterEditor:suggestValues\"; readonly AUTOCOMPLETE_USE_TIMERANGE: \"autocomplete:useTimeRange\"; readonly AUTOCOMPLETE_VALUE_SUGGESTION_METHOD: \"autocomplete:valueSuggestionMethod\"; readonly DATE_FORMAT: \"dateFormat\"; readonly DATEFORMAT_TZ: \"dateFormat:tz\"; }" + ], + "path": "src/plugins/data/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "setup": { + "parentPluginId": "data", + "id": "def-server.DataPluginSetup", + "type": "Interface", + "tags": [], + "label": "DataPluginSetup", + "description": [], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.DataPluginSetup.search", + "type": "Object", + "tags": [], + "label": "search", + "description": [], + "signature": [ + "ISearchSetup" + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.DataPluginSetup.query", + "type": "Object", + "tags": [], + "label": "query", + "description": [], + "signature": [ + "QuerySetup" + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.DataPluginSetup.fieldFormats", + "type": "Object", + "tags": [ + "deprecated" + ], + "label": "fieldFormats", + "description": [], + "signature": [ + { + "pluginId": "fieldFormats", + "scope": "server", + "docId": "kibFieldFormatsPluginApi", + "section": "def-server.FieldFormatsSetup", + "text": "FieldFormatsSetup" + } + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": true, + "trackAdoption": false, + "references": [] + } + ], + "lifecycle": "setup", + "initialIsOpen": true + }, + "start": { + "parentPluginId": "data", + "id": "def-server.DataPluginStart", + "type": "Interface", + "tags": [], + "label": "DataPluginStart", + "description": [], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-server.DataPluginStart.search", + "type": "Object", + "tags": [], + "label": "search", + "description": [], + "signature": [ + "ISearchStart", + "<", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IEsSearchRequest", + "text": "IEsSearchRequest" + }, + ", ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.IEsSearchResponse", + "text": "IEsSearchResponse" + }, + ">" + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.DataPluginStart.fieldFormats", + "type": "Object", + "tags": [ + "deprecated" + ], + "label": "fieldFormats", + "description": [], + "signature": [ + { + "pluginId": "fieldFormats", + "scope": "server", + "docId": "kibFieldFormatsPluginApi", + "section": "def-server.FieldFormatsStart", + "text": "FieldFormatsStart" + } + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": true, + "trackAdoption": false, + "references": [] + }, + { + "parentPluginId": "data", + "id": "def-server.DataPluginStart.indexPatterns", + "type": "Object", + "tags": [], + "label": "indexPatterns", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "server", + "docId": "kibDataViewsPluginApi", + "section": "def-server.DataViewsServerPluginStart", + "text": "DataViewsServerPluginStart" + } + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-server.DataPluginStart.datatableUtilities", + "type": "Object", + "tags": [], + "label": "datatableUtilities", + "description": [ + "\nDatatable type utility functions." + ], + "signature": [ + "DatatableUtilitiesService" + ], + "path": "src/plugins/data/server/plugin.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "lifecycle": "start", + "initialIsOpen": true + } + }, + "common": { + "classes": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService", + "type": "Class", "tags": [], - "label": "IEsSearchRequest", + "label": "DatatableUtilitiesService", "description": [], - "signature": [ - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IEsSearchRequest", - "text": "IEsSearchRequest" - }, - " extends ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IKibanaSearchRequest", - "text": "IKibanaSearchRequest" - }, - "<", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.ISearchRequestParams", - "text": "ISearchRequestParams" - }, - ">" - ], - "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-server.IEsSearchRequest.indexType", - "type": "string", + "id": "def-common.DatatableUtilitiesService.Unnamed", + "type": "Function", "tags": [], - "label": "indexType", + "label": "Constructor", "description": [], "signature": [ - "string | undefined" + "any" ], - "path": "src/plugins/data/common/search/strategies/es_search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.ISearchOptions", - "type": "Interface", - "tags": [], - "label": "ISearchOptions", - "description": [], - "path": "src/plugins/data/common/search/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.Unnamed.$1", + "type": "Object", + "tags": [], + "label": "aggs", + "description": [], + "signature": [ + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.AggsCommonStart", + "text": "AggsCommonStart" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.Unnamed.$2", + "type": "Object", + "tags": [], + "label": "dataViews", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewsContract", + "text": "DataViewsContract" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.Unnamed.$3", + "type": "Object", + "tags": [], + "label": "fieldFormats", + "description": [], + "signature": [ + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormatsStartCommon", + "text": "FieldFormatsStartCommon" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.abortSignal", - "type": "Object", + "id": "def-common.DatatableUtilitiesService.clearField", + "type": "Function", "tags": [], - "label": "abortSignal", - "description": [ - "\nAn `AbortSignal` that allows the caller of `search` to abort a search request." - ], + "label": "clearField", + "description": [], "signature": [ - "AbortSignal | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => void" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.clearField.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.strategy", - "type": "string", + "id": "def-common.DatatableUtilitiesService.clearFieldFormat", + "type": "Function", "tags": [], - "label": "strategy", - "description": [ - "\nUse this option to force using a specific server side search strategy. Leave empty to use the default strategy." - ], + "label": "clearFieldFormat", + "description": [], "signature": [ - "string | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => void" + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.clearFieldFormat.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } ], - "path": "src/plugins/data/common/search/types.ts", - "deprecated": false, - "trackAdoption": false + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.legacyHitsTotal", - "type": "CompoundType", + "id": "def-common.DatatableUtilitiesService.getAggConfig", + "type": "Function", "tags": [], - "label": "legacyHitsTotal", - "description": [ - "\nRequest the legacy format for the total number of hits. If sending `rest_total_hits_as_int` to\nsomething other than `true`, this should be set to `false`." - ], + "label": "getAggConfig", + "description": [], "signature": [ - "boolean | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => Promise<", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataSearchPluginApi", + "section": "def-common.AggConfig", + "text": "AggConfig" + }, + " | undefined>" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.ISearchOptions.sessionId", - "type": "string", - "tags": [], - "label": "sessionId", - "description": [ - "\nA session ID, grouping multiple search requests into a single session." - ], - "signature": [ - "string | undefined" + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getAggConfig.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } ], - "path": "src/plugins/data/common/search/types.ts", - "deprecated": false, - "trackAdoption": false + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.isStored", - "type": "CompoundType", + "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta", + "type": "Function", "tags": [], - "label": "isStored", + "label": "getDateHistogramMeta", "description": [ - "\nWhether the session is already saved (i.e. sent to background)" + "\nHelper function returning the used interval, used time zone and applied time filters for data table column created by the date_histogramm agg type.\n\"auto\" will get expanded to the actually used interval.\nIf the column is not a column created by a date_histogram aggregation of the esaggs data source,\nthis function will return undefined." ], "signature": [ - "boolean | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ", defaults?: Partial<{ timeZone: string; }>) => DateHistogramMeta | undefined" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta.$2", + "type": "Object", + "tags": [], + "label": "defaults", + "description": [], + "signature": [ + "Partial<{ timeZone: string; }>" + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.isSearchStored", - "type": "CompoundType", + "id": "def-common.DatatableUtilitiesService.getDataView", + "type": "Function", "tags": [], - "label": "isSearchStored", - "description": [ - "\nWhether the search was successfully polled after session was saved. Search was added to a session saved object and keepAlive extended." - ], + "label": "getDataView", + "description": [], "signature": [ - "boolean | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + " | undefined>" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getDataView.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.isRestore", - "type": "CompoundType", + "id": "def-common.DatatableUtilitiesService.getField", + "type": "Function", "tags": [], - "label": "isRestore", - "description": [ - "\nWhether the session is restored (i.e. search requests should re-use the stored search IDs,\nrather than starting from scratch)" - ], + "label": "getField", + "description": [], "signature": [ - "boolean | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + }, + " | undefined>" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.ISearchOptions.executionContext", - "type": "Object", - "tags": [], - "label": "executionContext", - "description": [ - "\nRepresents a meta-information about a Kibana entity intitating a saerch request." + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getField.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getFieldFormat", + "type": "Function", + "tags": [], + "label": "getFieldFormat", + "description": [], "signature": [ + "(column: ", { - "pluginId": "@kbn/core-execution-context-common", + "pluginId": "expressions", "scope": "common", - "docId": "kibKbnCoreExecutionContextCommonPluginApi", - "section": "def-common.KibanaExecutionContext", - "text": "KibanaExecutionContext" + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => ", + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormat", + "text": "FieldFormat" }, " | undefined" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getFieldFormat.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.indexPattern", - "type": "Object", + "id": "def-common.DatatableUtilitiesService.getInterval", + "type": "Function", "tags": [], - "label": "indexPattern", - "description": [ - "\nIndex pattern reference is used for better error messages" - ], + "label": "getInterval", + "description": [], "signature": [ + "(column: ", { - "pluginId": "dataViews", + "pluginId": "expressions", "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" }, - " | undefined" + ") => string | undefined" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getInterval.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.ISearchOptions.transport", - "type": "Object", + "id": "def-common.DatatableUtilitiesService.getNumberHistogramInterval", + "type": "Function", "tags": [], - "label": "transport", + "label": "getNumberHistogramInterval", "description": [ - "\nTransportRequestOptions, other than `signal`, to pass through to the ES client.\nTo pass an abort signal, use {@link ISearchOptions.abortSignal}" + "\nHelper function returning the used interval for data table column created by the histogramm agg type.\n\"auto\" will get expanded to the actually used interval.\nIf the column is not a column created by a histogram aggregation of the esaggs data source,\nthis function will return undefined." ], "signature": [ - "Omit<", - "TransportRequestOptions", - ", \"signal\"> | undefined" + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => number | undefined" ], - "path": "src/plugins/data/common/search/types.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - } - ], - "enums": [ - { - "parentPluginId": "data", - "id": "def-server.ES_FIELD_TYPES", - "type": "Enum", - "tags": [], - "label": "ES_FIELD_TYPES", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.KBN_FIELD_TYPES", - "type": "Enum", - "tags": [], - "label": "KBN_FIELD_TYPES", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.METRIC_TYPES", - "type": "Enum", - "tags": [], - "label": "METRIC_TYPES", - "description": [], - "path": "src/plugins/data/common/search/aggs/metrics/metric_agg_types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "misc": [ - { - "parentPluginId": "data", - "id": "def-server.DEFAULT_QUERY_LANGUAGE", - "type": "string", - "tags": [], - "label": "DEFAULT_QUERY_LANGUAGE", - "description": [], - "signature": [ - "\"kuery\"" - ], - "path": "src/plugins/data/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.ES_SEARCH_STRATEGY", - "type": "string", - "tags": [], - "label": "ES_SEARCH_STRATEGY", - "description": [], - "signature": [ - "\"es\"" - ], - "path": "src/plugins/data/common/search/strategies/es_search/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.IEsSearchResponse", - "type": "Type", - "tags": [], - "label": "IEsSearchResponse", - "description": [], - "signature": [ - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IKibanaSearchResponse", - "text": "IKibanaSearchResponse" - }, - "<", - "SearchResponse", - ">>" - ], - "path": "src/plugins/data/common/search/strategies/es_search/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.ParsedInterval", - "type": "Type", - "tags": [], - "label": "ParsedInterval", - "description": [], - "signature": [ - "{ value: number; unit: ", - { - "pluginId": "@kbn/datemath", - "scope": "common", - "docId": "kibKbnDatemathPluginApi", - "section": "def-common.Unit", - "text": "Unit" + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.getNumberHistogramInterval.$1", + "type": "Object", + "tags": [], + "label": "column", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] }, - "; type: \"fixed\" | \"calendar\"; }" - ], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/parse_es_interval.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "objects": [ - { - "parentPluginId": "data", - "id": "def-server.exporters", - "type": "Object", - "tags": [], - "label": "exporters", - "description": [], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { "parentPluginId": "data", - "id": "def-server.exporters.datatableToCSV", + "id": "def-common.DatatableUtilitiesService.getTotalCount", "type": "Function", "tags": [], - "label": "datatableToCSV", + "label": "getTotalCount", "description": [], "signature": [ - "({ columns, rows }: ", + "(table: ", { "pluginId": "expressions", "scope": "common", @@ -19356,19 +21804,18 @@ "section": "def-common.Datatable", "text": "Datatable" }, - ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" + ") => number | undefined" ], - "path": "src/plugins/data/server/index.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, "trackAdoption": false, - "returnComment": [], "children": [ { "parentPluginId": "data", - "id": "def-server.exporters.datatableToCSV.$1", + "id": "def-common.DatatableUtilitiesService.getTotalCount.$1", "type": "Object", "tags": [], - "label": "__0", + "label": "table", "description": [], "signature": [ { @@ -19379,863 +21826,1357 @@ "text": "Datatable" } ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.exporters.datatableToCSV.$2", - "type": "Object", - "tags": [], - "label": "__1", - "description": [], - "signature": [ - "CSVOptions" - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "isRequired": true } - ] + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-server.exporters.CSV_MIME_TYPE", - "type": "string", - "tags": [], - "label": "CSV_MIME_TYPE", - "description": [], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.search", - "type": "Object", - "tags": [], - "label": "search", - "description": [], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-server.search.aggs", - "type": "Object", + "id": "def-common.DatatableUtilitiesService.hasPrecisionError", + "type": "Function", "tags": [], - "label": "aggs", + "label": "hasPrecisionError", "description": [], - "path": "src/plugins/data/server/index.ts", + "signature": [ + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ") => ", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.Serializable", + "text": "Serializable" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-server.search.aggs.CidrMask", + "id": "def-common.DatatableUtilitiesService.hasPrecisionError.$1", "type": "Object", "tags": [], - "label": "CidrMask", + "label": "column", "description": [], "signature": [ - "typeof ", { - "pluginId": "data", + "pluginId": "expressions", "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.CidrMask", - "text": "CidrMask" + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" } ], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.search.aggs.dateHistogramInterval", - "type": "Function", - "tags": [], - "label": "dateHistogramInterval", - "description": [], - "signature": [ - "(interval: string, shouldForceFixed?: boolean | undefined) => Interval" - ], - "path": "src/plugins/data/server/index.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-server.search.aggs.dateHistogramInterval.$1", - "type": "string", - "tags": [], - "label": "interval", - "description": [], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.search.aggs.dateHistogramInterval.$2", - "type": "CompoundType", - "tags": [], - "label": "shouldForceFixed", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/date_histogram_interval.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.isFilterable", + "type": "Function", + "tags": [], + "label": "isFilterable", + "description": [], + "signature": [ + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" }, + ") => boolean" + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "data", - "id": "def-server.search.aggs.IpAddress", + "id": "def-common.DatatableUtilitiesService.isFilterable.$1", "type": "Object", "tags": [], - "label": "IpAddress", + "label": "column", "description": [], "signature": [ - "typeof ", { - "pluginId": "data", + "pluginId": "expressions", "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IpAddress", - "text": "IpAddress" + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" } ], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.search.aggs.parseInterval", - "type": "Function", - "tags": [], - "label": "parseInterval", - "description": [], - "signature": [ - "(interval: string) => moment.Duration | null" - ], - "path": "src/plugins/data/server/index.ts", + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", "deprecated": false, "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-server.search.aggs.parseInterval.$1", - "type": "string", - "tags": [], - "label": "interval", - "description": [], - "path": "src/plugins/data/common/search/aggs/utils/date_interval_utils/parse_interval.ts", - "deprecated": false, - "trackAdoption": false - } - ] + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.setFieldFormat", + "type": "Function", + "tags": [], + "label": "setFieldFormat", + "description": [], + "signature": [ + "(column: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + ", fieldFormat: ", + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormat", + "text": "FieldFormat" }, + ") => void" + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "data", - "id": "def-server.search.aggs.calcAutoIntervalLessThan", - "type": "Function", + "id": "def-common.DatatableUtilitiesService.setFieldFormat.$1", + "type": "Object", "tags": [], - "label": "calcAutoIntervalLessThan", + "label": "column", "description": [], "signature": [ - "(maxBucketCount: number, duration: number) => moment.Duration" - ], - "path": "src/plugins/data/server/index.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ - { - "parentPluginId": "data", - "id": "def-server.search.aggs.calcAutoIntervalLessThan.$1", - "type": "number", - "tags": [], - "label": "maxBucketCount", - "description": [], - "path": "src/plugins/data/common/search/aggs/buckets/lib/time_buckets/calc_auto_interval.ts", - "deprecated": false, - "trackAdoption": false - }, { - "parentPluginId": "data", - "id": "def-server.search.aggs.calcAutoIntervalLessThan.$2", - "type": "number", - "tags": [], - "label": "duration", - "description": [], - "path": "src/plugins/data/common/search/aggs/buckets/lib/time_buckets/calc_auto_interval.ts", - "deprecated": false, - "trackAdoption": false - } - ] - } - ] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-server.UI_SETTINGS", - "type": "Object", - "tags": [], - "label": "UI_SETTINGS", - "description": [], - "signature": [ - "{ readonly META_FIELDS: \"metaFields\"; readonly DOC_HIGHLIGHT: \"doc_table:highlight\"; readonly QUERY_STRING_OPTIONS: \"query:queryString:options\"; readonly QUERY_ALLOW_LEADING_WILDCARDS: \"query:allowLeadingWildcards\"; readonly SEARCH_QUERY_LANGUAGE: \"search:queryLanguage\"; readonly SORT_OPTIONS: \"sort:options\"; readonly COURIER_IGNORE_FILTER_IF_FIELD_NOT_IN_INDEX: \"courier:ignoreFilterIfFieldNotInIndex\"; readonly COURIER_SET_REQUEST_PREFERENCE: \"courier:setRequestPreference\"; readonly COURIER_CUSTOM_REQUEST_PREFERENCE: \"courier:customRequestPreference\"; readonly COURIER_MAX_CONCURRENT_SHARD_REQUESTS: \"courier:maxConcurrentShardRequests\"; readonly SEARCH_INCLUDE_FROZEN: \"search:includeFrozen\"; readonly SEARCH_TIMEOUT: \"search:timeout\"; readonly HISTOGRAM_BAR_TARGET: \"histogram:barTarget\"; readonly HISTOGRAM_MAX_BARS: \"histogram:maxBars\"; readonly HISTORY_LIMIT: \"history:limit\"; readonly TIMEPICKER_REFRESH_INTERVAL_DEFAULTS: \"timepicker:refreshIntervalDefaults\"; readonly TIMEPICKER_QUICK_RANGES: \"timepicker:quickRanges\"; readonly TIMEPICKER_TIME_DEFAULTS: \"timepicker:timeDefaults\"; readonly FILTERS_PINNED_BY_DEFAULT: \"filters:pinnedByDefault\"; readonly FILTERS_EDITOR_SUGGEST_VALUES: \"filterEditor:suggestValues\"; readonly AUTOCOMPLETE_USE_TIMERANGE: \"autocomplete:useTimeRange\"; readonly AUTOCOMPLETE_VALUE_SUGGESTION_METHOD: \"autocomplete:valueSuggestionMethod\"; readonly DATE_FORMAT: \"dateFormat\"; readonly DATEFORMAT_TZ: \"dateFormat:tz\"; }" - ], - "path": "src/plugins/data/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "setup": { - "parentPluginId": "data", - "id": "def-server.DataPluginSetup", - "type": "Interface", - "tags": [], - "label": "DataPluginSetup", - "description": [], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-server.DataPluginSetup.search", - "type": "Object", - "tags": [], - "label": "search", - "description": [], - "signature": [ - "ISearchSetup" - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.DataPluginSetup.query", - "type": "Object", - "tags": [], - "label": "query", - "description": [], - "signature": [ - "QuerySetup" - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.DataPluginSetup.fieldFormats", - "type": "Object", - "tags": [ - "deprecated" - ], - "label": "fieldFormats", - "description": [], - "signature": [ - { - "pluginId": "fieldFormats", - "scope": "server", - "docId": "kibFieldFormatsPluginApi", - "section": "def-server.FieldFormatsSetup", - "text": "FieldFormatsSetup" - } - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": true, - "trackAdoption": false, - "references": [] - } - ], - "lifecycle": "setup", - "initialIsOpen": true - }, - "start": { - "parentPluginId": "data", - "id": "def-server.DataPluginStart", - "type": "Interface", - "tags": [], - "label": "DataPluginStart", - "description": [], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-server.DataPluginStart.search", - "type": "Object", - "tags": [], - "label": "search", - "description": [], - "signature": [ - "ISearchStart", - "<", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IEsSearchRequest", - "text": "IEsSearchRequest" - }, - ", ", - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.IEsSearchResponse", - "text": "IEsSearchResponse" - }, - ">" - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.DataPluginStart.fieldFormats", - "type": "Object", - "tags": [ - "deprecated" - ], - "label": "fieldFormats", - "description": [], - "signature": [ - { - "pluginId": "fieldFormats", - "scope": "server", - "docId": "kibFieldFormatsPluginApi", - "section": "def-server.FieldFormatsStart", - "text": "FieldFormatsStart" - } - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": true, - "trackAdoption": false, - "references": [] - }, - { - "parentPluginId": "data", - "id": "def-server.DataPluginStart.indexPatterns", - "type": "Object", - "tags": [], - "label": "indexPatterns", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "server", - "docId": "kibDataViewsPluginApi", - "section": "def-server.DataViewsServerPluginStart", - "text": "DataViewsServerPluginStart" - } - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-server.DataPluginStart.datatableUtilities", - "type": "Object", - "tags": [], - "label": "datatableUtilities", - "description": [ - "\nDatatable type utility functions." - ], - "signature": [ - "DatatableUtilitiesService" - ], - "path": "src/plugins/data/server/plugin.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "lifecycle": "start", - "initialIsOpen": true - } - }, - "common": { - "classes": [ + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.DatatableUtilitiesService.setFieldFormat.$2", + "type": "Object", + "tags": [], + "label": "fieldFormat", + "description": [], + "signature": [ + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormat", + "text": "FieldFormat" + } + ], + "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService", + "id": "def-common.DataView", "type": "Class", "tags": [], - "label": "DatatableUtilitiesService", - "description": [], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "label": "DataView", + "description": [ + "\nData view class. Central kibana abstraction around multiple indices." + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + " implements ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewBase", + "text": "DataViewBase" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.Unnamed", - "type": "Function", + "id": "def-common.DataView.id", + "type": "string", "tags": [], - "label": "Constructor", - "description": [], + "label": "id", + "description": [ + "\nSaved object id" + ], "signature": [ - "any" + "string | undefined" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.title", + "type": "string", + "tags": [ + "deprecated" + ], + "label": "title", + "description": [ + "\nTitle of data view" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/types.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/source/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/source/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts" + }, + { + "plugin": "timelines", + "path": "x-pack/plugins/timelines/public/mock/index_pattern.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/mock/index_pattern.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" + }, + { + "plugin": "threatIntelligence", + "path": "x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/build_es_query.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/from_combined_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/from_filters.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/from_filters.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/from_kuery.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/es_query/from_nested_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/build_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/exists_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/get_filter_field.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/phrase_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/phrase_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/build_filters/phrases_filter.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/ast/ast.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/and.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/exists.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/is.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/nested.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/not.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/or.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/range.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/node_types/function.test.ts" + }, + { + "plugin": "@kbn/es-query", + "path": "packages/kbn-es-query/src/kuery/functions/utils/get_full_field_name_node.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/autocomplete/providers/value_suggestion_provider.ts" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/query_string_input/fetch_index_patterns.ts" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/dataview_picker/change_dataview.tsx" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/rest_api_routes/update_data_view.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/rest_api_routes/update_data_view.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx" + }, + { + "plugin": "controls", + "path": "src/plugins/controls/public/services/options_list/options_list_service.ts" + }, + { + "plugin": "controls", + "path": "src/plugins/controls/public/services/options_list/options_list_service.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/public/services/field_stats/load_field_stats.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/public/hooks/use_existing_fields.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/public/hooks/use_existing_fields.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/data_views_service/loader.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx" + }, + { + "plugin": "aiops", + "path": "x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/server/models/data_frame_analytics/index_patterns.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/server/models/job_service/new_job_caps/rollup.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/server/lib/alerts/alerting_service.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/server/models/data_recognizer/data_recognizer.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/common/log_views/resolved_log_view.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/server/lib/get_fields.ts" + }, + { + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/utils/observability_data_views/observability_data_views.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/report_definition_field.tsx" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/use_filter_values.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/filter_value_btn.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/hooks/use_data_visualizer_grid_data.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/index_data_visualizer_view/index_data_visualizer_view.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_details.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/datavisualizer/index_based/data_loader/data_loader.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/action_clone/clone_action_name.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/common/job_creator/job_creator.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/common/results_loader/categorization_examples_loader.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/preconfigured_job_redirect.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/estimate_bucket_span.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/new_job/wizard_steps.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_exploration/components/outlier_exploration/use_outlier_data.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_exploration/components/exploration_results_table/use_exploration_results.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/embeddables/anomaly_charts/anomaly_charts_embeddable.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/data_views.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/data_views.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/datasource/datasource_component.js" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/datasource.sagas.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/persistence.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/persistence.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + }, + { + "plugin": "timelines", + "path": "x-pack/plugins/timelines/server/search_strategy/index_fields/index.ts" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/expressions/boundary_index_expression.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/expressions/entity_index_expression.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + }, + { + "plugin": "stackAlerts", + "path": "x-pack/plugins/stack_alerts/public/rule_types/components/data_view_select_popover.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/filter_agg/components/filter_term_form.tsx" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/hooks/use_search_items/common.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/services/es_index_service.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/server/routes/api/transforms.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx" + }, + { + "plugin": "ux", + "path": "x-pack/plugins/ux/public/components/app/rum_dashboard/local_uifilters/use_data_view.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/datasource.test.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/classes/tooltips/es_tooltip_property.test.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/new_job_capabilities/remove_nested_field_children.test.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_kpi.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_with_reference_lines.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/test_formula_metric_attribute.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/mobile_test_attribute.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_cwv.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/common.test.ts" + }, + { + "plugin": "controls", + "path": "src/plugins/controls/public/services/data_views/data_views.story.ts" + }, + { + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" + }, + { + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" + }, { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.Unnamed.$1", - "type": "Object", - "tags": [], - "label": "aggs", - "description": [], - "signature": [ - { - "pluginId": "data", - "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.AggsCommonStart", - "text": "AggsCommonStart" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/field_editor/components/scripting_help/test_script.tsx" }, { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.Unnamed.$2", - "type": "Object", - "tags": [], - "label": "dataViews", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewsContract", - "text": "DataViewsContract" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/field_editor/field_editor.tsx" }, { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.Unnamed.$3", - "type": "Object", - "tags": [], - "label": "fieldFormats", - "description": [], - "signature": [ - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormatsStartCommon", - "text": "FieldFormatsStartCommon" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.clearField", - "type": "Function", - "tags": [], - "label": "clearField", - "description": [], - "signature": [ - "(column: ", + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/create_edit_field/create_edit_field.tsx" + }, { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" + "plugin": "inputControlVis", + "path": "src/plugins/input_control_vis/public/control/list_control_factory.ts" }, - ") => void" - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.clearField.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "inputControlVis", + "path": "src/plugins/input_control_vis/public/control/range_control_factory.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/server/routes/field_stats.ts" + }, + { + "plugin": "unifiedFieldList", + "path": "src/plugins/unified_field_list/server/routes/field_stats.ts" + }, + { + "plugin": "visDefaultEditor", + "path": "src/plugins/vis_default_editor/public/components/controls/field.tsx" + }, + { + "plugin": "visDefaultEditor", + "path": "src/plugins/vis_default_editor/public/components/controls/field.tsx" + }, + { + "plugin": "visDefaultEditor", + "path": "src/plugins/vis_default_editor/public/components/agg_select.tsx" + }, + { + "plugin": "inputControlVis", + "path": "src/plugins/input_control_vis/public/test_utils/get_index_pattern_mock.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/data_views/data_views.story.ts" + }, + { + "plugin": "visTypeTimelion", + "path": "src/plugins/vis_types/timelion/public/helpers/arg_value_suggestions.ts" + }, + { + "plugin": "visTypeTimelion", + "path": "src/plugins/vis_types/timelion/public/helpers/arg_value_suggestions.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.ts" + }, + { + "plugin": "visTypeVega", + "path": "src/plugins/vis_types/vega/public/data_model/search_api.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/lib/cached_index_pattern_fetcher.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/lib/cached_index_pattern_fetcher.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" } - ], - "returnComment": [] + ] }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.clearFieldFormat", - "type": "Function", + "id": "def-common.DataView.fieldFormatMap", + "type": "Object", "tags": [], - "label": "clearFieldFormat", - "description": [], + "label": "fieldFormatMap", + "description": [ + "\nMap of field formats by field name" + ], "signature": [ - "(column: ", + "{ [x: string]: ", { - "pluginId": "expressions", + "pluginId": "fieldFormats", "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" }, - ") => void" - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "<{}, ", { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.clearFieldFormat.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + ">; }" ], - "returnComment": [] + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getAggConfig", - "type": "Function", + "id": "def-common.DataView.typeMeta", + "type": "Object", "tags": [], - "label": "getAggConfig", - "description": [], + "label": "typeMeta", + "description": [ + "\nOnly used by rollup indices, used by rollup specific endpoint to load field list." + ], "signature": [ - "(column: ", { - "pluginId": "expressions", + "pluginId": "dataViews", "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" + "docId": "kibDataViewsPluginApi", + "section": "def-common.TypeMeta", + "text": "TypeMeta" }, - ") => Promise<", + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.fields", + "type": "CompoundType", + "tags": [], + "label": "fields", + "description": [ + "\nField list, in extended array format" + ], + "signature": [ { - "pluginId": "data", + "pluginId": "dataViews", "scope": "common", - "docId": "kibDataSearchPluginApi", - "section": "def-common.AggConfig", - "text": "AggConfig" + "docId": "kibDataViewsPluginApi", + "section": "def-common.IIndexPatternFieldList", + "text": "IIndexPatternFieldList" }, - " | undefined>" + " & { toSpec: () => ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewFieldMap", + "text": "DataViewFieldMap" + }, + "; }" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getAggConfig.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.timeFieldName", + "type": "string", + "tags": [], + "label": "timeFieldName", + "description": [ + "\nTimestamp field name" ], - "returnComment": [] + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta", - "type": "Function", + "id": "def-common.DataView.type", + "type": "string", "tags": [], - "label": "getDateHistogramMeta", + "label": "type", "description": [ - "\nHelper function returning the used interval, used time zone and applied time filters for data table column created by the date_histogramm agg type.\n\"auto\" will get expanded to the actually used interval.\nIf the column is not a column created by a date_histogram aggregation of the esaggs data source,\nthis function will return undefined." + "\nType is used to identify rollup index patterns." ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ", defaults?: Partial<{ timeZone: string; }>) => DateHistogramMeta | undefined" + "string | undefined" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.flattenHit", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "flattenHit", + "description": [], + "signature": [ + "(hit: Record, deep?: boolean | undefined) => Record" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx" + } + ], + "returnComment": [], "children": [ { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta.$1", + "id": "def-common.DataView.flattenHit.$1", "type": "Object", "tags": [], - "label": "column", + "label": "hit", "description": [], "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } + "{ [x: string]: unknown[]; }" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false, - "isRequired": true + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getDateHistogramMeta.$2", - "type": "Object", + "id": "def-common.DataView.flattenHit.$2", + "type": "CompoundType", "tags": [], - "label": "defaults", + "label": "deep", "description": [], "signature": [ - "Partial<{ timeZone: string; }>" + "boolean | undefined" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false, - "isRequired": true + "trackAdoption": false } + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.metaFields", + "type": "Array", + "tags": [], + "label": "metaFields", + "description": [ + "\nList of meta fields by name" ], - "returnComment": [] + "signature": [ + "string[]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getDataView", - "type": "Function", + "id": "def-common.DataView.version", + "type": "string", "tags": [], - "label": "getDataView", - "description": [], + "label": "version", + "description": [ + "\nSavedObject version" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.sourceFilters", + "type": "Array", + "tags": [], + "label": "sourceFilters", + "description": [ + "\nArray of filters - hides fields in discover" + ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => Promise<", { "pluginId": "dataViews", "scope": "common", "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "section": "def-common.SourceFilter", + "text": "SourceFilter" }, - " | undefined>" + "[] | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.namespaces", + "type": "Array", + "tags": [], + "label": "namespaces", + "description": [ + "\nArray of namespace ids" + ], + "signature": [ + "string[]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.allowNoIndex", + "type": "boolean", + "tags": [], + "label": "allowNoIndex", + "description": [ + "\nPrevents errors when index pattern exists before indices" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getDataView.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.name", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "\nName of the data view. Human readable name used to differentiate data view." ], - "returnComment": [] + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getField", - "type": "Function", + "id": "def-common.DataView.matchedIndices", + "type": "Array", "tags": [], - "label": "getField", + "label": "matchedIndices", "description": [], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - " | undefined>" + "string[]" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getField.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getFieldFormat", + "id": "def-common.DataView.Unnamed", "type": "Function", "tags": [], - "label": "getFieldFormat", - "description": [], + "label": "Constructor", + "description": [ + "\nconstructor" + ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormat", - "text": "FieldFormat" - }, - " | undefined" + "any" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getFieldFormat.$1", + "id": "def-common.DataView.Unnamed.$1", "type": "Object", "tags": [], - "label": "column", - "description": [], + "label": "config", + "description": [ + "- config data and dependencies" + ], "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } + "DataViewDeps" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -20245,137 +23186,69 @@ }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getInterval", + "id": "def-common.DataView.getName", "type": "Function", "tags": [], - "label": "getInterval", - "description": [], + "label": "getName", + "description": [ + "\nGet name of Data View" + ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => string | undefined" + "() => string" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getInterval.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], + "children": [], "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getNumberHistogramInterval", + "id": "def-common.DataView.getIndexPattern", "type": "Function", "tags": [], - "label": "getNumberHistogramInterval", + "label": "getIndexPattern", "description": [ - "\nHelper function returning the used interval for data table column created by the histogramm agg type.\n\"auto\" will get expanded to the actually used interval.\nIf the column is not a column created by a histogram aggregation of the esaggs data source,\nthis function will return undefined." + "\nGet index pattern" ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => number | undefined" + "() => string" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getNumberHistogramInterval.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "children": [], + "returnComment": [ + "index pattern string" + ] }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getTotalCount", + "id": "def-common.DataView.setIndexPattern", "type": "Function", "tags": [], - "label": "getTotalCount", - "description": [], + "label": "setIndexPattern", + "description": [ + "\nSet index pattern" + ], "signature": [ - "(table: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" - }, - ") => number | undefined" + "(indexPattern: string) => void" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.getTotalCount.$1", - "type": "Object", + "id": "def-common.DataView.setIndexPattern.$1", + "type": "string", "tags": [], - "label": "table", + "label": "indexPattern", "description": [], "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" - } + "string" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -20385,1072 +23258,4641 @@ }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.hasPrecisionError", + "id": "def-common.DataView.getOriginalSavedObjectBody", "type": "Function", "tags": [], - "label": "hasPrecisionError", - "description": [], + "label": "getOriginalSavedObjectBody", + "description": [ + "\nGet last saved saved object fields" + ], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ") => ", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.Serializable", - "text": "Serializable" - } + "() => { fieldAttrs?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; fields?: string | undefined; sourceFilters?: string | undefined; fieldFormatMap?: string | undefined; typeMeta?: string | undefined; type?: string | undefined; }" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.hasPrecisionError.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.resetOriginalSavedObjectBody", + "type": "Function", + "tags": [], + "label": "resetOriginalSavedObjectBody", + "description": [ + "\nReset last saved saved object fields. Used after saving." + ], + "signature": [ + "() => void" ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.isFilterable", + "id": "def-common.DataView.getFieldAttrs", "type": "Function", "tags": [], - "label": "isFilterable", - "description": [], + "label": "getFieldAttrs", + "description": [ + "\nReturns field attributes map" + ], "signature": [ - "(column: ", + "() => { [x: string]: ", { - "pluginId": "expressions", + "pluginId": "dataViews", "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrSet", + "text": "FieldAttrSet" }, - ") => boolean" + "; }" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.isFilterable.$1", - "type": "Object", - "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } - ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getComputedFields", + "type": "Function", + "tags": [], + "label": "getComputedFields", + "description": [ + "\nReturns scripted fields" + ], + "signature": [ + "() => { storedFields: string[]; scriptFields: Record; docvalueFields: { field: string; format: string; }[]; runtimeFields: ", + "MappingRuntimeFields", + "; }" ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.setFieldFormat", + "id": "def-common.DataView.isPersisted", "type": "Function", "tags": [], - "label": "setFieldFormat", + "label": "isPersisted", "description": [], "signature": [ - "(column: ", - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - ", fieldFormat: ", + "() => boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.toSpec", + "type": "Function", + "tags": [], + "label": "toSpec", + "description": [ + "\nCreates static representation of the data view." + ], + "signature": [ + "(includeFields?: boolean) => ", { - "pluginId": "fieldFormats", + "pluginId": "dataViews", "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormat", - "text": "FieldFormat" - }, - ") => void" + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + } ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.setFieldFormat.$1", - "type": "Object", + "id": "def-common.DataView.toSpec.$1", + "type": "boolean", "tags": [], - "label": "column", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - } + "label": "includeFields", + "description": [ + "Whether or not to include the `fields` list as part of this spec. If not included, the list\nwill be fetched from Elasticsearch when instantiating a new Data View with this spec." ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DatatableUtilitiesService.setFieldFormat.$2", - "type": "Object", - "tags": [], - "label": "fieldFormat", - "description": [], "signature": [ - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormat", - "text": "FieldFormat" - } + "boolean" ], - "path": "src/plugins/data/common/datatable_utilities/datatable_utilities_service.ts", + "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, "trackAdoption": false, "isRequired": true } ], "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataView", - "type": "Class", - "tags": [], - "label": "DataView", - "description": [ - "\nData view class. Central kibana abstraction around multiple indices." - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" }, - " implements ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.DataViewBase", - "text": "DataViewBase" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.id", - "type": "string", + "id": "def-common.DataView.getSourceFiltering", + "type": "Function", "tags": [], - "label": "id", + "label": "getSourceFiltering", "description": [ - "\nSaved object id" + "\nGet the source filtering configuration for that index." ], "signature": [ - "string | undefined" + "() => { excludes: string[]; }" ], "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "children": [], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DataView.title", - "type": "string", + "id": "def-common.DataView.removeScriptedField", + "type": "Function", "tags": [ "deprecated" ], - "label": "title", + "label": "removeScriptedField", "description": [ - "\nTitle of data view" + "\nRemoves scripted field from field list." + ], + "signature": [ + "(fieldName: string) => void" ], "path": "src/plugins/data_views/common/data_views/data_view.ts", "deprecated": true, "trackAdoption": false, "references": [ { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/types.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/containers/source/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/containers/source/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts" - }, - { - "plugin": "timelines", - "path": "x-pack/plugins/timelines/public/mock/index_pattern.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/mock/index_pattern.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "lists", - "path": "x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts" - }, - { - "plugin": "threatIntelligence", - "path": "x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/build_es_query.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/from_combined_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/from_filters.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/from_filters.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/from_kuery.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/es_query/from_nested_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/build_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/exists_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/get_filter_field.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/phrase_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/phrase_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/build_filters/phrases_filter.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/filters/helpers/compare_filters.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/ast/ast.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/and.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/exists.test.ts" - }, - { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/is.test.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/scripted_fields_table/scripted_fields_table.tsx" }, { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/nested.test.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/field_editor/field_editor.tsx" }, { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/not.test.ts" - }, + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" + } + ], + "children": [ { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/or.test.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.removeScriptedField.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "name of scripted field to remove" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getNonScriptedFields", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "getNonScriptedFields", + "description": [ + "\n" + ], + "signature": [ + "() => ", { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/range.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + "[]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/node_types/function.test.ts" + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/strategies/abstract_search_strategy.ts" }, { - "plugin": "@kbn/es-query", - "path": "packages/kbn-es-query/src/kuery/functions/utils/get_full_field_name_node.test.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/deserialize.ts" }, { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/datasource.test.ts" }, { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/deserialize.test.ts" }, { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/deserialize.test.ts" }, { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/source_filters_table/components/table/table.tsx" }, { - "plugin": "unifiedSearch", - "path": "src/plugins/unified_search/public/autocomplete/providers/value_suggestion_provider.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" }, { - "plugin": "unifiedSearch", - "path": "src/plugins/unified_search/public/query_string_input/fetch_index_patterns.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" }, { - "plugin": "unifiedSearch", - "path": "src/plugins/unified_search/public/dataview_picker/change_dataview.tsx" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" }, { "plugin": "dataViews", - "path": "src/plugins/data_views/server/rest_api_routes/update_data_view.ts" + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" }, { - "plugin": "dataViews", - "path": "src/plugins/data_views/server/rest_api_routes/update_data_view.ts" - }, + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/lib/fetch_fields.ts" + } + ], + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getScriptedFields", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "getScriptedFields", + "description": [ + "\n" + ], + "signature": [ + "() => ", { - "plugin": "triggersActionsUi", - "path": "x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + "[]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ { - "plugin": "savedObjectsManagement", - "path": "src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" }, { - "plugin": "savedObjectsManagement", - "path": "src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.ts" }, { - "plugin": "controls", - "path": "src/plugins/controls/public/services/options_list/options_list_service.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" }, { - "plugin": "controls", - "path": "src/plugins/controls/public/services/options_list/options_list_service.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/server/register_index_pattern_usage_collection.ts" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/public/services/field_stats/load_field_stats.ts" + "plugin": "dataViewManagement", + "path": "src/plugins/data_view_management/public/components/edit_index_pattern/scripted_fields_table/scripted_fields_table.tsx" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/common/utils/field_existing_utils.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/public/hooks/use_existing_fields.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/public/hooks/use_existing_fields.ts" - }, + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_view.test.ts" + } + ], + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.isTSDBMode", + "type": "Function", + "tags": [], + "label": "isTSDBMode", + "description": [ + "\nreturns true if dataview contains TSDB fields" + ], + "signature": [ + "() => boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.isTimeBased", + "type": "Function", + "tags": [], + "label": "isTimeBased", + "description": [ + "\nDoes the data view have a timestamp field?" + ], + "signature": [ + "() => this is ", { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/data_views_service/loader.ts" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.TimeBasedDataView", + "text": "TimeBasedDataView" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.isTimeNanosBased", + "type": "Function", + "tags": [], + "label": "isTimeNanosBased", + "description": [ + "\nDoes the data view have a timestamp field and is it a date nanos field?" + ], + "signature": [ + "() => this is ", { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.TimeBasedDataView", + "text": "TimeBasedDataView" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getTimeField", + "type": "Function", + "tags": [], + "label": "getTimeField", + "description": [ + "\nGet timestamp field as DataViewField or return undefined" + ], + "signature": [ + "() => ", { - "plugin": "aiops", - "path": "x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getFieldByName", + "type": "Function", + "tags": [], + "label": "getFieldByName", + "description": [ + "\nGet field by name." + ], + "signature": [ + "(name: string) => ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/server/models/data_frame_analytics/index_patterns.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/server/models/job_service/new_job_caps/rollup.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.getFieldByName.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "field name" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getAggregationRestrictions", + "type": "Function", + "tags": [], + "label": "getAggregationRestrictions", + "description": [ + "\nGet aggregation restrictions. Rollup fields can only perform a subset of aggregations." + ], + "signature": [ + "() => Record | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getAsSavedObjectBody", + "type": "Function", + "tags": [], + "label": "getAsSavedObjectBody", + "description": [ + "\nReturns index pattern as saved object body for saving" + ], + "signature": [ + "() => ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/server/models/data_recognizer/data_recognizer.ts" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewAttributes", + "text": "DataViewAttributes" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getFormatterForField", + "type": "Function", + "tags": [], + "label": "getFormatterForField", + "description": [ + "\nProvide a field, get its formatter" + ], + "signature": [ + "(field: ", { - "plugin": "infra", - "path": "x-pack/plugins/infra/common/log_views/resolved_log_view.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + " | ", { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + ") => ", { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.ts" - }, + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormat", + "text": "FieldFormat" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/server/lib/get_fields.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.getFormatterForField.$1", + "type": "CompoundType", + "tags": [], + "label": "field", + "description": [ + "field to get formatter for" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + }, + " | ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.addRuntimeField", + "type": "Function", + "tags": [], + "label": "addRuntimeField", + "description": [ + "\nAdd a runtime field - Appended to existing mapped field or a new field is\ncreated as appropriate." + ], + "signature": [ + "(name: string, runtimeField: ", { - "plugin": "apm", - "path": "x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeField", + "text": "RuntimeField" }, + ") => ", { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/utils/observability_data_views/observability_data_views.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" }, + "[]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/report_definition_field.tsx" + "parentPluginId": "data", + "id": "def-common.DataView.addRuntimeField.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "Field name" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/use_filter_values.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.addRuntimeField.$2", + "type": "Object", + "tags": [], + "label": "runtimeField", + "description": [ + "Runtime field definition" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeField", + "text": "RuntimeField" + } + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.hasRuntimeField", + "type": "Function", + "tags": [], + "label": "hasRuntimeField", + "description": [ + "\nChecks if runtime field exists" + ], + "signature": [ + "(name: string) => boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/filter_value_btn.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataView.hasRuntimeField.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "field name" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getRuntimeField", + "type": "Function", + "tags": [], + "label": "getRuntimeField", + "description": [ + "\nReturns runtime field if exists" + ], + "signature": [ + "(name: string) => ", { - "plugin": "dataVisualizer", - "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/hooks/use_data_visualizer_grid_data.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeField", + "text": "RuntimeField" }, + " | null" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "dataVisualizer", - "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/index_data_visualizer_view/index_data_visualizer_view.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataView.getRuntimeField.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "Runtime field name" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getAllRuntimeFields", + "type": "Function", + "tags": [], + "label": "getAllRuntimeFields", + "description": [ + "\nGet all runtime field definitions.\nNOTE: this does not strip out runtime fields that match mapped field names" + ], + "signature": [ + "() => Record" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [ + "map of runtime field definitions by field name" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getFieldsByRuntimeFieldName", + "type": "Function", + "tags": [], + "label": "getFieldsByRuntimeFieldName", + "description": [ + "\nReturns data view fields backed by runtime fields." + ], + "signature": [ + "(name: string) => Record | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.getFieldsByRuntimeFieldName.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "runtime field name" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "map of DataViewFields (that are runtime fields) by field name" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.replaceAllRuntimeFields", + "type": "Function", + "tags": [], + "label": "replaceAllRuntimeFields", + "description": [ + "\nReplaces all existing runtime fields with new fields." + ], + "signature": [ + "(newFields: Record) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.replaceAllRuntimeFields.$1", + "type": "Object", + "tags": [], + "label": "newFields", + "description": [ + "Map of runtime field definitions by field name" + ], + "signature": [ + "Record" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.removeRuntimeField", + "type": "Function", + "tags": [], + "label": "removeRuntimeField", + "description": [ + "\nRemove a runtime field - removed from mapped field or removed unmapped\nfield as appropriate. Doesn't clear associated field attributes." + ], + "signature": [ + "(name: string) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/hooks/use_index_data.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.removeRuntimeField.$1", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "- Field name to remove" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getRuntimeMappings", + "type": "Function", + "tags": [], + "label": "getRuntimeMappings", + "description": [ + "\nReturn the \"runtime_mappings\" section of the ES search query." + ], + "signature": [ + "() => ", + "MappingRuntimeFields" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.getFormatterForFieldNoDefault", + "type": "Function", + "tags": [], + "label": "getFormatterForFieldNoDefault", + "description": [ + "\nGet formatter for a given field name. Return undefined if none exists." + ], + "signature": [ + "(fieldname: string) => ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.FieldFormat", + "text": "FieldFormat" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataView.getFormatterForFieldNoDefault.$1", + "type": "string", + "tags": [], + "label": "fieldname", + "description": [ + "name of field to get formatter for" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.setFieldAttrs", + "type": "Function", + "tags": [], + "label": "setFieldAttrs", + "description": [ + "\nSet field attribute" + ], + "signature": [ + "(fieldName: string, attrName: K, value: ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/components/configuration_step/configuration_step_form.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrSet", + "text": "FieldAttrSet" }, + "[K]) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_creation/page.tsx" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldAttrs.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "name of field to set attribute on" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/action_clone/clone_action_name.tsx" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldAttrs.$2", + "type": "Uncategorized", + "tags": [], + "label": "attrName", + "description": [ + "name of attribute to set" + ], + "signature": [ + "K" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/common/job_creator/job_creator.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.setFieldAttrs.$3", + "type": "Uncategorized", + "tags": [], + "label": "value", + "description": [ + "value of attribute" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrSet", + "text": "FieldAttrSet" + }, + "[K]" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCustomLabel", + "type": "Function", + "tags": [], + "label": "setFieldCustomLabel", + "description": [ + "\nSet field custom label" + ], + "signature": [ + "(fieldName: string, customLabel: string | null | undefined) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/common/results_loader/categorization_examples_loader.ts" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCustomLabel.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "name of field to set custom label on" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/preconfigured_job_redirect.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCustomLabel.$2", + "type": "CompoundType", + "tags": [], + "label": "customLabel", + "description": [ + "custom label value. If undefined, custom label is removed" + ], + "signature": [ + "string | null | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCount", + "type": "Function", + "tags": [], + "label": "setFieldCount", + "description": [ + "\nSet field count" + ], + "signature": [ + "(fieldName: string, count: number | null | undefined) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCount.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "name of field to set count on" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldCount.$2", + "type": "CompoundType", + "tags": [], + "label": "count", + "description": [ + "count value. If undefined, count is removed" + ], + "signature": [ + "number | null | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.setFieldFormat", + "type": "Function", + "tags": [], + "label": "setFieldFormat", + "description": [ + "\nSet field formatter" + ], + "signature": [ + "(fieldName: string, format: ", + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" }, + "<{}, ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/job_type/page.tsx" + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" }, + ">) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/estimate_bucket_span.ts" + "parentPluginId": "data", + "id": "def-common.DataView.setFieldFormat.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "name of field to set format on" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataView.setFieldFormat.$2", + "type": "Object", + "tags": [], + "label": "format", + "description": [ + "field format in serialized form" + ], + "signature": [ + { + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" + }, + "<{}, ", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataView.deleteFieldFormat", + "type": "Function", + "tags": [], + "label": "deleteFieldFormat", + "description": [ + "\nRemove field format from the field format map." + ], + "signature": [ + "(fieldName: string) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/new_job/wizard_steps.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataView.deleteFieldFormat.$1", + "type": "string", + "tags": [], + "label": "fieldName", + "description": [ + "field name associated with the format for removal" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_view.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField", + "type": "Class", + "tags": [], + "label": "DataViewField", + "description": [ + "\nData view field class" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + }, + " implements ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewFieldBase", + "text": "DataViewFieldBase" + } + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewField.spec", + "type": "CompoundType", + "tags": [], + "label": "spec", + "description": [], + "signature": [ { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_exploration/components/outlier_exploration/use_outlier_data.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewFieldBase", + "text": "DataViewFieldBase" }, + " & { count?: number | undefined; conflictDescriptions?: Record | undefined; format?: ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_exploration/components/exploration_results_table/use_exploration_results.ts" + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" }, + "<{}, ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" }, + "> | undefined; esTypes?: string[] | undefined; searchable: boolean; aggregatable: boolean; readFromDocValues?: boolean | undefined; indexed?: boolean | undefined; customLabel?: string | undefined; runtimeField?: ", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/embeddables/anomaly_charts/anomaly_charts_embeddable.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeFieldSpec", + "text": "RuntimeFieldSpec" }, + " | undefined; fixedInterval?: string[] | undefined; timeZone?: string[] | undefined; timeSeriesDimension?: boolean | undefined; timeSeriesMetric?: \"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined; shortDotsEnable?: boolean | undefined; isMapped?: boolean | undefined; parentName?: string | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.Unnamed", + "type": "Function", + "tags": [ + "constructor" + ], + "label": "Constructor", + "description": [ + "\nDataView constructor" + ], + "signature": [ + "any" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + "parentPluginId": "data", + "id": "def-common.DataViewField.Unnamed.$1", + "type": "CompoundType", + "tags": [], + "label": "spec", + "description": [ + "Configuration for the field" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" + } + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.count", + "type": "number", + "tags": [], + "label": "count", + "description": [ + "\nCount is used for field popularity in discover." + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.count", + "type": "number", + "tags": [], + "label": "count", + "description": [ + "\nSet count, which is used for field popularity in discover." + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.runtimeField", + "type": "CompoundType", + "tags": [], + "label": "runtimeField", + "description": [ + "\nReturns runtime field definition or undefined if field is not runtime field." + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeFieldSpec", + "text": "RuntimeFieldSpec" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.runtimeField", + "type": "CompoundType", + "tags": [], + "label": "runtimeField", + "description": [ + "\nSets runtime field definition or unsets if undefined is provided." + ], + "signature": [ { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeFieldSpec", + "text": "RuntimeFieldSpec" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.script", + "type": "string", + "tags": [], + "label": "script", + "description": [ + "\nScript field code" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.script", + "type": "string", + "tags": [], + "label": "script", + "description": [ + "\nSets scripted field painless code" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.lang", + "type": "string", + "tags": [], + "label": "lang", + "description": [ + "\nScript field language" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.lang", + "type": "string", + "tags": [], + "label": "lang", + "description": [ + "\nSets scripted field langauge." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.customLabel", + "type": "string", + "tags": [], + "label": "customLabel", + "description": [ + "\nReturns custom label if set, otherwise undefined." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.customLabel", + "type": "string", + "tags": [], + "label": "customLabel", + "description": [ + "\nSets custom label for field, or unsets if passed undefined." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.conflictDescriptions", + "type": "Object", + "tags": [], + "label": "conflictDescriptions", + "description": [ + "\nDescription of field type conflicts across different indices in the same index pattern." + ], + "signature": [ + "Record | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.conflictDescriptions", + "type": "Object", + "tags": [], + "label": "conflictDescriptions", + "description": [ + "\nSets conflict descriptions for field." + ], + "signature": [ + "Record | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.name", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "\nGet field name" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.displayName", + "type": "string", + "tags": [], + "label": "displayName", + "description": [ + "\nGets display name, calcualted based on name, custom label and shortDotsEnable." + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "\nGets field type" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.esTypes", + "type": "Array", + "tags": [], + "label": "esTypes", + "description": [ + "\nGets ES types as string array" + ], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.scripted", + "type": "boolean", + "tags": [], + "label": "scripted", + "description": [ + "\nReturns true if scripted field" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.searchable", + "type": "boolean", + "tags": [], + "label": "searchable", + "description": [ + "\nReturns true if field is searchable" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.aggregatable", + "type": "boolean", + "tags": [], + "label": "aggregatable", + "description": [ + "\nReturns true if field is aggregatable" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.timeSeriesDimension", + "type": "boolean", + "tags": [], + "label": "timeSeriesDimension", + "description": [ + "\nreturns true if field is a TSDB dimension field" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.timeSeriesMetric", + "type": "CompoundType", + "tags": [], + "label": "timeSeriesMetric", + "description": [ + "\nreturns type of TSDB metric or undefined" + ], + "signature": [ + "\"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.fixedInterval", + "type": "Array", + "tags": [], + "label": "fixedInterval", + "description": [ + "\nreturns list of alloeed fixed intervals" + ], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isRolledUpField", + "type": "CompoundType", + "tags": [], + "label": "isRolledUpField", + "description": [ + "\nreturns true if the field is of rolled up type" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.timeZone", + "type": "Array", + "tags": [], + "label": "timeZone", + "description": [ + "\nreturn list of allowed time zones" + ], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.readFromDocValues", + "type": "boolean", + "tags": [], + "label": "readFromDocValues", + "description": [ + "\nReturns true if field is available via doc values" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.subType", + "type": "CompoundType", + "tags": [], + "label": "subType", + "description": [ + "\nReturns field subtype, multi, nested, or undefined if neither" + ], + "signature": [ { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isMapped", + "type": "CompoundType", + "tags": [], + "label": "isMapped", + "description": [ + "\nIs the field part of the index mapping?" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isRuntimeField", + "type": "boolean", + "tags": [], + "label": "isRuntimeField", + "description": [ + "\nReturns true if runtime field defined on data view" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.sortable", + "type": "boolean", + "tags": [], + "label": "sortable", + "description": [ + "\nReturns true if field is sortable" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.filterable", + "type": "boolean", + "tags": [], + "label": "filterable", + "description": [ + "\nReturns true if field is filterable" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.visualizable", + "type": "boolean", + "tags": [], + "label": "visualizable", + "description": [ + "\nReturns true if field is visualizable" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isSubtypeNested", + "type": "Function", + "tags": [], + "label": "isSubtypeNested", + "description": [ + "\nReturns true if field is subtype nested" + ], + "signature": [ + "() => boolean" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isSubtypeMulti", + "type": "Function", + "tags": [], + "label": "isSubtypeMulti", + "description": [ + "\nReturns true if field is subtype multi" + ], + "signature": [ + "() => boolean" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.getSubtypeNested", + "type": "Function", + "tags": [], + "label": "getSubtypeNested", + "description": [ + "\nReturns subtype nested data if exists" + ], + "signature": [ + "() => ", { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeNested", + "text": "IFieldSubTypeNested" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.getSubtypeMulti", + "type": "Function", + "tags": [], + "label": "getSubtypeMulti", + "description": [ + "\nReturns subtype multi data if exists" + ], + "signature": [ + "() => ", { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeMulti", + "text": "IFieldSubTypeMulti" }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.deleteCount", + "type": "Function", + "tags": [], + "label": "deleteCount", + "description": [ + "\nDeletes count value. Popularity as used by discover" + ], + "signature": [ + "() => void" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.toJSON", + "type": "Function", + "tags": [], + "label": "toJSON", + "description": [ + "\nJSON version of field" + ], + "signature": [ + "() => { count: number; script: string | undefined; lang: string | undefined; conflictDescriptions: Record | undefined; name: string; type: string; esTypes: string[] | undefined; scripted: boolean; searchable: boolean; aggregatable: boolean; readFromDocValues: boolean; subType: ", { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined; customLabel: string | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.toSpec", + "type": "Function", + "tags": [], + "label": "toSpec", + "description": [ + "\nGet field in serialized form - fieldspec." + ], + "signature": [ + "(config?: ", { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.ToSpecConfig", + "text": "ToSpecConfig" }, + ") => ", { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" + } + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewField.toSpec.$1", + "type": "Object", + "tags": [], + "label": "config", + "description": [ + "provide a method to get a field formatter" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.ToSpecConfig", + "text": "ToSpecConfig" + } + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "field in serialized form - field spec" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewField.isRuntimeCompositeSubField", + "type": "Function", + "tags": [], + "label": "isRuntimeCompositeSubField", + "description": [ + "\nReturns true if composite runtime field" + ], + "signature": [ + "() => boolean" + ], + "path": "src/plugins/data_views/common/fields/data_view_field.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewSavedObjectConflictError", + "type": "Class", + "tags": [], + "label": "DataViewSavedObjectConflictError", + "description": [ + "\nError thrown when saved object has been changed when attempting to save." + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSavedObjectConflictError", + "text": "DataViewSavedObjectConflictError" + }, + " extends Error" + ], + "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewSavedObjectConflictError.Unnamed", + "type": "Function", + "tags": [], + "label": "Constructor", + "description": [ + "\nconstructor" + ], + "signature": [ + "any" + ], + "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewSavedObjectConflictError.Unnamed.$1", + "type": "string", + "tags": [], + "label": "savedObjectId", + "description": [ + "saved object id with conflict" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService", + "type": "Class", + "tags": [], + "label": "DataViewsService", + "description": [ + "\nData views service, providing CRUD operations for data views." + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getCanSave", + "type": "Function", + "tags": [], + "label": "getCanSave", + "description": [ + "\nCan the user save data views?" + ], + "signature": [ + "() => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.Unnamed", + "type": "Function", + "tags": [], + "label": "Constructor", + "description": [ + "\nDataViewsService constructor" + ], + "signature": [ + "any" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.Unnamed.$1", + "type": "Object", + "tags": [], + "label": "deps", + "description": [ + "Service dependencies" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewsServiceDeps", + "text": "DataViewsServiceDeps" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getIds", + "type": "Function", + "tags": [], + "label": "getIds", + "description": [ + "\nGets list of index pattern ids." + ], + "signature": [ + "(refresh?: boolean) => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getIds.$1", + "type": "boolean", + "tags": [], + "label": "refresh", + "description": [ + "Force refresh of index pattern list" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getTitles", + "type": "Function", + "tags": [], + "label": "getTitles", + "description": [ + "\nGets list of index pattern titles." + ], + "signature": [ + "(refresh?: boolean) => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getTitles.$1", + "type": "boolean", + "tags": [], + "label": "refresh", + "description": [ + "Force refresh of index pattern list" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.find", + "type": "Function", + "tags": [], + "label": "find", + "description": [ + "\nFind and load index patterns by title." + ], + "signature": [ + "(search: string, size?: number) => Promise<", { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/services/kibana/data_views.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + "[]>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/services/kibana/data_views.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.find.$1", + "type": "string", + "tags": [], + "label": "search", + "description": [ + "Search string" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/public/components/datasource/datasource_component.js" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.find.$2", + "type": "number", + "tags": [], + "label": "size", + "description": [ + "Number of data views to return" + ], + "signature": [ + "number" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "DataView[]" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getIdsWithTitle", + "type": "Function", + "tags": [], + "label": "getIdsWithTitle", + "description": [ + "\nGets list of index pattern ids with titles." + ], + "signature": [ + "(refresh?: boolean) => Promise<", { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/state_management/datasource.sagas.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewListItem", + "text": "DataViewListItem" }, + "[]>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/state_management/persistence.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getIdsWithTitle.$1", + "type": "boolean", + "tags": [], + "label": "refresh", + "description": [ + "Force refresh of index pattern list" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.clearCache", + "type": "Function", + "tags": [], + "label": "clearCache", + "description": [ + "\nClear index pattern saved objects cache." + ], + "signature": [ + "() => void" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.clearInstanceCache", + "type": "Function", + "tags": [], + "label": "clearInstanceCache", + "description": [ + "\nClear index pattern instance cache" + ], + "signature": [ + "(id?: string | undefined) => void" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/state_management/persistence.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.clearInstanceCache.$1", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getCache", + "type": "Function", + "tags": [], + "label": "getCache", + "description": [ + "\nGet cache, contains data view saved objects." + ], + "signature": [ + "() => Promise<", { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" }, + "<", { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSavedObjectAttrs", + "text": "DataViewSavedObjectAttrs" }, + ">[] | null | undefined>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getDefault", + "type": "Function", + "tags": [], + "label": "getDefault", + "description": [ + "\nGet default index pattern" + ], + "signature": [ + "(displayErrors?: boolean) => Promise<", { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + " | null>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getDefault.$1", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getDefaultId", + "type": "Function", + "tags": [], + "label": "getDefaultId", + "description": [ + "\nGet default index pattern id" + ], + "signature": [ + "() => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.setDefault", + "type": "Function", + "tags": [], + "label": "setDefault", + "description": [ + "\nOptionally set default index pattern, unless force = true" + ], + "signature": [ + "(id: string | null, force?: boolean) => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "timelines", - "path": "x-pack/plugins/timelines/server/search_strategy/index_fields/index.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.setDefault.$1", + "type": "CompoundType", + "tags": [], + "label": "id", + "description": [ + "data view id" + ], + "signature": [ + "string | null" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false }, { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/expressions/boundary_index_expression.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.setDefault.$2", + "type": "boolean", + "tags": [], + "label": "force", + "description": [ + "set default data view even if there's an existing default" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.hasUserDataView", + "type": "Function", + "tags": [], + "label": "hasUserDataView", + "description": [ + "\nChecks if current user has a user created index pattern ignoring fleet's server default index patterns." + ], + "signature": [ + "() => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getFieldsForWildcard", + "type": "Function", + "tags": [], + "label": "getFieldsForWildcard", + "description": [ + "\nGet field list by providing { pattern }." + ], + "signature": [ + "(options: ", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/expressions/entity_index_expression.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" }, + ") => Promise<", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[]>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getFieldsForWildcard.$1", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "options for getting field list" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "FieldSpec[]" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getFieldsForIndexPattern", + "type": "Function", + "tags": [], + "label": "getFieldsForIndexPattern", + "description": [ + "\nGet field list by providing an index patttern (or spec)." + ], + "signature": [ + "(indexPattern: ", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + " | ", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + ", options?: ", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" }, + " | undefined) => Promise<", { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/geo_containment/query_builder/index.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[]>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "stackAlerts", - "path": "x-pack/plugins/stack_alerts/public/rule_types/components/data_view_select_popover.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.getFieldsForIndexPattern.$1", + "type": "CompoundType", + "tags": [], + "label": "indexPattern", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + " | ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "synthetics", - "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getFieldsForIndexPattern.$2", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "options for getting field list" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" + }, + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [ + "FieldSpec[]" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.refreshFields", + "type": "Function", + "tags": [], + "label": "refreshFields", + "description": [ + "\nRefresh field list for a given index pattern." + ], + "signature": [ + "(dataView: ", { - "plugin": "synthetics", - "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ", displayErrors?: boolean) => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "transform", - "path": "x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/filter_agg/components/filter_term_form.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.refreshFields.$1", + "type": "Object", + "tags": [], + "label": "dataView", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "transform", - "path": "x-pack/plugins/transform/public/app/hooks/use_search_items/common.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.refreshFields.$2", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.fieldArrayToMap", + "type": "Function", + "tags": [], + "label": "fieldArrayToMap", + "description": [ + "\nConverts field array to map." + ], + "signature": [ + "(fields: ", { - "plugin": "transform", - "path": "x-pack/plugins/transform/public/app/services/es_index_service.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[], fieldAttrs?: ", { - "plugin": "transform", - "path": "x-pack/plugins/transform/server/routes/api/transforms.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrs", + "text": "FieldAttrs" }, + " | undefined) => ", { - "plugin": "upgradeAssistant", - "path": "x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewFieldMap", + "text": "DataViewFieldMap" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "ux", - "path": "x-pack/plugins/ux/public/components/app/rum_dashboard/local_uifilters/use_data_view.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.fieldArrayToMap.$1", + "type": "Array", + "tags": [], + "label": "fields", + "description": [ + ": FieldSpec[]" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" + }, + "[]" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/state_management/datasource.test.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.fieldArrayToMap.$2", + "type": "Object", + "tags": [], + "label": "fieldAttrs", + "description": [ + ": FieldAttrs" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrs", + "text": "FieldAttrs" + }, + " | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [ + "Record" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.savedObjectToSpec", + "type": "Function", + "tags": [], + "label": "savedObjectToSpec", + "description": [ + "\nConverts data view saved object to data view spec." + ], + "signature": [ + "(savedObject: ", { - "plugin": "infra", - "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" }, + "<", { - "plugin": "infra", - "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewAttributes", + "text": "DataViewAttributes" }, + ">) => ", { - "plugin": "infra", - "path": "x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/classes/tooltips/es_tooltip_property.test.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.savedObjectToSpec.$1", + "type": "Object", + "tags": [], + "label": "savedObject", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewAttributes", + "text": "DataViewAttributes" + }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "DataViewSpec" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.get", + "type": "Function", + "tags": [], + "label": "get", + "description": [ + "\nGet an index pattern by id, cache optimized." + ], + "signature": [ + "(id: string, displayErrors?: boolean, refreshFields?: boolean) => Promise<", { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/services/new_job_capabilities/remove_nested_field_children.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.get.$1", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_kpi.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.get.$2", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_with_reference_lines.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.get.$3", + "type": "boolean", + "tags": [], + "label": "refreshFields", + "description": [ + "- If set true, will fetch fields from the index pattern" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.create", + "type": "Function", + "tags": [], + "label": "create", + "description": [ + "\nCreate data view instance." + ], + "signature": [ + "(spec: ", { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/test_formula_metric_attribute.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + ", skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.create.$1", + "type": "Object", + "tags": [], + "label": "spec", + "description": [ + "data view spec" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/mobile_test_attribute.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.create.$2", + "type": "boolean", + "tags": [], + "label": "skipFetchFields", + "description": [ + "if true, will not fetch fields" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "observability", - "path": "x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_cwv.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.create.$3", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "DataView" + ] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.createAndSave", + "type": "Function", + "tags": [], + "label": "createAndSave", + "description": [ + "\nCreate a new data view and save it right away." + ], + "signature": [ + "(spec: ", { - "plugin": "transform", - "path": "x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/common.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + ", override?: boolean, skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", { - "plugin": "controls", - "path": "src/plugins/controls/public/services/data_views/data_views.story.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.createAndSave.$1", + "type": "Object", + "tags": [], + "label": "spec", + "description": [ + "data view spec" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.createAndSave.$2", + "type": "boolean", + "tags": [], + "label": "override", + "description": [ + "Overwrite if existing index pattern exists." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/field_editor/components/scripting_help/test_script.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.createAndSave.$3", + "type": "boolean", + "tags": [], + "label": "skipFetchFields", + "description": [ + "Whether to skip field refresh step." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/field_editor/field_editor.tsx" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.createAndSave.$4", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.createSavedObject", + "type": "Function", + "tags": [], + "label": "createSavedObject", + "description": [ + "\nSave a new data view." + ], + "signature": [ + "(dataView: ", { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/create_edit_field/create_edit_field.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ", override?: boolean, displayErrors?: boolean) => Promise<", { - "plugin": "inputControlVis", - "path": "src/plugins/input_control_vis/public/control/list_control_factory.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ">" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "inputControlVis", - "path": "src/plugins/input_control_vis/public/control/range_control_factory.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.createSavedObject.$1", + "type": "Object", + "tags": [], + "label": "dataView", + "description": [ + "data view instance" + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/server/routes/field_stats.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.createSavedObject.$2", + "type": "boolean", + "tags": [], + "label": "override", + "description": [ + "Overwrite if existing index pattern exists" + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "unifiedFieldList", - "path": "src/plugins/unified_field_list/server/routes/field_stats.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.createSavedObject.$3", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.updateSavedObject", + "type": "Function", + "tags": [], + "label": "updateSavedObject", + "description": [ + "\nSave existing data view. Will attempt to merge differences if there are conflicts." + ], + "signature": [ + "(indexPattern: ", { - "plugin": "visDefaultEditor", - "path": "src/plugins/vis_default_editor/public/components/controls/field.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ", saveAttempts?: number, ignoreErrors?: boolean, displayErrors?: boolean) => Promise" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visDefaultEditor", - "path": "src/plugins/vis_default_editor/public/components/agg_select.tsx" + "parentPluginId": "data", + "id": "def-common.DataViewsService.updateSavedObject.$1", + "type": "Object", + "tags": [], + "label": "indexPattern", + "description": [], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + } + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "inputControlVis", - "path": "src/plugins/input_control_vis/public/test_utils/get_index_pattern_mock.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.updateSavedObject.$2", + "type": "number", + "tags": [], + "label": "saveAttempts", + "description": [], + "signature": [ + "number" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "presentationUtil", - "path": "src/plugins/presentation_util/public/services/data_views/data_views.story.ts" + "parentPluginId": "data", + "id": "def-common.DataViewsService.updateSavedObject.$3", + "type": "boolean", + "tags": [], + "label": "ignoreErrors", + "description": [], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true }, { - "plugin": "visTypeTimelion", - "path": "src/plugins/vis_types/timelion/public/helpers/arg_value_suggestions.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.updateSavedObject.$4", + "type": "boolean", + "tags": [], + "label": "displayErrors", + "description": [ + "- If set false, API consumer is responsible for displaying and handling errors." + ], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.delete", + "type": "Function", + "tags": [], + "label": "delete", + "description": [ + "\nDeletes an index pattern from .kibana index." + ], + "signature": [ + "(indexPatternId: string) => Promise<{}>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visTypeTimelion", - "path": "src/plugins/vis_types/timelion/public/helpers/arg_value_suggestions.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.delete.$1", + "type": "string", + "tags": [], + "label": "indexPatternId", + "description": [ + ": Id of kibana Index Pattern to delete" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsService.getDefaultDataView", + "type": "Function", + "tags": [], + "label": "getDefaultDataView", + "description": [ + "\nReturns the default data view as an object.\nIf no default is found, or it is missing\nanother data view is selected as default and returned.\nIf no possible data view found to become a default returns null.\n" + ], + "signature": [ + "(refreshFields?: boolean | undefined) => Promise<", { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + " | null>" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts" - }, + "parentPluginId": "data", + "id": "def-common.DataViewsService.getDefaultDataView.$1", + "type": "CompoundType", + "tags": [], + "label": "refreshFields", + "description": [ + "- if true, will refresh the fields of the default data view" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + } + ], + "returnComment": [ + "default data view" + ] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DuplicateDataViewError", + "type": "Class", + "tags": [], + "label": "DuplicateDataViewError", + "description": [ + "\nError thrown when attempting to create duplicate index pattern based on title." + ], + "signature": [ + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DuplicateDataViewError", + "text": "DuplicateDataViewError" + }, + " extends Error" + ], + "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DuplicateDataViewError.Unnamed", + "type": "Function", + "tags": [], + "label": "Constructor", + "description": [ + "\nconstructor" + ], + "signature": [ + "any" + ], + "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.ts" - }, + "parentPluginId": "data", + "id": "def-common.DuplicateDataViewError.Unnamed.$1", + "type": "string", + "tags": [], + "label": "message", + "description": [ + "- Error message" + ], + "signature": [ + "string" + ], + "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType", + "type": "Class", + "tags": [], + "label": "KbnFieldType", + "description": [], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType.name", + "type": "string", + "tags": [], + "label": "name", + "description": [], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType.sortable", + "type": "boolean", + "tags": [], + "label": "sortable", + "description": [], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType.filterable", + "type": "boolean", + "tags": [], + "label": "filterable", + "description": [], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType.esTypes", + "type": "Object", + "tags": [], + "label": "esTypes", + "description": [], + "signature": [ + "readonly ", { - "plugin": "visTypeVega", - "path": "src/plugins/vis_types/vega/public/data_model/search_api.ts" + "pluginId": "@kbn/field-types", + "scope": "common", + "docId": "kibKbnFieldTypesPluginApi", + "section": "def-common.ES_FIELD_TYPES", + "text": "ES_FIELD_TYPES" }, + "[]" + ], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldType.Unnamed", + "type": "Function", + "tags": [], + "label": "Constructor", + "description": [], + "signature": [ + "any" + ], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.test.ts" - }, + "parentPluginId": "data", + "id": "def-common.KbnFieldType.Unnamed.$1", + "type": "Object", + "tags": [], + "label": "options", + "description": [], + "signature": [ + "Partial<", + { + "pluginId": "@kbn/field-types", + "scope": "common", + "docId": "kibKbnFieldTypesPluginApi", + "section": "def-common.KbnFieldTypeOptions", + "text": "KbnFieldTypeOptions" + }, + ">" + ], + "path": "packages/kbn-field-types/src/kbn_field_type.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + } + ], + "initialIsOpen": false + } + ], + "functions": [ + { + "parentPluginId": "data", + "id": "def-common.cellHasFormulas", + "type": "Function", + "tags": [], + "label": "cellHasFormulas", + "description": [], + "signature": [ + "(val: string) => boolean" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.cellHasFormulas.$1", + "type": "string", + "tags": [], + "label": "val", + "description": [], + "signature": [ + "string" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.createEscapeValue", + "type": "Function", + "tags": [], + "label": "createEscapeValue", + "description": [ + "\nCreate a function that will escape CSV values like \"=\", \"@\" and \"+\" with a\n\"'\". This will also place CSV values in \"\" if contain non-alphanumeric chars.\n\nFor example:\n\nGiven: =1+1\nReturns: \"'=1+1\"\n\nSee OWASP: https://www.owasp.org/index.php/CSV_Injection." + ], + "signature": [ + "(quoteValues: boolean, escapeFormulas: boolean) => (val: RawValue) => string" + ], + "path": "src/plugins/data/common/exports/escape_value.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.createEscapeValue.$1", + "type": "boolean", + "tags": [], + "label": "quoteValues", + "description": [], + "signature": [ + "boolean" + ], + "path": "src/plugins/data/common/exports/escape_value.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.createEscapeValue.$2", + "type": "boolean", + "tags": [], + "label": "escapeFormulas", + "description": [], + "signature": [ + "boolean" + ], + "path": "src/plugins/data/common/exports/escape_value.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.datatableToCSV", + "type": "Function", + "tags": [], + "label": "datatableToCSV", + "description": [], + "signature": [ + "({ columns, rows }: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + }, + ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.datatableToCSV.$1", + "type": "Object", + "tags": [], + "label": "{ columns, rows }", + "description": [], + "signature": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" - }, + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + } + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.datatableToCSV.$2", + "type": "Object", + "tags": [], + "label": "{ csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }", + "description": [], + "signature": [ + "CSVOptions" + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.fieldList", + "type": "Function", + "tags": [], + "label": "fieldList", + "description": [], + "signature": [ + "(specs?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" + }, + "[], shortDotsEnable?: boolean) => ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.IIndexPatternFieldList", + "text": "IIndexPatternFieldList" + } + ], + "path": "src/plugins/data_views/common/fields/field_list.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.fieldList.$1", + "type": "Array", + "tags": [], + "label": "specs", + "description": [], + "signature": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[]" + ], + "path": "src/plugins/data_views/common/fields/field_list.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.fieldList.$2", + "type": "boolean", + "tags": [], + "label": "shortDotsEnable", + "description": [], + "signature": [ + "boolean" + ], + "path": "src/plugins/data_views/common/fields/field_list.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.getEsQueryConfig", + "type": "Function", + "tags": [], + "label": "getEsQueryConfig", + "description": [], + "signature": [ + "(config: KibanaConfig) => ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.EsQueryConfig", + "text": "EsQueryConfig" + } + ], + "path": "src/plugins/data/common/es_query/get_es_query_config.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.getEsQueryConfig.$1", + "type": "Object", + "tags": [], + "label": "config", + "description": [], + "signature": [ + "KibanaConfig" + ], + "path": "src/plugins/data/common/es_query/get_es_query_config.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.getFieldSubtypeMulti", + "type": "Function", + "tags": [], + "label": "getFieldSubtypeMulti", + "description": [], + "signature": [ + "(field: HasSubtype) => ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeMulti", + "text": "IFieldSubTypeMulti" + }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-common.getFieldSubtypeMulti.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.getFieldSubtypeNested", + "type": "Function", + "tags": [], + "label": "getFieldSubtypeNested", + "description": [], + "signature": [ + "(field: HasSubtype) => ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubTypeNested", + "text": "IFieldSubTypeNested" + }, + " | undefined" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-common.getFieldSubtypeNested.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/lib/cached_index_pattern_fetcher.test.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.getIndexPatternLoadMeta", + "type": "Function", + "tags": [], + "label": "getIndexPatternLoadMeta", + "description": [], + "signature": [ + "() => Omit<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.IndexPatternLoadExpressionFunctionDefinition", + "text": "IndexPatternLoadExpressionFunctionDefinition" + }, + ", \"fn\">" + ], + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "children": [], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.isFilterable", + "type": "Function", + "tags": [], + "label": "isFilterable", + "description": [], + "signature": [ + "(field: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + }, + ") => boolean" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.isFilterable.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/lib/cached_index_pattern_fetcher.test.ts" - }, + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewField", + "text": "DataViewField" + } + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.isMultiField", + "type": "Function", + "tags": [], + "label": "isMultiField", + "description": [], + "signature": [ + "(field: HasSubtype) => boolean" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-common.isMultiField.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_views.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.isNestedField", + "type": "Function", + "tags": [], + "label": "isNestedField", + "description": [], + "signature": [ + "(field: HasSubtype) => boolean" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "data", + "id": "def-common.isNestedField.$1", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "{ subType?: ", { - "plugin": "discover", - "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.IFieldSubType", + "text": "IFieldSubType" }, + " | undefined; }" + ], + "path": "src/plugins/data_views/common/fields/utils.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.tableHasFormulas", + "type": "Function", + "tags": [], + "label": "tableHasFormulas", + "description": [], + "signature": [ + "(columns: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" + }, + "[], rows: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableRow", + "text": "DatatableRow" + }, + "[]) => boolean" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.tableHasFormulas.$1", + "type": "Array", + "tags": [], + "label": "columns", + "description": [], + "signature": [ { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableColumn", + "text": "DatatableColumn" }, + "[]" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "data", + "id": "def-common.tableHasFormulas.$2", + "type": "Array", + "tags": [], + "label": "rows", + "description": [], + "signature": [ { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.DatatableRow", + "text": "DatatableRow" }, - { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" - } - ] + "[]" + ], + "path": "src/plugins/data/common/exports/formula_checks.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + } + ], + "interfaces": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes", + "type": "Interface", + "tags": [], + "label": "DataViewAttributes", + "description": [ + "\nInterface for the data view saved object" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.fields", + "type": "string", + "tags": [], + "label": "fields", + "description": [ + "\nFields as a serialized array of field specs" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.title", + "type": "string", + "tags": [], + "label": "title", + "description": [ + "\nData view title" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "\nData view type, default or rollup" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.typeMeta", + "type": "string", + "tags": [], + "label": "typeMeta", + "description": [ + "\nType metadata information, serialized. Only used by rollup data views." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.timeFieldName", + "type": "string", + "tags": [], + "label": "timeFieldName", + "description": [ + "\nTime field name" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.sourceFilters", + "type": "string", + "tags": [], + "label": "sourceFilters", + "description": [ + "\nSerialized array of filters. Used by discover to hide fields." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.fieldFormatMap", + "type": "string", + "tags": [], + "label": "fieldFormatMap", + "description": [ + "\nSerialized map of field formats by field name" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.fieldAttrs", + "type": "string", + "tags": [], + "label": "fieldAttrs", + "description": [ + "\nSerialized map of field attributes, currently field count and name" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.fieldFormatMap", - "type": "Object", + "id": "def-common.DataViewAttributes.runtimeFieldMap", + "type": "string", "tags": [], - "label": "fieldFormatMap", + "label": "runtimeFieldMap", "description": [ - "\nMap of field formats by field name" + "\nSerialized map of runtime field definitions, by field name" ], "signature": [ - "{ [x: string]: ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.SerializedFieldFormat", - "text": "SerializedFieldFormat" - }, - "<{}, ", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" - }, - ">; }" + "string | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.typeMeta", + "id": "def-common.DataViewAttributes.allowNoIndex", + "type": "CompoundType", + "tags": [], + "label": "allowNoIndex", + "description": [ + "\nPrevents errors when index pattern exists before indices" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewAttributes.name", + "type": "string", + "tags": [], + "label": "name", + "description": [ + "\nName of the data view. Human readable name used to differentiate data view." + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem", + "type": "Interface", + "tags": [], + "label": "DataViewListItem", + "description": [ + "\nResult from data view search - summary data." + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "\nSaved object id (or generated id if in-memory only)" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem.namespaces", + "type": "Array", + "tags": [], + "label": "namespaces", + "description": [ + "\nNamespace ids" + ], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem.title", + "type": "string", + "tags": [], + "label": "title", + "description": [ + "\nData view title" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "\nData view type" + ], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewListItem.typeMeta", "type": "Object", "tags": [], "label": "typeMeta", "description": [ - "\nOnly used by rollup indices, used by rollup specific endpoint to load field list." + "\nData view type meta" ], "signature": [ { @@ -21462,176 +27904,283 @@ }, " | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/data_views/data_views.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.fields", + "id": "def-common.DataViewListItem.name", + "type": "string", + "tags": [], + "label": "name", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions", + "type": "Interface", + "tags": [], + "label": "GetFieldsOptions", + "description": [], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.pattern", + "type": "string", + "tags": [], + "label": "pattern", + "description": [], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.lookBack", "type": "CompoundType", "tags": [], - "label": "fields", - "description": [ - "\nField list, in extended array format" + "label": "lookBack", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.metaFields", + "type": "Array", + "tags": [], + "label": "metaFields", + "description": [], + "signature": [ + "string[] | undefined" ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.rollupIndex", + "type": "string", + "tags": [], + "label": "rollupIndex", + "description": [], "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.IIndexPatternFieldList", - "text": "IIndexPatternFieldList" - }, - " & { toSpec: () => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewFieldMap", - "text": "DataViewFieldMap" - }, - "; }" + "string | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.timeFieldName", - "type": "string", + "id": "def-common.GetFieldsOptions.allowNoIndex", + "type": "CompoundType", "tags": [], - "label": "timeFieldName", - "description": [ - "\nTimestamp field name" - ], + "label": "allowNoIndex", + "description": [], "signature": [ - "string | undefined" + "boolean | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.type", - "type": "string", + "id": "def-common.GetFieldsOptions.indexFilter", + "type": "Object", "tags": [], - "label": "type", - "description": [ - "\nType is used to identify rollup index patterns." - ], + "label": "indexFilter", + "description": [], "signature": [ - "string | undefined" + "QueryDslQueryContainer", + " | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.flattenHit", - "type": "Function", - "tags": [ - "deprecated" + "id": "def-common.GetFieldsOptions.includeUnmapped", + "type": "CompoundType", + "tags": [], + "label": "includeUnmapped", + "description": [], + "signature": [ + "boolean | undefined" ], - "label": "flattenHit", + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetFieldsOptions.fields", + "type": "Array", + "tags": [], + "label": "fields", "description": [], "signature": [ - "(hit: Record, deep?: boolean | undefined) => Record" + "string[] | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" - }, + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.IDataViewsApiClient", + "type": "Interface", + "tags": [], + "label": "IDataViewsApiClient", + "description": [], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "data", + "id": "def-common.IDataViewsApiClient.getFieldsForWildcard", + "type": "Function", + "tags": [], + "label": "getFieldsForWildcard", + "description": [], + "signature": [ + "(options: ", { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx" + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx" - } + ") => Promise<", + "FieldsForWildcardResponse", + ">" ], - "returnComment": [], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.flattenHit.$1", + "id": "def-common.IDataViewsApiClient.getFieldsForWildcard.$1", "type": "Object", "tags": [], - "label": "hit", - "description": [], - "signature": [ - "{ [x: string]: unknown[]; }" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.flattenHit.$2", - "type": "CompoundType", - "tags": [], - "label": "deep", + "label": "options", "description": [], "signature": [ - "boolean | undefined" + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" + } ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, - "trackAdoption": false + "trackAdoption": false, + "isRequired": true } - ] + ], + "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DataView.metaFields", - "type": "Array", + "id": "def-common.IDataViewsApiClient.hasUserDataView", + "type": "Function", "tags": [], - "label": "metaFields", - "description": [ - "\nList of meta fields by name" - ], + "label": "hasUserDataView", + "description": [], "signature": [ - "string[]" + "() => Promise" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, - "trackAdoption": false - }, + "trackAdoption": false, + "children": [], + "returnComment": [] + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.IndexPatternExpressionType", + "type": "Interface", + "tags": [], + "label": "IndexPatternExpressionType", + "description": [ + "\nIndex pattern expression interface" + ], + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.version", + "id": "def-common.IndexPatternExpressionType.type", "type": "string", "tags": [], - "label": "version", + "label": "type", "description": [ - "\nSavedObject version" + "\nExpression type" ], "signature": [ - "string | undefined" + "\"index_pattern\"" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.sourceFilters", - "type": "Array", + "id": "def-common.IndexPatternExpressionType.value", + "type": "Object", "tags": [], - "label": "sourceFilters", + "label": "value", "description": [ - "\nArray of filters - hides fields in discover" + "\nValue - DataViewSpec" ], "signature": [ + "{ id?: string | undefined; version?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; sourceFilters?: ", { "pluginId": "dataViews", "scope": "common", @@ -21639,97 +28188,173 @@ "section": "def-common.SourceFilter", "text": "SourceFilter" }, - "[] | undefined" + "[] | undefined; fields?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewFieldMap", + "text": "DataViewFieldMap" + }, + " | undefined; typeMeta?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.TypeMeta", + "text": "TypeMeta" + }, + " | undefined; type?: string | undefined; fieldFormats?: Record> | undefined; runtimeFieldMap?: Record | undefined; fieldAttrs?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrs", + "text": "FieldAttrs" + }, + " | undefined; allowNoIndex?: boolean | undefined; namespaces?: string[] | undefined; name?: string | undefined; }" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.KbnFieldTypeOptions", + "type": "Interface", + "tags": [], + "label": "KbnFieldTypeOptions", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.namespaces", - "type": "Array", + "id": "def-common.KbnFieldTypeOptions.sortable", + "type": "boolean", "tags": [], - "label": "namespaces", - "description": [ - "\nArray of namespace ids" - ], - "signature": [ - "string[]" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "label": "sortable", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.allowNoIndex", + "id": "def-common.KbnFieldTypeOptions.filterable", "type": "boolean", "tags": [], - "label": "allowNoIndex", - "description": [ - "\nPrevents errors when index pattern exists before indices" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "label": "filterable", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.name", + "id": "def-common.KbnFieldTypeOptions.name", "type": "string", "tags": [], "label": "name", - "description": [ - "\nName of the data view. Human readable name used to differentiate data view." - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.matchedIndices", + "id": "def-common.KbnFieldTypeOptions.esTypes", "type": "Array", "tags": [], - "label": "matchedIndices", + "label": "esTypes", "description": [], "signature": [ - "string[]" + { + "pluginId": "@kbn/field-types", + "scope": "common", + "docId": "kibKbnFieldTypesPluginApi", + "section": "def-common.ES_FIELD_TYPES", + "text": "ES_FIELD_TYPES" + }, + "[]" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "packages/kbn-field-types/src/types.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.UiSettingsCommon", + "type": "Interface", + "tags": [], + "label": "UiSettingsCommon", + "description": [ + "\nInterface for UiSettings common interface {@link UiSettingsClient}" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.Unnamed", + "id": "def-common.UiSettingsCommon.get", "type": "Function", "tags": [], - "label": "Constructor", + "label": "get", "description": [ - "\nconstructor" + "\nGet a setting value" ], "signature": [ - "any" + "(key: string) => Promise" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.Unnamed.$1", - "type": "Object", + "id": "def-common.UiSettingsCommon.get.$1", + "type": "string", "tags": [], - "label": "config", + "label": "key", "description": [ - "- config data and dependencies" + "name of value" ], "signature": [ - "DataViewDeps" + "string" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -21739,17 +28364,17 @@ }, { "parentPluginId": "data", - "id": "def-common.DataView.getName", + "id": "def-common.UiSettingsCommon.getAll", "type": "Function", "tags": [], - "label": "getName", + "label": "getAll", "description": [ - "\nGet name of Data View" + "\nGet all settings values" ], "signature": [ - "() => string" + "() => Promise>" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "children": [], @@ -21757,6202 +28382,2479 @@ }, { "parentPluginId": "data", - "id": "def-common.DataView.getIndexPattern", - "type": "Function", - "tags": [], - "label": "getIndexPattern", - "description": [ - "\nGet index pattern" - ], - "signature": [ - "() => string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [ - "index pattern string" - ] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setIndexPattern", + "id": "def-common.UiSettingsCommon.set", "type": "Function", "tags": [], - "label": "setIndexPattern", + "label": "set", "description": [ - "\nSet index pattern" + "\nSet a setting value" ], "signature": [ - "(indexPattern: string) => void" + "(key: string, value: T) => Promise" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.setIndexPattern.$1", + "id": "def-common.UiSettingsCommon.set.$1", "type": "string", "tags": [], - "label": "indexPattern", - "description": [], + "label": "key", + "description": [ + "name of value" + ], "signature": [ "string" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "isRequired": true - } - ], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.getOriginalSavedObjectBody", - "type": "Function", - "tags": [], - "label": "getOriginalSavedObjectBody", - "description": [ - "\nGet last saved saved object fields" - ], - "signature": [ - "() => { fieldAttrs?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; fields?: string | undefined; sourceFilters?: string | undefined; fieldFormatMap?: string | undefined; typeMeta?: string | undefined; type?: string | undefined; }" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.resetOriginalSavedObjectBody", - "type": "Function", - "tags": [], - "label": "resetOriginalSavedObjectBody", - "description": [ - "\nReset last saved saved object fields. Used after saving." - ], - "signature": [ - "() => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.getFieldAttrs", - "type": "Function", - "tags": [], - "label": "getFieldAttrs", - "description": [ - "\nReturns field attributes map" - ], - "signature": [ - "() => { [x: string]: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrSet", - "text": "FieldAttrSet" }, - "; }" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.getComputedFields", - "type": "Function", - "tags": [], - "label": "getComputedFields", - "description": [ - "\nReturns scripted fields" - ], - "signature": [ - "() => { storedFields: string[]; scriptFields: Record; docvalueFields: { field: string; format: string; }[]; runtimeFields: ", - "MappingRuntimeFields", - "; }" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.isPersisted", - "type": "Function", - "tags": [], - "label": "isPersisted", - "description": [], - "signature": [ - "() => boolean" + { + "parentPluginId": "data", + "id": "def-common.UiSettingsCommon.set.$2", + "type": "Uncategorized", + "tags": [], + "label": "value", + "description": [ + "value to set" + ], + "signature": [ + "T" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], "returnComment": [] }, { "parentPluginId": "data", - "id": "def-common.DataView.toSpec", + "id": "def-common.UiSettingsCommon.remove", "type": "Function", "tags": [], - "label": "toSpec", + "label": "remove", "description": [ - "\nCreates static representation of the data view." + "\nRemove a setting value" ], "signature": [ - "(includeFields?: boolean) => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - } + "(key: string) => Promise" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.toSpec.$1", - "type": "boolean", + "id": "def-common.UiSettingsCommon.remove.$1", + "type": "string", "tags": [], - "label": "includeFields", + "label": "key", "description": [ - "Whether or not to include the `fields` list as part of this spec. If not included, the list\nwill be fetched from Elasticsearch when instantiating a new Data View with this spec." + "name of value" ], "signature": [ - "boolean" + "string" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data_views/common/types.ts", "deprecated": false, "trackAdoption": false, "isRequired": true } ], "returnComment": [] + } + ], + "initialIsOpen": false + } + ], + "enums": [ + { + "parentPluginId": "data", + "id": "def-common.DataViewType", + "type": "Enum", + "tags": [], + "label": "DataViewType", + "description": [ + "\nData View type. Default or rollup" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.ES_FIELD_TYPES", + "type": "Enum", + "tags": [], + "label": "ES_FIELD_TYPES", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.KBN_FIELD_TYPES", + "type": "Enum", + "tags": [], + "label": "KBN_FIELD_TYPES", + "description": [], + "path": "packages/kbn-field-types/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "misc": [ + { + "parentPluginId": "data", + "id": "def-common.AggregationRestrictions", + "type": "Type", + "tags": [], + "label": "AggregationRestrictions", + "description": [], + "signature": [ + "{ [x: string]: { agg?: string | undefined; interval?: number | undefined; fixed_interval?: string | undefined; calendar_interval?: string | undefined; delay?: string | undefined; time_zone?: string | undefined; }; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.CSV_FORMULA_CHARS", + "type": "Array", + "tags": [], + "label": "CSV_FORMULA_CHARS", + "description": [], + "signature": [ + "string[]" + ], + "path": "src/plugins/data/common/exports/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.CSV_MIME_TYPE", + "type": "string", + "tags": [], + "label": "CSV_MIME_TYPE", + "description": [], + "signature": [ + "\"text/plain;charset=utf-8\"" + ], + "path": "src/plugins/data/common/exports/export_csv.tsx", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DATA_VIEW_SAVED_OBJECT_TYPE", + "type": "string", + "tags": [], + "label": "DATA_VIEW_SAVED_OBJECT_TYPE", + "description": [ + "\nData view saved object type." + ], + "signature": [ + "\"index-pattern\"" + ], + "path": "src/plugins/data_views/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewFieldMap", + "type": "Type", + "tags": [], + "label": "DataViewFieldMap", + "description": [], + "signature": [ + "{ [x: string]: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewsContract", + "type": "Type", + "tags": [], + "label": "DataViewsContract", + "description": [ + "\nData views service interface" + ], + "signature": [ + "{ get: (id: string, displayErrors?: boolean, refreshFields?: boolean) => Promise<", { - "parentPluginId": "data", - "id": "def-common.DataView.getSourceFiltering", - "type": "Function", - "tags": [], - "label": "getSourceFiltering", - "description": [ - "\nGet the source filtering configuration for that index." - ], - "signature": [ - "() => { excludes: string[]; }" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + ">; delete: (indexPatternId: string) => Promise<{}>; create: (spec: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" + }, + ", skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + ">; find: (search: string, size?: number) => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + "[]>; getCanSave: () => Promise; getIds: (refresh?: boolean) => Promise; getTitles: (refresh?: boolean) => Promise; getIdsWithTitle: (refresh?: boolean) => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewListItem", + "text": "DataViewListItem" + }, + "[]>; clearCache: () => void; clearInstanceCache: (id?: string | undefined) => void; getCache: () => Promise<", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSavedObjectAttrs", + "text": "DataViewSavedObjectAttrs" + }, + ">[] | null | undefined>; getDefault: (displayErrors?: boolean) => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + " | null>; getDefaultId: () => Promise; setDefault: (id: string | null, force?: boolean) => Promise; hasUserDataView: () => Promise; getFieldsForWildcard: (options: ", { - "parentPluginId": "data", - "id": "def-common.DataView.removeScriptedField", - "type": "Function", - "tags": [ - "deprecated" - ], - "label": "removeScriptedField", - "description": [ - "\nRemoves scripted field from field list." - ], - "signature": [ - "(fieldName: string) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/scripted_fields_table/scripted_fields_table.tsx" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/field_editor/field_editor.tsx" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - } - ], - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.removeScriptedField.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "name of scripted field to remove" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" }, + ") => Promise<", { - "parentPluginId": "data", - "id": "def-common.DataView.getNonScriptedFields", - "type": "Function", - "tags": [ - "deprecated" - ], - "label": "getNonScriptedFields", - "description": [ - "\n" - ], - "signature": [ - "() => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - "[]" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/server/lib/search_strategies/strategies/abstract_search_strategy.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/deserialize.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/state_management/datasource.test.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/deserialize.test.ts" - }, - { - "plugin": "graph", - "path": "x-pack/plugins/graph/public/services/persistence/deserialize.test.ts" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/source_filters_table/components/table/table.tsx" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/edit_index_pattern.tsx" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - }, - { - "plugin": "visTypeTimeseries", - "path": "src/plugins/vis_types/timeseries/public/application/lib/fetch_fields.ts" - } - ], - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[]>; getFieldsForIndexPattern: (indexPattern: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getScriptedFields", - "type": "Function", - "tags": [ - "deprecated" - ], - "label": "getScriptedFields", - "description": [ - "\n" - ], - "signature": [ - "() => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - "[]" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_views.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/server/register_index_pattern_usage_collection.ts" - }, - { - "plugin": "dataViewManagement", - "path": "src/plugins/data_view_management/public/components/edit_index_pattern/scripted_fields_table/scripted_fields_table.tsx" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - }, - { - "plugin": "dataViews", - "path": "src/plugins/data_views/common/data_views/data_view.test.ts" - } - ], - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + " | ", { - "parentPluginId": "data", - "id": "def-common.DataView.isTSDBMode", - "type": "Function", - "tags": [], - "label": "isTSDBMode", - "description": [ - "\nreturns true if dataview contains TSDB fields" - ], - "signature": [ - "() => boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + ", options?: ", { - "parentPluginId": "data", - "id": "def-common.DataView.isTimeBased", - "type": "Function", - "tags": [], - "label": "isTimeBased", - "description": [ - "\nDoes the data view have a timestamp field?" - ], - "signature": [ - "() => this is ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.TimeBasedDataView", - "text": "TimeBasedDataView" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.GetFieldsOptions", + "text": "GetFieldsOptions" }, + " | undefined) => Promise<", { - "parentPluginId": "data", - "id": "def-common.DataView.isTimeNanosBased", - "type": "Function", - "tags": [], - "label": "isTimeNanosBased", - "description": [ - "\nDoes the data view have a timestamp field and is it a date nanos field?" - ], - "signature": [ - "() => this is ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.TimeBasedDataView", - "text": "TimeBasedDataView" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[]>; refreshFields: (dataView: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getTimeField", - "type": "Function", - "tags": [], - "label": "getTimeField", - "description": [ - "\nGet timestamp field as DataViewField or return undefined" - ], - "signature": [ - "() => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ", displayErrors?: boolean) => Promise; fieldArrayToMap: (fields: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getFieldByName", - "type": "Function", - "tags": [], - "label": "getFieldByName", - "description": [ - "\nGet field by name." - ], - "signature": [ - "(name: string) => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.getFieldByName.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "field name" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldSpec", + "text": "FieldSpec" }, + "[], fieldAttrs?: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getAggregationRestrictions", - "type": "Function", - "tags": [], - "label": "getAggregationRestrictions", - "description": [ - "\nGet aggregation restrictions. Rollup fields can only perform a subset of aggregations." - ], - "signature": [ - "() => Record | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrs", + "text": "FieldAttrs" }, + " | undefined) => ", { - "parentPluginId": "data", - "id": "def-common.DataView.getAsSavedObjectBody", - "type": "Function", - "tags": [], - "label": "getAsSavedObjectBody", - "description": [ - "\nReturns index pattern as saved object body for saving" - ], - "signature": [ - "() => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewAttributes", - "text": "DataViewAttributes" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewFieldMap", + "text": "DataViewFieldMap" }, + "; savedObjectToSpec: (savedObject: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getFormatterForField", - "type": "Function", - "tags": [], - "label": "getFormatterForField", - "description": [ - "\nProvide a field, get its formatter" - ], - "signature": [ - "(field: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - " | ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - ") => ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormat", - "text": "FieldFormat" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.getFormatterForField.$1", - "type": "CompoundType", - "tags": [], - "label": "field", - "description": [ - "field to get formatter for" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - " | ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewAttributes", + "text": "DataViewAttributes" + }, + ">) => ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + "; createAndSave: (spec: ", { - "parentPluginId": "data", - "id": "def-common.DataView.addRuntimeField", - "type": "Function", - "tags": [], - "label": "addRuntimeField", - "description": [ - "\nAdd a runtime field - Appended to existing mapped field or a new field is\ncreated as appropriate." - ], - "signature": [ - "(name: string, runtimeField: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeField", - "text": "RuntimeField" - }, - ") => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - }, - "[]" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.addRuntimeField.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "Field name" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.addRuntimeField.$2", - "type": "Object", - "tags": [], - "label": "runtimeField", - "description": [ - "Runtime field definition" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeField", - "text": "RuntimeField" - } - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewSpec", + "text": "DataViewSpec" }, + ", override?: boolean, skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", { - "parentPluginId": "data", - "id": "def-common.DataView.hasRuntimeField", - "type": "Function", - "tags": [], - "label": "hasRuntimeField", - "description": [ - "\nChecks if runtime field exists" - ], - "signature": [ - "(name: string) => boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.hasRuntimeField.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "field name" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ">; createSavedObject: (dataView: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getRuntimeField", - "type": "Function", - "tags": [], - "label": "getRuntimeField", - "description": [ - "\nReturns runtime field if exists" - ], - "signature": [ - "(name: string) => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeField", - "text": "RuntimeField" - }, - " | null" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.getRuntimeField.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "Runtime field name" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" }, + ", override?: boolean, displayErrors?: boolean) => Promise<", { - "parentPluginId": "data", - "id": "def-common.DataView.getAllRuntimeFields", - "type": "Function", - "tags": [], - "label": "getAllRuntimeFields", - "description": [ - "\nGet all runtime field definitions.\nNOTE: this does not strip out runtime fields that match mapped field names" - ], - "signature": [ - "() => Record" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [ - "map of runtime field definitions by field name" - ] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + ">; updateSavedObject: (indexPattern: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + ", saveAttempts?: number, ignoreErrors?: boolean, displayErrors?: boolean) => Promise; getDefaultDataView: (refreshFields?: boolean | undefined) => Promise<", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataView", + "text": "DataView" + }, + " | null>; }" + ], + "path": "src/plugins/data_views/common/data_views/data_views.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DataViewSpec", + "type": "Type", + "tags": [], + "label": "DataViewSpec", + "description": [ + "\nStatic data view format\nSerialized data object, representing data view attributes and state" + ], + "signature": [ + "{ id?: string | undefined; version?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; sourceFilters?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.SourceFilter", + "text": "SourceFilter" + }, + "[] | undefined; fields?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.DataViewFieldMap", + "text": "DataViewFieldMap" }, + " | undefined; typeMeta?: ", { - "parentPluginId": "data", - "id": "def-common.DataView.getFieldsByRuntimeFieldName", - "type": "Function", - "tags": [], - "label": "getFieldsByRuntimeFieldName", - "description": [ - "\nReturns data view fields backed by runtime fields." - ], - "signature": [ - "(name: string) => Record | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.getFieldsByRuntimeFieldName.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "runtime field name" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "map of DataViewFields (that are runtime fields) by field name" - ] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.TypeMeta", + "text": "TypeMeta" }, + " | undefined; type?: string | undefined; fieldFormats?: Record) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.replaceAllRuntimeFields.$1", - "type": "Object", - "tags": [], - "label": "newFields", - "description": [ - "Map of runtime field definitions by field name" - ], - "signature": [ - "Record" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" }, + "<{}, ", { - "parentPluginId": "data", - "id": "def-common.DataView.removeRuntimeField", - "type": "Function", - "tags": [], - "label": "removeRuntimeField", - "description": [ - "\nRemove a runtime field - removed from mapped field or removed unmapped\nfield as appropriate. Doesn't clear associated field attributes." - ], - "signature": [ - "(name: string) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.removeRuntimeField.$1", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "- Field name to remove" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" }, + ">> | undefined; runtimeFieldMap?: Record ", - "MappingRuntimeFields" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeFieldSpec", + "text": "RuntimeFieldSpec" + }, + "> | undefined; fieldAttrs?: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrs", + "text": "FieldAttrs" + }, + " | undefined; allowNoIndex?: boolean | undefined; namespaces?: string[] | undefined; name?: string | undefined; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.DEFAULT_QUERY_LANGUAGE", + "type": "string", + "tags": [], + "label": "DEFAULT_QUERY_LANGUAGE", + "description": [], + "signature": [ + "\"kuery\"" + ], + "path": "src/plugins/data/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.FieldAttrs", + "type": "Type", + "tags": [], + "label": "FieldAttrs", + "description": [ + "\nSet of field attributes" + ], + "signature": [ + "{ [key: string]: ", + { + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.FieldAttrSet", + "text": "FieldAttrSet" }, + "; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.FieldAttrSet", + "type": "Type", + "tags": [], + "label": "FieldAttrSet", + "description": [ + "\nField attributes that are stored on the data view" + ], + "signature": [ + "{ customLabel?: string | undefined; count?: number | undefined; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.FieldSpec", + "type": "Type", + "tags": [], + "label": "FieldSpec", + "description": [ + "\nSerialized version of DataViewField" + ], + "signature": [ { - "parentPluginId": "data", - "id": "def-common.DataView.getFormatterForFieldNoDefault", - "type": "Function", - "tags": [], - "label": "getFormatterForFieldNoDefault", - "description": [ - "\nGet formatter for a given field name. Return undefined if none exists." - ], - "signature": [ - "(fieldname: string) => ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.FieldFormat", - "text": "FieldFormat" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.getFormatterForFieldNoDefault.$1", - "type": "string", - "tags": [], - "label": "fieldname", - "description": [ - "name of field to get formatter for" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewFieldBase", + "text": "DataViewFieldBase" }, + " & { count?: number | undefined; conflictDescriptions?: Record | undefined; format?: ", { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldAttrs", - "type": "Function", - "tags": [], - "label": "setFieldAttrs", - "description": [ - "\nSet field attribute" - ], - "signature": [ - "(fieldName: string, attrName: K, value: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrSet", - "text": "FieldAttrSet" - }, - "[K]) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldAttrs.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "name of field to set attribute on" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldAttrs.$2", - "type": "Uncategorized", - "tags": [], - "label": "attrName", - "description": [ - "name of attribute to set" - ], - "signature": [ - "K" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldAttrs.$3", - "type": "Uncategorized", - "tags": [], - "label": "value", - "description": [ - "value of attribute" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrSet", - "text": "FieldAttrSet" - }, - "[K]" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "pluginId": "fieldFormats", + "scope": "common", + "docId": "kibFieldFormatsPluginApi", + "section": "def-common.SerializedFieldFormat", + "text": "SerializedFieldFormat" }, + "<{}, ", { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCustomLabel", - "type": "Function", - "tags": [], - "label": "setFieldCustomLabel", - "description": [ - "\nSet field custom label" - ], - "signature": [ - "(fieldName: string, customLabel: string | null | undefined) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCustomLabel.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "name of field to set custom label on" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCustomLabel.$2", - "type": "CompoundType", - "tags": [], - "label": "customLabel", - "description": [ - "custom label value. If undefined, custom label is removed" - ], - "signature": [ - "string | null | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [] + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" }, + "> | undefined; esTypes?: string[] | undefined; searchable: boolean; aggregatable: boolean; readFromDocValues?: boolean | undefined; indexed?: boolean | undefined; customLabel?: string | undefined; runtimeField?: ", { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCount", - "type": "Function", - "tags": [], - "label": "setFieldCount", - "description": [ - "\nSet field count" - ], - "signature": [ - "(fieldName: string, count: number | null | undefined) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCount.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "name of field to set count on" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldCount.$2", - "type": "CompoundType", - "tags": [], - "label": "count", - "description": [ - "count value. If undefined, count is removed" - ], - "signature": [ - "number | null | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [] + "pluginId": "dataViews", + "scope": "common", + "docId": "kibDataViewsPluginApi", + "section": "def-common.RuntimeFieldSpec", + "text": "RuntimeFieldSpec" }, + " | undefined; fixedInterval?: string[] | undefined; timeZone?: string[] | undefined; timeSeriesDimension?: boolean | undefined; timeSeriesMetric?: \"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined; shortDotsEnable?: boolean | undefined; isMapped?: boolean | undefined; parentName?: string | undefined; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.FieldSpecConflictDescriptions", + "type": "Type", + "tags": [], + "label": "FieldSpecConflictDescriptions", + "description": [], + "signature": [ + "{ [x: string]: string[]; }" + ], + "path": "src/plugins/data_views/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.GetConfigFn", + "type": "Type", + "tags": [], + "label": "GetConfigFn", + "description": [ + "\nIf a service is being shared on both the client and the server, and\nthe client code requires synchronous access to uiSettings, both client\nand server should wrap the core uiSettings services in a function\nmatching this signature.\n\nThis matches the signature of the public `core.uiSettings.get`, and\nshould only be used in scenarios where async access to uiSettings is\nnot possible." + ], + "signature": [ + "(key: string, defaultOverride?: T | undefined) => T" + ], + "path": "src/plugins/data/common/types.ts", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ { "parentPluginId": "data", - "id": "def-common.DataView.setFieldFormat", - "type": "Function", + "id": "def-common.GetConfigFn.$1", + "type": "string", "tags": [], - "label": "setFieldFormat", - "description": [ - "\nSet field formatter" - ], - "signature": [ - "(fieldName: string, format: ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.SerializedFieldFormat", - "text": "SerializedFieldFormat" - }, - "<{}, ", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" - }, - ">) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "label": "key", + "description": [], + "path": "src/plugins/data/common/types.ts", "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldFormat.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "name of field to set format on" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataView.setFieldFormat.$2", - "type": "Object", - "tags": [], - "label": "format", - "description": [ - "field format in serialized form" - ], - "signature": [ - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.SerializedFieldFormat", - "text": "SerializedFieldFormat" - }, - "<{}, ", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "trackAdoption": false }, { "parentPluginId": "data", - "id": "def-common.DataView.deleteFieldFormat", - "type": "Function", + "id": "def-common.GetConfigFn.$2", + "type": "Uncategorized", "tags": [], - "label": "deleteFieldFormat", - "description": [ - "\nRemove field format from the field format map." - ], + "label": "defaultOverride", + "description": [], "signature": [ - "(fieldName: string) => void" + "T | undefined" ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", + "path": "src/plugins/data/common/types.ts", "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataView.deleteFieldFormat.$1", - "type": "string", - "tags": [], - "label": "fieldName", - "description": [ - "field name associated with the format for removal" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_view.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "trackAdoption": false } ], "initialIsOpen": false }, { "parentPluginId": "data", - "id": "def-common.DataViewField", - "type": "Class", + "id": "def-common.IndexPatternLoadExpressionFunctionDefinition", + "type": "Type", "tags": [], - "label": "DataViewField", + "label": "IndexPatternLoadExpressionFunctionDefinition", + "description": [], + "signature": [ + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.ExpressionFunctionDefinition", + "text": "ExpressionFunctionDefinition" + }, + "<\"indexPatternLoad\", null, Arguments, Output, ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.ExecutionContext", + "text": "ExecutionContext" + }, + "<", + { + "pluginId": "inspector", + "scope": "common", + "docId": "kibInspectorPluginApi", + "section": "def-common.Adapters", + "text": "Adapters" + }, + ", ", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + ">>" + ], + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.KIBANA_USER_QUERY_LANGUAGE_KEY", + "type": "string", + "tags": [], + "label": "KIBANA_USER_QUERY_LANGUAGE_KEY", + "description": [], + "signature": [ + "\"kibana.userQueryLanguage\"" + ], + "path": "src/plugins/data/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.META_FIELDS", + "type": "string", + "tags": [], + "label": "META_FIELDS", "description": [ - "\nData view field class" + "\nUiSettings key for metaFields list." + ], + "signature": [ + "\"metaFields\"" + ], + "path": "src/plugins/data_views/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.Query", + "type": "Type", + "tags": [], + "label": "Query", + "description": [], + "signature": [ + "{ query: string | { [key: string]: any; }; language: string; }" + ], + "path": "packages/kbn-es-query/src/filters/build_filters/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "data", + "id": "def-common.SavedObject", + "type": "Type", + "tags": [ + "deprecated" ], + "label": "SavedObject", + "description": [], "signature": [ { - "pluginId": "dataViews", + "pluginId": "@kbn/core-saved-objects-common", "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" }, - " implements ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.DataViewFieldBase", - "text": "DataViewFieldBase" - } + "" ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "data", - "id": "def-common.DataViewField.spec", - "type": "CompoundType", - "tags": [], - "label": "spec", - "description": [], - "signature": [ - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.DataViewFieldBase", - "text": "DataViewFieldBase" - }, - " & { count?: number | undefined; conflictDescriptions?: Record | undefined; format?: ", - { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.SerializedFieldFormat", - "text": "SerializedFieldFormat" - }, - "<{}, ", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" - }, - "> | undefined; esTypes?: string[] | undefined; searchable: boolean; aggregatable: boolean; readFromDocValues?: boolean | undefined; indexed?: boolean | undefined; customLabel?: string | undefined; runtimeField?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeFieldSpec", - "text": "RuntimeFieldSpec" - }, - " | undefined; fixedInterval?: string[] | undefined; timeZone?: string[] | undefined; timeSeriesDimension?: boolean | undefined; timeSeriesMetric?: \"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined; shortDotsEnable?: boolean | undefined; isMapped?: boolean | undefined; parentName?: string | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.Unnamed", - "type": "Function", - "tags": [ - "constructor" - ], - "label": "Constructor", - "description": [ - "\nDataView constructor" - ], - "signature": [ - "any" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewField.Unnamed.$1", - "type": "CompoundType", - "tags": [], - "label": "spec", - "description": [ - "Configuration for the field" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - } - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.count", - "type": "number", - "tags": [], - "label": "count", - "description": [ - "\nCount is used for field popularity in discover." - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.count", - "type": "number", - "tags": [], - "label": "count", - "description": [ - "\nSet count, which is used for field popularity in discover." - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.runtimeField", - "type": "CompoundType", - "tags": [], - "label": "runtimeField", - "description": [ - "\nReturns runtime field definition or undefined if field is not runtime field." - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeFieldSpec", - "text": "RuntimeFieldSpec" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.runtimeField", - "type": "CompoundType", - "tags": [], - "label": "runtimeField", - "description": [ - "\nSets runtime field definition or unsets if undefined is provided." - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeFieldSpec", - "text": "RuntimeFieldSpec" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.script", - "type": "string", - "tags": [], - "label": "script", - "description": [ - "\nScript field code" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.script", - "type": "string", - "tags": [], - "label": "script", - "description": [ - "\nSets scripted field painless code" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.lang", - "type": "string", - "tags": [], - "label": "lang", - "description": [ - "\nScript field language" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.lang", - "type": "string", - "tags": [], - "label": "lang", - "description": [ - "\nSets scripted field langauge." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.customLabel", - "type": "string", - "tags": [], - "label": "customLabel", - "description": [ - "\nReturns custom label if set, otherwise undefined." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.customLabel", - "type": "string", - "tags": [], - "label": "customLabel", - "description": [ - "\nSets custom label for field, or unsets if passed undefined." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.conflictDescriptions", - "type": "Object", - "tags": [], - "label": "conflictDescriptions", - "description": [ - "\nDescription of field type conflicts across different indices in the same index pattern." - ], - "signature": [ - "Record | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.conflictDescriptions", - "type": "Object", - "tags": [], - "label": "conflictDescriptions", - "description": [ - "\nSets conflict descriptions for field." - ], - "signature": [ - "Record | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.name", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "\nGet field name" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.displayName", - "type": "string", - "tags": [], - "label": "displayName", - "description": [ - "\nGets display name, calcualted based on name, custom label and shortDotsEnable." - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "\nGets field type" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.esTypes", - "type": "Array", - "tags": [], - "label": "esTypes", - "description": [ - "\nGets ES types as string array" - ], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.scripted", - "type": "boolean", - "tags": [], - "label": "scripted", - "description": [ - "\nReturns true if scripted field" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.searchable", - "type": "boolean", - "tags": [], - "label": "searchable", - "description": [ - "\nReturns true if field is searchable" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.aggregatable", - "type": "boolean", - "tags": [], - "label": "aggregatable", - "description": [ - "\nReturns true if field is aggregatable" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.timeSeriesDimension", - "type": "boolean", - "tags": [], - "label": "timeSeriesDimension", - "description": [ - "\nreturns true if field is a TSDB dimension field" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.timeSeriesMetric", - "type": "CompoundType", - "tags": [], - "label": "timeSeriesMetric", - "description": [ - "\nreturns type of TSDB metric or undefined" - ], - "signature": [ - "\"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.fixedInterval", - "type": "Array", - "tags": [], - "label": "fixedInterval", - "description": [ - "\nreturns list of alloeed fixed intervals" - ], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isRolledUpField", - "type": "CompoundType", - "tags": [], - "label": "isRolledUpField", - "description": [ - "\nreturns true if the field is of rolled up type" - ], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.timeZone", - "type": "Array", - "tags": [], - "label": "timeZone", - "description": [ - "\nreturn list of allowed time zones" - ], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.readFromDocValues", - "type": "boolean", - "tags": [], - "label": "readFromDocValues", - "description": [ - "\nReturns true if field is available via doc values" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.subType", - "type": "CompoundType", - "tags": [], - "label": "subType", - "description": [ - "\nReturns field subtype, multi, nested, or undefined if neither" - ], - "signature": [ - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isMapped", - "type": "CompoundType", - "tags": [], - "label": "isMapped", - "description": [ - "\nIs the field part of the index mapping?" - ], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isRuntimeField", - "type": "boolean", - "tags": [], - "label": "isRuntimeField", - "description": [ - "\nReturns true if runtime field defined on data view" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.sortable", - "type": "boolean", - "tags": [], - "label": "sortable", - "description": [ - "\nReturns true if field is sortable" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.filterable", - "type": "boolean", - "tags": [], - "label": "filterable", - "description": [ - "\nReturns true if field is filterable" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.visualizable", - "type": "boolean", - "tags": [], - "label": "visualizable", - "description": [ - "\nReturns true if field is visualizable" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isSubtypeNested", - "type": "Function", - "tags": [], - "label": "isSubtypeNested", - "description": [ - "\nReturns true if field is subtype nested" - ], - "signature": [ - "() => boolean" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isSubtypeMulti", - "type": "Function", - "tags": [], - "label": "isSubtypeMulti", - "description": [ - "\nReturns true if field is subtype multi" - ], - "signature": [ - "() => boolean" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.getSubtypeNested", - "type": "Function", - "tags": [], - "label": "getSubtypeNested", - "description": [ - "\nReturns subtype nested data if exists" - ], - "signature": [ - "() => ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeNested", - "text": "IFieldSubTypeNested" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.getSubtypeMulti", - "type": "Function", - "tags": [], - "label": "getSubtypeMulti", - "description": [ - "\nReturns subtype multi data if exists" - ], - "signature": [ - "() => ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeMulti", - "text": "IFieldSubTypeMulti" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/index.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.deleteCount", - "type": "Function", - "tags": [], - "label": "deleteCount", - "description": [ - "\nDeletes count value. Popularity as used by discover" - ], - "signature": [ - "() => void" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.toJSON", - "type": "Function", - "tags": [], - "label": "toJSON", - "description": [ - "\nJSON version of field" - ], - "signature": [ - "() => { count: number; script: string | undefined; lang: string | undefined; conflictDescriptions: Record | undefined; name: string; type: string; esTypes: string[] | undefined; scripted: boolean; searchable: boolean; aggregatable: boolean; readFromDocValues: boolean; subType: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; customLabel: string | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.toSpec", - "type": "Function", - "tags": [], - "label": "toSpec", - "description": [ - "\nGet field in serialized form - fieldspec." - ], - "signature": [ - "(config?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.ToSpecConfig", - "text": "ToSpecConfig" - }, - ") => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - } - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewField.toSpec.$1", - "type": "Object", - "tags": [], - "label": "config", - "description": [ - "provide a method to get a field formatter" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.ToSpecConfig", - "text": "ToSpecConfig" - } - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "field in serialized form - field spec" - ] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewField.isRuntimeCompositeSubField", - "type": "Function", - "tags": [], - "label": "isRuntimeCompositeSubField", - "description": [ - "\nReturns true if composite runtime field" - ], - "signature": [ - "() => boolean" - ], - "path": "src/plugins/data_views/common/fields/data_view_field.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewSavedObjectConflictError", - "type": "Class", - "tags": [], - "label": "DataViewSavedObjectConflictError", - "description": [ - "\nError thrown when saved object has been changed when attempting to save." - ], - "signature": [ + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSavedObjectConflictError", - "text": "DataViewSavedObjectConflictError" + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" }, - " extends Error" - ], - "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.DataViewSavedObjectConflictError.Unnamed", - "type": "Function", - "tags": [], - "label": "Constructor", - "description": [ - "\nconstructor" - ], - "signature": [ - "any" - ], - "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewSavedObjectConflictError.Unnamed.$1", - "type": "string", - "tags": [], - "label": "savedObjectId", - "description": [ - "saved object id with conflict" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/errors/data_view_saved_object_conflict.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService", - "type": "Class", - "tags": [], - "label": "DataViewsService", - "description": [ - "\nData views service, providing CRUD operations for data views." - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getCanSave", - "type": "Function", - "tags": [], - "label": "getCanSave", - "description": [ - "\nCan the user save data views?" - ], - "signature": [ - "() => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.Unnamed", - "type": "Function", - "tags": [], - "label": "Constructor", - "description": [ - "\nDataViewsService constructor" - ], - "signature": [ - "any" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.Unnamed.$1", - "type": "Object", - "tags": [], - "label": "deps", - "description": [ - "Service dependencies" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewsServiceDeps", - "text": "DataViewsServiceDeps" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getIds", - "type": "Function", - "tags": [], - "label": "getIds", - "description": [ - "\nGets list of index pattern ids." - ], - "signature": [ - "(refresh?: boolean) => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getIds.$1", - "type": "boolean", - "tags": [], - "label": "refresh", - "description": [ - "Force refresh of index pattern list" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getTitles", - "type": "Function", - "tags": [], - "label": "getTitles", - "description": [ - "\nGets list of index pattern titles." - ], - "signature": [ - "(refresh?: boolean) => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getTitles.$1", - "type": "boolean", - "tags": [], - "label": "refresh", - "description": [ - "Force refresh of index pattern list" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.find", - "type": "Function", - "tags": [], - "label": "find", - "description": [ - "\nFind and load index patterns by title." - ], - "signature": [ - "(search: string, size?: number) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - "[]>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.find.$1", - "type": "string", - "tags": [], - "label": "search", - "description": [ - "Search string" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.find.$2", - "type": "number", - "tags": [], - "label": "size", - "description": [ - "Number of data views to return" - ], - "signature": [ - "number" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "DataView[]" - ] + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getIdsWithTitle", - "type": "Function", - "tags": [], - "label": "getIdsWithTitle", - "description": [ - "\nGets list of index pattern ids with titles." - ], - "signature": [ - "(refresh?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewListItem", - "text": "DataViewListItem" - }, - "[]>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getIdsWithTitle.$1", - "type": "boolean", - "tags": [], - "label": "refresh", - "description": [ - "Force refresh of index pattern list" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.clearCache", - "type": "Function", - "tags": [], - "label": "clearCache", - "description": [ - "\nClear index pattern saved objects cache." - ], - "signature": [ - "() => void" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.clearInstanceCache", - "type": "Function", - "tags": [], - "label": "clearInstanceCache", - "description": [ - "\nClear index pattern instance cache" - ], - "signature": [ - "(id?: string | undefined) => void" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.clearInstanceCache.$1", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [] + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getCache", - "type": "Function", - "tags": [], - "label": "getCache", - "description": [ - "\nGet cache, contains data view saved objects." - ], - "signature": [ - "() => Promise<", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSavedObjectAttrs", - "text": "DataViewSavedObjectAttrs" - }, - ">[] | null | undefined>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getDefault", - "type": "Function", - "tags": [], - "label": "getDefault", - "description": [ - "\nGet default index pattern" - ], - "signature": [ - "(displayErrors?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - " | null>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getDefault.$1", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getDefaultId", - "type": "Function", - "tags": [], - "label": "getDefaultId", - "description": [ - "\nGet default index pattern id" - ], - "signature": [ - "() => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.setDefault", - "type": "Function", - "tags": [], - "label": "setDefault", - "description": [ - "\nOptionally set default index pattern, unless force = true" - ], - "signature": [ - "(id: string | null, force?: boolean) => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.setDefault.$1", - "type": "CompoundType", - "tags": [], - "label": "id", - "description": [ - "data view id" - ], - "signature": [ - "string | null" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.setDefault.$2", - "type": "boolean", - "tags": [], - "label": "force", - "description": [ - "set default data view even if there's an existing default" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.hasUserDataView", - "type": "Function", - "tags": [], - "label": "hasUserDataView", - "description": [ - "\nChecks if current user has a user created index pattern ignoring fleet's server default index patterns." - ], - "signature": [ - "() => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getFieldsForWildcard", - "type": "Function", - "tags": [], - "label": "getFieldsForWildcard", - "description": [ - "\nGet field list by providing { pattern }." - ], - "signature": [ - "(options: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - }, - ") => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - "[]>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getFieldsForWildcard.$1", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "options for getting field list" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "FieldSpec[]" - ] + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getFieldsForIndexPattern", - "type": "Function", - "tags": [], - "label": "getFieldsForIndexPattern", - "description": [ - "\nGet field list by providing an index patttern (or spec)." - ], - "signature": [ - "(indexPattern: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - " | ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - }, - ", options?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - }, - " | undefined) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - "[]>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getFieldsForIndexPattern.$1", - "type": "CompoundType", - "tags": [], - "label": "indexPattern", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - " | ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getFieldsForIndexPattern.$2", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "options for getting field list" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [ - "FieldSpec[]" - ] + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.refreshFields", - "type": "Function", - "tags": [], - "label": "refreshFields", - "description": [ - "\nRefresh field list for a given index pattern." - ], - "signature": [ - "(dataView: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ", displayErrors?: boolean) => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.refreshFields.$1", - "type": "Object", - "tags": [], - "label": "dataView", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.refreshFields.$2", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.fieldArrayToMap", - "type": "Function", - "tags": [], - "label": "fieldArrayToMap", - "description": [ - "\nConverts field array to map." - ], - "signature": [ - "(fields: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - "[], fieldAttrs?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrs", - "text": "FieldAttrs" - }, - " | undefined) => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewFieldMap", - "text": "DataViewFieldMap" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.fieldArrayToMap.$1", - "type": "Array", - "tags": [], - "label": "fields", - "description": [ - ": FieldSpec[]" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - "[]" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.fieldArrayToMap.$2", - "type": "Object", - "tags": [], - "label": "fieldAttrs", - "description": [ - ": FieldAttrs" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrs", - "text": "FieldAttrs" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [ - "Record" - ] + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.savedObjectToSpec", - "type": "Function", - "tags": [], - "label": "savedObjectToSpec", - "description": [ - "\nConverts data view saved object to data view spec." - ], - "signature": [ - "(savedObject: ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewAttributes", - "text": "DataViewAttributes" - }, - ">) => ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.savedObjectToSpec.$1", - "type": "Object", - "tags": [], - "label": "savedObject", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewAttributes", - "text": "DataViewAttributes" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "DataViewSpec" - ] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.get", - "type": "Function", - "tags": [], - "label": "get", - "description": [ - "\nGet an index pattern by id, cache optimized." - ], - "signature": [ - "(id: string, displayErrors?: boolean, refreshFields?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.get.$1", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.get.$2", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.get.$3", - "type": "boolean", - "tags": [], - "label": "refreshFields", - "description": [ - "- If set true, will fetch fields from the index pattern" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.create", - "type": "Function", - "tags": [], - "label": "create", - "description": [ - "\nCreate data view instance." - ], - "signature": [ - "(spec: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - }, - ", skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.create.$1", - "type": "Object", - "tags": [], - "label": "spec", - "description": [ - "data view spec" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.create.$2", - "type": "boolean", - "tags": [], - "label": "skipFetchFields", - "description": [ - "if true, will not fetch fields" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.create.$3", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "DataView" - ] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createAndSave", - "type": "Function", - "tags": [], - "label": "createAndSave", - "description": [ - "\nCreate a new data view and save it right away." - ], - "signature": [ - "(spec: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - }, - ", override?: boolean, skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createAndSave.$1", - "type": "Object", - "tags": [], - "label": "spec", - "description": [ - "data view spec" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createAndSave.$2", - "type": "boolean", - "tags": [], - "label": "override", - "description": [ - "Overwrite if existing index pattern exists." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createAndSave.$3", - "type": "boolean", - "tags": [], - "label": "skipFetchFields", - "description": [ - "Whether to skip field refresh step." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createAndSave.$4", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createSavedObject", - "type": "Function", - "tags": [], - "label": "createSavedObject", - "description": [ - "\nSave a new data view." - ], - "signature": [ - "(dataView: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ", override?: boolean, displayErrors?: boolean) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ">" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createSavedObject.$1", - "type": "Object", - "tags": [], - "label": "dataView", - "description": [ - "data view instance" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createSavedObject.$2", - "type": "boolean", - "tags": [], - "label": "override", - "description": [ - "Overwrite if existing index pattern exists" - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.createSavedObject.$3", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.updateSavedObject", - "type": "Function", - "tags": [], - "label": "updateSavedObject", - "description": [ - "\nSave existing data view. Will attempt to merge differences if there are conflicts." - ], - "signature": [ - "(indexPattern: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - ", saveAttempts?: number, ignoreErrors?: boolean, displayErrors?: boolean) => Promise" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.updateSavedObject.$1", - "type": "Object", - "tags": [], - "label": "indexPattern", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - } - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.updateSavedObject.$2", - "type": "number", - "tags": [], - "label": "saveAttempts", - "description": [], - "signature": [ - "number" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.updateSavedObject.$3", - "type": "boolean", - "tags": [], - "label": "ignoreErrors", - "description": [], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.updateSavedObject.$4", - "type": "boolean", - "tags": [], - "label": "displayErrors", - "description": [ - "- If set false, API consumer is responsible for displaying and handling errors." - ], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.delete", - "type": "Function", - "tags": [], - "label": "delete", - "description": [ - "\nDeletes an index pattern from .kibana index." - ], - "signature": [ - "(indexPatternId: string) => Promise<{}>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.delete.$1", - "type": "string", - "tags": [], - "label": "indexPatternId", - "description": [ - ": Id of kibana Index Pattern to delete" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getDefaultDataView", - "type": "Function", - "tags": [], - "label": "getDefaultDataView", - "description": [ - "\nReturns the default data view as an object.\nIf no default is found, or it is missing\nanother data view is selected as default and returned.\nIf no possible data view found to become a default returns null.\n" - ], - "signature": [ - "(refreshFields?: boolean | undefined) => Promise<", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" - }, - " | null>" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewsService.getDefaultDataView.$1", - "type": "CompoundType", - "tags": [], - "label": "refreshFields", - "description": [ - "- if true, will refresh the fields of the default data view" - ], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": false - } - ], - "returnComment": [ - "default data view" - ] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DuplicateDataViewError", - "type": "Class", - "tags": [], - "label": "DuplicateDataViewError", - "description": [ - "\nError thrown when attempting to create duplicate index pattern based on title." - ], - "signature": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DuplicateDataViewError", - "text": "DuplicateDataViewError" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" }, - " extends Error" - ], - "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.DuplicateDataViewError.Unnamed", - "type": "Function", - "tags": [], - "label": "Constructor", - "description": [ - "\nconstructor" - ], - "signature": [ - "any" - ], - "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.DuplicateDataViewError.Unnamed.$1", - "type": "string", - "tags": [], - "label": "message", - "description": [ - "- Error message" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/errors/duplicate_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.KbnFieldType", - "type": "Class", - "tags": [], - "label": "KbnFieldType", - "description": [], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.sortable", - "type": "boolean", - "tags": [], - "label": "sortable", - "description": [], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.filterable", - "type": "boolean", - "tags": [], - "label": "filterable", - "description": [], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.esTypes", - "type": "Object", - "tags": [], - "label": "esTypes", - "description": [], - "signature": [ - "readonly ", - { - "pluginId": "@kbn/field-types", - "scope": "common", - "docId": "kibKbnFieldTypesPluginApi", - "section": "def-common.ES_FIELD_TYPES", - "text": "ES_FIELD_TYPES" - }, - "[]" - ], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.Unnamed", - "type": "Function", - "tags": [], - "label": "Constructor", - "description": [], - "signature": [ - "any" - ], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.KbnFieldType.Unnamed.$1", - "type": "Object", - "tags": [], - "label": "options", - "description": [], - "signature": [ - "Partial<", - { - "pluginId": "@kbn/field-types", - "scope": "common", - "docId": "kibKbnFieldTypesPluginApi", - "section": "def-common.KbnFieldTypeOptions", - "text": "KbnFieldTypeOptions" - }, - ">" - ], - "path": "packages/kbn-field-types/src/kbn_field_type.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - } - ], - "functions": [ - { - "parentPluginId": "data", - "id": "def-common.cellHasFormulas", - "type": "Function", - "tags": [], - "label": "cellHasFormulas", - "description": [], - "signature": [ - "(val: string) => boolean" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, { - "parentPluginId": "data", - "id": "def-common.cellHasFormulas.$1", - "type": "string", - "tags": [], - "label": "val", - "description": [], - "signature": [ - "string" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.createEscapeValue", - "type": "Function", - "tags": [], - "label": "createEscapeValue", - "description": [ - "\nCreate a function that will escape CSV values like \"=\", \"@\" and \"+\" with a\n\"'\". This will also place CSV values in \"\" if contain non-alphanumeric chars.\n\nFor example:\n\nGiven: =1+1\nReturns: \"'=1+1\"\n\nSee OWASP: https://www.owasp.org/index.php/CSV_Injection." - ], - "signature": [ - "(quoteValues: boolean, escapeFormulas: boolean) => (val: RawValue) => string" - ], - "path": "src/plugins/data/common/exports/escape_value.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, { - "parentPluginId": "data", - "id": "def-common.createEscapeValue.$1", - "type": "boolean", - "tags": [], - "label": "quoteValues", - "description": [], - "signature": [ - "boolean" - ], - "path": "src/plugins/data/common/exports/escape_value.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.createEscapeValue.$2", - "type": "boolean", - "tags": [], - "label": "escapeFormulas", - "description": [], - "signature": [ - "boolean" - ], - "path": "src/plugins/data/common/exports/escape_value.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.datatableToCSV", - "type": "Function", - "tags": [], - "label": "datatableToCSV", - "description": [], - "signature": [ - "({ columns, rows }: ", + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, - ", { csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }: CSVOptions) => string" - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.datatableToCSV.$1", - "type": "Object", - "tags": [], - "label": "{ columns, rows }", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.Datatable", - "text": "Datatable" - } - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" }, { - "parentPluginId": "data", - "id": "def-common.datatableToCSV.$2", - "type": "Object", - "tags": [], - "label": "{ csvSeparator, quoteValues, formatFactory, raw, escapeFormulaValues }", - "description": [], - "signature": [ - "CSVOptions" - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.fieldList", - "type": "Function", - "tags": [], - "label": "fieldList", - "description": [], - "signature": [ - "(specs?: ", + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" }, - "[], shortDotsEnable?: boolean) => ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.IIndexPatternFieldList", - "text": "IIndexPatternFieldList" - } - ], - "path": "src/plugins/data_views/common/fields/field_list.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, { - "parentPluginId": "data", - "id": "def-common.fieldList.$1", - "type": "Array", - "tags": [], - "label": "specs", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" - }, - "[]" - ], - "path": "src/plugins/data_views/common/fields/field_list.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" }, { - "parentPluginId": "data", - "id": "def-common.fieldList.$2", - "type": "boolean", - "tags": [], - "label": "shortDotsEnable", - "description": [], - "signature": [ - "boolean" - ], - "path": "src/plugins/data_views/common/fields/field_list.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.getEsQueryConfig", - "type": "Function", - "tags": [], - "label": "getEsQueryConfig", - "description": [], - "signature": [ - "(config: KibanaConfig) => ", + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.EsQueryConfig", - "text": "EsQueryConfig" - } - ], - "path": "src/plugins/data/common/es_query/get_es_query_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "core", + "path": "src/core/types/index.ts" + }, { - "parentPluginId": "data", - "id": "def-common.getEsQueryConfig.$1", - "type": "Object", - "tags": [], - "label": "config", - "description": [], - "signature": [ - "KibanaConfig" - ], - "path": "src/plugins/data/common/es_query/get_es_query_config.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.getFieldSubtypeMulti", - "type": "Function", - "tags": [], - "label": "getFieldSubtypeMulti", - "description": [], - "signature": [ - "(field: HasSubtype) => ", + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts" + }, { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeMulti", - "text": "IFieldSubTypeMulti" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ { - "parentPluginId": "data", - "id": "def-common.getFieldSubtypeMulti.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.getFieldSubtypeNested", - "type": "Function", - "tags": [], - "label": "getFieldSubtypeNested", - "description": [], - "signature": [ - "(field: HasSubtype) => ", + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubTypeNested", - "text": "IFieldSubTypeNested" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, - " | undefined" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ { - "parentPluginId": "data", - "id": "def-common.getFieldSubtypeNested.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.getIndexPatternLoadMeta", - "type": "Function", - "tags": [], - "label": "getIndexPatternLoadMeta", - "description": [], - "signature": [ - "() => Omit<", + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.IndexPatternLoadExpressionFunctionDefinition", - "text": "IndexPatternLoadExpressionFunctionDefinition" + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" }, - ", \"fn\">" - ], - "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.isFilterable", - "type": "Function", - "tags": [], - "label": "isFilterable", - "description": [], - "signature": [ - "(field: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" }, - ") => boolean" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.isFilterable.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewField", - "text": "DataViewField" - } - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.isMultiField", - "type": "Function", - "tags": [], - "label": "isMultiField", - "description": [], - "signature": [ - "(field: HasSubtype) => boolean" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, { - "parentPluginId": "data", - "id": "def-common.isMultiField.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.isNestedField", - "type": "Function", - "tags": [], - "label": "isNestedField", - "description": [], - "signature": [ - "(field: HasSubtype) => boolean" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, { - "parentPluginId": "data", - "id": "def-common.isNestedField.$1", - "type": "Object", - "tags": [], - "label": "field", - "description": [], - "signature": [ - "{ subType?: ", - { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.IFieldSubType", - "text": "IFieldSubType" - }, - " | undefined; }" - ], - "path": "src/plugins/data_views/common/fields/utils.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.tableHasFormulas", - "type": "Function", - "tags": [], - "label": "tableHasFormulas", - "description": [], - "signature": [ - "(columns: ", + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" }, - "[], rows: ", { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableRow", - "text": "DatatableRow" + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" }, - "[]) => boolean" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.tableHasFormulas.$1", - "type": "Array", - "tags": [], - "label": "columns", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableColumn", - "text": "DatatableColumn" - }, - "[]" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" }, { - "parentPluginId": "data", - "id": "def-common.tableHasFormulas.$2", - "type": "Array", - "tags": [], - "label": "rows", - "description": [], - "signature": [ - { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.DatatableRow", - "text": "DatatableRow" - }, - "[]" - ], - "path": "src/plugins/data/common/exports/formula_checks.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [], - "initialIsOpen": false - } - ], - "interfaces": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes", - "type": "Interface", - "tags": [], - "label": "DataViewAttributes", - "description": [ - "\nInterface for the data view saved object" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.fields", - "type": "string", - "tags": [], - "label": "fields", - "description": [ - "\nFields as a serialized array of field specs" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.title", - "type": "string", - "tags": [], - "label": "title", - "description": [ - "\nData view title" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "\nData view type, default or rollup" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.typeMeta", - "type": "string", - "tags": [], - "label": "typeMeta", - "description": [ - "\nType metadata information, serialized. Only used by rollup data views." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.timeFieldName", - "type": "string", - "tags": [], - "label": "timeFieldName", - "description": [ - "\nTime field name" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.sourceFilters", - "type": "string", - "tags": [], - "label": "sourceFilters", - "description": [ - "\nSerialized array of filters. Used by discover to hide fields." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.fieldFormatMap", - "type": "string", - "tags": [], - "label": "fieldFormatMap", - "description": [ - "\nSerialized map of field formats by field name" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.fieldAttrs", - "type": "string", - "tags": [], - "label": "fieldAttrs", - "description": [ - "\nSerialized map of field attributes, currently field count and name" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.runtimeFieldMap", - "type": "string", - "tags": [], - "label": "runtimeFieldMap", - "description": [ - "\nSerialized map of runtime field definitions, by field name" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.allowNoIndex", - "type": "CompoundType", - "tags": [], - "label": "allowNoIndex", - "description": [ - "\nPrevents errors when index pattern exists before indices" - ], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewAttributes.name", - "type": "string", - "tags": [], - "label": "name", - "description": [ - "\nName of the data view. Human readable name used to differentiate data view." - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewListItem", - "type": "Interface", - "tags": [], - "label": "DataViewListItem", - "description": [ - "\nResult from data view search - summary data." - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "\nSaved object id (or generated id if in-memory only)" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.namespaces", - "type": "Array", - "tags": [], - "label": "namespaces", - "description": [ - "\nNamespace ids" - ], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.title", - "type": "string", - "tags": [], - "label": "title", - "description": [ - "\nData view title" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "\nData view type" - ], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.typeMeta", - "type": "Object", - "tags": [], - "label": "typeMeta", - "description": [ - "\nData view type meta" - ], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.TypeMeta", - "text": "TypeMeta" - }, - " | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" }, { - "parentPluginId": "data", - "id": "def-common.DataViewListItem.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions", - "type": "Interface", - "tags": [], - "label": "GetFieldsOptions", - "description": [], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.pattern", - "type": "string", - "tags": [], - "label": "pattern", - "description": [], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.lookBack", - "type": "CompoundType", - "tags": [], - "label": "lookBack", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.metaFields", - "type": "Array", - "tags": [], - "label": "metaFields", - "description": [], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.rollupIndex", - "type": "string", - "tags": [], - "label": "rollupIndex", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.allowNoIndex", - "type": "CompoundType", - "tags": [], - "label": "allowNoIndex", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.indexFilter", - "type": "Object", - "tags": [], - "label": "indexFilter", - "description": [], - "signature": [ - "QueryDslQueryContainer", - " | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.includeUnmapped", - "type": "CompoundType", - "tags": [], - "label": "includeUnmapped", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetFieldsOptions.fields", - "type": "Array", - "tags": [], - "label": "fields", - "description": [], - "signature": [ - "string[] | undefined" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.IDataViewsApiClient", - "type": "Interface", - "tags": [], - "label": "IDataViewsApiClient", - "description": [], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, { - "parentPluginId": "data", - "id": "def-common.IDataViewsApiClient.getFieldsForWildcard", - "type": "Function", - "tags": [], - "label": "getFieldsForWildcard", - "description": [], - "signature": [ - "(options: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - }, - ") => Promise<", - "FieldsForWildcardResponse", - ">" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.IDataViewsApiClient.getFieldsForWildcard.$1", - "type": "Object", - "tags": [], - "label": "options", - "description": [], - "signature": [ - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" - } - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" }, { - "parentPluginId": "data", - "id": "def-common.IDataViewsApiClient.hasUserDataView", - "type": "Function", - "tags": [], - "label": "hasUserDataView", - "description": [], - "signature": [ - "() => Promise" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.IndexPatternExpressionType", - "type": "Interface", - "tags": [], - "label": "IndexPatternExpressionType", - "description": [ - "\nIndex pattern expression interface" - ], - "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, { - "parentPluginId": "data", - "id": "def-common.IndexPatternExpressionType.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "\nExpression type" - ], - "signature": [ - "\"index_pattern\"" - ], - "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" }, { - "parentPluginId": "data", - "id": "def-common.IndexPatternExpressionType.value", - "type": "Object", - "tags": [], - "label": "value", - "description": [ - "\nValue - DataViewSpec" - ], - "signature": [ - "{ id?: string | undefined; version?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; sourceFilters?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.SourceFilter", - "text": "SourceFilter" - }, - "[] | undefined; fields?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewFieldMap", - "text": "DataViewFieldMap" - }, - " | undefined; typeMeta?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.TypeMeta", - "text": "TypeMeta" - }, - " | undefined; type?: string | undefined; fieldFormats?: Record> | undefined; runtimeFieldMap?: Record | undefined; fieldAttrs?: ", - { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrs", - "text": "FieldAttrs" - }, - " | undefined; allowNoIndex?: boolean | undefined; namespaces?: string[] | undefined; name?: string | undefined; }" - ], - "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.KbnFieldTypeOptions", - "type": "Interface", - "tags": [], - "label": "KbnFieldTypeOptions", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldTypeOptions.sortable", - "type": "boolean", - "tags": [], - "label": "sortable", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldTypeOptions.filterable", - "type": "boolean", - "tags": [], - "label": "filterable", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldTypeOptions.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" }, { - "parentPluginId": "data", - "id": "def-common.KbnFieldTypeOptions.esTypes", - "type": "Array", - "tags": [], - "label": "esTypes", - "description": [], - "signature": [ - { - "pluginId": "@kbn/field-types", - "scope": "common", - "docId": "kibKbnFieldTypesPluginApi", - "section": "def-common.ES_FIELD_TYPES", - "text": "ES_FIELD_TYPES" - }, - "[]" - ], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.SavedObject", - "type": "Interface", - "tags": [], - "label": "SavedObject", - "description": [], - "signature": [ + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "data", - "id": "def-common.SavedObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.created_at", - "type": "string", - "tags": [], - "label": "created_at", - "description": [ - "Timestamp of the time this document had been created." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.updated_at", - "type": "string", - "tags": [], - "label": "updated_at", - "description": [ - "Timestamp of the last time this document had been updated." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.error", - "type": "Object", - "tags": [], - "label": "error", - "description": [ - "Error associated with this object, populated if an operation failed for this object." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "{@inheritdoc SavedObjectReference}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.coreMigrationVersion", - "type": "string", - "tags": [], - "label": "coreMigrationVersion", - "description": [ - "A semver value that is used when upgrading objects between Kibana versions." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.namespaces", - "type": "Array", - "tags": [], - "label": "namespaces", - "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." - ], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" }, { - "parentPluginId": "data", - "id": "def-common.SavedObject.originId", - "type": "string", - "tags": [], - "label": "originId", - "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon", - "type": "Interface", - "tags": [], - "label": "UiSettingsCommon", - "description": [ - "\nInterface for UiSettings common interface {@link UiSettingsClient}" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.get", - "type": "Function", - "tags": [], - "label": "get", - "description": [ - "\nGet a setting value" - ], - "signature": [ - "(key: string) => Promise" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.get.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "name of value" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.getAll", - "type": "Function", - "tags": [], - "label": "getAll", - "description": [ - "\nGet all settings values" - ], - "signature": [ - "() => Promise>" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.set", - "type": "Function", - "tags": [], - "label": "set", - "description": [ - "\nSet a setting value" - ], - "signature": [ - "(key: string, value: T) => Promise" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.set.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "name of value" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.set.$2", - "type": "Uncategorized", - "tags": [], - "label": "value", - "description": [ - "value to set" - ], - "signature": [ - "T" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.remove", - "type": "Function", - "tags": [], - "label": "remove", - "description": [ - "\nRemove a setting value" - ], - "signature": [ - "(key: string) => Promise" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "data", - "id": "def-common.UiSettingsCommon.remove.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [ - "name of value" - ], - "signature": [ - "string" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - } - ], - "initialIsOpen": false - } - ], - "enums": [ - { - "parentPluginId": "data", - "id": "def-common.DataViewType", - "type": "Enum", - "tags": [], - "label": "DataViewType", - "description": [ - "\nData View type. Default or rollup" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.ES_FIELD_TYPES", - "type": "Enum", - "tags": [], - "label": "ES_FIELD_TYPES", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.KBN_FIELD_TYPES", - "type": "Enum", - "tags": [], - "label": "KBN_FIELD_TYPES", - "description": [], - "path": "packages/kbn-field-types/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - } - ], - "misc": [ - { - "parentPluginId": "data", - "id": "def-common.AggregationRestrictions", - "type": "Type", - "tags": [], - "label": "AggregationRestrictions", - "description": [], - "signature": [ - "{ [x: string]: { agg?: string | undefined; interval?: number | undefined; fixed_interval?: string | undefined; calendar_interval?: string | undefined; delay?: string | undefined; time_zone?: string | undefined; }; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.CSV_FORMULA_CHARS", - "type": "Array", - "tags": [], - "label": "CSV_FORMULA_CHARS", - "description": [], - "signature": [ - "string[]" - ], - "path": "src/plugins/data/common/exports/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.CSV_MIME_TYPE", - "type": "string", - "tags": [], - "label": "CSV_MIME_TYPE", - "description": [], - "signature": [ - "\"text/plain;charset=utf-8\"" - ], - "path": "src/plugins/data/common/exports/export_csv.tsx", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DATA_VIEW_SAVED_OBJECT_TYPE", - "type": "string", - "tags": [], - "label": "DATA_VIEW_SAVED_OBJECT_TYPE", - "description": [ - "\nData view saved object type." - ], - "signature": [ - "\"index-pattern\"" - ], - "path": "src/plugins/data_views/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewFieldMap", - "type": "Type", - "tags": [], - "label": "DataViewFieldMap", - "description": [], - "signature": [ - "{ [x: string]: ", + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - "; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewsContract", - "type": "Type", - "tags": [], - "label": "DataViewsContract", - "description": [ - "\nData views service interface" - ], - "signature": [ - "{ get: (id: string, displayErrors?: boolean, refreshFields?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - ">; delete: (indexPatternId: string) => Promise<{}>; create: (spec: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, - ", skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" }, - ">; find: (search: string, size?: number) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" }, - "[]>; getCanSave: () => Promise; getIds: (refresh?: boolean) => Promise; getTitles: (refresh?: boolean) => Promise; getIdsWithTitle: (refresh?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewListItem", - "text": "DataViewListItem" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" }, - "[]>; clearCache: () => void; clearInstanceCache: (id?: string | undefined) => void; getCache: () => Promise<", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" }, - "<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSavedObjectAttrs", - "text": "DataViewSavedObjectAttrs" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" }, - ">[] | null | undefined>; getDefault: (displayErrors?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" }, - " | null>; getDefaultId: () => Promise; setDefault: (id: string | null, force?: boolean) => Promise; hasUserDataView: () => Promise; getFieldsForWildcard: (options: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" }, - ") => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" }, - "[]>; getFieldsForIndexPattern: (indexPattern: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" }, - " | ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" }, - ", options?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.GetFieldsOptions", - "text": "GetFieldsOptions" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" }, - " | undefined) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" }, - "[]>; refreshFields: (dataView: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" }, - ", displayErrors?: boolean) => Promise; fieldArrayToMap: (fields: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldSpec", - "text": "FieldSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" }, - "[], fieldAttrs?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrs", - "text": "FieldAttrs" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" }, - " | undefined) => ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewFieldMap", - "text": "DataViewFieldMap" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" }, - "; savedObjectToSpec: (savedObject: ", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" }, - "<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewAttributes", - "text": "DataViewAttributes" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" }, - ">) => ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" }, - "; createAndSave: (spec: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewSpec", - "text": "DataViewSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" }, - ", override?: boolean, skipFetchFields?: boolean, displayErrors?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" }, - ">; createSavedObject: (dataView: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" }, - ", override?: boolean, displayErrors?: boolean) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" }, - ">; updateSavedObject: (indexPattern: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" }, - ", saveAttempts?: number, ignoreErrors?: boolean, displayErrors?: boolean) => Promise; getDefaultDataView: (refreshFields?: boolean | undefined) => Promise<", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataView", - "text": "DataView" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" }, - " | null>; }" - ], - "path": "src/plugins/data_views/common/data_views/data_views.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DataViewSpec", - "type": "Type", - "tags": [], - "label": "DataViewSpec", - "description": [ - "\nStatic data view format\nSerialized data object, representing data view attributes and state" - ], - "signature": [ - "{ id?: string | undefined; version?: string | undefined; title?: string | undefined; timeFieldName?: string | undefined; sourceFilters?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.SourceFilter", - "text": "SourceFilter" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" }, - "[] | undefined; fields?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.DataViewFieldMap", - "text": "DataViewFieldMap" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" }, - " | undefined; typeMeta?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.TypeMeta", - "text": "TypeMeta" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" }, - " | undefined; type?: string | undefined; fieldFormats?: Record> | undefined; runtimeFieldMap?: Record | undefined; fieldAttrs?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrs", - "text": "FieldAttrs" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" }, - " | undefined; allowNoIndex?: boolean | undefined; namespaces?: string[] | undefined; name?: string | undefined; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.DEFAULT_QUERY_LANGUAGE", - "type": "string", - "tags": [], - "label": "DEFAULT_QUERY_LANGUAGE", - "description": [], - "signature": [ - "\"kuery\"" - ], - "path": "src/plugins/data/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.FieldAttrs", - "type": "Type", - "tags": [], - "label": "FieldAttrs", - "description": [ - "\nSet of field attributes" - ], - "signature": [ - "{ [key: string]: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.FieldAttrSet", - "text": "FieldAttrSet" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" }, - "; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.FieldAttrSet", - "type": "Type", - "tags": [], - "label": "FieldAttrSet", - "description": [ - "\nField attributes that are stored on the data view" - ], - "signature": [ - "{ customLabel?: string | undefined; count?: number | undefined; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.FieldSpec", - "type": "Type", - "tags": [], - "label": "FieldSpec", - "description": [ - "\nSerialized version of DataViewField" - ], - "signature": [ { - "pluginId": "@kbn/es-query", - "scope": "common", - "docId": "kibKbnEsQueryPluginApi", - "section": "def-common.DataViewFieldBase", - "text": "DataViewFieldBase" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" }, - " & { count?: number | undefined; conflictDescriptions?: Record | undefined; format?: ", { - "pluginId": "fieldFormats", - "scope": "common", - "docId": "kibFieldFormatsPluginApi", - "section": "def-common.SerializedFieldFormat", - "text": "SerializedFieldFormat" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" }, - "<{}, ", { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" }, - "> | undefined; esTypes?: string[] | undefined; searchable: boolean; aggregatable: boolean; readFromDocValues?: boolean | undefined; indexed?: boolean | undefined; customLabel?: string | undefined; runtimeField?: ", { - "pluginId": "dataViews", - "scope": "common", - "docId": "kibDataViewsPluginApi", - "section": "def-common.RuntimeFieldSpec", - "text": "RuntimeFieldSpec" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" }, - " | undefined; fixedInterval?: string[] | undefined; timeZone?: string[] | undefined; timeSeriesDimension?: boolean | undefined; timeSeriesMetric?: \"gauge\" | \"histogram\" | \"summary\" | \"counter\" | undefined; shortDotsEnable?: boolean | undefined; isMapped?: boolean | undefined; parentName?: string | undefined; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.FieldSpecConflictDescriptions", - "type": "Type", - "tags": [], - "label": "FieldSpecConflictDescriptions", - "description": [], - "signature": [ - "{ [x: string]: string[]; }" - ], - "path": "src/plugins/data_views/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.GetConfigFn", - "type": "Type", - "tags": [], - "label": "GetConfigFn", - "description": [ - "\nIf a service is being shared on both the client and the server, and\nthe client code requires synchronous access to uiSettings, both client\nand server should wrap the core uiSettings services in a function\nmatching this signature.\n\nThis matches the signature of the public `core.uiSettings.get`, and\nshould only be used in scenarios where async access to uiSettings is\nnot possible." - ], - "signature": [ - "(key: string, defaultOverride?: T | undefined) => T" - ], - "path": "src/plugins/data/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "returnComment": [], - "children": [ { - "parentPluginId": "data", - "id": "def-common.GetConfigFn.$1", - "type": "string", - "tags": [], - "label": "key", - "description": [], - "path": "src/plugins/data/common/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" }, { - "parentPluginId": "data", - "id": "def-common.GetConfigFn.$2", - "type": "Uncategorized", - "tags": [], - "label": "defaultOverride", - "description": [], - "signature": [ - "T | undefined" - ], - "path": "src/plugins/data/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.IndexPatternLoadExpressionFunctionDefinition", - "type": "Type", - "tags": [], - "label": "IndexPatternLoadExpressionFunctionDefinition", - "description": [], - "signature": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.ExpressionFunctionDefinition", - "text": "ExpressionFunctionDefinition" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" }, - "<\"indexPatternLoad\", null, Arguments, Output, ", { - "pluginId": "expressions", - "scope": "common", - "docId": "kibExpressionsPluginApi", - "section": "def-common.ExecutionContext", - "text": "ExecutionContext" + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" }, - "<", { - "pluginId": "inspector", - "scope": "common", - "docId": "kibInspectorPluginApi", - "section": "def-common.Adapters", - "text": "Adapters" + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" }, - ", ", { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" }, - ">>" - ], - "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.KIBANA_USER_QUERY_LANGUAGE_KEY", - "type": "string", - "tags": [], - "label": "KIBANA_USER_QUERY_LANGUAGE_KEY", - "description": [], - "signature": [ - "\"kibana.userQueryLanguage\"" - ], - "path": "src/plugins/data/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.META_FIELDS", - "type": "string", - "tags": [], - "label": "META_FIELDS", - "description": [ - "\nUiSettings key for metaFields list." - ], - "signature": [ - "\"metaFields\"" - ], - "path": "src/plugins/data_views/common/constants.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "data", - "id": "def-common.Query", - "type": "Type", - "tags": [], - "label": "Query", - "description": [], - "signature": [ - "{ query: string | { [key: string]: any; }; language: string; }" + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + } ], - "path": "packages/kbn-es-query/src/filters/build_filters/types.ts", - "deprecated": false, - "trackAdoption": false, "initialIsOpen": false }, { diff --git a/api_docs/data.mdx b/api_docs/data.mdx index b78ddbb0bd64b..fbdbddfe7bd5c 100644 --- a/api_docs/data.mdx +++ b/api_docs/data.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/data title: "data" image: https://source.unsplash.com/400x175/?github description: API docs for the data plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data'] --- import dataObj from './data.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-disco | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 3300 | 119 | 2578 | 27 | +| 3276 | 119 | 2578 | 27 | ## Client diff --git a/api_docs/data_query.mdx b/api_docs/data_query.mdx index f6e7c535342ad..9f8b6bcca7a44 100644 --- a/api_docs/data_query.mdx +++ b/api_docs/data_query.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/data-query title: "data.query" image: https://source.unsplash.com/400x175/?github description: API docs for the data.query plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data.query'] --- import dataQueryObj from './data_query.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-disco | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 3300 | 119 | 2578 | 27 | +| 3276 | 119 | 2578 | 27 | ## Client diff --git a/api_docs/data_search.mdx b/api_docs/data_search.mdx index 291be4fd74cce..b3d8168770760 100644 --- a/api_docs/data_search.mdx +++ b/api_docs/data_search.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/data-search title: "data.search" image: https://source.unsplash.com/400x175/?github description: API docs for the data.search plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data.search'] --- import dataSearchObj from './data_search.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-disco | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 3300 | 119 | 2578 | 27 | +| 3276 | 119 | 2578 | 27 | ## Client diff --git a/api_docs/data_view_editor.mdx b/api_docs/data_view_editor.mdx index 837fe016b3e40..7b012a86f90df 100644 --- a/api_docs/data_view_editor.mdx +++ b/api_docs/data_view_editor.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dataViewEditor title: "dataViewEditor" image: https://source.unsplash.com/400x175/?github description: API docs for the dataViewEditor plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViewEditor'] --- import dataViewEditorObj from './data_view_editor.devdocs.json'; diff --git a/api_docs/data_view_field_editor.mdx b/api_docs/data_view_field_editor.mdx index 8583ad0e7b8c2..dd9454f0f63de 100644 --- a/api_docs/data_view_field_editor.mdx +++ b/api_docs/data_view_field_editor.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dataViewFieldEditor title: "dataViewFieldEditor" image: https://source.unsplash.com/400x175/?github description: API docs for the dataViewFieldEditor plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViewFieldEditor'] --- import dataViewFieldEditorObj from './data_view_field_editor.devdocs.json'; diff --git a/api_docs/data_view_management.mdx b/api_docs/data_view_management.mdx index 927a76ee4f24f..bc6d6f1ae8f68 100644 --- a/api_docs/data_view_management.mdx +++ b/api_docs/data_view_management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dataViewManagement title: "dataViewManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the dataViewManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViewManagement'] --- import dataViewManagementObj from './data_view_management.devdocs.json'; diff --git a/api_docs/data_views.devdocs.json b/api_docs/data_views.devdocs.json index 8f90a134180e3..c8c66a842fcf8 100644 --- a/api_docs/data_views.devdocs.json +++ b/api_docs/data_views.devdocs.json @@ -585,19 +585,23 @@ }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" }, { "plugin": "timelines", @@ -875,14 +879,6 @@ "plugin": "discover", "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, { "plugin": "infra", "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" @@ -8801,19 +8797,23 @@ }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" }, { "plugin": "timelines", @@ -9091,14 +9091,6 @@ "plugin": "discover", "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, { "plugin": "infra", "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" @@ -16112,19 +16104,23 @@ }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" + "path": "x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" + "path": "x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/detections/components/rules/step_define_rule/index.tsx" }, { "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" + "path": "x-pack/plugins/security_solution/public/detection_engine/rule_details_ui/pages/rule_details/index.tsx" }, { "plugin": "timelines", @@ -16402,14 +16398,6 @@ "plugin": "discover", "path": "src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts" }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts" - }, { "plugin": "infra", "path": "x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts" @@ -24056,237 +24044,6 @@ ], "initialIsOpen": false }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject", - "type": "Interface", - "tags": [], - "label": "SavedObject", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.created_at", - "type": "string", - "tags": [], - "label": "created_at", - "description": [ - "Timestamp of the time this document had been created." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.updated_at", - "type": "string", - "tags": [], - "label": "updated_at", - "description": [ - "Timestamp of the last time this document had been updated." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.error", - "type": "Object", - "tags": [], - "label": "error", - "description": [ - "Error associated with this object, populated if an operation failed for this object." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.attributes", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "{@inheritdoc SavedObjectReference}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.migrationVersion", - "type": "Object", - "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.coreMigrationVersion", - "type": "string", - "tags": [], - "label": "coreMigrationVersion", - "description": [ - "A semver value that is used when upgrading objects between Kibana versions." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.namespaces", - "type": "Array", - "tags": [], - "label": "namespaces", - "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." - ], - "signature": [ - "string[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "dataViews", - "id": "def-common.SavedObject.originId", - "type": "string", - "tags": [], - "label": "originId", - "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, { "parentPluginId": "dataViews", "id": "def-common.SavedObjectsClientCommon", @@ -25948,6 +25705,1664 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "dataViews", + "id": "def-common.SavedObject", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObject", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/index.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/common/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + }, + { + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + } + ], + "initialIsOpen": false + }, { "parentPluginId": "dataViews", "id": "def-common.SourceFilter", diff --git a/api_docs/data_views.mdx b/api_docs/data_views.mdx index 1b34c2f8374a5..ab8c80d61f817 100644 --- a/api_docs/data_views.mdx +++ b/api_docs/data_views.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dataViews title: "dataViews" image: https://source.unsplash.com/400x175/?github description: API docs for the dataViews plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViews'] --- import dataViewsObj from './data_views.devdocs.json'; @@ -21,7 +21,7 @@ Contact [App Services](https://github.com/orgs/elastic/teams/kibana-app-services | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 1032 | 0 | 231 | 2 | +| 1020 | 0 | 231 | 2 | ## Client diff --git a/api_docs/data_visualizer.mdx b/api_docs/data_visualizer.mdx index b2d2f7049457c..179199a6ed267 100644 --- a/api_docs/data_visualizer.mdx +++ b/api_docs/data_visualizer.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/dataVisualizer title: "dataVisualizer" image: https://source.unsplash.com/400x175/?github description: API docs for the dataVisualizer plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataVisualizer'] --- import dataVisualizerObj from './data_visualizer.devdocs.json'; diff --git a/api_docs/deprecations_by_api.mdx b/api_docs/deprecations_by_api.mdx index 1bdfe7e8ee894..7c1d32518069c 100644 --- a/api_docs/deprecations_by_api.mdx +++ b/api_docs/deprecations_by_api.mdx @@ -7,7 +7,7 @@ id: kibDevDocsDeprecationsByApi slug: /kibana-dev-docs/api-meta/deprecated-api-list-by-api title: Deprecated API usage by API description: A list of deprecated APIs, which plugins are still referencing them, and when they need to be removed by. -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana'] --- @@ -21,13 +21,19 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | visTypePie | - | | | alerting, discover, securitySolution | - | | | stackAlerts, alerting, securitySolution, inputControlVis | - | +| | @kbn/core-saved-objects-common, @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-api-server, core, home, dataViews, discover, savedObjectsTagging, savedObjectsFinder, fleet, canvas, osquery, securitySolution, synthetics, savedObjects, @kbn/core-saved-objects-browser-mocks, @kbn/core-saved-objects-server, @kbn/core-saved-objects-api-server-internal, @kbn/core-saved-objects-import-export-server-internal, @kbn/core-saved-objects-server-internal, apm, savedObjectsTaggingOss, savedObjectsManagement, cases, lists, upgradeAssistant, security, encryptedSavedObjects, lens, alerting, observability, @kbn/core-ui-settings-server-internal, data, dashboard | - | +| | @kbn/core-saved-objects-common, @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-api-server, core, home, dataViews, discover, savedObjectsTagging, savedObjectsFinder, fleet, canvas, osquery, securitySolution, synthetics, savedObjects, @kbn/core-saved-objects-browser-mocks, @kbn/core-saved-objects-server, @kbn/core-saved-objects-api-server-internal, @kbn/core-saved-objects-import-export-server-internal, @kbn/core-saved-objects-server-internal, apm, savedObjectsTaggingOss, savedObjectsManagement, cases, lists, upgradeAssistant, security, encryptedSavedObjects, lens, alerting, observability, @kbn/core-ui-settings-server-internal, data | - | | | alerting, discover, securitySolution | - | | | stackAlerts, alerting, securitySolution, inputControlVis | - | | | actions, alerting | - | -| | @kbn/core-saved-objects-common, savedObjects, embeddable, visualizations, dashboard, fleet, infra, canvas, graph, actions, alerting, enterpriseSearch, securitySolution, taskManager, savedSearch, ml, @kbn/core-saved-objects-server-internal | - | -| | @kbn/core-saved-objects-common, savedObjects, embeddable, visualizations, dashboard, fleet, infra, canvas, graph, actions, alerting, enterpriseSearch, securitySolution, taskManager, savedSearch, ml, @kbn/core-saved-objects-server-internal | - | +| | @kbn/core-saved-objects-common, advancedSettings, triggersActionsUi, visualizations, alerting | - | +| | @kbn/core-saved-objects-common, savedObjects, embeddable, visualizations, dashboard, fleet, infra, canvas, graph, ml, alerting, @kbn/core-saved-objects-server-internal | - | +| | @kbn/core-saved-objects-common, @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-api-server, savedObjects, savedObjectsManagement, visualizations, savedObjectsTagging, lens, fleet, graph, dashboard, savedObjectsTaggingOss, @kbn/core-saved-objects-server, kibanaUtils, expressions, dataViews, data, embeddable, controls, uiActionsEnhanced, maps, canvas, cases, dashboardEnhanced, globalSearchProviders, alerting, @kbn/core-saved-objects-api-server-internal, @kbn/core-saved-objects-import-export-server-internal | - | +| | @kbn/core-saved-objects-common, @kbn/core-saved-objects-server, actions, alerting, canvas, enterpriseSearch, securitySolution, taskManager, dashboard, savedSearch | - | | | @kbn/core-saved-objects-migration-server-internal, actions, dataViews, data, alerting, savedObjectsTagging, canvas, lens, cases, graph, lists, maps, securitySolution, dashboard, savedSearch, visualizations, @kbn/core-test-helpers-so-type-serializer | - | -| | core, savedObjects, embeddable, visualizations, dashboard, fleet, infra, canvas, graph, actions, alerting, enterpriseSearch, securitySolution, taskManager, savedSearch, ml, @kbn/core-saved-objects-server-internal | - | +| | core, advancedSettings, triggersActionsUi, visualizations, alerting | - | +| | core, savedObjects, embeddable, visualizations, dashboard, fleet, infra, canvas, graph, ml, alerting, @kbn/core-saved-objects-server-internal, @kbn/core-saved-objects-common, actions, enterpriseSearch, securitySolution, taskManager, savedSearch | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-api-server, core, savedObjects, savedObjectsManagement, visualizations, savedObjectsTagging, lens, fleet, graph, dashboard, savedObjectsTaggingOss, @kbn/core-saved-objects-server, kibanaUtils, expressions, dataViews, data, embeddable, controls, uiActionsEnhanced, maps, canvas, cases, dashboardEnhanced, globalSearchProviders, alerting, @kbn/core-saved-objects-api-server-internal, @kbn/core-saved-objects-import-export-server-internal | - | | | @kbn/core-saved-objects-migration-server-internal, actions, dataViews, data, alerting, savedObjectsTagging, canvas, lens, cases, graph, lists, maps, securitySolution, dashboard, savedSearch, visualizations, @kbn/core-test-helpers-so-type-serializer | - | | | discover, monitoring | - | | | @kbn/es-query, securitySolution, timelines, lists, threatIntelligence, dataViews, unifiedSearch, triggersActionsUi, savedObjectsManagement, controls, unifiedFieldList, lens, aiops, ml, infra, visTypeTimeseries, apm, observability, dataVisualizer, fleet, canvas, graph, stackAlerts, synthetics, transform, upgradeAssistant, ux, maps, dataViewManagement, inputControlVis, visDefaultEditor, presentationUtil, visTypeTimelion, visTypeVega, discover, data | - | @@ -36,11 +42,16 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | @kbn/es-query, securitySolution, timelines, lists, threatIntelligence, data, unifiedSearch, triggersActionsUi, savedObjectsManagement, controls, unifiedFieldList, lens, aiops, ml, infra, visTypeTimeseries, apm, observability, dataVisualizer, fleet, canvas, graph, stackAlerts, synthetics, transform, upgradeAssistant, ux, maps, dataViewManagement, inputControlVis, visDefaultEditor, presentationUtil, visTypeTimelion, visTypeVega, discover | - | | | data, discover, imageEmbeddable, embeddable | - | | | advancedSettings, discover | - | +| | @kbn/core-plugins-browser-internal, @kbn/core-root-browser-internal, dataViews, home, data, savedObjects, embeddable, unifiedSearch, presentationUtil, visualizations, dashboard, lens, discover, cases, fileUpload, maps, ml, infra, fleet, canvas, dashboardEnhanced, graph, synthetics, transform, watcher, dataVisualizer, cloudSecurityPosture, securitySolution | - | | | advancedSettings, discover | - | +| | @kbn/core-plugins-browser-internal, @kbn/core-root-browser-internal, dataViews, home, data, savedObjects, embeddable, unifiedSearch, presentationUtil, visualizations, dashboard, lens, discover, cases, fileUpload, maps, ml, infra, fleet, canvas, dashboardEnhanced, graph, synthetics, transform, watcher, dataVisualizer, cloudSecurityPosture, securitySolution | - | | | advancedSettings, discover | - | | | infra, graph, stackAlerts, inputControlVis, securitySolution, savedObjects | - | | | securitySolution | - | | | encryptedSavedObjects, actions, data, ml, logstash, securitySolution, cloudChat | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser, @kbn/core-saved-objects-browser-internal, dataViews, home, savedObjects, savedSearch, visualizations, dashboard, lens, ml, canvas, graph, securitySolution, synthetics, watcher, visTypeTimeseries, @kbn/core-saved-objects-browser-mocks | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, presentationUtil, savedSearch, visualizations, dashboard, lens, savedObjectsFinder, cases, maps, ml, infra, cloudSecurityPosture, dashboardEnhanced, graph, securitySolution, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, dataViews, savedObjects, embeddable, presentationUtil, visualizations, dashboard, lens, savedObjectsFinder, aiops, ml, cases, maps, dataVisualizer, infra, fleet, cloudSecurityPosture, dashboardEnhanced, graph, synthetics, securitySolution, @kbn/core-saved-objects-browser-mocks | - | | | lists, securitySolution, @kbn/securitysolution-io-ts-list-types | - | | | lists, securitySolution, @kbn/securitysolution-io-ts-list-types | - | | | lists, securitySolution, @kbn/securitysolution-io-ts-list-types | - | @@ -53,25 +64,78 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | securitySolution | - | | | securitySolution | - | | | securitySolution | - | +| | @kbn/core-saved-objects-browser, @kbn/core-saved-objects-browser-internal, core, dataViews, home, savedObjects, savedSearch, visualizations, dashboard, lens, ml, canvas, graph, securitySolution, synthetics, watcher, visTypeTimeseries, @kbn/core-saved-objects-browser-mocks | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, presentationUtil, savedSearch, visualizations, dashboard, lens, savedObjectsFinder, cases, maps, ml, infra, cloudSecurityPosture, dashboardEnhanced, graph, securitySolution, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, core, dataViews, savedObjects, embeddable, presentationUtil, visualizations, dashboard, lens, savedObjectsFinder, aiops, ml, cases, maps, dataVisualizer, infra, fleet, cloudSecurityPosture, dashboardEnhanced, graph, synthetics, securitySolution, @kbn/core-saved-objects-browser-mocks | - | | | dashboard, dataVisualizer, stackAlerts, expressionPartitionVis | - | -| | visTypeTimeseries, graph, dataViewManagement, dataViews | - | -| | visTypeTimeseries, graph, dataViewManagement, dataViews | - | -| | visTypeTimeseries, graph, dataViewManagement | - | -| | observability, dataVisualizer, fleet, cloudSecurityPosture, discoverEnhanced, osquery, synthetics | - | +| | @kbn/core-saved-objects-common | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, dataViews, savedObjects, visualizations, infra | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, infra | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, savedObjectsManagement, visualizations, cloudSecurityPosture | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, dataViews | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, spaces, savedSearch, visualizations, dashboard, lens, cases, maps, fleet, canvas, graph | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal, osquery | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-api-browser | - | +| | @kbn/core-saved-objects-api-browser | - | +| | @kbn/core-saved-objects-api-browser, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser, @kbn/core-lifecycle-browser, @kbn/core-saved-objects-browser-internal, savedObjects, savedSearch, visualizations, dashboard, lens, savedObjectsFinder, observability, canvas, transform, @kbn/core-saved-objects-browser-mocks | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, savedSearch, visualizations, dashboard, lens, maps, infra, graph, synthetics | - | +| | @kbn/core-saved-objects-browser-mocks, home, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, visualizations, dashboard, maps, infra, graph | - | +| | @kbn/core-saved-objects-browser-mocks, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, visualizations, dashboard, dataVisualizer, ml, infra, cloudSecurityPosture, dashboardEnhanced, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dashboard, savedObjects, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedSearch, visualizations, dashboard, lens, maps, graph, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, fleet, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedSearch, maps, infra, savedObjects | - | +| | @kbn/core-saved-objects-browser-mocks, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser, @kbn/core-lifecycle-browser, @kbn/core-saved-objects-browser-internal, savedObjects, savedSearch, visualizations, dashboard, lens, savedObjectsFinder, observability, canvas, transform, @kbn/core-saved-objects-browser-mocks | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, savedSearch, visualizations, dashboard, lens, maps, infra, graph, synthetics | - | +| | @kbn/core-saved-objects-browser-mocks, home, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, visualizations, dashboard, maps, infra, graph | - | +| | @kbn/core-saved-objects-browser-mocks, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedObjects, visualizations, dashboard, dataVisualizer, ml, infra, cloudSecurityPosture, dashboardEnhanced, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dashboard, savedObjects, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, dataViews, savedSearch, visualizations, dashboard, lens, maps, graph, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-mocks, fleet, synthetics, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, @kbn/core-saved-objects-browser-mocks, dataViews, savedSearch, maps, infra, savedObjects | - | +| | @kbn/core-saved-objects-browser-mocks, @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-saved-objects-browser-internal, core, dataViews, savedObjects, visualizations, infra | - | +| | @kbn/core-saved-objects-browser-internal, core | - | +| | @kbn/core-saved-objects-browser-internal, core, infra | - | +| | @kbn/core-saved-objects-browser-internal, core, savedObjectsManagement, visualizations, cloudSecurityPosture | - | +| | @kbn/core-saved-objects-browser-internal, core, dataViews | - | +| | @kbn/core-saved-objects-browser-internal, core, spaces, savedSearch, visualizations, dashboard, lens, cases, maps, fleet, canvas, graph | - | +| | @kbn/core-saved-objects-browser-internal, core | - | +| | @kbn/core-saved-objects-browser-internal, core, osquery | - | +| | @kbn/core-saved-objects-browser-internal, core | - | +| | @kbn/core-saved-objects-browser-internal, core | - | +| | @kbn/core-saved-objects-browser-internal | - | +| | @kbn/core-lifecycle-browser, @kbn/core-saved-objects-browser-internal, core, savedObjects, savedSearch, visualizations, dashboard, lens, savedObjectsFinder, observability, canvas, transform, @kbn/core-saved-objects-browser-mocks | - | +| | core | - | +| | core | - | +| | @kbn/core-lifecycle-browser-mocks, core, ml, dashboard, dataViews, savedSearch, @kbn/core-plugins-browser-internal | - | +| | core, lens, savedObjects, visualizations | - | +| | core | - | +| | home, ml, canvas, osquery | - | +| | home, data, esUiShared, spaces, savedObjectsManagement, fleet, observability, ml, apm, indexLifecycleManagement, synthetics, upgradeAssistant, ux, kibanaOverview | - | | | dataViews, maps | - | | | dataViewManagement, dataViews | - | +| | visTypeTimeseries, graph, dataViewManagement, dataViews | - | | | dataViews, dataViewManagement | - | | | dataViews, maps | - | | | dataViewManagement, dataViews | - | +| | visTypeTimeseries, graph, dataViewManagement, dataViews | - | | | dataViews, dataViewManagement | - | -| | unifiedSearch | - | -| | unifiedSearch | - | -| | home, data, esUiShared, spaces, savedObjectsManagement, fleet, observability, ml, apm, indexLifecycleManagement, synthetics, upgradeAssistant, ux, kibanaOverview | - | -| | spaces, savedObjectsManagement | - | -| | spaces, savedObjectsManagement | - | -| | spaces, savedObjectsManagement | - | -| | home, ml, canvas, osquery | - | | | actions, ml, savedObjectsTagging, enterpriseSearch | - | +| | observability, dataVisualizer, fleet, cloudSecurityPosture, discoverEnhanced, osquery, synthetics | - | | | canvas | - | | | canvas | - | | | canvas | - | @@ -82,12 +146,19 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | canvas | - | | | canvas | - | | | canvas | - | +| | @kbn/core-root-browser-internal, @kbn/core-saved-objects-browser-mocks | - | +| | spaces, savedObjectsManagement | - | +| | spaces, savedObjectsManagement | - | +| | spaces, savedObjectsManagement | - | +| | encryptedSavedObjects | - | +| | encryptedSavedObjects | - | +| | visTypeTimeseries, graph, dataViewManagement | - | +| | unifiedSearch | - | +| | unifiedSearch | - | | | maps | - | | | dataViewManagement | - | | | dataViewManagement | - | | | enterpriseSearch | - | -| | encryptedSavedObjects | - | -| | encryptedSavedObjects | - | | | @kbn/core-elasticsearch-server-internal, @kbn/core-plugins-server-internal, console | - | | | @kbn/core-elasticsearch-server-internal, @kbn/core-plugins-server-internal, console | - | | | @kbn/core-plugins-server-internal | - | @@ -98,26 +169,17 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | embeddable, presentationUtil, dashboard, discover, graph | 8.8.0 | | | apm, security, securitySolution | 8.8.0 | | | apm, security, securitySolution | 8.8.0 | -| | @kbn/core-application-browser-internal, @kbn/core-application-browser-mocks, visualizations, dashboard, lens, maps, ml, securitySolution, security | 8.8.0 | -| | @kbn/core-application-browser, @kbn/core-application-browser-internal, securitySolution | 8.8.0 | -| | @kbn/core-application-browser-internal, core, securitySolution | 8.8.0 | -| | @kbn/core-application-browser-internal, @kbn/core-application-browser-mocks, visualizations, dashboard, lens, maps, ml, securitySolution, security, core | 8.8.0 | -| | @kbn/core-apps-browser-internal, @kbn/core-metrics-server-internal, @kbn/core-status-server-internal, @kbn/core-usage-data-server-internal, monitoring, kibanaUsageCollection | 8.8.0 | -| | @kbn/core-apps-browser-internal, @kbn/core-metrics-server-internal, @kbn/core-status-server-internal, @kbn/core-usage-data-server-internal, monitoring, kibanaUsageCollection | 8.8.0 | -| | savedObjectsTaggingOss, dashboard | 8.8.0 | -| | maps, dashboard, @kbn/core-saved-objects-migration-server-internal | 8.8.0 | -| | maps, dashboard, @kbn/core-saved-objects-migration-server-internal | 8.8.0 | -| | security, licenseManagement, ml, apm, crossClusterReplication, logstash, painlessLab, searchprofiler, watcher | 8.8.0 | -| | apm | 8.8.0 | +| | @kbn/core-application-browser-internal, @kbn/core-application-browser-mocks, management, fleet, security, kibanaOverview, core | 8.8.0 | +| | @kbn/core-plugins-server-internal, core | 8.8.0 | | | security, fleet | 8.8.0 | | | security, fleet | 8.8.0 | | | security, fleet | 8.8.0 | | | @kbn/core-application-browser-internal, @kbn/core-application-browser-mocks, management, fleet, security, kibanaOverview | 8.8.0 | -| | @kbn/core-application-browser-internal, @kbn/core-application-browser-mocks, management, fleet, security, kibanaOverview, core | 8.8.0 | +| | apm | 8.8.0 | +| | security, licenseManagement, ml, apm, crossClusterReplication, logstash, painlessLab, searchprofiler, watcher | 8.8.0 | | | security | 8.8.0 | | | mapsEms | 8.8.0 | | | @kbn/core-plugins-server, @kbn/core-plugins-server-internal | 8.8.0 | -| | @kbn/core-plugins-server-internal, core | 8.8.0 | | | security | 8.8.0 This is relied on by the reporting feature, and should be removed once reporting @@ -165,4 +227,6 @@ Safe to remove. | | reporting | | | reporting | | | taskManager | -| | @kbn/storybook | \ No newline at end of file +| | @kbn/storybook | +| | @kbn/core-saved-objects-api-browser | +| | @kbn/core-saved-objects-api-browser | \ No newline at end of file diff --git a/api_docs/deprecations_by_plugin.mdx b/api_docs/deprecations_by_plugin.mdx index 7504461ae5cd4..89adefbf1c2ab 100644 --- a/api_docs/deprecations_by_plugin.mdx +++ b/api_docs/deprecations_by_plugin.mdx @@ -7,29 +7,17 @@ id: kibDevDocsDeprecationsByPlugin slug: /kibana-dev-docs/api-meta/deprecated-api-list-by-plugin title: Deprecated API usage by plugin description: A list of deprecated APIs, which plugins are still referencing them, and when they need to be removed by. -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana'] --- -## @kbn/core-application-browser - -| Deprecated API | Reference location(s) | Remove By | -| ---------------|-----------|-----------| -| | [app_leave.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_leave.ts#:~:text=AppLeaveHandler), [app_leave.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_leave.ts#:~:text=AppLeaveHandler), [app_leave.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_leave.ts#:~:text=AppLeaveHandler), [app_leave.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_leave.ts#:~:text=AppLeaveHandler), [app_mount.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_mount.ts#:~:text=AppLeaveHandler), [app_mount.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_mount.ts#:~:text=AppLeaveHandler), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/index.ts#:~:text=AppLeaveHandler) | 8.8.0 | - - - ## @kbn/core-application-browser-internal | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath) | 8.8.0 | -| | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler) | 8.8.0 | -| | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler) | 8.8.0 | | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath) | 8.8.0 | -| | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=onAppLeave) | 8.8.0 | @@ -38,36 +26,44 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath) | 8.8.0 | -| | [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=onAppLeave) | 8.8.0 | | | [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath) | 8.8.0 | -| | [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=onAppLeave) | 8.8.0 | -## @kbn/core-apps-browser-internal +## @kbn/core-elasticsearch-server-internal | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts#:~:text=process) | 8.8.0 | -| | [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts#:~:text=process) | 8.8.0 | +| | [elasticsearch_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.ts#:~:text=legacy), [elasticsearch_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.test.ts#:~:text=legacy) | - | +| | [elasticsearch_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.ts#:~:text=legacy), [elasticsearch_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.test.ts#:~:text=legacy) | - | -## @kbn/core-elasticsearch-server-internal +## @kbn/core-lifecycle-browser | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [elasticsearch_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.ts#:~:text=legacy), [elasticsearch_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.test.ts#:~:text=legacy) | - | -| | [elasticsearch_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.ts#:~:text=legacy), [elasticsearch_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/elasticsearch/core-elasticsearch-server-internal/src/elasticsearch_service.test.ts#:~:text=legacy) | - | +| | [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart), [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart) | - | +| | [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart), [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart) | - | +| | [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart), [core_start.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts#:~:text=SavedObjectsStart) | - | + +## @kbn/core-lifecycle-browser-mocks + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [core_start.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser-mocks/src/core_start.mock.ts#:~:text=savedObjectsServiceMock), [core_start.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/lifecycle/core-lifecycle-browser-mocks/src/core_start.mock.ts#:~:text=savedObjectsServiceMock) | - | + -## @kbn/core-metrics-server-internal + +## @kbn/core-plugins-browser-internal | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [ops_metrics_collector.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts#:~:text=process), [get_ops_metrics_log.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts#:~:text=process), [get_ops_metrics_log.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts#:~:text=process) | 8.8.0 | -| | [ops_metrics_collector.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts#:~:text=process), [get_ops_metrics_log.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts#:~:text=process), [get_ops_metrics_log.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts#:~:text=process) | 8.8.0 | +| | [plugin_context.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts#:~:text=savedObjects), [plugin_context.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts#:~:text=savedObjects), [plugins_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts#:~:text=savedObjects) | - | +| | [plugin_context.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts#:~:text=savedObjects), [plugin_context.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts#:~:text=savedObjects), [plugins_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts#:~:text=savedObjects) | - | +| | [plugins_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts#:~:text=savedObjectsServiceMock), [plugins_service.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts#:~:text=savedObjectsServiceMock) | - | @@ -92,12 +88,199 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] +## @kbn/core-root-browser-internal + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [core_system.ts](https://github.com/elastic/kibana/tree/main/packages/core/root/core-root-browser-internal/src/core_system.ts#:~:text=savedObjects) | - | +| | [core_system.ts](https://github.com/elastic/kibana/tree/main/packages/core/root/core-root-browser-internal/src/core_system.ts#:~:text=savedObjects) | - | +| | [core_system.ts](https://github.com/elastic/kibana/tree/main/packages/core/root/core-root-browser-internal/src/core_system.ts#:~:text=SavedObjectsService), [core_system.ts](https://github.com/elastic/kibana/tree/main/packages/core/root/core-root-browser-internal/src/core_system.ts#:~:text=SavedObjectsService), [core_system.ts](https://github.com/elastic/kibana/tree/main/packages/core/root/core-root-browser-internal/src/core_system.ts#:~:text=SavedObjectsService) | - | + + + +## @kbn/core-saved-objects-api-browser + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject)+ 14 more | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SavedObject)+ 26 more | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsClientContract) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts#:~:text=SimpleSavedObject), [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts#:~:text=SimpleSavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts#:~:text=SimpleSavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SimpleSavedObject) | - | +| | [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts#:~:text=SavedObjectsCreateOptions), [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts#:~:text=SavedObjectsCreateOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsDeleteOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsDeleteOptions) | - | +| | [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts#:~:text=SavedObjectsBatchResponse), [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts#:~:text=SavedObjectsBatchResponse), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBatchResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsFindOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts#:~:text=ResolvedSimpleSavedObject), [bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts#:~:text=ResolvedSimpleSavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBulkUpdateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBulkUpdateObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsFindResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBulkCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBulkCreateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBulkUpdateOptions), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBulkUpdateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBulkResolveResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkResolveResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkResolveResponse), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBulkResolveResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/index.ts#:~:text=SavedObjectsBulkCreateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/index.ts#:~:text=SavedObjectsBulkCreateObject) | - | +| | [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts#:~:text=SavedObjectReference), [bulk_update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts#:~:text=SavedObjectReference), [bulk_update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts#:~:text=SavedObjectReference) | - | +| | [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts#:~:text=SavedObjectReference), [bulk_update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts#:~:text=SavedObjectReference), [bulk_update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts#:~:text=SavedObjectReference) | - | + + + +## @kbn/core-saved-objects-api-server + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts#:~:text=SavedObject), [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts#:~:text=SavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts#:~:text=SavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts#:~:text=SavedObject), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObject), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObject), [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts#:~:text=SavedObject), [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts#:~:text=SavedObject), [saved_objects_repository.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts#:~:text=SavedObject), [saved_objects_repository.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts#:~:text=SavedObject)+ 20 more | - | +| | [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts#:~:text=SavedObject), [base.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts#:~:text=SavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts#:~:text=SavedObject), [resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts#:~:text=SavedObject), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObject), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObject), [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts#:~:text=SavedObject), [find.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts#:~:text=SavedObject), [saved_objects_repository.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts#:~:text=SavedObject), [saved_objects_repository.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts#:~:text=SavedObject)+ 35 more | - | +| | [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts#:~:text=SavedObjectReference), [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts#:~:text=SavedObjectReference) | - | +| | [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts#:~:text=SavedObjectReference), [bulk_create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [update.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts#:~:text=SavedObjectReference), [create.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts#:~:text=SavedObjectReference) | - | + + + +## @kbn/core-saved-objects-api-server-internal + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts#:~:text=SavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts#:~:text=SavedObject), [internal_utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts#:~:text=SavedObject), [internal_utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts#:~:text=SavedObject), [internal_bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts#:~:text=SavedObject), [internal_bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [update_objects_spaces.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts#:~:text=SavedObject)+ 80 more | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts#:~:text=SavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts#:~:text=SavedObject), [internal_utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts#:~:text=SavedObject), [internal_utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts#:~:text=SavedObject), [internal_bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts#:~:text=SavedObject), [internal_bulk_resolve.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [collect_multi_namespace_references.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts#:~:text=SavedObject), [update_objects_spaces.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts#:~:text=SavedObject)+ 125 more | - | +| | [repository.test.common.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts#:~:text=SavedObjectReference), [repository.test.common.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference) | - | +| | [repository.test.common.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts#:~:text=SavedObjectReference), [repository.test.common.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference), [repository.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts#:~:text=SavedObjectReference) | - | + + + +## @kbn/core-saved-objects-browser + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/index.ts#:~:text=SavedObjectsStart) | - | +| | [contracts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts#:~:text=SavedObjectsClientContract), [contracts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts#:~:text=SavedObjectsClientContract) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/index.ts#:~:text=SavedObjectsStart) | - | +| | [contracts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts#:~:text=SavedObjectsClientContract), [contracts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts#:~:text=SavedObjectsClientContract) | - | + + + +## @kbn/core-saved-objects-browser-internal + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject)+ 46 more | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObject)+ 74 more | - | +| | [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObjectsClientContract), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsClientContract), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=SavedObjectsClientContract) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=create), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=create), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=delete), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkDelete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkDelete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkDelete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get)+ 9 more | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkGet) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve)+ 4 more | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkResolve) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=update), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=update), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkUpdate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkUpdate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkUpdate) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=save), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=save), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=save) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=delete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject) | - | +| | [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SavedObjectsClientContract), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsClientContract), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=SavedObjectsClientContract) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=create), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=create), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=create) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkCreate) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=delete), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=delete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkDelete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkDelete), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkDelete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=find) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=get)+ 9 more | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkGet) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=resolve)+ 4 more | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkResolve) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=update), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=update), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=update) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=bulkUpdate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkUpdate), [saved_objects_client.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts#:~:text=bulkUpdate) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SimpleSavedObject) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=save), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=save), [simple_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts#:~:text=save) | - | +| | [simple_saved_object.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts#:~:text=delete) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsDeleteOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBatchResponse) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkUpdateObject) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsFindResponse) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateOptions) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkCreateObject) | - | +| | [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkDeleteResponse), [saved_objects_client.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts#:~:text=SavedObjectsBulkDeleteResponse) | - | +| | [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart), [saved_objects_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts#:~:text=SavedObjectsStart) | - | + + + +## @kbn/core-saved-objects-browser-mocks + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject) | - | +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObject) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart), [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart) | - | +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObjectsClientContract) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=create) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkCreate) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=delete) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkDelete) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=find) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=get) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkGet) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=resolve) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkResolve) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=update) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkUpdate) | - | +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart), [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart) | - | +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObjectsClientContract), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SavedObjectsClientContract) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=create) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkCreate) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=delete) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkDelete) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=find) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=get) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkGet) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=resolve) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkResolve) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=update) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=bulkUpdate) | - | +| | [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject), [simple_saved_object.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts#:~:text=SimpleSavedObject) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart), [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsStart) | - | +| | [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsService), [saved_objects_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts#:~:text=SavedObjectsService) | - | + + + ## @kbn/core-saved-objects-common | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes), [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectAttributes) | - | -| | [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes), [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectAttributes) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectAttribute) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectAttributes) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectAttributeSingle) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/index.ts#:~:text=SavedObjectReference) | - | +| | [server_types.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts#:~:text=SavedObjectAttributes), [server_types.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts#:~:text=SavedObjectAttributes), [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes) | - | +| | [server_types.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts#:~:text=SavedObjectAttributes), [server_types.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts#:~:text=SavedObjectAttributes), [saved_objects.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts#:~:text=SavedObjectAttributes) | - | + + + +## @kbn/core-saved-objects-import-export-server-internal + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject)+ 262 more | - | +| | [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject), [check_origin_conflicts.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts#:~:text=SavedObject)+ 398 more | - | +| | [resolve_import_errors.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts#:~:text=SavedObjectReference), [resolve_import_errors.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts#:~:text=SavedObjectReference), [check_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts#:~:text=SavedObjectReference), [check_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts#:~:text=SavedObjectReference), [check_origin_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts#:~:text=SavedObjectReference), [check_origin_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts#:~:text=SavedObjectReference) | - | +| | [resolve_import_errors.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts#:~:text=SavedObjectReference), [resolve_import_errors.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts#:~:text=SavedObjectReference), [check_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts#:~:text=SavedObjectReference), [check_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts#:~:text=SavedObjectReference), [check_origin_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts#:~:text=SavedObjectReference), [check_origin_conflicts.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts#:~:text=SavedObjectReference) | - | @@ -105,29 +288,31 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=warning), [migration_logger.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts#:~:text=warning) | 8.8.0 | | | [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion)+ 12 more | - | -| | [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=warning), [migration_logger.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts#:~:text=warning) | 8.8.0 | | | [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion), [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=convertToMultiNamespaceTypeVersion)+ 12 more | - | -## @kbn/core-saved-objects-server-internal +## @kbn/core-saved-objects-server | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes) | - | -| | [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes) | - | -| | [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes) | - | +| | [encryption.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts#:~:text=SavedObject), [encryption.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/import.ts#:~:text=SavedObject)+ 24 more | - | +| | [encryption.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts#:~:text=SavedObject), [encryption.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [security.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [export.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/export.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/import.ts#:~:text=SavedObject)+ 41 more | - | +| | [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/index.ts#:~:text=SavedObjectAttributes) | - | +| | [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference), [serialization.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server/src/serialization.ts#:~:text=SavedObjectReference) | - | -## @kbn/core-status-server-internal +## @kbn/core-saved-objects-server-internal | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [status.ts](https://github.com/elastic/kibana/tree/main/packages/core/status/core-status-server-internal/src/routes/status.ts#:~:text=process), [status.ts](https://github.com/elastic/kibana/tree/main/packages/core/status/core-status-server-internal/src/routes/status.ts#:~:text=process) | 8.8.0 | -| | [status.ts](https://github.com/elastic/kibana/tree/main/packages/core/status/core-status-server-internal/src/routes/status.ts#:~:text=process), [status.ts](https://github.com/elastic/kibana/tree/main/packages/core/status/core-status-server-internal/src/routes/status.ts#:~:text=process) | 8.8.0 | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [import_dashboards.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts#:~:text=SavedObject), [import_dashboards.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts#:~:text=SavedObject), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObject)+ 16 more | - | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [collect_references_deep.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts#:~:text=SavedObject), [import_dashboards.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts#:~:text=SavedObject), [import_dashboards.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts#:~:text=SavedObject), [import.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts#:~:text=SavedObject), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObject)+ 29 more | - | +| | [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes) | - | +| | [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes), [collect_references_deep.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts#:~:text=SavedObjectAttributes) | - | @@ -140,12 +325,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] -## @kbn/core-usage-data-server-internal +## @kbn/core-ui-settings-server-internal | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process), [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process), [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process) | 8.8.0 | -| | [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process), [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process), [core_usage_data_service.ts](https://github.com/elastic/kibana/tree/main/packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts#:~:text=process) | 8.8.0 | +| | [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject) | - | +| | [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject), [transforms.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts#:~:text=SavedObject) | - | @@ -201,11 +386,10 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/plugin.ts#:~:text=authc) | - | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/plugin.ts#:~:text=authz) | - | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/plugin.ts#:~:text=index), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/plugin.ts#:~:text=index) | - | -| | [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes)+ 3 more | - | | | [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes)+ 3 more | - | | | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes)+ 3 more | - | | | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [actions_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/actions_client.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/actions/server/types.ts#:~:text=SavedObjectAttributes)+ 3 more | - | @@ -214,7 +398,9 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=metric) | - | +| | [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=SavedObjectAttribute), [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=SavedObjectAttribute) | - | | | [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=metric) | - | +| | [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=SavedObjectAttribute), [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=SavedObjectAttribute) | - | | | [to_editable_config.ts](https://github.com/elastic/kibana/tree/main/src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts#:~:text=metric) | - | @@ -226,6 +412,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [log_categorization_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx#:~:text=title), [log_categorization_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx#:~:text=title) | - | | | [log_categorization_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx#:~:text=title), [log_categorization_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx#:~:text=title) | - | | | [log_categorization_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/components/log_categorization/log_categorization_page.tsx#:~:text=title) | - | +| | [search_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/application/utils/search_utils.ts#:~:text=SimpleSavedObject), [search_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/application/utils/search_utils.ts#:~:text=SimpleSavedObject) | - | +| | [search_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/application/utils/search_utils.ts#:~:text=SimpleSavedObject), [search_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/aiops/public/application/utils/search_utils.ts#:~:text=SimpleSavedObject) | - | @@ -235,15 +423,21 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | ---------------|-----------|-----------| | | [wrap_search_source_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.ts#:~:text=create) | - | | | [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch) | - | +| | [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject)+ 4 more | - | +| | [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [bulk_disable.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject), [test_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts#:~:text=SavedObject)+ 11 more | - | | | [wrap_search_source_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.ts#:~:text=create) | - | | | [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/wrap_search_source_client.test.ts#:~:text=fetch) | - | | | [plugin.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/plugin.test.ts#:~:text=getKibanaFeatures) | 8.8.0 | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/plugin.ts#:~:text=license%24), [license_state.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/license_state.test.ts#:~:text=license%24), [license_state.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/lib/license_state.test.ts#:~:text=license%24) | 8.8.0 | | | [task.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/usage/task.ts#:~:text=index) | - | -| | [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes)+ 14 more | - | -| | [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes)+ 14 more | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectAttribute) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttributes) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference) | - | +| | [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes)+ 10 more | - | | | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes), [migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts#:~:text=SavedObjectAttributes)+ 14 more | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectAttribute) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes), [rule.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/common/rule.ts#:~:text=SavedObjectAttributes)+ 14 more | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts#:~:text=SavedObjectReference) | - | | | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/alerting/server/saved_objects/index.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -252,6 +446,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts#:~:text=SavedObject), [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts#:~:text=SavedObject) | - | +| | [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts#:~:text=SavedObject), [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts#:~:text=SavedObject), [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts#:~:text=SavedObject) | - | | | [create_static_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts#:~:text=title), [create_static_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts#:~:text=title) | - | | | [create_static_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts#:~:text=title), [create_static_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts#:~:text=title) | - | | | [create_static_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/apm/server/routes/data_view/create_static_data_view.ts#:~:text=title) | - | @@ -267,6 +463,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [use_upload_workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts#:~:text=SavedObject), [use_upload_workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject)+ 2 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [use_upload_workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts#:~:text=SavedObject), [use_upload_workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/workpad.ts#:~:text=SavedObject)+ 8 more | - | | | [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [datasource_component.js](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/datasource/datasource_component.js#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title)+ 8 more | - | | | [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [datasource_component.js](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/datasource/datasource_component.js#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title)+ 8 more | - | | | [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.component.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [es_data_view_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/es_data_view_select/es_data_view_select.tsx#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/data_views.ts#:~:text=title), [datasource_component.js](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/datasource/datasource_component.js#:~:text=title) | - | @@ -281,10 +479,21 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [setup_expressions.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/setup_expressions.ts#:~:text=getTypes), [application.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/application.tsx#:~:text=getTypes), [functions.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/functions/functions.ts#:~:text=getTypes) | - | | | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/server/demodata/index.ts#:~:text=context), [embeddable.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts#:~:text=context), [esdocs.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/esdocs.ts#:~:text=context), [escount.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/browser/escount.ts#:~:text=context), [filters.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/common/functions/filters.ts#:~:text=context), [neq.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/common/neq.ts#:~:text=context), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/server/pointseries/index.ts#:~:text=context) | - | | | [home.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/home.component.tsx#:~:text=KibanaPageTemplate), [home.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/home.component.tsx#:~:text=KibanaPageTemplate), [home.component.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/components/home/home.component.tsx#:~:text=KibanaPageTemplate) | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes) | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsClientContract), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsClientContract) | - | +| | [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes) | - | +| | [saved_lens.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts#:~:text=SavedObjectReference), [saved_lens.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts#:~:text=SavedObjectReference), [saved_map.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts#:~:text=SavedObjectReference), [saved_map.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts#:~:text=SavedObjectReference), [saved_search.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts#:~:text=SavedObjectReference), [saved_search.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts#:~:text=SavedObjectReference), [saved_visualization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts#:~:text=SavedObjectReference), [saved_visualization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts#:~:text=SavedObjectReference), [embeddable.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts#:~:text=SavedObjectReference), [embeddable.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts#:~:text=SavedObjectReference) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/platform.ts#:~:text=savedObjects), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/platform.ts#:~:text=savedObjects) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart) | - | +| | [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes) | - | | | [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/saved_objects/workpad.ts#:~:text=convertToMultiNamespaceTypeVersion), [custom_element.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/saved_objects/custom_element.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/platform.ts#:~:text=savedObjects), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/kibana/platform.ts#:~:text=savedObjects) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsClientContract), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsClientContract) | - | +| | [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject), [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/workpad.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart), [platform.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/public/services/platform.ts#:~:text=SavedObjectsStart) | - | | | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/shareable_runtime/types.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/custom_elements/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes), [find.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/routes/workpad/find.ts#:~:text=SavedObjectAttributes) | - | +| | [saved_lens.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts#:~:text=SavedObjectReference), [saved_lens.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts#:~:text=SavedObjectReference), [saved_map.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts#:~:text=SavedObjectReference), [saved_map.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts#:~:text=SavedObjectReference), [saved_search.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts#:~:text=SavedObjectReference), [saved_search.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts#:~:text=SavedObjectReference), [saved_visualization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts#:~:text=SavedObjectReference), [saved_visualization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts#:~:text=SavedObjectReference), [embeddable.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts#:~:text=SavedObjectReference), [embeddable.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts#:~:text=SavedObjectReference) | - | | | [workpad.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/saved_objects/workpad.ts#:~:text=convertToMultiNamespaceTypeVersion), [custom_element.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/canvas/server/saved_objects/custom_element.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -293,7 +502,19 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObject), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject)+ 14 more | - | +| | [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObject), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/utils.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject), [authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/authorization/authorization.ts#:~:text=SavedObject)+ 26 more | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=find) | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject)+ 1 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference) | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=savedObjects), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/plugin.tsx#:~:text=savedObjects) | - | | | [cases.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/cases.ts#:~:text=convertToMultiNamespaceTypeVersion), [configure.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/configure.ts#:~:text=convertToMultiNamespaceTypeVersion), [comments.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/comments.ts#:~:text=convertToMultiNamespaceTypeVersion), [user_actions.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/user_actions.ts#:~:text=convertToMultiNamespaceTypeVersion), [connector_mappings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/connector_mappings.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=savedObjects), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/plugin.tsx#:~:text=savedObjects) | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=find) | - | +| | [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject), [saved_objects_finder.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx#:~:text=SimpleSavedObject)+ 1 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/common/ui/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/attachment_framework/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference), [so_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/services/so_references.ts#:~:text=SavedObjectReference) | - | | | [cases.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/cases.ts#:~:text=convertToMultiNamespaceTypeVersion), [configure.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/configure.ts#:~:text=convertToMultiNamespaceTypeVersion), [comments.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/comments.ts#:~:text=convertToMultiNamespaceTypeVersion), [user_actions.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/user_actions.ts#:~:text=convertToMultiNamespaceTypeVersion), [connector_mappings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cases/server/saved_object_types/connector_mappings.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -311,6 +532,16 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [overview_tab.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/findings/findings_flyout/overview_tab.tsx#:~:text=indexPatternId) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=find) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=get) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SavedObjectsFindOptions), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SavedObjectsFindOptions) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=savedObjects) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=savedObjects) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=find) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=get) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SimpleSavedObject) | - | +| | [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SavedObjectsFindOptions), [use_csp_rules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts#:~:text=SavedObjectsFindOptions) | - | @@ -330,6 +561,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/data_views/data_views.story.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/data_views/data_views.story.ts#:~:text=title) | - | | | [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/data_views/data_views.story.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/data_views/data_views.story.ts#:~:text=title) | - | | | [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [options_list_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/options_list/options_list_service.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/public/services/data_views/data_views.story.ts#:~:text=title) | - | +| | [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [control_group_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/control_group/control_group_persistable_state.ts#:~:text=SavedObjectReference)+ 2 more | - | +| | [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [options_list_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/options_list/options_list_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [range_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/range_slider/range_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [time_slider_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/time_slider/time_slider_persistable_state.ts#:~:text=SavedObjectReference), [control_group_persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/controls/common/control_group/control_group_persistable_state.ts#:~:text=SavedObjectReference)+ 2 more | - | @@ -337,11 +570,31 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=AppLeaveHandler) | 8.8.0 | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObject) | - | | | [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=appBasePath) | 8.8.0 | -| | [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=onAppLeave) | 8.8.0 | | | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=AsyncPlugin) | 8.8.0 | -| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObjectAttributes) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsClientContract) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SimpleSavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsDeleteOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBatchResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsFindOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBulkUpdateObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsFindResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBulkCreateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBulkUpdateOptions) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBulkResolveResponse) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsBulkCreateObject) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectsStart), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=SavedObjectsStart) | - | +| | [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=savedObjectsServiceMock) | - | +| | [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=simpleSavedObjectMock) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectAttributeSingle), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObjectAttributeSingle) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectAttribute), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObjectAttribute) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObjectAttributes), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=SavedObjectAttributes) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=SavedObjectReference), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/types/index.ts#:~:text=SavedObjectReference) | - | @@ -360,29 +613,74 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/data/types.ts#:~:text=fieldFormats), [data_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/data/data_service.ts#:~:text=fieldFormats) | - | | | [save_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_container/embeddable/api/overlays/save_modal.tsx#:~:text=SavedObjectSaveModal), [save_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_container/embeddable/api/overlays/save_modal.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | | | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject) | 8.8.0 | -| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/types.ts#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [find_by_value_embeddables.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/find_by_value_embeddables.ts#:~:text=SavedObjectAttributes)+ 11 more | - | -| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [find_by_value_embeddables.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/find_by_value_embeddables.ts#:~:text=SavedObjectAttributes)+ 11 more | - | -| | [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning), [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning) | 8.8.0 | +| | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectsClientContract), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectsClientContract), [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=SavedObjectsClientContract), [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=SavedObjectsClientContract)+ 4 more | - | +| | [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=create), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=create) | - | +| | [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=delete) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=find), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=find), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=find), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=find) | - | +| | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=get) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=bulkGet) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=resolve) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SimpleSavedObject), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SimpleSavedObject), [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=SimpleSavedObject), [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=SimpleSavedObject) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=ResolvedSimpleSavedObject), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes)+ 2 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/bwc/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/bwc/types.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference) | - | +| | [dashboard_saved_object_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object_service.ts#:~:text=savedObjects), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/index.ts#:~:text=savedObjects), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/index.ts#:~:text=savedObjects) | - | +| | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart) | - | +| | [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [find_by_value_embeddables.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/find_by_value_embeddables.ts#:~:text=SavedObjectAttributes), [find_by_value_embeddables.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/find_by_value_embeddables.ts#:~:text=SavedObjectAttributes) | - | | | [dashboard_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/dashboard_saved_object.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/types.ts#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [migrate_extract_panel_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry_collection_task.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [dashboard_telemetry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/dashboard_telemetry.ts#:~:text=SavedObjectAttributes), [find_by_value_embeddables.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/usage/find_by_value_embeddables.ts#:~:text=SavedObjectAttributes)+ 11 more | - | -| | [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning), [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning) | 8.8.0 | +| | [dashboard_saved_object_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object_service.ts#:~:text=savedObjects), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/index.ts#:~:text=savedObjects), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/index.ts#:~:text=savedObjects) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectsClientContract), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectsClientContract), [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=SavedObjectsClientContract), [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=SavedObjectsClientContract)+ 4 more | - | +| | [save_dashboard_state_to_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts#:~:text=create), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=create) | - | +| | [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=delete) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=find), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=find), [check_for_duplicate_dashboard_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts#:~:text=find), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=find) | - | +| | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=get) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=bulkGet) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=resolve) | - | +| | [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SimpleSavedObject), [find_dashboard_saved_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts#:~:text=SimpleSavedObject), [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=SimpleSavedObject), [dashboard_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx#:~:text=SimpleSavedObject) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=ResolvedSimpleSavedObject), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObjectsStart) | - | +| | [dashboard_saved_object.stub.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object.stub.ts#:~:text=savedObjectsServiceMock), [dashboard_saved_object.stub.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object.stub.ts#:~:text=savedObjectsServiceMock) | - | +| | [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [load_dashboard_state_from_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectAttributes)+ 11 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/bwc/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/bwc/types.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_saved_object_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference), [dashboard_container_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts#:~:text=SavedObjectReference) | - | | | [dashboard_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/dashboard_saved_object.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +## dashboardEnhanced + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=find) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=get) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=SimpleSavedObject), [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=SimpleSavedObject) | - | +| | [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference), [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference), [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=savedObjects), [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=savedObjects) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=savedObjects), [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=savedObjects) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=find) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=get) | - | +| | [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=SimpleSavedObject), [collect_config_container.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx#:~:text=SimpleSavedObject) | - | +| | [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference), [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference), [dashboard_drilldown_persistable_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts#:~:text=SavedObjectReference) | - | + + + ## data | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [inspector_stats.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inspect/inspector_stats.ts#:~:text=title), [response_writer.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/tabify/response_writer.ts#:~:text=title), [field.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/param_types/field.ts#:~:text=title), [get_display_value.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts#:~:text=title), [painless_error.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/errors/painless_error.tsx#:~:text=title), [agg_config.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/agg_config.test.ts#:~:text=title), [_terms_other_bucket_helper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/buckets/_terms_other_bucket_helper.test.ts#:~:text=title)+ 6 more | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/index.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts#:~:text=SavedObject)+ 30 more | - | | | [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [inspector_stats.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inspect/inspector_stats.ts#:~:text=title), [response_writer.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/tabify/response_writer.ts#:~:text=title), [field.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/param_types/field.ts#:~:text=title), [get_display_value.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts#:~:text=title), [painless_error.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/errors/painless_error.tsx#:~:text=title), [agg_config.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/agg_config.test.ts#:~:text=title), [_terms_other_bucket_helper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/buckets/_terms_other_bucket_helper.test.ts#:~:text=title)+ 6 more | - | | | [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [kibana_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.test.ts#:~:text=title), [inspector_stats.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inspect/inspector_stats.ts#:~:text=title), [response_writer.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/tabify/response_writer.ts#:~:text=title), [field.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/param_types/field.ts#:~:text=title), [get_display_value.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts#:~:text=title), [painless_error.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/errors/painless_error.tsx#:~:text=title), [agg_config.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/agg_config.test.ts#:~:text=title), [_terms_other_bucket_helper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/aggs/buckets/_terms_other_bucket_helper.test.ts#:~:text=title)+ 6 more | - | | | [get_columns.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/get_columns.tsx#:~:text=RedirectAppLinks), [get_columns.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/get_columns.tsx#:~:text=RedirectAppLinks), [get_columns.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/get_columns.tsx#:~:text=RedirectAppLinks), [connected_search_session_indicator.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/session_indicator/connected_search_session_indicator/connected_search_session_indicator.tsx#:~:text=RedirectAppLinks), [connected_search_session_indicator.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/session_indicator/connected_search_session_indicator/connected_search_session_indicator.tsx#:~:text=RedirectAppLinks), [connected_search_session_indicator.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/session_indicator/connected_search_session_indicator/connected_search_session_indicator.tsx#:~:text=RedirectAppLinks) | - | | | [data_table.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/utils/table_inspector_view/components/data_table.tsx#:~:text=executeTriggerActions), [data_table.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/utils/table_inspector_view/components/data_table.tsx#:~:text=executeTriggerActions) | - | | | [session_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/search/session/session_service.ts#:~:text=authc) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/index.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/index.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [route_handler_context.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/query/route_handler_context.test.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts#:~:text=SavedObject)+ 10 more | - | +| | [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.ts#:~:text=SavedObjectReference), [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [inject_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inject_references.ts#:~:text=SavedObjectReference), [inject_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inject_references.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference)+ 5 more | - | +| | [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/expressions/kibana_context.ts#:~:text=savedObjects) | - | | | [query.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/saved_objects/query.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/public/search/expressions/kibana_context.ts#:~:text=savedObjects) | - | +| | [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.ts#:~:text=SavedObjectReference), [kibana_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/expressions/kibana_context.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [extract_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/extract_references.ts#:~:text=SavedObjectReference), [inject_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inject_references.ts#:~:text=SavedObjectReference), [inject_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/search/search_source/inject_references.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference), [persistable_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/common/query/filters/persistable_state.ts#:~:text=SavedObjectReference)+ 5 more | - | | | [query.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data/server/saved_objects/query.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -410,6 +708,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/index.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject)+ 44 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/index.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=SavedObject)+ 44 more | - | | | [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=title), [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=title), [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=title), [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=title), [update_data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/server/rest_api_routes/update_data_view.ts#:~:text=title), [update_data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/server/rest_api_routes/update_data_view.ts#:~:text=title), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=title) | - | | | [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=flattenHit) | - | | | [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=removeScriptedField) | - | @@ -420,7 +720,32 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=removeScriptedField) | - | | | [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getNonScriptedFields) | - | | | [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=getScriptedFields), [data_view.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.ts#:~:text=getScriptedFields), [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_views.ts#:~:text=getScriptedFields), [register_index_pattern_usage_collection.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/server/register_index_pattern_usage_collection.ts#:~:text=getScriptedFields), [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getScriptedFields), [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getScriptedFields), [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getScriptedFields), [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getScriptedFields), [data_view.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/data_view.test.ts#:~:text=getScriptedFields) | - | +| | [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=SavedObjectsClientContract), [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=SavedObjectsClientContract), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsClientContract), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsClientContract) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=create) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=delete) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=find) | - | +| | [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=get) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=update) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SimpleSavedObject), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsCreateOptions), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsUpdateOptions), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [load_index_pattern.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/expressions/load_index_pattern.ts#:~:text=SavedObjectReference), [load_index_pattern.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/expressions/load_index_pattern.ts#:~:text=SavedObjectReference), [persistable_state.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/persistable_state.test.ts#:~:text=SavedObjectReference), [persistable_state.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/persistable_state.test.ts#:~:text=SavedObjectReference) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/plugin.ts#:~:text=savedObjects) | - | | | [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/server/saved_objects/data_views.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/plugin.ts#:~:text=savedObjects) | - | +| | [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=SavedObjectsClientContract), [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=SavedObjectsClientContract), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsClientContract), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsClientContract) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=create) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=delete) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=find) | - | +| | [get_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/lib/get_title.ts#:~:text=get) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=resolve) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=update) | - | +| | [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SimpleSavedObject), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsCreateOptions), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsCreateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsUpdateOptions), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/types.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsUpdateOptions), [saved_objects_client_wrapper.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.ts#:~:text=SavedObjectsUpdateOptions) | - | +| | [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=savedObjectsServiceMock), [saved_objects_client_wrapper.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/public/saved_objects_client_wrapper.test.ts#:~:text=savedObjectsServiceMock) | - | +| | [load_index_pattern.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/expressions/load_index_pattern.ts#:~:text=SavedObjectReference), [load_index_pattern.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/expressions/load_index_pattern.ts#:~:text=SavedObjectReference), [persistable_state.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/persistable_state.test.ts#:~:text=SavedObjectReference), [persistable_state.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/common/data_views/persistable_state.test.ts#:~:text=SavedObjectReference) | - | | | [data_views.ts](https://github.com/elastic/kibana/tree/main/src/plugins/data_views/server/saved_objects/data_views.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -434,6 +759,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [use_data_visualizer_grid_data.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/hooks/use_data_visualizer_grid_data.ts#:~:text=title), [index_data_visualizer_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/index_data_visualizer_view/index_data_visualizer_view.tsx#:~:text=title), [use_data_visualizer_grid_data.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/hooks/use_data_visualizer_grid_data.ts#:~:text=title), [index_data_visualizer_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/index_data_visualizer_view/index_data_visualizer_view.tsx#:~:text=title) | - | | | [use_data_visualizer_grid_data.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/hooks/use_data_visualizer_grid_data.ts#:~:text=title), [index_data_visualizer_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/index_data_visualizer_view/index_data_visualizer_view.tsx#:~:text=title) | - | | | [results_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/common/components/results_links/results_links.tsx#:~:text=indexPatternId), [actions_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/components/actions_panel/actions_panel.tsx#:~:text=indexPatternId) | - | +| | [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=get) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/common/types/index.ts#:~:text=SimpleSavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/common/types/index.ts#:~:text=SimpleSavedObject), [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=SimpleSavedObject), [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=SimpleSavedObject) | - | +| | [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=savedObjects) | - | +| | [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=savedObjects) | - | +| | [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=get) | - | +| | [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/common/types/index.ts#:~:text=SimpleSavedObject), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/common/types/index.ts#:~:text=SimpleSavedObject), [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=SimpleSavedObject), [index_data_visualizer.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx#:~:text=SimpleSavedObject) | - | @@ -443,6 +774,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | ---------------|-----------|-----------| | | [saved_search_embeddable.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx#:~:text=create), [saved_search_embeddable.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx#:~:text=create) | - | | | [discover_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/services/discover_state.ts#:~:text=syncQueryStateWithUrl), [discover_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/services/discover_state.ts#:~:text=syncQueryStateWithUrl) | - | +| | [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject) | - | +| | [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject), [get_layout_props.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts#:~:text=SavedObject) | - | | | [use_text_based_query_language.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts#:~:text=title), [use_text_based_query_language.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/hooks/use_text_based_query_language.ts#:~:text=title) | - | | | [saved_search_embeddable.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx#:~:text=create), [saved_search_embeddable.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx#:~:text=create) | - | | | [fetch_hits_in_interval.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/context/utils/fetch_hits_in_interval.ts#:~:text=EsQuerySearchAfter), [fetch_hits_in_interval.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/context/utils/fetch_hits_in_interval.ts#:~:text=EsQuerySearchAfter), [get_es_query_search_after.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/context/utils/get_es_query_search_after.ts#:~:text=EsQuerySearchAfter), [get_es_query_search_after.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/context/utils/get_es_query_search_after.ts#:~:text=EsQuerySearchAfter), [get_es_query_search_after.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/context/utils/get_es_query_search_after.ts#:~:text=EsQuerySearchAfter) | - | @@ -451,7 +784,9 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [on_save_search.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx#:~:text=SavedObjectSaveModal), [on_save_search.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | | | [saved_search_embeddable.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx#:~:text=executeTriggerActions), [search_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/search_embeddable_factory.ts#:~:text=executeTriggerActions), [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/plugin.tsx#:~:text=executeTriggerActions) | - | | | [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric) | - | +| | [search_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/search_embeddable_factory.ts#:~:text=savedObjects), [open_search_panel.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/top_nav/open_search_panel.tsx#:~:text=savedObjects), [persist_saved_search.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/utils/persist_saved_search.ts#:~:text=savedObjects), [use_discover_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/hooks/use_discover_state.ts#:~:text=savedObjects), [discover_main_route.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/discover_main_route.tsx#:~:text=savedObjects), [discover_main_route.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/discover_main_route.tsx#:~:text=savedObjects) | - | | | [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric) | - | +| | [search_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/embeddable/search_embeddable_factory.ts#:~:text=savedObjects), [open_search_panel.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/components/top_nav/open_search_panel.tsx#:~:text=savedObjects), [persist_saved_search.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/utils/persist_saved_search.ts#:~:text=savedObjects), [use_discover_state.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/hooks/use_discover_state.ts#:~:text=savedObjects), [discover_main_route.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/discover_main_route.tsx#:~:text=savedObjects), [discover_main_route.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/discover/public/application/main/discover_main_route.tsx#:~:text=savedObjects) | - | | | [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric), [ui_settings.ts](https://github.com/elastic/kibana/tree/main/src/plugins/discover/server/ui_settings.ts#:~:text=metric) | - | @@ -470,9 +805,14 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | ---------------|-----------|-----------| | | [attribute_service.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx#:~:text=SavedObjectSaveModal), [attribute_service.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | | | [container.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/tests/container.test.ts#:~:text=executeTriggerActions), [container.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/tests/container.test.ts#:~:text=executeTriggerActions), [container.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/tests/container.test.ts#:~:text=executeTriggerActions), [container.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/tests/container.test.ts#:~:text=executeTriggerActions), [explicit_input.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/tests/explicit_input.test.ts#:~:text=executeTriggerActions) | - | +| | [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject) | - | | | [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes) | - | -| | [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes) | - | +| | [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [inject.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/inject.ts#:~:text=SavedObjectReference), [inject.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/inject.ts#:~:text=SavedObjectReference) | - | +| | [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/plugin.tsx#:~:text=savedObjects) | - | +| | [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/plugin.tsx#:~:text=savedObjects) | - | +| | [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SimpleSavedObject) | - | | | [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [add_panel_flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [default_embeddable_factory_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/public/types.ts#:~:text=SavedObjectAttributes) | - | +| | [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [migrate_base_input.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/migrate_base_input.ts#:~:text=SavedObjectReference), [inject.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/inject.ts#:~:text=SavedObjectReference), [inject.ts](https://github.com/elastic/kibana/tree/main/src/plugins/embeddable/common/lib/inject.ts#:~:text=SavedObjectReference) | - | @@ -480,6 +820,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject) | - | +| | [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject), [saved_objects_encryption_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts#:~:text=SavedObject) | - | | | [encryption_key_rotation_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/crypto/encryption_key_rotation_service.ts#:~:text=authc), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/saved_objects/index.ts#:~:text=authc) | - | | | [create_migration.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/create_migration.ts#:~:text=convertToMultiNamespaceTypeVersion), [create_migration.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/create_migration.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | | | [create_migration.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/create_migration.ts#:~:text=convertToMultiNamespaceTypeVersion), [create_migration.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/encrypted_saved_objects/server/create_migration.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -492,9 +834,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | ---------------|-----------|-----------| | | [account_settings.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/account_settings/account_settings.tsx#:~:text=uiApi), [account_settings.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/account_settings/account_settings.tsx#:~:text=uiApi), [account_settings.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/account_settings/account_settings.tsx#:~:text=uiApi), [account_settings.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/account_settings/account_settings.tsx#:~:text=uiApi) | - | | | [check_access.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/lib/check_access.ts#:~:text=authz), [check_access.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/lib/check_access.ts#:~:text=authz), [check_access.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/lib/check_access.ts#:~:text=authz) | - | -| | [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes) | - | | | [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes) | - | -| | [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes) | - | +| | [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes), [telemetry.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts#:~:text=SavedObjectAttributes) | - | @@ -514,10 +855,30 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] +## expressions + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference)+ 3 more | - | +| | [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expression_function.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/expression_functions/expression_function.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [expressions_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/service/expressions_services.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference), [executor.ts](https://github.com/elastic/kibana/tree/main/src/plugins/expressions/common/executor/executor.ts#:~:text=SavedObjectReference)+ 3 more | - | + + + +## fileUpload + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/file_upload/public/kibana_services.ts#:~:text=savedObjects) | - | +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/file_upload/public/kibana_services.ts#:~:text=savedObjects) | - | + + + ## fleet | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject)+ 4 more | - | +| | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [action.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/services/agents/action.mock.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObject)+ 11 more | - | | | [filter_dataset.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx#:~:text=title), [filter_log_level.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx#:~:text=title), [query_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx#:~:text=title), [filter_dataset.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx#:~:text=title), [filter_log_level.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx#:~:text=title), [query_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx#:~:text=title) | - | | | [filter_dataset.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx#:~:text=title), [filter_log_level.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx#:~:text=title), [query_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx#:~:text=title), [filter_dataset.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx#:~:text=title), [filter_log_level.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx#:~:text=title), [query_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx#:~:text=title) | - | | | [filter_dataset.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_dataset.tsx#:~:text=title), [filter_log_level.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/filter_log_level.tsx#:~:text=title), [query_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/agent_logs/query_bar.tsx#:~:text=title) | - | @@ -527,10 +888,28 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/plugin.ts#:~:text=disabled) | 8.8.0 | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/server/plugin.ts#:~:text=disabled) | 8.8.0 | | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/index.tsx#:~:text=appBasePath) | 8.8.0 | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=bulkResolve) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts#:~:text=SimpleSavedObject) | - | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=ResolvedSimpleSavedObject), [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=ResolvedSimpleSavedObject) | - | | | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes) | - | -| | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes) | - | +| | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference) | - | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=savedObjects) | - | | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/index.tsx#:~:text=appBasePath) | 8.8.0 | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=savedObjects) | - | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=bulkResolve) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts#:~:text=SimpleSavedObject) | - | +| | [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=ResolvedSimpleSavedObject), [assets.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx#:~:text=ResolvedSimpleSavedObject) | - | | | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes), [settings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/settings.ts#:~:text=SavedObjectAttributes) | - | +| | [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference), [epm.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/fleet/common/types/models/epm.ts#:~:text=SavedObjectReference) | - | + + + +## globalSearchProviders + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [map_object_to_result.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts#:~:text=SavedObjectReference), [map_object_to_result.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts#:~:text=SavedObjectReference) | - | +| | [map_object_to_result.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts#:~:text=SavedObjectReference), [map_object_to_result.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts#:~:text=SavedObjectReference) | - | @@ -547,10 +926,27 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [deserialize.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/deserialize.ts#:~:text=getNonScriptedFields), [datasource.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/state_management/datasource.test.ts#:~:text=getNonScriptedFields), [deserialize.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/deserialize.test.ts#:~:text=getNonScriptedFields), [deserialize.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/deserialize.test.ts#:~:text=getNonScriptedFields) | - | | | [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/save_modal.tsx#:~:text=SavedObjectSaveModal), [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/save_modal.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/server/plugin.ts#:~:text=license%24) | 8.8.0 | +| | [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/save_modal.tsx#:~:text=SavedObjectsClientContract), [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/save_modal.tsx#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/state_management/store.ts#:~:text=SavedObjectsClientContract), [store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/state_management/store.ts#:~:text=SavedObjectsClientContract), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=SavedObjectsClientContract)+ 5 more | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=create), [saved_workspace_utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts#:~:text=create) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=delete) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=find), [saved_workspace_utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts#:~:text=find) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=resolve) | - | +| | [app_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/app_state.ts#:~:text=SimpleSavedObject), [app_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/app_state.ts#:~:text=SimpleSavedObject) | - | +| | [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject) | - | | | [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes) | - | -| | [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes) | - | +| | [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [persistence.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/persistence.ts#:~:text=SavedObjectReference), [persistence.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/persistence.ts#:~:text=SavedObjectReference) | - | +| | [source_picker.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/source_picker.tsx#:~:text=savedObjects), [source_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/source_modal.tsx#:~:text=savedObjects), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/plugin.ts#:~:text=savedObjects), [search_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/search_bar.tsx#:~:text=savedObjects), [guidance_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/guidance_panel/guidance_panel.tsx#:~:text=savedObjects) | - | | | [graph_workspace.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/server/saved_objects/graph_workspace.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [source_picker.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/source_picker.tsx#:~:text=savedObjects), [source_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/source_modal.tsx#:~:text=savedObjects), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/plugin.ts#:~:text=savedObjects), [search_bar.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/search_bar.tsx#:~:text=savedObjects), [guidance_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/components/guidance_panel/guidance_panel.tsx#:~:text=savedObjects) | - | +| | [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/save_modal.tsx#:~:text=SavedObjectsClientContract), [save_modal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/save_modal.tsx#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectsClientContract), [store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/state_management/store.ts#:~:text=SavedObjectsClientContract), [store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/state_management/store.ts#:~:text=SavedObjectsClientContract), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=SavedObjectsClientContract)+ 5 more | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=create), [saved_workspace_utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts#:~:text=create) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=delete) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=find), [saved_workspace_utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts#:~:text=find) | - | +| | [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=resolve) | - | +| | [app_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/app_state.ts#:~:text=SimpleSavedObject), [app_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/app_state.ts#:~:text=SimpleSavedObject) | - | +| | [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject), [use_workspace_loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/use_workspace_loader.ts#:~:text=ResolvedSimpleSavedObject) | - | | | [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes), [saved_workspace_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts#:~:text=SavedObjectAttributes) | - | +| | [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [saved_workspace_references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts#:~:text=SavedObjectReference), [persistence.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/persistence.ts#:~:text=SavedObjectReference), [persistence.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/public/types/persistence.ts#:~:text=SavedObjectReference) | - | | | [graph_workspace.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/graph/server/saved_objects/graph_workspace.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -559,8 +955,16 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject) | - | +| | [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject), [sample_data_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/server/services/sample_data/sample_data_registry.ts#:~:text=SavedObject) | - | | | [tutorial_directory.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial_directory.js#:~:text=KibanaPageTemplate), [tutorial_directory.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial_directory.js#:~:text=KibanaPageTemplate), [tutorial_directory.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial_directory.js#:~:text=KibanaPageTemplate), [tutorial.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial/tutorial.js#:~:text=KibanaPageTemplate), [tutorial.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial/tutorial.js#:~:text=KibanaPageTemplate), [tutorial.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial/tutorial.js#:~:text=KibanaPageTemplate), [tutorial.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/tutorial/tutorial.js#:~:text=KibanaPageTemplate) | - | | | [add_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/add_data/add_data.tsx#:~:text=RedirectAppLinks), [add_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/add_data/add_data.tsx#:~:text=RedirectAppLinks), [add_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/add_data/add_data.tsx#:~:text=RedirectAppLinks), [manage_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/manage_data/manage_data.tsx#:~:text=RedirectAppLinks), [manage_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/manage_data/manage_data.tsx#:~:text=RedirectAppLinks), [manage_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/manage_data/manage_data.tsx#:~:text=RedirectAppLinks), [manage_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/manage_data/manage_data.tsx#:~:text=RedirectAppLinks), [manage_data.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/manage_data/manage_data.tsx#:~:text=RedirectAppLinks), [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/application.tsx#:~:text=RedirectAppLinks), [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/application.tsx#:~:text=RedirectAppLinks)+ 1 more | - | +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/kibana_services.ts#:~:text=SavedObjectsClientContract), [kibana_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/kibana_services.ts#:~:text=SavedObjectsClientContract) | - | +| | [home_app.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/home_app.js#:~:text=bulkCreate) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/plugin.ts#:~:text=savedObjects) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/plugin.ts#:~:text=savedObjects) | - | +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/kibana_services.ts#:~:text=SavedObjectsClientContract), [kibana_services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/kibana_services.ts#:~:text=SavedObjectsClientContract) | - | +| | [home_app.js](https://github.com/elastic/kibana/tree/main/src/plugins/home/public/application/components/home_app.js#:~:text=bulkCreate) | - | @@ -589,8 +993,25 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [resolved_log_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/log_views/resolved_log_view.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [use_data_view.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts#:~:text=title), [resolved_log_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/log_views/resolved_log_view.ts#:~:text=title)+ 8 more | - | | | [resolved_log_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/log_views/resolved_log_view.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [use_data_view.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts#:~:text=title), [resolved_log_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/log_views/resolved_log_view.ts#:~:text=title)+ 8 more | - | | | [resolved_log_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/log_views/resolved_log_view.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [validation_errors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/logs/settings/validation_errors.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [index_patterns.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/common/dependency_mocks/index_patterns.ts#:~:text=title), [use_data_view.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/pages/metrics/hosts/hooks/use_data_view.test.ts#:~:text=title) | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=create) | - | +| | [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=delete) | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=find), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=find) | - | +| | [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=get) | - | +| | [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=update) | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SimpleSavedObject), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SimpleSavedObject), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SimpleSavedObject), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SimpleSavedObject), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SimpleSavedObject), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SimpleSavedObject), [saved_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx#:~:text=SimpleSavedObject), [saved_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx#:~:text=SimpleSavedObject) | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectsCreateOptions) | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectsBatchResponse), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectsBatchResponse) | - | | | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes)+ 2 more | - | -| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes)+ 2 more | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=savedObjects), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=savedObjects), [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=savedObjects), [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=savedObjects), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=savedObjects), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=savedObjects), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=savedObjects)+ 1 more | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=savedObjects), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=savedObjects), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=savedObjects), [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=savedObjects), [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=savedObjects), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=savedObjects), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=savedObjects), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=savedObjects)+ 1 more | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=create) | - | +| | [use_delete_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx#:~:text=delete) | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=find), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=find) | - | +| | [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=get) | - | +| | [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=update) | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SimpleSavedObject), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SimpleSavedObject), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SimpleSavedObject), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SimpleSavedObject), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SimpleSavedObject), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SimpleSavedObject), [saved_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx#:~:text=SimpleSavedObject), [saved_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx#:~:text=SimpleSavedObject) | - | +| | [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectsCreateOptions), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectsCreateOptions) | - | +| | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectsBatchResponse), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectsBatchResponse) | - | | | [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_find_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_create_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_get_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes), [use_update_saved_object.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx#:~:text=SavedObjectAttributes)+ 2 more | - | @@ -618,12 +1039,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] -## kibanaUsageCollection +## kibanaUtils | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [ops_stats_collector.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts#:~:text=process) | 8.8.0 | -| | [ops_stats_collector.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts#:~:text=process) | 8.8.0 | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_utils/common/persistable_state/types.ts#:~:text=SavedObjectReference) | - | @@ -631,12 +1052,32 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject) | - | +| | [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject), [make_lens_embeddable_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts#:~:text=SavedObject) | - | | | [loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/data_views_service/loader.ts#:~:text=title), [lens_top_nav.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx#:~:text=title), [loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/data_views_service/loader.ts#:~:text=title), [lens_top_nav.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx#:~:text=title) | - | | | [loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/data_views_service/loader.ts#:~:text=title), [lens_top_nav.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx#:~:text=title), [loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/data_views_service/loader.ts#:~:text=title), [lens_top_nav.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx#:~:text=title) | - | | | [loader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/data_views_service/loader.ts#:~:text=title), [lens_top_nav.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx#:~:text=title) | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [reference_editor.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx#:~:text=SavedObjectsClientContract), [reference_editor.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx#:~:text=SavedObjectsClientContract), [dimension_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx#:~:text=SavedObjectsClientContract), [dimension_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx#:~:text=SavedObjectsClientContract), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts#:~:text=SavedObjectsClientContract), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts#:~:text=SavedObjectsClientContract)+ 8 more | - | +| | [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=create) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=find) | - | +| | [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=resolve) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/utils.ts#:~:text=SavedObjectReference)+ 43 more | - | +| | [lens_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/lens_attribute_service.ts#:~:text=savedObjects), [lens_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/lens_attribute_service.ts#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [visualization.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/visualizations/xy/visualization.tsx#:~:text=savedObjects), [visualization.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/visualizations/xy/visualization.tsx#:~:text=savedObjects), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=savedObjects) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart) | - | | | [saved_objects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/saved_objects.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [lens_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/lens_attribute_service.ts#:~:text=savedObjects), [lens_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/lens_attribute_service.ts#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [form_based.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/form_based.tsx#:~:text=savedObjects), [visualization.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/visualizations/xy/visualization.tsx#:~:text=savedObjects), [visualization.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/visualizations/xy/visualization.tsx#:~:text=savedObjects), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=savedObjects) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [reference_editor.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx#:~:text=SavedObjectsClientContract), [reference_editor.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx#:~:text=SavedObjectsClientContract), [dimension_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx#:~:text=SavedObjectsClientContract), [dimension_panel.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx#:~:text=SavedObjectsClientContract), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts#:~:text=SavedObjectsClientContract), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts#:~:text=SavedObjectsClientContract)+ 8 more | - | +| | [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=create) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=find) | - | +| | [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=resolve) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/types.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject), [saved_object_store.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_object_store.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=SavedObjectsStart) | - | +| | [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock) | - | +| | [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [state_helpers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [selectors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/state_management/selectors.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/utils.ts#:~:text=SavedObjectReference)+ 43 more | - | | | [saved_objects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/server/saved_objects.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -653,6 +1094,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject) | - | +| | [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject), [exception_list_client.mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts#:~:text=SavedObject)+ 5 more | - | | | [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title)+ 8 more | - | | | [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title)+ 8 more | - | | | [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title), [helpers.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lists/public/exceptions/components/builder/helpers.test.ts#:~:text=title) | - | @@ -693,11 +1136,25 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit), [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit), [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit), [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit) | - | | | [es_tooltip_property.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/tooltips/es_tooltip_property.test.ts#:~:text=title) | - | | | [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit), [es_search_source.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/classes/sources/es_search_source/es_search_source.tsx#:~:text=flattenHit) | - | -| | [render_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/render_app.tsx#:~:text=onAppLeave), [map_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx#:~:text=onAppLeave), [map_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_page.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [saved_object_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts#:~:text=warning) | 8.8.0 | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=create) | - | +| | [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=delete) | - | +| | [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=find), [load_list_and_render.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx#:~:text=find) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=resolve) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=update) | - | +| | [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SimpleSavedObject), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SimpleSavedObject) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=SavedObjectReference), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=SavedObjectReference), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SavedObjectReference), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SavedObjectReference) | - | +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/kibana_services.ts#:~:text=savedObjects) | - | | | [setup_saved_objects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/setup_saved_objects.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [render_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/render_app.tsx#:~:text=onAppLeave), [map_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx#:~:text=onAppLeave), [map_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_page.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [saved_object_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts#:~:text=warning) | 8.8.0 | +| | [kibana_services.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/kibana_services.ts#:~:text=savedObjects) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=create) | - | +| | [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=delete) | - | +| | [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=find), [load_list_and_render.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx#:~:text=find) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=resolve) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=update) | - | +| | [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_vis_type_alias.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/maps_vis_type_alias.ts#:~:text=SimpleSavedObject), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SimpleSavedObject), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SimpleSavedObject) | - | +| | [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/common/migrations/references.ts#:~:text=SavedObjectReference), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=SavedObjectReference), [map_attribute_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/map_attribute_service.ts#:~:text=SavedObjectReference), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SavedObjectReference), [maps_list_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx#:~:text=SavedObjectReference) | - | | | [setup_saved_objects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/setup_saved_objects.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -724,10 +1181,18 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/plugin.ts#:~:text=license%24) | 8.8.0 | | | [annotations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/routes/annotations.ts#:~:text=authc) | - | | | [initialization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/saved_objects/initialization/initialization.ts#:~:text=authz), [sync_task.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/saved_objects/sync_task.ts#:~:text=authz), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/plugin.ts#:~:text=authz), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/plugin.ts#:~:text=authz) | - | -| | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [dependency_cache.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/dependency_cache.ts#:~:text=SavedObjectsClientContract), [dependency_cache.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/dependency_cache.ts#:~:text=SavedObjectsClientContract), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=SavedObjectsClientContract), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=SavedObjectsClientContract) | - | +| | [index_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/index_utils.ts#:~:text=find), [resolvers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/recognize/resolvers.ts#:~:text=find), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=find), [dashboard_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.test.ts#:~:text=find) | - | +| | [index_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/index_utils.ts#:~:text=get), [route_resolver.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/job_from_lens/route_resolver.ts#:~:text=get) | - | +| | [kibana.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/kibana.ts#:~:text=SimpleSavedObject), [kibana.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/kibana.ts#:~:text=SimpleSavedObject), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=SimpleSavedObject), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=SimpleSavedObject) | - | | | [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes), [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes) | - | -| | [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes), [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes) | - | -| | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=savedObjects), [page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/page.tsx#:~:text=savedObjects), [change_data_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx#:~:text=savedObjects), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=savedObjects), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=savedObjects) | - | +| | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=savedObjects), [page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/page.tsx#:~:text=savedObjects), [change_data_view.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx#:~:text=savedObjects), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=savedObjects), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=savedObjects) | - | +| | [dependency_cache.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/dependency_cache.ts#:~:text=SavedObjectsClientContract), [dependency_cache.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/dependency_cache.ts#:~:text=SavedObjectsClientContract), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=SavedObjectsClientContract), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=SavedObjectsClientContract) | - | +| | [index_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/index_utils.ts#:~:text=find), [resolvers.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/recognize/resolvers.ts#:~:text=find), [dashboard_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.ts#:~:text=find), [dashboard_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.test.ts#:~:text=find) | - | +| | [index_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/util/index_utils.ts#:~:text=get), [route_resolver.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/jobs/new_job/job_from_lens/route_resolver.ts#:~:text=get) | - | +| | [kibana.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/kibana.ts#:~:text=SimpleSavedObject), [kibana.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/kibana.ts#:~:text=SimpleSavedObject), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=SimpleSavedObject), [source_selection.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx#:~:text=SimpleSavedObject) | - | +| | [dashboard_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.test.ts#:~:text=savedObjectsServiceMock), [dashboard_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/services/dashboard_service.test.ts#:~:text=savedObjectsServiceMock) | - | | | [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes), [modules.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/common/types/modules.ts#:~:text=SavedObjectAttributes) | - | @@ -737,8 +1202,6 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| | | [url_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/public/url_state.ts#:~:text=syncQueryStateWithUrl), [url_state.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/public/url_state.ts#:~:text=syncQueryStateWithUrl) | - | -| | [bulk_uploader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts#:~:text=process) | 8.8.0 | -| | [bulk_uploader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts#:~:text=process) | 8.8.0 | @@ -746,11 +1209,16 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject) | - | +| | [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject), [slo.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts#:~:text=SavedObject) | - | | | [observability_data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/utils/observability_data_views/observability_data_views.ts#:~:text=title), [report_definition_field.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/report_definition_field.tsx#:~:text=title), [use_filter_values.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/use_filter_values.ts#:~:text=title), [filter_value_btn.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/filter_value_btn.tsx#:~:text=title), [sample_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute.ts#:~:text=title), [sample_attribute_kpi.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_kpi.ts#:~:text=title), [sample_attribute_with_reference_lines.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_with_reference_lines.ts#:~:text=title), [test_formula_metric_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/test_formula_metric_attribute.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title)+ 14 more | - | | | [observability_data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/utils/observability_data_views/observability_data_views.ts#:~:text=title), [report_definition_field.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/report_definition_field.tsx#:~:text=title), [use_filter_values.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/use_filter_values.ts#:~:text=title), [filter_value_btn.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/filter_value_btn.tsx#:~:text=title), [sample_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute.ts#:~:text=title), [sample_attribute_kpi.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_kpi.ts#:~:text=title), [sample_attribute_with_reference_lines.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_with_reference_lines.ts#:~:text=title), [test_formula_metric_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/test_formula_metric_attribute.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title)+ 14 more | - | | | [observability_data_views.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/utils/observability_data_views/observability_data_views.ts#:~:text=title), [report_definition_field.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/report_definition_field.tsx#:~:text=title), [use_filter_values.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/use_filter_values.ts#:~:text=title), [filter_value_btn.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/series_editor/columns/filter_value_btn.tsx#:~:text=title), [sample_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute.ts#:~:text=title), [sample_attribute_kpi.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_kpi.ts#:~:text=title), [sample_attribute_with_reference_lines.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/sample_attribute_with_reference_lines.ts#:~:text=title), [test_formula_metric_attribute.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/test_data/test_formula_metric_attribute.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title), [single_metric_attributes.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/lens_attributes/single_metric_attributes.test.ts#:~:text=title)+ 2 more | - | | | [use_discover_link.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/components/shared/exploratory_view/hooks/use_discover_link.tsx#:~:text=indexPatternId) | - | | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/index.tsx#:~:text=RedirectAppLinks), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/index.tsx#:~:text=RedirectAppLinks), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/index.tsx#:~:text=RedirectAppLinks) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/observability/public/application/types.ts#:~:text=SavedObjectsStart) | - | @@ -758,8 +1226,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx#:~:text=SavedObject), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject)+ 6 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx#:~:text=SavedObject), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [use_assets_status.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/assets/use_assets_status.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/types.ts#:~:text=SavedObject)+ 14 more | - | | | [pack_queries_status_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/pack_queries_status_table.tsx#:~:text=indexPatternId), [view_results_in_discover.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/discover/view_results_in_discover.tsx#:~:text=indexPatternId), [use_discover_link.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/common/hooks/use_discover_link.tsx#:~:text=indexPatternId) | - | | | [empty_state.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/components/empty_state.tsx#:~:text=KibanaPageTemplate), [empty_state.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/components/empty_state.tsx#:~:text=KibanaPageTemplate) | - | +| | [use_saved_queries.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts#:~:text=SavedObjectsFindResponse), [use_saved_queries.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts#:~:text=SavedObjectsFindResponse), [use_packs.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/use_packs.ts#:~:text=SavedObjectsFindResponse), [use_packs.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/use_packs.ts#:~:text=SavedObjectsFindResponse) | - | +| | [use_saved_queries.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts#:~:text=SavedObjectsFindResponse), [use_saved_queries.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts#:~:text=SavedObjectsFindResponse), [use_packs.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/use_packs.ts#:~:text=SavedObjectsFindResponse), [use_packs.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/osquery/public/packs/use_packs.ts#:~:text=SavedObjectsFindResponse) | - | @@ -780,6 +1252,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/data_views/data_views.story.ts#:~:text=title), [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/data_views/data_views.story.ts#:~:text=title) | - | | | [data_views.story.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/data_views/data_views.story.ts#:~:text=title) | - | | | [saved_object_save_modal_dashboard.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/components/saved_object_save_modal_dashboard.tsx#:~:text=SavedObjectSaveModal), [saved_object_save_modal_dashboard.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/components/saved_object_save_modal_dashboard.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | +| | [dashboards_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts#:~:text=find) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject) | - | +| | [dashboards_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts#:~:text=savedObjects) | - | +| | [dashboards_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts#:~:text=savedObjects) | - | +| | [dashboards_service.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts#:~:text=find) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/services/dashboards/types.ts#:~:text=SimpleSavedObject) | - | @@ -803,10 +1281,53 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject) | - | | | [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=indexPatterns), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=indexPatterns) | - | +| | [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObject) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectsClientContract), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectsClientContract), [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=SavedObjectsClientContract), [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObjectsClientContract)+ 5 more | - | +| | [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=create), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=create), [save_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_saved_object.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create)+ 9 more | - | +| | [build_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/build_saved_object.ts#:~:text=delete) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=find), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=find), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=find) | - | +| | [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=get), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=get) | - | +| | [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=bulkGet) | - | +| | [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=update) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject)+ 15 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions) | - | | | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectAttributes)+ 15 more | - | -| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectAttributes)+ 15 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/plugin.ts#:~:text=savedObjects), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=savedObjects) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/plugin.ts#:~:text=savedObjects), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=savedObjects) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectsClientContract), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectsClientContract), [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=SavedObjectsClientContract), [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=SavedObjectsClientContract)+ 5 more | - | +| | [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=create), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=create), [save_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_saved_object.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=create)+ 9 more | - | +| | [build_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/build_saved_object.ts#:~:text=delete) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=find), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=find), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=find) | - | +| | [initialize_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts#:~:text=get), [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=get) | - | +| | [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=bulkGet) | - | +| | [saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/saved_object.test.ts#:~:text=update) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject)+ 15 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | +| | [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock) | - | | | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [create_source.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/create_source.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts#:~:text=SavedObjectAttributes)+ 15 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects/public/types.ts#:~:text=SavedObjectReference) | - | + + + +## savedObjectsFinder + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObject) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=find) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=find) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SimpleSavedObject) | - | +| | [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart), [saved_object_finder.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx#:~:text=SavedObjectsStart) | - | @@ -814,12 +1335,18 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject)+ 2 more | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/common/types.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject), [find_relationships.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/server/lib/find_relationships.test.ts#:~:text=SavedObject)+ 8 more | - | | | [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title) | - | | | [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title) | - | | | [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title), [flyout.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/components/flyout.tsx#:~:text=title) | - | | | [saved_objects_edition_page.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx#:~:text=RedirectAppLinks), [saved_objects_edition_page.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx#:~:text=RedirectAppLinks), [saved_objects_edition_page.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx#:~:text=RedirectAppLinks), [saved_objects_table.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx#:~:text=RedirectAppLinks), [saved_objects_table.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx#:~:text=RedirectAppLinks), [saved_objects_table.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx#:~:text=RedirectAppLinks) | - | +| | [find_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/find_objects.ts#:~:text=SavedObjectsFindOptions), [find_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/find_objects.ts#:~:text=SavedObjectsFindOptions) | - | +| | [record.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/services/types/record.ts#:~:text=SavedObjectReference), [record.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/services/types/record.ts#:~:text=SavedObjectReference) | - | | | [resolve_import_errors.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts#:~:text=createNewCopy) | - | | | [resolve_import_errors.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts#:~:text=createNewCopy) | - | +| | [find_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/find_objects.ts#:~:text=SavedObjectsFindOptions), [find_objects.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/find_objects.ts#:~:text=SavedObjectsFindOptions) | - | +| | [record.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/services/types/record.ts#:~:text=SavedObjectReference), [record.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/services/types/record.ts#:~:text=SavedObjectReference) | - | | | [resolve_import_errors.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts#:~:text=createNewCopy) | - | @@ -828,8 +1355,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/types.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject)+ 16 more | - | +| | [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/types.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.test.ts#:~:text=SavedObject)+ 29 more | - | | | [request_handler_context.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/server/request_handler_context.ts#:~:text=authz) | - | +| | [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObjectReference), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObjectReference)+ 11 more | - | | | [tag.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/server/saved_objects/tag.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObjectReference), [get_table_column_definition.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [references.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/common/references.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObjectReference), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/public/utils.ts#:~:text=SavedObjectReference)+ 11 more | - | | | [tag.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/saved_objects_tagging/server/saved_objects/tag.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -838,7 +1369,10 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject) | 8.8.0 | +| | [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject)+ 1 more | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject) | - | +| | [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [inject_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts#:~:text=SavedObjectReference), [inject_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts#:~:text=SavedObjectReference), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObjectReference), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObjectReference)+ 2 more | - | +| | [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [extract_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts#:~:text=SavedObjectReference), [inject_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts#:~:text=SavedObjectReference), [inject_tag_references.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts#:~:text=SavedObjectReference), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObjectReference), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObjectReference)+ 2 more | - | @@ -846,11 +1380,26 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes), [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart) | - | +| | [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=SavedObjectsClientContract), [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=SavedObjectsClientContract), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsClientContract), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsClientContract) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=create), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=create) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=find), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=find), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=find) | - | +| | [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=update), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=update), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=update) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart) | - | | | [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes), [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes) | - | | | [search.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes), [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes) | - | +| | [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=SavedObjectsClientContract), [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=SavedObjectsClientContract), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsClientContract), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsClientContract) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=create), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=create) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=find), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=find), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=find) | - | +| | [get_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=resolve) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=update), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=update), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=update) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [save_saved_searches.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=SavedObjectsStart) | - | +| | [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=savedObjectsServiceMock), [get_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts#:~:text=savedObjectsServiceMock), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=savedObjectsServiceMock), [save_saved_searches.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts#:~:text=savedObjectsServiceMock) | - | | | [search.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes), [search_migrations.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_search/server/saved_objects/search_migrations.ts#:~:text=SavedObjectAttributes) | - | @@ -867,6 +1416,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject) | - | +| | [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject), [saved_objects_security_extension.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts#:~:text=SavedObject) | - | | | [elasticsearch_role.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/roles/elasticsearch_role.ts#:~:text=disabled), [role_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/lib/role_utils.ts#:~:text=disabled), [role_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/lib/role_utils.ts#:~:text=disabled), [primary_feature_privilege.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/management/roles/model/primary_feature_privilege.ts#:~:text=disabled), [elasticsearch_role.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/roles/elasticsearch_role.test.ts#:~:text=disabled), [kibana_features.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts#:~:text=disabled), [put.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/put.test.ts#:~:text=disabled), [put_payload.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/model/put_payload.test.ts#:~:text=disabled), [put_payload.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/model/put_payload.test.ts#:~:text=disabled) | 8.8.0 | | | [disable_ui_capabilities.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/disable_ui_capabilities.ts#:~:text=requiredRoles) | 8.8.0 @@ -885,9 +1436,7 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode) | 8.8.0 | | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/plugin.ts#:~:text=license%24) | 8.8.0 | | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=appBasePath) | 8.8.0 | -| | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=onAppLeave) | 8.8.0 | | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=appBasePath) | 8.8.0 | -| | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=onAppLeave) | 8.8.0 | @@ -897,20 +1446,23 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | ---------------|-----------|-----------| | | [wrap_search_source_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.ts#:~:text=create) | - | | | [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch) | - | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=SavedObject), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=SavedObject), [host_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts#:~:text=SavedObject), [host_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts#:~:text=SavedObject), [user_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts#:~:text=SavedObject), [user_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject)+ 6 more | - | | | [dependencies_start_mock.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/endpoint/dependencies_start_mock.ts#:~:text=indexPatterns) | - | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [validators.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts#:~:text=title)+ 20 more | - | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=SavedObject), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=SavedObject), [host_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts#:~:text=SavedObject), [host_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts#:~:text=SavedObject), [user_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts#:~:text=SavedObject), [user_risk_score_dashboards.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObject)+ 14 more | - | +| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [create_sourcerer_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts#:~:text=title)+ 18 more | - | | | [wrap_search_source_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.ts#:~:text=create) | - | | | [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch), [wrap_search_source_client.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/wrap_search_source_client.test.ts#:~:text=fetch) | - | | | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/eql/api.ts#:~:text=options) | - | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [validators.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts#:~:text=title)+ 20 more | - | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [validators.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/components/rules/eql_query_bar/validators.ts#:~:text=title)+ 5 more | - | +| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [create_sourcerer_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts#:~:text=title)+ 18 more | - | +| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/source/index.tsx#:~:text=title), [use_rule_from_timeline.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/use_rule_from_timeline.tsx#:~:text=title), [get_es_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/containers/detection_engine/exceptions/get_es_query_filter.ts#:~:text=title), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/utils.ts#:~:text=title), [middleware.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/store/middleware.ts#:~:text=title), [get_query_filter.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/get_query_filter.ts#:~:text=title), [index_pattern.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/mock/index_pattern.ts#:~:text=title), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/alerts_actions/utils.test.ts#:~:text=title), [create_sourcerer_data_view.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts#:~:text=title)+ 4 more | - | | | [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode)+ 7 more | 8.8.0 | | | [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode)+ 7 more | 8.8.0 | | | [query.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/executors/query.ts#:~:text=license%24) | 8.8.0 | | | [request_context_factory.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/request_context_factory.ts#:~:text=authc), [route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/route.ts#:~:text=authc), [create_signals_migration_route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/routes/signals/create_signals_migration_route.ts#:~:text=authc), [delete_signals_migration_route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/routes/signals/delete_signals_migration_route.ts#:~:text=authc), [finalize_signals_migration_route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/routes/signals/finalize_signals_migration_route.ts#:~:text=authc), [open_close_signals_route.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/routes/signals/open_close_signals_route.ts#:~:text=authc), [common.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/utils/common.ts#:~:text=authc) | - | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/index.tsx#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [use_timeline_save_prompt.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts#:~:text=AppLeaveHandler)+ 1 more | 8.8.0 | -| | [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes) | - | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts#:~:text=SavedObjectsClientContract), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts#:~:text=SavedObjectsClientContract) | - | +| | [use_dashboard_button_href.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts#:~:text=find), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=find), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=find), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=find), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=find) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/types.ts#:~:text=SimpleSavedObject) | - | +| | [use_dashboard_button_href.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts#:~:text=savedObjects), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=savedObjects), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=savedObjects), [use_create_security_dashboard_link.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_create_security_dashboard_link.ts#:~:text=savedObjects) | - | | | [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes) | - | | | [timelines.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/timelines.ts#:~:text=convertToMultiNamespaceTypeVersion), [notes.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/notes.ts#:~:text=convertToMultiNamespaceTypeVersion), [pinned_events.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/pinned_events.ts#:~:text=convertToMultiNamespaceTypeVersion), [saved_objects_type.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_type.ts#:~:text=convertToMultiNamespaceTypeVersion), [legacy_saved_object_mappings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_saved_object_mappings.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | | | [policy_hooks.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_hooks.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [policy_hooks.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_hooks.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/trusted_apps/constants.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/trusted_apps/constants.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/trusted_apps/service/api_client.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/trusted_apps/service/api_client.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/trusted_apps/service/api_client.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [lists.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/artifacts/lists.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [manifest_manager.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/services/artifacts/manifest_manager/manifest_manager.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID), [manifest_manager.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/services/artifacts/manifest_manager/manifest_manager.ts#:~:text=ENDPOINT_TRUSTED_APPS_LIST_ID)+ 34 more | - | @@ -925,10 +1477,12 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [policy_hooks.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_hooks.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [policy_hooks.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_hooks.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [blocklists_api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/services/blocklists_api_client.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [blocklists_api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/services/blocklists_api_client.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [blocklists_api_client.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/services/blocklists_api_client.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [lists.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/artifacts/lists.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [manifest_manager.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/services/artifacts/manifest_manager/manifest_manager.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID), [manifest_manager.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/services/artifacts/manifest_manager/manifest_manager.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_ID)+ 14 more | - | | | [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_NAME), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_NAME), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/scripts/endpoint/blocklists/index.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_NAME), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/scripts/endpoint/blocklists/index.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_NAME) | - | | | [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_DESCRIPTION), [constants.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/management/pages/blocklist/constants.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_DESCRIPTION), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/scripts/endpoint/blocklists/index.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_DESCRIPTION), [index.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/scripts/endpoint/blocklists/index.ts#:~:text=ENDPOINT_BLOCKLISTS_LIST_DESCRIPTION) | - | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [use_timeline_save_prompt.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts#:~:text=AppLeaveHandler)+ 1 more | 8.8.0 | -| | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/index.tsx#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| | [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes) | - | +| | [use_dashboard_button_href.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts#:~:text=savedObjects), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=savedObjects), [use_security_dashboards_table.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx#:~:text=savedObjects), [use_create_security_dashboard_link.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/use_create_security_dashboard_link.ts#:~:text=savedObjects) | - | +| | [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=SavedObjectsClientContract), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts#:~:text=SavedObjectsClientContract), [utils.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts#:~:text=SavedObjectsClientContract) | - | +| | [use_dashboard_button_href.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts#:~:text=find), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=find), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx#:~:text=find), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=find), [utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts#:~:text=find) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/types.ts#:~:text=SimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/types.ts#:~:text=SimpleSavedObject) | - | | | [timelines.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/timelines.ts#:~:text=convertToMultiNamespaceTypeVersion), [notes.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/notes.ts#:~:text=convertToMultiNamespaceTypeVersion), [pinned_events.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/timeline/saved_object_mappings/pinned_events.ts#:~:text=convertToMultiNamespaceTypeVersion), [saved_objects_type.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_type.ts#:~:text=convertToMultiNamespaceTypeVersion), [legacy_saved_object_mappings.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_saved_object_mappings.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | +| | [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes), [legacy_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts#:~:text=SavedObjectAttributes) | - | @@ -947,8 +1501,10 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [spaces_management_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/management/spaces_management_app.tsx#:~:text=RedirectAppLinks), [spaces_management_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/management/spaces_management_app.tsx#:~:text=RedirectAppLinks), [spaces_management_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/management/spaces_management_app.tsx#:~:text=RedirectAppLinks) | - | | | [on_post_auth_interceptor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/lib/request_interceptors/on_post_auth_interceptor.ts#:~:text=getKibanaFeatures), [spaces_usage_collector.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.ts#:~:text=getKibanaFeatures), [on_post_auth_interceptor.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/lib/request_interceptors/on_post_auth_interceptor.test.ts#:~:text=getKibanaFeatures) | 8.8.0 | | | [spaces_usage_collector.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [spaces_usage_collector.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.test.ts#:~:text=license%24) | 8.8.0 | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/legacy_urls/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/legacy_urls/types.ts#:~:text=ResolvedSimpleSavedObject) | - | | | [copy_to_space_flyout_internal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx#:~:text=createNewCopy) | - | | | [copy_to_space_flyout_internal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx#:~:text=createNewCopy) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/legacy_urls/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/legacy_urls/types.ts#:~:text=ResolvedSimpleSavedObject) | - | | | [copy_to_space_flyout_internal.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx#:~:text=createNewCopy) | - | @@ -971,11 +1527,29 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [monitor_detail_flyout.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx#:~:text=SavedObject), [monitor_detail_flyout.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts#:~:text=SavedObject), [effects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts#:~:text=SavedObject), [effects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts#:~:text=SavedObject)+ 24 more | - | +| | [monitor_detail_flyout.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx#:~:text=SavedObject), [monitor_detail_flyout.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts#:~:text=SavedObject), [effects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts#:~:text=SavedObject), [effects.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts#:~:text=SavedObject)+ 41 more | - | | | [filter_group.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx#:~:text=title), [filters_expression_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx#:~:text=title), [filter_group.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx#:~:text=title), [filters_expression_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx#:~:text=title) | - | | | [filter_group.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx#:~:text=title), [filters_expression_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx#:~:text=title), [filter_group.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx#:~:text=title), [filters_expression_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx#:~:text=title) | - | | | [filter_group.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/filter_group/filter_group.tsx#:~:text=title), [filters_expression_select.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/overview/alerts/monitor_expressions/filters_expression_select.tsx#:~:text=title) | - | | | [stderr_logs.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/synthetics/check_steps/stderr_logs.tsx#:~:text=indexPatternId), [stderr_logs.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/stderr_logs.tsx#:~:text=indexPatternId) | - | | | [alert_messages.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/lib/alert_types/alert_messages.tsx#:~:text=RedirectAppLinks), [alert_messages.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/lib/alert_types/alert_messages.tsx#:~:text=RedirectAppLinks), [alert_messages.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/lib/alert_types/alert_messages.tsx#:~:text=RedirectAppLinks), [uptime_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/app/uptime_app.tsx#:~:text=RedirectAppLinks), [uptime_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/app/uptime_app.tsx#:~:text=RedirectAppLinks), [uptime_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/app/uptime_app.tsx#:~:text=RedirectAppLinks), [synthetics_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/synthetics_app.tsx#:~:text=RedirectAppLinks), [synthetics_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/synthetics_app.tsx#:~:text=RedirectAppLinks), [synthetics_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/synthetics_app.tsx#:~:text=RedirectAppLinks) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=create), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=create) | - | +| | [delete_param.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx#:~:text=bulkDelete) | - | +| | [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts#:~:text=find), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts#:~:text=find), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts#:~:text=find), [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts#:~:text=find), [use_filters.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts#:~:text=find), [use_filters.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts#:~:text=find), [use_filters.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts#:~:text=find) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=get), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=get) | - | +| | [use_invalid_monitors.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx#:~:text=bulkResolve), [use_recently_viewed_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts#:~:text=bulkResolve) | - | +| | [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject), [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject), [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject) | - | +| | [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts#:~:text=savedObjects), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts#:~:text=savedObjects), [use_locations_api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_locations_api.ts#:~:text=savedObjects), [use_invalid_monitors.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx#:~:text=savedObjects), [delete_param.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx#:~:text=savedObjects), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts#:~:text=savedObjects), [use_locations_api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_locations_api.ts#:~:text=savedObjects), [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts#:~:text=savedObjects), [use_recently_viewed_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts#:~:text=savedObjects), [use_filters.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts#:~:text=savedObjects)+ 1 more | - | +| | [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts#:~:text=savedObjects), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts#:~:text=savedObjects), [use_locations_api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_locations_api.ts#:~:text=savedObjects), [use_invalid_monitors.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx#:~:text=savedObjects), [delete_param.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx#:~:text=savedObjects), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts#:~:text=savedObjects), [use_locations_api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_locations_api.ts#:~:text=savedObjects), [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts#:~:text=savedObjects), [use_recently_viewed_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts#:~:text=savedObjects), [use_filters.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts#:~:text=savedObjects)+ 1 more | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=SavedObjectsClientContract) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=create), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=create) | - | +| | [delete_param.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx#:~:text=bulkDelete) | - | +| | [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts#:~:text=find), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts#:~:text=find), [use_location_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts#:~:text=find), [use_monitor_name.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts#:~:text=find), [use_filters.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts#:~:text=find), [use_filters.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts#:~:text=find), [use_filters.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts#:~:text=find) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts#:~:text=get), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts#:~:text=get) | - | +| | [use_invalid_monitors.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx#:~:text=bulkResolve), [use_recently_viewed_monitors.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts#:~:text=bulkResolve) | - | +| | [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject), [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject), [synthetics_monitor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/synthetics/common/types/synthetics_monitor.ts#:~:text=SimpleSavedObject) | - | @@ -983,9 +1557,8 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes), [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes) | - | | | [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes), [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes) | - | -| | [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes), [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes) | - | +| | [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes), [task_store.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/task_manager/server/task_store.test.ts#:~:text=SavedObjectAttributes) | - | @@ -1017,6 +1590,11 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [filter_term_form.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/filter_agg/components/filter_term_form.tsx#:~:text=title), [common.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/hooks/use_search_items/common.ts#:~:text=title), [es_index_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/services/es_index_service.ts#:~:text=title), [transforms.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/server/routes/api/transforms.ts#:~:text=title), [common.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/common.test.ts#:~:text=title), [filter_term_form.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/filter_agg/components/filter_term_form.tsx#:~:text=title), [common.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/hooks/use_search_items/common.ts#:~:text=title), [es_index_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/services/es_index_service.ts#:~:text=title), [transforms.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/server/routes/api/transforms.ts#:~:text=title), [common.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/common.test.ts#:~:text=title) | - | | | [filter_term_form.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/filter_agg/components/filter_term_form.tsx#:~:text=title), [common.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/hooks/use_search_items/common.ts#:~:text=title), [es_index_service.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/services/es_index_service.ts#:~:text=title), [transforms.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/server/routes/api/transforms.ts#:~:text=title), [common.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/sections/create_transform/components/step_define/common/common.test.ts#:~:text=title) | - | | | [license.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/server/services/license.ts#:~:text=license%24) | 8.8.0 | +| | [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart), [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart) | - | +| | [mount_management_section.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/mount_management_section.ts#:~:text=savedObjects) | - | +| | [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart), [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart) | - | +| | [mount_management_section.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/mount_management_section.ts#:~:text=savedObjects) | - | +| | [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart), [app_dependencies.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/public/app/app_dependencies.tsx#:~:text=SavedObjectsStart) | - | @@ -1027,6 +1605,17 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [data_apis.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts#:~:text=title), [data_apis.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts#:~:text=title) | - | | | [data_apis.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts#:~:text=title), [data_apis.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts#:~:text=title) | - | | | [data_apis.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/common/lib/data_apis.ts#:~:text=title) | - | +| | [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute), [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute), [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute) | - | +| | [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute), [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute), [rule_reducer.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts#:~:text=SavedObjectAttribute) | - | + + + +## uiActionsEnhanced + +| Deprecated API | Reference location(s) | Remove By | +| ---------------|-----------|-----------| +| | [action_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts#:~:text=SavedObjectReference), [action_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference) | - | +| | [action_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts#:~:text=SavedObjectReference), [action_factory.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [ui_actions_service_enhancements.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference), [dynamic_action_enhancement.ts](https://github.com/elastic/kibana/tree/main/src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts#:~:text=SavedObjectReference) | - | @@ -1049,6 +1638,8 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [value_suggestion_provider.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/autocomplete/providers/value_suggestion_provider.ts#:~:text=title), [fetch_index_patterns.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/query_string_input/fetch_index_patterns.ts#:~:text=title), [change_dataview.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/dataview_picker/change_dataview.tsx#:~:text=title) | - | | | [terms_enum.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_enum.ts#:~:text=getFieldByName), [terms_enum.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_enum.ts#:~:text=getFieldByName), [terms_agg.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_agg.ts#:~:text=getFieldByName), [terms_agg.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_agg.ts#:~:text=getFieldByName) | - | | | [terms_enum.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_enum.ts#:~:text=findIndexPatternById), [terms_enum.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_enum.ts#:~:text=findIndexPatternById), [terms_agg.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_agg.ts#:~:text=findIndexPatternById), [terms_agg.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/server/autocomplete/terms_agg.ts#:~:text=findIndexPatternById) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/types.ts#:~:text=savedObjects), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/types.ts#:~:text=savedObjects) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/types.ts#:~:text=savedObjects), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/unified_search/public/types.ts#:~:text=savedObjects) | - | @@ -1056,6 +1647,8 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/common/types.ts#:~:text=SavedObject) | - | | | [external_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx#:~:text=title), [external_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx#:~:text=title) | - | | | [external_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx#:~:text=title), [external_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx#:~:text=title) | - | | | [external_links.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/upgrade_assistant/public/application/components/es_deprecation_logs/fix_deprecation_logs/external_links.tsx#:~:text=title) | - | @@ -1122,6 +1715,8 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | | [abstract_search_strategy.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/server/lib/search_strategies/strategies/abstract_search_strategy.ts#:~:text=getNonScriptedFields), [fetch_fields.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/lib/fetch_fields.ts#:~:text=getNonScriptedFields), [abstract_search_strategy.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/server/lib/search_strategies/strategies/abstract_search_strategy.ts#:~:text=getNonScriptedFields), [fetch_fields.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/lib/fetch_fields.ts#:~:text=getNonScriptedFields) | - | | | [index_patterns_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/common/index_patterns_utils.ts#:~:text=title), [index_patterns_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/common/index_patterns_utils.ts#:~:text=title), [get_fields.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/server/lib/get_fields.ts#:~:text=title), [index_patterns_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts#:~:text=title), [index_patterns_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/common/index_patterns_utils.test.ts#:~:text=title), [convert_series_to_datatable.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.ts#:~:text=title), [convert_series_to_datatable.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/components/lib/convert_series_to_datatable.test.ts#:~:text=title), [datasource_info.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts#:~:text=title), [datasource_info.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts#:~:text=title), [datasource_info.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/datasource/datasource_info.test.ts#:~:text=title)+ 2 more | - | | | [abstract_search_strategy.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/server/lib/search_strategies/strategies/abstract_search_strategy.ts#:~:text=getNonScriptedFields), [fetch_fields.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/lib/fetch_fields.ts#:~:text=getNonScriptedFields) | - | +| | [query_input_bar_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts#:~:text=SavedObjectsClientContract), [query_input_bar_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts#:~:text=SavedObjectsClientContract) | - | +| | [query_input_bar_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts#:~:text=SavedObjectsClientContract), [query_input_bar_context.ts](https://github.com/elastic/kibana/tree/main/src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts#:~:text=SavedObjectsClientContract) | - | @@ -1139,12 +1734,39 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [visualize_top_nav.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx#:~:text=onAppLeave), [visualize_editor_common.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx#:~:text=onAppLeave), [app.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/app.tsx#:~:text=onAppLeave), [index.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/index.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart) | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract)+ 12 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=create), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=create), [update_basic_attributes.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create)+ 7 more | - | +| | [visualize_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx#:~:text=delete) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=find), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find)+ 2 more | - | +| | [update_basic_attributes.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts#:~:text=get) | - | +| | [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=resolve), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=resolve) | - | +| | [vis_type_alias_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts#:~:text=SimpleSavedObject), [vis_type_alias_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [show_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts#:~:text=SimpleSavedObject)+ 4 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsFindOptions), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsFindOptions) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectAttribute), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectAttribute) | - | | | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes)+ 11 more | - | -| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes)+ 11 more | - | +| | [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=SavedObjectReference), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=SavedObjectReference), [controls_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts#:~:text=SavedObjectReference)+ 5 more | - | +| | [get_top_nav_config.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/plugin.ts#:~:text=savedObjects), [visualize_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx#:~:text=savedObjects) | - | +| | [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart) | - | | | [visualization.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/server/saved_objects/visualization.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | -| | [visualize_top_nav.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx#:~:text=onAppLeave), [visualize_editor_common.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx#:~:text=onAppLeave), [app.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/app.tsx#:~:text=onAppLeave), [index.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/index.tsx#:~:text=onAppLeave) | 8.8.0 | +| | [get_top_nav_config.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [get_visualization_instance.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=savedObjects), [plugin.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/plugin.ts#:~:text=savedObjects), [visualize_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx#:~:text=savedObjects) | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [check_for_duplicate_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsClientContract)+ 12 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=create), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=create), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=create), [update_basic_attributes.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=create)+ 7 more | - | +| | [visualize_listing.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx#:~:text=delete) | - | +| | [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=find), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=find)+ 2 more | - | +| | [update_basic_attributes.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts#:~:text=get) | - | +| | [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=resolve), [saved_visualize_utils.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts#:~:text=resolve) | - | +| | [vis_type_alias_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts#:~:text=SimpleSavedObject), [vis_type_alias_registry.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [show_saved_object.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=SimpleSavedObject), [show_saved_object.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts#:~:text=SimpleSavedObject)+ 4 more | - | +| | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions), [save_with_confirmation.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts#:~:text=SavedObjectsCreateOptions) | - | +| | [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsFindOptions), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectsFindOptions) | - | +| | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/types.ts#:~:text=ResolvedSimpleSavedObject) | - | +| | [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [services.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/services.ts#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [search_selection.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart), [new_vis_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/wizard/new_vis_modal.tsx#:~:text=SavedObjectsStart) | - | +| | [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock), [find_object_by_title.test.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts#:~:text=simpleSavedObjectMock) | - | +| | [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectAttribute), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectAttribute) | - | | | [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [save_with_confirmation.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [find_object_by_title.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectAttributes)+ 11 more | - | +| | [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualization_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [saved_visualize_utils.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualize_utils.ts#:~:text=SavedObjectReference), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=SavedObjectReference), [visualize_embeddable_factory.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx#:~:text=SavedObjectReference), [controls_references.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts#:~:text=SavedObjectReference)+ 5 more | - | | | [visualization.ts](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/server/saved_objects/visualization.ts#:~:text=convertToMultiNamespaceTypeVersion) | - | @@ -1153,4 +1775,8 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | Deprecated API | Reference location(s) | Remove By | | ---------------|-----------|-----------| -| | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=license%24) | 8.8.0 | \ No newline at end of file +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=license%24) | 8.8.0 | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/index.tsx#:~:text=SavedObjectsClientContract), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/index.tsx#:~:text=SavedObjectsClientContract) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=savedObjects) | - | +| | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/plugin.ts#:~:text=savedObjects) | - | +| | [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [api.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/lib/api.ts#:~:text=SavedObjectsClientContract), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/index.tsx#:~:text=SavedObjectsClientContract), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/watcher/public/application/index.tsx#:~:text=SavedObjectsClientContract) | - | \ No newline at end of file diff --git a/api_docs/deprecations_by_team.mdx b/api_docs/deprecations_by_team.mdx index b4da21755cc64..9f73589003491 100644 --- a/api_docs/deprecations_by_team.mdx +++ b/api_docs/deprecations_by_team.mdx @@ -7,7 +7,7 @@ id: kibDevDocsDeprecationsDueByTeam slug: /kibana-dev-docs/api-meta/deprecations-due-by-team title: Deprecated APIs due to be removed, by team description: Lists the teams that are referencing deprecated APIs with a remove by date. -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana'] --- @@ -56,10 +56,6 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Plugin | Deprecated API | Reference location(s) | Remove By | | --------|-------|-----------|-----------| -| maps | | [render_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/render_app.tsx#:~:text=onAppLeave), [map_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx#:~:text=onAppLeave), [map_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_page.tsx#:~:text=onAppLeave) | 8.8.0 | -| maps | | [saved_object_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts#:~:text=warning) | 8.8.0 | -| maps | | [render_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/render_app.tsx#:~:text=onAppLeave), [map_app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx#:~:text=onAppLeave), [map_page.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/public/routes/map_page/map_page.tsx#:~:text=onAppLeave) | 8.8.0 | -| maps | | [saved_object_migrations.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts#:~:text=warning) | 8.8.0 | | mapsEms | | [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/maps_ems/server/index.ts#:~:text=license%24) | 8.8.0 | | mapsEms | | [index.ts](https://github.com/elastic/kibana/tree/main/src/plugins/maps_ems/server/index.ts#:~:text=refresh) | 8.8.0 | @@ -69,19 +65,11 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Plugin | Deprecated API | Reference location(s) | Remove By | | --------|-------|-----------|-----------| -| kibanaOverview | | [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_overview/public/application.tsx#:~:text=appBasePath), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath) | 8.8.0 | -| kibanaOverview | | [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_overview/public/application.tsx#:~:text=appBasePath), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath), [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=appBasePath) | 8.8.0 | +| core | | [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=appBasePath), [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_overview/public/application.tsx#:~:text=appBasePath), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath) | 8.8.0 | +| core | | [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=AsyncPlugin), [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin), [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin) | 8.8.0 | | savedObjectsTaggingOss | | [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/decorator/types.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject), [api.ts](https://github.com/elastic/kibana/tree/main/src/plugins/saved_objects_tagging_oss/public/api.ts#:~:text=SavedObject) | 8.8.0 | -| @kbn/core-application-browser-internal | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=onAppLeave), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=onAppLeave) | 8.8.0 | -| @kbn/core-application-browser-internal | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [app_leave.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser/src/app_leave.ts#:~:text=AppLeaveHandler)+ 6 more | 8.8.0 | -| @kbn/core-application-browser-internal | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [app_router.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_router.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_leave.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_leave.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [application_service.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/application_service.tsx#:~:text=AppLeaveHandler), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/public/index.ts#:~:text=AppLeaveHandler) | 8.8.0 | -| @kbn/core-application-browser-internal | | [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=onAppLeave), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=onAppLeave), [mocks.ts](https://github.com/elastic/kibana/tree/main/src/core/public/mocks.ts#:~:text=onAppLeave) | 8.8.0 | +| kibanaOverview | | [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_overview/public/application.tsx#:~:text=appBasePath), [app_container.tsx](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-internal/src/ui/app_container.tsx#:~:text=appBasePath), [application_service.mock.ts](https://github.com/elastic/kibana/tree/main/packages/core/application/core-application-browser-mocks/src/application_service.mock.ts#:~:text=appBasePath) | 8.8.0 | | @kbn/core-plugins-server-internal | | [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin), [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin), [types.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server/src/types.ts#:~:text=AsyncPlugin), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server/src/index.ts#:~:text=AsyncPlugin), [index.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server/index.ts#:~:text=AsyncPlugin) | 8.8.0 | -| @kbn/core-plugins-server-internal | | [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin), [plugin.ts](https://github.com/elastic/kibana/tree/main/packages/core/plugins/core-plugins-server-internal/src/plugin.ts#:~:text=AsyncPlugin), [index.ts](https://github.com/elastic/kibana/tree/main/src/core/server/index.ts#:~:text=AsyncPlugin) | 8.8.0 | -| @kbn/core-saved-objects-migration-server-internal | | [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=warning), [migration_logger.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts#:~:text=warning) | 8.8.0 | -| @kbn/core-saved-objects-migration-server-internal | | [document_migrator.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts#:~:text=warning), [migration_logger.ts](https://github.com/elastic/kibana/tree/main/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts#:~:text=warning) | 8.8.0 | -| @kbn/core-apps-browser-internal | | [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts#:~:text=process), [ops_metrics_collector.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts#:~:text=process), [get_ops_metrics_log.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts#:~:text=process), [get_ops_metrics_log.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts#:~:text=process)+ 5 more | 8.8.0 | -| @kbn/core-apps-browser-internal | | [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts#:~:text=process), [load_status.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts#:~:text=process), [ops_metrics_collector.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts#:~:text=process), [get_ops_metrics_log.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts#:~:text=process), [get_ops_metrics_log.test.ts](https://github.com/elastic/kibana/tree/main/packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts#:~:text=process)+ 5 more | 8.8.0 | @@ -91,19 +79,6 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | --------|-------|-----------|-----------| | dashboard | | [save_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_container/embeddable/api/overlays/save_modal.tsx#:~:text=SavedObjectSaveModal), [save_modal.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_container/embeddable/api/overlays/save_modal.tsx#:~:text=SavedObjectSaveModal), [saved_object_save_modal_dashboard.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/components/saved_object_save_modal_dashboard.tsx#:~:text=SavedObjectSaveModal), [saved_object_save_modal_dashboard.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/presentation_util/public/components/saved_object_save_modal_dashboard.tsx#:~:text=SavedObjectSaveModal) | 8.8.0 | | dashboard | | [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject), [clone_panel_action.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx#:~:text=SavedObject) | 8.8.0 | -| dashboard | | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/types.ts#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| dashboard | | [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning), [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning) | 8.8.0 | -| dashboard | | [types.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/dashboard_app/types.ts#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| dashboard | | [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning), [migrations_730.ts](https://github.com/elastic/kibana/tree/main/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts#:~:text=warning) | 8.8.0 | - - - -## Kibana Telemetry - -| Plugin | Deprecated API | Reference location(s) | Remove By | -| --------|-------|-----------|-----------| -| kibanaUsageCollection | | [ops_stats_collector.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts#:~:text=process) | 8.8.0 | -| kibanaUsageCollection | | [ops_stats_collector.ts](https://github.com/elastic/kibana/tree/main/src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts#:~:text=process) | 8.8.0 | @@ -121,8 +96,6 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | --------|-------|-----------|-----------| | ml | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/plugin.ts#:~:text=license%24) | 8.8.0 | | ml | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/server/plugin.ts#:~:text=license%24), [license.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/transform/server/services/license.ts#:~:text=license%24) | 8.8.0 | -| ml | | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=onAppLeave) | 8.8.0 | -| ml | | [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/ml/public/application/app.tsx#:~:text=onAppLeave) | 8.8.0 | @@ -130,8 +103,6 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Plugin | Deprecated API | Reference location(s) | Remove By | | --------|-------|-----------|-----------| -| spaces | | [on_post_auth_interceptor.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/lib/request_interceptors/on_post_auth_interceptor.ts#:~:text=getKibanaFeatures), [spaces_usage_collector.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.ts#:~:text=getKibanaFeatures), [on_post_auth_interceptor.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/lib/request_interceptors/on_post_auth_interceptor.test.ts#:~:text=getKibanaFeatures), [app_authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/app_authorization.ts#:~:text=getKibanaFeatures), [privileges.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.ts#:~:text=getKibanaFeatures), [authorization_service.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/authorization_service.tsx#:~:text=getKibanaFeatures), [app_authorization.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/app_authorization.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures)+ 18 more | 8.8.0 | -| spaces | | [spaces_usage_collector.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [spaces_usage_collector.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.test.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/plugin.ts#:~:text=license%24) | 8.8.0 | | security | | [elasticsearch_role.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/roles/elasticsearch_role.ts#:~:text=disabled), [role_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/lib/role_utils.ts#:~:text=disabled), [role_utils.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/lib/role_utils.ts#:~:text=disabled), [primary_feature_privilege.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/management/roles/model/primary_feature_privilege.ts#:~:text=disabled), [elasticsearch_role.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/roles/elasticsearch_role.test.ts#:~:text=disabled), [kibana_features.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts#:~:text=disabled), [put.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/put.test.ts#:~:text=disabled), [put_payload.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/model/put_payload.test.ts#:~:text=disabled), [put_payload.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/routes/authorization/roles/model/put_payload.test.ts#:~:text=disabled) | 8.8.0 | | security | | [disable_ui_capabilities.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/disable_ui_capabilities.ts#:~:text=requiredRoles) | 8.8.0 @@ -143,14 +114,14 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ This is relied on by the reporting feature, and should be removed once reporting migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/issues/19914 | +| security | | [app_authorization.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/app_authorization.ts#:~:text=getKibanaFeatures), [privileges.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.ts#:~:text=getKibanaFeatures), [authorization_service.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/authorization_service.tsx#:~:text=getKibanaFeatures), [app_authorization.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/app_authorization.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures), [privileges.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/privileges/privileges.test.ts#:~:text=getKibanaFeatures)+ 18 more | 8.8.0 | | security | | [authorization_service.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/authorization/authorization_service.tsx#:~:text=getElasticsearchFeatures) | 8.8.0 | | security | | [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode) | 8.8.0 | | security | | [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/plugin.tsx#:~:text=license%24) | 8.8.0 | | security | | [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode), [license_service.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/common/licensing/license_service.test.ts#:~:text=mode) | 8.8.0 | +| security | | [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/server/plugin.ts#:~:text=license%24), [spaces_usage_collector.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [plugin.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/plugin.ts#:~:text=license%24), [spaces_usage_collector.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/spaces/server/usage_collection/spaces_usage_collector.test.ts#:~:text=license%24) | 8.8.0 | | security | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=appBasePath) | 8.8.0 | -| security | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=onAppLeave) | 8.8.0 | | security | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=appBasePath) | 8.8.0 | -| security | | [logout_app.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security/public/authentication/logout/logout_app.test.ts#:~:text=onAppLeave) | 8.8.0 | @@ -170,10 +141,6 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ | securitySolution | | [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode)+ 7 more | 8.8.0 | | securitySolution | | [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [policy_config.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/common/license/policy_config.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [fleet_integration.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/fleet_integration.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [create_default_policy.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_default_policy.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode), [license_watch.test.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/endpoint/lib/policy/license_watch.test.ts#:~:text=mode)+ 7 more | 8.8.0 | | securitySolution | | [query.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/server/lib/detection_engine/signals/executors/query.ts#:~:text=license%24) | 8.8.0 | -| securitySolution | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/index.tsx#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | -| securitySolution | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [use_timeline_save_prompt.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts#:~:text=AppLeaveHandler)+ 1 more | 8.8.0 | -| securitySolution | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/types.ts#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [routes.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/routes.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [app.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/app.tsx#:~:text=AppLeaveHandler), [use_timeline_save_prompt.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts#:~:text=AppLeaveHandler)+ 1 more | 8.8.0 | -| securitySolution | | [index.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/app/index.tsx#:~:text=onAppLeave), [plugin.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/security_solution/public/plugin.tsx#:~:text=onAppLeave) | 8.8.0 | @@ -186,20 +153,9 @@ migrates to using the Kibana Privilege model: https://github.com/elastic/kibana/ -## Stack Monitoring - -| Plugin | Deprecated API | Reference location(s) | Remove By | -| --------|-------|-----------|-----------| -| monitoring | | [bulk_uploader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts#:~:text=process) | 8.8.0 | -| monitoring | | [bulk_uploader.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts#:~:text=process) | 8.8.0 | - - - ## Vis Editors | Plugin | Deprecated API | Reference location(s) | Remove By | | --------|-------|-----------|-----------| -| lens | | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=onAppLeave), [visualize_top_nav.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx#:~:text=onAppLeave), [visualize_editor_common.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx#:~:text=onAppLeave), [app.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/app.tsx#:~:text=onAppLeave), [index.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/index.tsx#:~:text=onAppLeave) | 8.8.0 | -| lens | | [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [types.ts](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/types.ts#:~:text=onAppLeave), [mounter.tsx](https://github.com/elastic/kibana/tree/main/x-pack/plugins/lens/public/app_plugin/mounter.tsx#:~:text=onAppLeave), [visualize_top_nav.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx#:~:text=onAppLeave), [visualize_editor_common.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx#:~:text=onAppLeave), [app.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/app.tsx#:~:text=onAppLeave), [index.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/visualizations/public/visualize_app/index.tsx#:~:text=onAppLeave) | 8.8.0 | | management | | [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/management/public/application.tsx#:~:text=appBasePath) | 8.8.0 | | management | | [application.tsx](https://github.com/elastic/kibana/tree/main/src/plugins/management/public/application.tsx#:~:text=appBasePath) | 8.8.0 | \ No newline at end of file diff --git a/api_docs/dev_tools.mdx b/api_docs/dev_tools.mdx index 52161703cf8e7..e16ed19cfd0bd 100644 --- a/api_docs/dev_tools.mdx +++ b/api_docs/dev_tools.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/devTools title: "devTools" image: https://source.unsplash.com/400x175/?github description: API docs for the devTools plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'devTools'] --- import devToolsObj from './dev_tools.devdocs.json'; diff --git a/api_docs/discover.mdx b/api_docs/discover.mdx index 83fca54d43528..565b0c4d7f7cc 100644 --- a/api_docs/discover.mdx +++ b/api_docs/discover.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/discover title: "discover" image: https://source.unsplash.com/400x175/?github description: API docs for the discover plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'discover'] --- import discoverObj from './discover.devdocs.json'; diff --git a/api_docs/discover_enhanced.mdx b/api_docs/discover_enhanced.mdx index b56b67c21d9d7..cfea72b74deed 100644 --- a/api_docs/discover_enhanced.mdx +++ b/api_docs/discover_enhanced.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/discoverEnhanced title: "discoverEnhanced" image: https://source.unsplash.com/400x175/?github description: API docs for the discoverEnhanced plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'discoverEnhanced'] --- import discoverEnhancedObj from './discover_enhanced.devdocs.json'; diff --git a/api_docs/embeddable.devdocs.json b/api_docs/embeddable.devdocs.json index 72f7f70edfd90..a9b6f4421c811 100644 --- a/api_docs/embeddable.devdocs.json +++ b/api_docs/embeddable.devdocs.json @@ -485,36 +485,6 @@ { "parentPluginId": "embeddable", "id": "def-public.AttributeService.Unnamed.$2", - "type": "Function", - "tags": [], - "label": "showSaveModal", - "description": [], - "signature": [ - "(saveModal: React.ReactElement>, I18nContext: ({ children }: { children: React.ReactNode; }) => JSX.Element) => void" - ], - "path": "src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "embeddable", - "id": "def-public.AttributeService.Unnamed.$3", - "type": "Function", - "tags": [], - "label": "i18nContext", - "description": [], - "signature": [ - "({ children }: { children: React.ReactNode; }) => JSX.Element" - ], - "path": "src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "embeddable", - "id": "def-public.AttributeService.Unnamed.$4", "type": "Object", "tags": [], "label": "toasts", @@ -535,7 +505,7 @@ }, { "parentPluginId": "embeddable", - "id": "def-public.AttributeService.Unnamed.$5", + "id": "def-public.AttributeService.Unnamed.$3", "type": "Object", "tags": [], "label": "options", @@ -551,7 +521,7 @@ }, { "parentPluginId": "embeddable", - "id": "def-public.AttributeService.Unnamed.$6", + "id": "def-public.AttributeService.Unnamed.$4", "type": "Function", "tags": [], "label": "getEmbeddableFactory", @@ -7041,10 +7011,10 @@ ], "signature": [ { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.PresentableGrouping", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGrouping", "text": "PresentableGrouping" }, " | undefined" diff --git a/api_docs/embeddable.mdx b/api_docs/embeddable.mdx index 3d0477f17a5b1..7cf851f266482 100644 --- a/api_docs/embeddable.mdx +++ b/api_docs/embeddable.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/embeddable title: "embeddable" image: https://source.unsplash.com/400x175/?github description: API docs for the embeddable plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'embeddable'] --- import embeddableObj from './embeddable.devdocs.json'; @@ -21,7 +21,7 @@ Contact [App Services](https://github.com/orgs/elastic/teams/kibana-app-services | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 524 | 8 | 423 | 4 | +| 522 | 8 | 421 | 4 | ## Client diff --git a/api_docs/embeddable_enhanced.devdocs.json b/api_docs/embeddable_enhanced.devdocs.json index 6b615629b9469..16468b31ded5d 100644 --- a/api_docs/embeddable_enhanced.devdocs.json +++ b/api_docs/embeddable_enhanced.devdocs.json @@ -248,7 +248,13 @@ "label": "drilldownGrouping", "description": [], "signature": [ - "PresentableGroup", + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGroup", + "text": "PresentableGroup" + }, "<{ embeddable?: ", { "pluginId": "embeddable", diff --git a/api_docs/embeddable_enhanced.mdx b/api_docs/embeddable_enhanced.mdx index abedc7602291f..ca3ea6630622d 100644 --- a/api_docs/embeddable_enhanced.mdx +++ b/api_docs/embeddable_enhanced.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/embeddableEnhanced title: "embeddableEnhanced" image: https://source.unsplash.com/400x175/?github description: API docs for the embeddableEnhanced plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'embeddableEnhanced'] --- import embeddableEnhancedObj from './embeddable_enhanced.devdocs.json'; diff --git a/api_docs/encrypted_saved_objects.mdx b/api_docs/encrypted_saved_objects.mdx index a46de465e5129..82087851680ec 100644 --- a/api_docs/encrypted_saved_objects.mdx +++ b/api_docs/encrypted_saved_objects.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/encryptedSavedObjects title: "encryptedSavedObjects" image: https://source.unsplash.com/400x175/?github description: API docs for the encryptedSavedObjects plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'encryptedSavedObjects'] --- import encryptedSavedObjectsObj from './encrypted_saved_objects.devdocs.json'; diff --git a/api_docs/enterprise_search.mdx b/api_docs/enterprise_search.mdx index dfbf84fc295ab..d74e7509a5329 100644 --- a/api_docs/enterprise_search.mdx +++ b/api_docs/enterprise_search.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/enterpriseSearch title: "enterpriseSearch" image: https://source.unsplash.com/400x175/?github description: API docs for the enterpriseSearch plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'enterpriseSearch'] --- import enterpriseSearchObj from './enterprise_search.devdocs.json'; diff --git a/api_docs/es_ui_shared.mdx b/api_docs/es_ui_shared.mdx index bd3b64f99a5b6..79cb8cd8f1ab5 100644 --- a/api_docs/es_ui_shared.mdx +++ b/api_docs/es_ui_shared.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/esUiShared title: "esUiShared" image: https://source.unsplash.com/400x175/?github description: API docs for the esUiShared plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'esUiShared'] --- import esUiSharedObj from './es_ui_shared.devdocs.json'; diff --git a/api_docs/event_annotation.mdx b/api_docs/event_annotation.mdx index 607bcc39aa041..291ef13aa8a94 100644 --- a/api_docs/event_annotation.mdx +++ b/api_docs/event_annotation.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/eventAnnotation title: "eventAnnotation" image: https://source.unsplash.com/400x175/?github description: API docs for the eventAnnotation plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'eventAnnotation'] --- import eventAnnotationObj from './event_annotation.devdocs.json'; diff --git a/api_docs/event_log.devdocs.json b/api_docs/event_log.devdocs.json index 316da215e9fec..e847693888d03 100644 --- a/api_docs/event_log.devdocs.json +++ b/api_docs/event_log.devdocs.json @@ -1499,7 +1499,7 @@ "label": "data", "description": [], "signature": [ - "(Readonly<{ error?: Readonly<{ type?: string | undefined; id?: string | undefined; message?: string | undefined; code?: string | undefined; stack_trace?: string | undefined; } & {}> | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ active?: string | number | undefined; recovered?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; url?: string | undefined; code?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}> | undefined)[]" + "(Readonly<{ error?: Readonly<{ type?: string | undefined; id?: string | undefined; message?: string | undefined; code?: string | undefined; stack_trace?: string | undefined; } & {}> | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ recovered?: string | number | undefined; active?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; code?: string | undefined; url?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}> | undefined)[]" ], "path": "x-pack/plugins/event_log/server/es/cluster_client_adapter.ts", "deprecated": false, @@ -1519,7 +1519,7 @@ "label": "IEvent", "description": [], "signature": [ - "DeepPartial | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ active?: string | number | undefined; recovered?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; url?: string | undefined; code?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}>>> | undefined" + "DeepPartial | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ recovered?: string | number | undefined; active?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; code?: string | undefined; url?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}>>> | undefined" ], "path": "x-pack/plugins/event_log/generated/schemas.ts", "deprecated": false, @@ -1534,7 +1534,7 @@ "label": "IValidatedEvent", "description": [], "signature": [ - "Readonly<{ error?: Readonly<{ type?: string | undefined; id?: string | undefined; message?: string | undefined; code?: string | undefined; stack_trace?: string | undefined; } & {}> | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ active?: string | number | undefined; recovered?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; url?: string | undefined; code?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}> | undefined" + "Readonly<{ error?: Readonly<{ type?: string | undefined; id?: string | undefined; message?: string | undefined; code?: string | undefined; stack_trace?: string | undefined; } & {}> | undefined; tags?: string[] | undefined; log?: Readonly<{ logger?: string | undefined; level?: string | undefined; } & {}> | undefined; user?: Readonly<{ name?: string | undefined; } & {}> | undefined; message?: string | undefined; kibana?: Readonly<{ alert?: Readonly<{ rule?: Readonly<{ consumer?: string | undefined; execution?: Readonly<{ status?: string | undefined; metrics?: Readonly<{ number_of_triggered_actions?: string | number | undefined; number_of_generated_actions?: string | number | undefined; alert_counts?: Readonly<{ recovered?: string | number | undefined; active?: string | number | undefined; new?: string | number | undefined; } & {}> | undefined; number_of_searches?: string | number | undefined; total_indexing_duration_ms?: string | number | undefined; es_search_duration_ms?: string | number | undefined; total_search_duration_ms?: string | number | undefined; execution_gap_duration_s?: string | number | undefined; rule_type_run_duration_ms?: string | number | undefined; process_alerts_duration_ms?: string | number | undefined; trigger_actions_duration_ms?: string | number | undefined; process_rule_duration_ms?: string | number | undefined; claim_to_start_duration_ms?: string | number | undefined; prepare_rule_duration_ms?: string | number | undefined; total_run_duration_ms?: string | number | undefined; total_enrichment_duration_ms?: string | number | undefined; } & {}> | undefined; uuid?: string | undefined; status_order?: string | number | undefined; } & {}> | undefined; rule_type_id?: string | undefined; } & {}> | undefined; flapping?: boolean | undefined; } & {}> | undefined; version?: string | undefined; alerting?: Readonly<{ status?: string | undefined; outcome?: string | undefined; instance_id?: string | undefined; action_group_id?: string | undefined; action_subgroup?: string | undefined; } & {}> | undefined; server_uuid?: string | undefined; task?: Readonly<{ id?: string | undefined; schedule_delay?: string | number | undefined; scheduled?: string | undefined; } & {}> | undefined; saved_objects?: Readonly<{ type?: string | undefined; id?: string | undefined; namespace?: string | undefined; rel?: string | undefined; type_id?: string | undefined; } & {}>[] | undefined; space_ids?: string[] | undefined; } & {}> | undefined; ecs?: Readonly<{ version?: string | undefined; } & {}> | undefined; rule?: Readonly<{ name?: string | undefined; description?: string | undefined; category?: string | undefined; id?: string | undefined; version?: string | undefined; license?: string | undefined; reference?: string | undefined; author?: string[] | undefined; ruleset?: string | undefined; uuid?: string | undefined; } & {}> | undefined; event?: Readonly<{ start?: string | undefined; category?: string[] | undefined; type?: string[] | undefined; id?: string | undefined; reason?: string | undefined; created?: string | undefined; outcome?: string | undefined; end?: string | undefined; original?: string | undefined; duration?: string | number | undefined; kind?: string | undefined; hash?: string | undefined; code?: string | undefined; url?: string | undefined; action?: string | undefined; severity?: string | number | undefined; dataset?: string | undefined; ingested?: string | undefined; module?: string | undefined; provider?: string | undefined; reference?: string | undefined; risk_score?: number | undefined; risk_score_norm?: number | undefined; sequence?: string | number | undefined; timezone?: string | undefined; } & {}> | undefined; '@timestamp'?: string | undefined; } & {}> | undefined" ], "path": "x-pack/plugins/event_log/generated/schemas.ts", "deprecated": false, diff --git a/api_docs/event_log.mdx b/api_docs/event_log.mdx index c296d038c1d62..fc2109c0d7dca 100644 --- a/api_docs/event_log.mdx +++ b/api_docs/event_log.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/eventLog title: "eventLog" image: https://source.unsplash.com/400x175/?github description: API docs for the eventLog plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'eventLog'] --- import eventLogObj from './event_log.devdocs.json'; diff --git a/api_docs/expression_error.mdx b/api_docs/expression_error.mdx index 4f66131b3c160..03dde1c927134 100644 --- a/api_docs/expression_error.mdx +++ b/api_docs/expression_error.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionError title: "expressionError" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionError plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionError'] --- import expressionErrorObj from './expression_error.devdocs.json'; diff --git a/api_docs/expression_gauge.mdx b/api_docs/expression_gauge.mdx index 6bd67af894931..a5727fca7e085 100644 --- a/api_docs/expression_gauge.mdx +++ b/api_docs/expression_gauge.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionGauge title: "expressionGauge" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionGauge plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionGauge'] --- import expressionGaugeObj from './expression_gauge.devdocs.json'; diff --git a/api_docs/expression_heatmap.mdx b/api_docs/expression_heatmap.mdx index 631e95c3a04f9..836bb3313c2c9 100644 --- a/api_docs/expression_heatmap.mdx +++ b/api_docs/expression_heatmap.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionHeatmap title: "expressionHeatmap" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionHeatmap plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionHeatmap'] --- import expressionHeatmapObj from './expression_heatmap.devdocs.json'; diff --git a/api_docs/expression_image.mdx b/api_docs/expression_image.mdx index 0f8cc1d434448..14604257af610 100644 --- a/api_docs/expression_image.mdx +++ b/api_docs/expression_image.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionImage title: "expressionImage" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionImage plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionImage'] --- import expressionImageObj from './expression_image.devdocs.json'; diff --git a/api_docs/expression_legacy_metric_vis.mdx b/api_docs/expression_legacy_metric_vis.mdx index bfb9669016023..bfc5df0096f61 100644 --- a/api_docs/expression_legacy_metric_vis.mdx +++ b/api_docs/expression_legacy_metric_vis.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionLegacyMetricVis title: "expressionLegacyMetricVis" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionLegacyMetricVis plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionLegacyMetricVis'] --- import expressionLegacyMetricVisObj from './expression_legacy_metric_vis.devdocs.json'; diff --git a/api_docs/expression_metric.mdx b/api_docs/expression_metric.mdx index 456e3ae7436af..3349475198cf6 100644 --- a/api_docs/expression_metric.mdx +++ b/api_docs/expression_metric.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionMetric title: "expressionMetric" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionMetric plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionMetric'] --- import expressionMetricObj from './expression_metric.devdocs.json'; diff --git a/api_docs/expression_metric_vis.mdx b/api_docs/expression_metric_vis.mdx index 2c4c085ee09eb..b55cf7dd6a34a 100644 --- a/api_docs/expression_metric_vis.mdx +++ b/api_docs/expression_metric_vis.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionMetricVis title: "expressionMetricVis" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionMetricVis plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionMetricVis'] --- import expressionMetricVisObj from './expression_metric_vis.devdocs.json'; diff --git a/api_docs/expression_partition_vis.mdx b/api_docs/expression_partition_vis.mdx index 7019231e838dc..576953499ecf5 100644 --- a/api_docs/expression_partition_vis.mdx +++ b/api_docs/expression_partition_vis.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionPartitionVis title: "expressionPartitionVis" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionPartitionVis plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionPartitionVis'] --- import expressionPartitionVisObj from './expression_partition_vis.devdocs.json'; diff --git a/api_docs/expression_repeat_image.mdx b/api_docs/expression_repeat_image.mdx index 2af4db495dc7d..87da8eee58ebf 100644 --- a/api_docs/expression_repeat_image.mdx +++ b/api_docs/expression_repeat_image.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionRepeatImage title: "expressionRepeatImage" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionRepeatImage plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionRepeatImage'] --- import expressionRepeatImageObj from './expression_repeat_image.devdocs.json'; diff --git a/api_docs/expression_reveal_image.mdx b/api_docs/expression_reveal_image.mdx index f6f3d8eb7f224..ec8c9a1a71a17 100644 --- a/api_docs/expression_reveal_image.mdx +++ b/api_docs/expression_reveal_image.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionRevealImage title: "expressionRevealImage" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionRevealImage plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionRevealImage'] --- import expressionRevealImageObj from './expression_reveal_image.devdocs.json'; diff --git a/api_docs/expression_shape.mdx b/api_docs/expression_shape.mdx index be7694b34475a..660533d209edf 100644 --- a/api_docs/expression_shape.mdx +++ b/api_docs/expression_shape.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionShape title: "expressionShape" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionShape plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionShape'] --- import expressionShapeObj from './expression_shape.devdocs.json'; diff --git a/api_docs/expression_tagcloud.mdx b/api_docs/expression_tagcloud.mdx index 80c28dabbb7f1..28d1142fed4ec 100644 --- a/api_docs/expression_tagcloud.mdx +++ b/api_docs/expression_tagcloud.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionTagcloud title: "expressionTagcloud" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionTagcloud plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionTagcloud'] --- import expressionTagcloudObj from './expression_tagcloud.devdocs.json'; diff --git a/api_docs/expression_x_y.mdx b/api_docs/expression_x_y.mdx index 9acc9b2129a10..1e75b8cf5945c 100644 --- a/api_docs/expression_x_y.mdx +++ b/api_docs/expression_x_y.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressionXY title: "expressionXY" image: https://source.unsplash.com/400x175/?github description: API docs for the expressionXY plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressionXY'] --- import expressionXYObj from './expression_x_y.devdocs.json'; diff --git a/api_docs/expressions.mdx b/api_docs/expressions.mdx index 5dac98a18cffa..8b8ddd01e44e0 100644 --- a/api_docs/expressions.mdx +++ b/api_docs/expressions.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/expressions title: "expressions" image: https://source.unsplash.com/400x175/?github description: API docs for the expressions plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressions'] --- import expressionsObj from './expressions.devdocs.json'; diff --git a/api_docs/features.devdocs.json b/api_docs/features.devdocs.json index 6831369f3b147..01692bc13b431 100644 --- a/api_docs/features.devdocs.json +++ b/api_docs/features.devdocs.json @@ -56,7 +56,7 @@ "label": "config", "description": [], "signature": [ - "Readonly<{ id: string; name: string; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", + "Readonly<{ id: string; name: string; description?: string | undefined; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", { "pluginId": "features", "scope": "common", @@ -64,7 +64,7 @@ "section": "def-common.SubFeaturePrivilegeGroupType", "text": "SubFeaturePrivilegeGroupType" }, - "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" + "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; description?: string | undefined; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" ], "path": "x-pack/plugins/features/common/kibana_feature.ts", "deprecated": false, @@ -96,6 +96,20 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-public.KibanaFeature.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-public.KibanaFeature.order", @@ -556,6 +570,22 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-public.KibanaFeatureConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "\nAn optional description that will appear as subtext underneath the feature name" + ], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-public.KibanaFeatureConfig.category", @@ -882,6 +912,22 @@ "path": "x-pack/plugins/features/common/sub_feature.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "features", + "id": "def-public.SubFeatureConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "\nAn optional description that will appear as subtext underneath the sub-feature name" + ], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/sub_feature.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -1263,7 +1309,7 @@ "label": "config", "description": [], "signature": [ - "Readonly<{ id: string; name: string; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", + "Readonly<{ id: string; name: string; description?: string | undefined; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", { "pluginId": "features", "scope": "common", @@ -1271,7 +1317,7 @@ "section": "def-common.SubFeaturePrivilegeGroupType", "text": "SubFeaturePrivilegeGroupType" }, - "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" + "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; description?: string | undefined; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" ], "path": "x-pack/plugins/features/common/kibana_feature.ts", "deprecated": false, @@ -1303,6 +1349,20 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-server.KibanaFeature.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-server.KibanaFeature.order", @@ -1942,6 +2002,22 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-server.KibanaFeatureConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "\nAn optional description that will appear as subtext underneath the feature name" + ], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-server.KibanaFeatureConfig.category", @@ -2998,7 +3074,7 @@ "label": "config", "description": [], "signature": [ - "Readonly<{ id: string; name: string; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", + "Readonly<{ id: string; name: string; description?: string | undefined; category: Readonly<{ id: string; label: string; ariaLabel?: string | undefined; order?: number | undefined; euiIconType?: string | undefined; }>; order?: number | undefined; excludeFromBasePrivileges?: boolean | undefined; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; app: readonly string[]; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: readonly string[] | undefined; cases?: readonly string[] | undefined; privileges: Readonly<{ all: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; read: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }> | null; subFeatures?: readonly Readonly<{ name: string; requireAllSpaces?: boolean | undefined; privilegesTooltip?: string | undefined; privilegeGroups: readonly Readonly<{ groupType: ", { "pluginId": "features", "scope": "common", @@ -3006,7 +3082,7 @@ "section": "def-common.SubFeaturePrivilegeGroupType", "text": "SubFeaturePrivilegeGroupType" }, - "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" + "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; description?: string | undefined; }>[] | undefined; privilegesTooltip?: string | undefined; reserved?: Readonly<{ description: string; privileges: readonly Readonly<{ id: string; privilege: Readonly<{ excludeFromBasePrivileges?: boolean | undefined; requireAllSpaces?: boolean | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; api?: readonly string[] | undefined; app?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; ui: readonly string[]; }>; }>[]; }> | undefined; }>" ], "path": "x-pack/plugins/features/common/kibana_feature.ts", "deprecated": false, @@ -3038,6 +3114,20 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-common.KibanaFeature.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-common.KibanaFeature.order", @@ -3256,7 +3346,7 @@ "section": "def-common.SubFeaturePrivilegeGroupType", "text": "SubFeaturePrivilegeGroupType" }, - "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; }>" + "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; description?: string | undefined; }>" ], "path": "x-pack/plugins/features/common/sub_feature.ts", "deprecated": false, @@ -3310,6 +3400,17 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-common.SubFeature.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "path": "x-pack/plugins/features/common/sub_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-common.SubFeature.toRaw", @@ -3326,7 +3427,7 @@ "section": "def-common.SubFeaturePrivilegeGroupType", "text": "SubFeaturePrivilegeGroupType" }, - "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; }" + "; privileges: readonly Readonly<{ id: string; name: string; includeIn: \"none\" | \"all\" | \"read\"; minimumLicense?: \"basic\" | \"standard\" | \"gold\" | \"platinum\" | \"enterprise\" | \"trial\" | undefined; disabled?: boolean | undefined; management?: Readonly<{ [x: string]: readonly string[]; }> | undefined; catalogue?: readonly string[] | undefined; alerting?: Readonly<{ rule?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; alert?: Readonly<{ all?: readonly string[] | undefined; read?: readonly string[] | undefined; }> | undefined; }> | undefined; cases?: Readonly<{ all?: readonly string[] | undefined; push?: readonly string[] | undefined; create?: readonly string[] | undefined; read?: readonly string[] | undefined; update?: readonly string[] | undefined; delete?: readonly string[] | undefined; }> | undefined; ui: readonly string[]; app?: readonly string[] | undefined; requireAllSpaces?: boolean | undefined; api?: readonly string[] | undefined; savedObject: Readonly<{ all: readonly string[]; read: readonly string[]; }>; }>[]; }>[]; description?: string | undefined; }" ], "path": "x-pack/plugins/features/common/sub_feature.ts", "deprecated": false, @@ -3799,6 +3900,22 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "features", + "id": "def-common.KibanaFeatureConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "\nAn optional description that will appear as subtext underneath the feature name" + ], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/kibana_feature.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "features", "id": "def-common.KibanaFeatureConfig.category", @@ -4125,6 +4242,22 @@ "path": "x-pack/plugins/features/common/sub_feature.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "features", + "id": "def-common.SubFeatureConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [ + "\nAn optional description that will appear as subtext underneath the sub-feature name" + ], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/features/common/sub_feature.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false diff --git a/api_docs/features.mdx b/api_docs/features.mdx index 876b9bab2f44a..685c5af44bf66 100644 --- a/api_docs/features.mdx +++ b/api_docs/features.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/features title: "features" image: https://source.unsplash.com/400x175/?github description: API docs for the features plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'features'] --- import featuresObj from './features.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) for que | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 227 | 0 | 96 | 2 | +| 236 | 0 | 100 | 2 | ## Client diff --git a/api_docs/field_formats.mdx b/api_docs/field_formats.mdx index 2000819ea5b3a..4a995c0759556 100644 --- a/api_docs/field_formats.mdx +++ b/api_docs/field_formats.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/fieldFormats title: "fieldFormats" image: https://source.unsplash.com/400x175/?github description: API docs for the fieldFormats plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'fieldFormats'] --- import fieldFormatsObj from './field_formats.devdocs.json'; diff --git a/api_docs/file_upload.mdx b/api_docs/file_upload.mdx index 1c3c35bce1ba3..e1ad0971791c6 100644 --- a/api_docs/file_upload.mdx +++ b/api_docs/file_upload.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/fileUpload title: "fileUpload" image: https://source.unsplash.com/400x175/?github description: API docs for the fileUpload plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'fileUpload'] --- import fileUploadObj from './file_upload.devdocs.json'; diff --git a/api_docs/files.mdx b/api_docs/files.mdx index 5637f36d5909f..a68ca7b2dbd97 100644 --- a/api_docs/files.mdx +++ b/api_docs/files.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/files title: "files" image: https://source.unsplash.com/400x175/?github description: API docs for the files plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'files'] --- import filesObj from './files.devdocs.json'; diff --git a/api_docs/files_management.mdx b/api_docs/files_management.mdx index ce45e38fe64bc..e13d523ab4b56 100644 --- a/api_docs/files_management.mdx +++ b/api_docs/files_management.mdx @@ -8,14 +8,14 @@ slug: /kibana-dev-docs/api/filesManagement title: "filesManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the filesManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'filesManagement'] --- import filesManagementObj from './files_management.devdocs.json'; Simple UI for managing files in Kibana -Contact [@elastic/kibana-global-experience](https://github.com/orgs/elastic/teams/@elastic/kibana-global-experience) for questions regarding this plugin. +Contact [@elastic/appex-sharedux](https://github.com/orgs/elastic/teams/@elastic/appex-sharedux) for questions regarding this plugin. **Code health stats** diff --git a/api_docs/fleet.devdocs.json b/api_docs/fleet.devdocs.json index 4cce579a0dca7..54d1eaeee0c99 100644 --- a/api_docs/fleet.devdocs.json +++ b/api_docs/fleet.devdocs.json @@ -2580,7 +2580,7 @@ "label": "integrations_all", "description": [], "signature": [ - "({ searchTerm, category }: { searchTerm?: string | undefined; category?: string | undefined; }) => [string, string]" + "({ searchTerm, category, subCategory, }: { searchTerm?: string | undefined; category?: string | undefined; subCategory?: string | undefined; }) => [string, string]" ], "path": "x-pack/plugins/fleet/public/constants/page_paths.ts", "deprecated": false, @@ -2591,7 +2591,7 @@ "id": "def-public.pagePathGetters.integrations_all.$1", "type": "Object", "tags": [], - "label": "{ searchTerm, category }", + "label": "{\n searchTerm,\n category,\n subCategory,\n }", "description": [], "path": "x-pack/plugins/fleet/public/constants/page_paths.ts", "deprecated": false, @@ -2624,6 +2624,20 @@ "path": "x-pack/plugins/fleet/public/constants/page_paths.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "fleet", + "id": "def-public.pagePathGetters.integrations_all.$1.subCategory", + "type": "string", + "tags": [], + "label": "subCategory", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/fleet/public/constants/page_paths.ts", + "deprecated": false, + "trackAdoption": false } ] } @@ -9221,7 +9235,7 @@ "label": "status", "description": [], "signature": [ - "\"inactive\" | \"active\"" + "\"active\" | \"inactive\"" ], "path": "x-pack/plugins/fleet/common/types/models/agent_policy.ts", "deprecated": false, @@ -13762,6 +13776,28 @@ "path": "x-pack/plugins/fleet/common/types/models/package_spec.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "fleet", + "id": "def-common.PackageSpecManifest.elasticsearch", + "type": "Object", + "tags": [], + "label": "elasticsearch", + "description": [], + "signature": [ + "Pick<", + { + "pluginId": "fleet", + "scope": "common", + "docId": "kibFleetPluginApi", + "section": "def-common.RegistryElasticsearch", + "text": "RegistryElasticsearch" + }, + ", \"index_template.settings\" | \"index_template.mappings\"> | undefined" + ], + "path": "x-pack/plugins/fleet/common/types/models/package_spec.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -14182,6 +14218,21 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "fleet", + "id": "def-common.RegistryElasticsearch.index_template.data_stream", + "type": "Object", + "tags": [], + "label": "'index_template.data_stream'", + "description": [], + "signature": [ + "RegistryDataStreamProperties", + " | undefined" + ], + "path": "x-pack/plugins/fleet/common/types/models/epm.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "fleet", "id": "def-common.RegistryElasticsearch.ingest_pipeline.name", diff --git a/api_docs/fleet.mdx b/api_docs/fleet.mdx index 105e8c2b0ca80..ed7baca4ce876 100644 --- a/api_docs/fleet.mdx +++ b/api_docs/fleet.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/fleet title: "fleet" image: https://source.unsplash.com/400x175/?github description: API docs for the fleet plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'fleet'] --- import fleetObj from './fleet.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Fleet](https://github.com/orgs/elastic/teams/fleet) for questions regar | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 1036 | 3 | 931 | 23 | +| 1039 | 3 | 934 | 24 | ## Client diff --git a/api_docs/global_search.mdx b/api_docs/global_search.mdx index 7e79cdf16b339..654e51d6c43ae 100644 --- a/api_docs/global_search.mdx +++ b/api_docs/global_search.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/globalSearch title: "globalSearch" image: https://source.unsplash.com/400x175/?github description: API docs for the globalSearch plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'globalSearch'] --- import globalSearchObj from './global_search.devdocs.json'; diff --git a/api_docs/guided_onboarding.devdocs.json b/api_docs/guided_onboarding.devdocs.json index bb97b8874edc4..4e356303de146 100644 --- a/api_docs/guided_onboarding.devdocs.json +++ b/api_docs/guided_onboarding.devdocs.json @@ -895,9 +895,9 @@ }, ") => Promise<", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, @@ -995,150 +995,7 @@ "interfaces": [], "enums": [], "misc": [], - "objects": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig", - "type": "Object", - "tags": [], - "label": "testGuideConfig", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.title", - "type": "string", - "tags": [], - "label": "title", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.description", - "type": "string", - "tags": [], - "label": "description", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.guideName", - "type": "string", - "tags": [], - "label": "guideName", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.telemetryId", - "type": "string", - "tags": [], - "label": "telemetryId", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.completedGuideRedirectLocation", - "type": "Object", - "tags": [], - "label": "completedGuideRedirectLocation", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.completedGuideRedirectLocation.appID", - "type": "string", - "tags": [], - "label": "appID", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.completedGuideRedirectLocation.path", - "type": "string", - "tags": [], - "label": "path", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ] - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.docs", - "type": "Object", - "tags": [], - "label": "docs", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.docs.text", - "type": "string", - "tags": [], - "label": "text", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.docs.url", - "type": "string", - "tags": [], - "label": "url", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ] - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-server.testGuideConfig.steps", - "type": "Array", - "tags": [], - "label": "steps", - "description": [], - "signature": [ - "({ id: \"step1\"; title: string; descriptionList: string[]; location: { appID: string; path: string; }; integration: string; } | { id: \"step2\"; title: string; descriptionList: (string | { descriptionText: string; linkText: string; linkUrl: string; isLinkExternal: true; })[]; location: { appID: string; path: string; }; manualCompletion: { title: string; description: string; readyToCompleteOnNavigation: true; }; } | { id: \"step3\"; title: string; description: string; manualCompletion: { title: string; description: string; }; location: { appID: string; path: string; }; })[]" - ], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - } - ], + "objects": [], "setup": { "parentPluginId": "guidedOnboarding", "id": "def-server.GuidedOnboardingPluginSetup", @@ -1168,9 +1025,9 @@ }, ", guideConfig: ", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, @@ -1210,9 +1067,9 @@ "description": [], "signature": [ { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" } @@ -1248,113 +1105,6 @@ "classes": [], "functions": [], "interfaces": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig", - "type": "Interface", - "tags": [], - "label": "GuideConfig", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.title", - "type": "string", - "tags": [], - "label": "title", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.description", - "type": "string", - "tags": [], - "label": "description", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.guideName", - "type": "string", - "tags": [], - "label": "guideName", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.telemetryId", - "type": "string", - "tags": [], - "label": "telemetryId", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.docs", - "type": "Object", - "tags": [], - "label": "docs", - "description": [], - "signature": [ - "{ text: string; url: string; } | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.completedGuideRedirectLocation", - "type": "Object", - "tags": [], - "label": "completedGuideRedirectLocation", - "description": [], - "signature": [ - "{ appID: string; path: string; } | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.GuideConfig.steps", - "type": "Array", - "tags": [], - "label": "steps", - "description": [], - "signature": [ - { - "pluginId": "guidedOnboarding", - "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", - "section": "def-common.StepConfig", - "text": "StepConfig" - }, - "[]" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, { "parentPluginId": "guidedOnboarding", "id": "def-common.PluginState", @@ -1414,213 +1164,6 @@ } ], "initialIsOpen": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig", - "type": "Interface", - "tags": [], - "label": "StepConfig", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.id", - "type": "CompoundType", - "tags": [], - "label": "id", - "description": [], - "signature": [ - "\"add_data\" | \"view_dashboard\" | \"tour_observability\" | \"rules\" | \"alertsCases\" | \"search_experience\" | \"step1\" | \"step2\" | \"step3\"" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.title", - "type": "string", - "tags": [], - "label": "title", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.description", - "type": "CompoundType", - "tags": [], - "label": "description", - "description": [], - "signature": [ - "string | ", - { - "pluginId": "guidedOnboarding", - "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", - "section": "def-common.StepDescriptionWithLink", - "text": "StepDescriptionWithLink" - }, - " | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.descriptionList", - "type": "Array", - "tags": [], - "label": "descriptionList", - "description": [], - "signature": [ - "(string | ", - { - "pluginId": "guidedOnboarding", - "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", - "section": "def-common.StepDescriptionWithLink", - "text": "StepDescriptionWithLink" - }, - ")[] | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.location", - "type": "Object", - "tags": [], - "label": "location", - "description": [], - "signature": [ - "{ appID: string; path: string; } | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.status", - "type": "CompoundType", - "tags": [], - "label": "status", - "description": [], - "signature": [ - { - "pluginId": "@kbn/guided-onboarding", - "scope": "common", - "docId": "kibKbnGuidedOnboardingPluginApi", - "section": "def-common.StepStatus", - "text": "StepStatus" - }, - " | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.integration", - "type": "string", - "tags": [], - "label": "integration", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepConfig.manualCompletion", - "type": "Object", - "tags": [], - "label": "manualCompletion", - "description": [], - "signature": [ - "{ title: string; description: string; readyToCompleteOnNavigation?: boolean | undefined; } | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepDescriptionWithLink", - "type": "Interface", - "tags": [], - "label": "StepDescriptionWithLink", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepDescriptionWithLink.descriptionText", - "type": "string", - "tags": [], - "label": "descriptionText", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepDescriptionWithLink.linkText", - "type": "string", - "tags": [], - "label": "linkText", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepDescriptionWithLink.linkUrl", - "type": "string", - "tags": [], - "label": "linkUrl", - "description": [], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.StepDescriptionWithLink.isLinkExternal", - "type": "CompoundType", - "tags": [], - "label": "isLinkExternal", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "src/plugins/guided_onboarding/common/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false } ], "enums": [], @@ -1650,33 +1193,33 @@ "signature": [ "{ search: ", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, "; kubernetes: ", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, "; siem: ", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, "; testGuide: ", { - "pluginId": "guidedOnboarding", + "pluginId": "@kbn/guided-onboarding", "scope": "common", - "docId": "kibGuidedOnboardingPluginApi", + "docId": "kibKbnGuidedOnboardingPluginApi", "section": "def-common.GuideConfig", "text": "GuideConfig" }, @@ -1733,166 +1276,8 @@ "deprecated": false, "trackAdoption": false, "initialIsOpen": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideId", - "type": "CompoundType", - "tags": [], - "label": "testGuideId", - "description": [], - "signature": [ - "\"search\" | \"kubernetes\" | \"siem\" | \"testGuide\"" - ], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false } ], - "objects": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig", - "type": "Object", - "tags": [], - "label": "testGuideConfig", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.title", - "type": "string", - "tags": [], - "label": "title", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.description", - "type": "string", - "tags": [], - "label": "description", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.guideName", - "type": "string", - "tags": [], - "label": "guideName", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.telemetryId", - "type": "string", - "tags": [], - "label": "telemetryId", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.completedGuideRedirectLocation", - "type": "Object", - "tags": [], - "label": "completedGuideRedirectLocation", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.completedGuideRedirectLocation.appID", - "type": "string", - "tags": [], - "label": "appID", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.completedGuideRedirectLocation.path", - "type": "string", - "tags": [], - "label": "path", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ] - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.docs", - "type": "Object", - "tags": [], - "label": "docs", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.docs.text", - "type": "string", - "tags": [], - "label": "text", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.docs.url", - "type": "string", - "tags": [], - "label": "url", - "description": [], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ] - }, - { - "parentPluginId": "guidedOnboarding", - "id": "def-common.testGuideConfig.steps", - "type": "Array", - "tags": [], - "label": "steps", - "description": [], - "signature": [ - "({ id: \"step1\"; title: string; descriptionList: string[]; location: { appID: string; path: string; }; integration: string; } | { id: \"step2\"; title: string; descriptionList: (string | { descriptionText: string; linkText: string; linkUrl: string; isLinkExternal: true; })[]; location: { appID: string; path: string; }; manualCompletion: { title: string; description: string; readyToCompleteOnNavigation: true; }; } | { id: \"step3\"; title: string; description: string; manualCompletion: { title: string; description: string; }; location: { appID: string; path: string; }; })[]" - ], - "path": "src/plugins/guided_onboarding/common/test_guide_config.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - } - ] + "objects": [] } } \ No newline at end of file diff --git a/api_docs/guided_onboarding.mdx b/api_docs/guided_onboarding.mdx index bb2e793f45082..64a6caf49b723 100644 --- a/api_docs/guided_onboarding.mdx +++ b/api_docs/guided_onboarding.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/guidedOnboarding title: "guidedOnboarding" image: https://source.unsplash.com/400x175/?github description: API docs for the guidedOnboarding plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'guidedOnboarding'] --- import guidedOnboardingObj from './guided_onboarding.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Journey Onboarding](https://github.com/orgs/elastic/teams/platform-onbo | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 103 | 0 | 102 | 0 | +| 56 | 0 | 55 | 0 | ## Client @@ -42,14 +42,8 @@ Contact [Journey Onboarding](https://github.com/orgs/elastic/teams/platform-onbo ### Start -### Objects - - ## Common -### Objects - - ### Interfaces diff --git a/api_docs/home.mdx b/api_docs/home.mdx index 05f87cb1774b9..77ad2143f7b2a 100644 --- a/api_docs/home.mdx +++ b/api_docs/home.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/home title: "home" image: https://source.unsplash.com/400x175/?github description: API docs for the home plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'home'] --- import homeObj from './home.devdocs.json'; diff --git a/api_docs/image_embeddable.mdx b/api_docs/image_embeddable.mdx index b7ed2ee6adf76..4440519f019a8 100644 --- a/api_docs/image_embeddable.mdx +++ b/api_docs/image_embeddable.mdx @@ -8,14 +8,14 @@ slug: /kibana-dev-docs/api/imageEmbeddable title: "imageEmbeddable" image: https://source.unsplash.com/400x175/?github description: API docs for the imageEmbeddable plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'imageEmbeddable'] --- import imageEmbeddableObj from './image_embeddable.devdocs.json'; Image embeddable -Contact [@elastic/kibana-global-experience](https://github.com/orgs/elastic/teams/@elastic/kibana-global-experience) for questions regarding this plugin. +Contact [@elastic/appex-sharedux](https://github.com/orgs/elastic/teams/@elastic/appex-sharedux) for questions regarding this plugin. **Code health stats** diff --git a/api_docs/index_lifecycle_management.mdx b/api_docs/index_lifecycle_management.mdx index 23b772f1341cc..317230f20ad2c 100644 --- a/api_docs/index_lifecycle_management.mdx +++ b/api_docs/index_lifecycle_management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/indexLifecycleManagement title: "indexLifecycleManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the indexLifecycleManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'indexLifecycleManagement'] --- import indexLifecycleManagementObj from './index_lifecycle_management.devdocs.json'; diff --git a/api_docs/index_management.mdx b/api_docs/index_management.mdx index 5f309bb4c825f..5559e84683575 100644 --- a/api_docs/index_management.mdx +++ b/api_docs/index_management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/indexManagement title: "indexManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the indexManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'indexManagement'] --- import indexManagementObj from './index_management.devdocs.json'; diff --git a/api_docs/infra.mdx b/api_docs/infra.mdx index ef62a9a769cca..6d60a22acbdc6 100644 --- a/api_docs/infra.mdx +++ b/api_docs/infra.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/infra title: "infra" image: https://source.unsplash.com/400x175/?github description: API docs for the infra plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'infra'] --- import infraObj from './infra.devdocs.json'; diff --git a/api_docs/inspector.mdx b/api_docs/inspector.mdx index 73b6d21e2c2dd..c1cf59533b565 100644 --- a/api_docs/inspector.mdx +++ b/api_docs/inspector.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/inspector title: "inspector" image: https://source.unsplash.com/400x175/?github description: API docs for the inspector plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'inspector'] --- import inspectorObj from './inspector.devdocs.json'; diff --git a/api_docs/interactive_setup.mdx b/api_docs/interactive_setup.mdx index 432aecf330007..207535b488d0e 100644 --- a/api_docs/interactive_setup.mdx +++ b/api_docs/interactive_setup.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/interactiveSetup title: "interactiveSetup" image: https://source.unsplash.com/400x175/?github description: API docs for the interactiveSetup plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'interactiveSetup'] --- import interactiveSetupObj from './interactive_setup.devdocs.json'; diff --git a/api_docs/kbn_ace.mdx b/api_docs/kbn_ace.mdx index 3fe279e278d31..647c83071adf4 100644 --- a/api_docs/kbn_ace.mdx +++ b/api_docs/kbn_ace.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ace title: "@kbn/ace" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ace plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ace'] --- import kbnAceObj from './kbn_ace.devdocs.json'; diff --git a/api_docs/kbn_aiops_components.mdx b/api_docs/kbn_aiops_components.mdx index bc2ca9c0a5a6f..0a861cecc1ec6 100644 --- a/api_docs/kbn_aiops_components.mdx +++ b/api_docs/kbn_aiops_components.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-aiops-components title: "@kbn/aiops-components" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/aiops-components plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/aiops-components'] --- import kbnAiopsComponentsObj from './kbn_aiops_components.devdocs.json'; diff --git a/api_docs/kbn_aiops_utils.mdx b/api_docs/kbn_aiops_utils.mdx index 4552522285498..e895507a8bf91 100644 --- a/api_docs/kbn_aiops_utils.mdx +++ b/api_docs/kbn_aiops_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-aiops-utils title: "@kbn/aiops-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/aiops-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/aiops-utils'] --- import kbnAiopsUtilsObj from './kbn_aiops_utils.devdocs.json'; diff --git a/api_docs/kbn_alerts.mdx b/api_docs/kbn_alerts.mdx index 4f646d77700f5..cf0d2f46adbec 100644 --- a/api_docs/kbn_alerts.mdx +++ b/api_docs/kbn_alerts.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-alerts title: "@kbn/alerts" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/alerts plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/alerts'] --- import kbnAlertsObj from './kbn_alerts.devdocs.json'; diff --git a/api_docs/kbn_analytics.mdx b/api_docs/kbn_analytics.mdx index 25305aedeaaf0..3608cf3a13b81 100644 --- a/api_docs/kbn_analytics.mdx +++ b/api_docs/kbn_analytics.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics title: "@kbn/analytics" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics'] --- import kbnAnalyticsObj from './kbn_analytics.devdocs.json'; diff --git a/api_docs/kbn_analytics_client.mdx b/api_docs/kbn_analytics_client.mdx index 048a32c3720cb..7b1769cff3cbd 100644 --- a/api_docs/kbn_analytics_client.mdx +++ b/api_docs/kbn_analytics_client.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-client title: "@kbn/analytics-client" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-client plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-client'] --- import kbnAnalyticsClientObj from './kbn_analytics_client.devdocs.json'; diff --git a/api_docs/kbn_analytics_shippers_elastic_v3_browser.mdx b/api_docs/kbn_analytics_shippers_elastic_v3_browser.mdx index 144156b832170..fcf036f77b563 100644 --- a/api_docs/kbn_analytics_shippers_elastic_v3_browser.mdx +++ b/api_docs/kbn_analytics_shippers_elastic_v3_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-shippers-elastic-v3-browser title: "@kbn/analytics-shippers-elastic-v3-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-shippers-elastic-v3-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-elastic-v3-browser'] --- import kbnAnalyticsShippersElasticV3BrowserObj from './kbn_analytics_shippers_elastic_v3_browser.devdocs.json'; diff --git a/api_docs/kbn_analytics_shippers_elastic_v3_common.mdx b/api_docs/kbn_analytics_shippers_elastic_v3_common.mdx index 3bed244b25cae..29a259b8828c7 100644 --- a/api_docs/kbn_analytics_shippers_elastic_v3_common.mdx +++ b/api_docs/kbn_analytics_shippers_elastic_v3_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-shippers-elastic-v3-common title: "@kbn/analytics-shippers-elastic-v3-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-shippers-elastic-v3-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-elastic-v3-common'] --- import kbnAnalyticsShippersElasticV3CommonObj from './kbn_analytics_shippers_elastic_v3_common.devdocs.json'; diff --git a/api_docs/kbn_analytics_shippers_elastic_v3_server.mdx b/api_docs/kbn_analytics_shippers_elastic_v3_server.mdx index 7c7bcb54e86b0..9a1c30af89cd0 100644 --- a/api_docs/kbn_analytics_shippers_elastic_v3_server.mdx +++ b/api_docs/kbn_analytics_shippers_elastic_v3_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-shippers-elastic-v3-server title: "@kbn/analytics-shippers-elastic-v3-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-shippers-elastic-v3-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-elastic-v3-server'] --- import kbnAnalyticsShippersElasticV3ServerObj from './kbn_analytics_shippers_elastic_v3_server.devdocs.json'; diff --git a/api_docs/kbn_analytics_shippers_fullstory.mdx b/api_docs/kbn_analytics_shippers_fullstory.mdx index ae268c787a282..cb8390087c873 100644 --- a/api_docs/kbn_analytics_shippers_fullstory.mdx +++ b/api_docs/kbn_analytics_shippers_fullstory.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-shippers-fullstory title: "@kbn/analytics-shippers-fullstory" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-shippers-fullstory plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-fullstory'] --- import kbnAnalyticsShippersFullstoryObj from './kbn_analytics_shippers_fullstory.devdocs.json'; diff --git a/api_docs/kbn_analytics_shippers_gainsight.mdx b/api_docs/kbn_analytics_shippers_gainsight.mdx index b2b682b6de3be..e4c5124db35fd 100644 --- a/api_docs/kbn_analytics_shippers_gainsight.mdx +++ b/api_docs/kbn_analytics_shippers_gainsight.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-analytics-shippers-gainsight title: "@kbn/analytics-shippers-gainsight" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/analytics-shippers-gainsight plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-gainsight'] --- import kbnAnalyticsShippersGainsightObj from './kbn_analytics_shippers_gainsight.devdocs.json'; diff --git a/api_docs/kbn_apm_config_loader.mdx b/api_docs/kbn_apm_config_loader.mdx index 5513cd368dbca..97321b2ba4322 100644 --- a/api_docs/kbn_apm_config_loader.mdx +++ b/api_docs/kbn_apm_config_loader.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-apm-config-loader title: "@kbn/apm-config-loader" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/apm-config-loader plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/apm-config-loader'] --- import kbnApmConfigLoaderObj from './kbn_apm_config_loader.devdocs.json'; diff --git a/api_docs/kbn_apm_synthtrace.mdx b/api_docs/kbn_apm_synthtrace.mdx index 82993d5123f3d..5bdc3f4fc1fca 100644 --- a/api_docs/kbn_apm_synthtrace.mdx +++ b/api_docs/kbn_apm_synthtrace.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-apm-synthtrace title: "@kbn/apm-synthtrace" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/apm-synthtrace plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/apm-synthtrace'] --- import kbnApmSynthtraceObj from './kbn_apm_synthtrace.devdocs.json'; diff --git a/api_docs/kbn_apm_synthtrace_client.mdx b/api_docs/kbn_apm_synthtrace_client.mdx index 896956338384b..bb35b450cc192 100644 --- a/api_docs/kbn_apm_synthtrace_client.mdx +++ b/api_docs/kbn_apm_synthtrace_client.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-apm-synthtrace-client title: "@kbn/apm-synthtrace-client" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/apm-synthtrace-client plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/apm-synthtrace-client'] --- import kbnApmSynthtraceClientObj from './kbn_apm_synthtrace_client.devdocs.json'; diff --git a/api_docs/kbn_apm_utils.mdx b/api_docs/kbn_apm_utils.mdx index ada37c0cdf7d3..b27258335c691 100644 --- a/api_docs/kbn_apm_utils.mdx +++ b/api_docs/kbn_apm_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-apm-utils title: "@kbn/apm-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/apm-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/apm-utils'] --- import kbnApmUtilsObj from './kbn_apm_utils.devdocs.json'; diff --git a/api_docs/kbn_axe_config.mdx b/api_docs/kbn_axe_config.mdx index f833c186ddeab..0eca8f52fc3df 100644 --- a/api_docs/kbn_axe_config.mdx +++ b/api_docs/kbn_axe_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-axe-config title: "@kbn/axe-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/axe-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/axe-config'] --- import kbnAxeConfigObj from './kbn_axe_config.devdocs.json'; diff --git a/api_docs/kbn_cases_components.devdocs.json b/api_docs/kbn_cases_components.devdocs.json index 098fcecdffa0d..0d0cf52bf71ea 100644 --- a/api_docs/kbn_cases_components.devdocs.json +++ b/api_docs/kbn_cases_components.devdocs.json @@ -67,9 +67,240 @@ } ], "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.Tooltip", + "type": "Function", + "tags": [], + "label": "Tooltip", + "description": [], + "signature": [ + "React.NamedExoticComponent<", + { + "pluginId": "@kbn/cases-components", + "scope": "common", + "docId": "kibKbnCasesComponentsPluginApi", + "section": "def-common.CaseTooltipProps", + "text": "CaseTooltipProps" + }, + "> & { readonly type: React.NamedExoticComponent<", + { + "pluginId": "@kbn/cases-components", + "scope": "common", + "docId": "kibKbnCasesComponentsPluginApi", + "section": "def-common.CaseTooltipProps", + "text": "CaseTooltipProps" + }, + ">; }" + ], + "path": "packages/kbn-cases-components/src/tooltip/tooltip.tsx", + "deprecated": false, + "trackAdoption": false, + "returnComment": [], + "children": [ + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.Tooltip.$1", + "type": "Uncategorized", + "tags": [], + "label": "props", + "description": [], + "signature": [ + "P" + ], + "path": "node_modules/@types/react/index.d.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "interfaces": [ + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps", + "type": "Interface", + "tags": [], + "label": "CaseTooltipContentProps", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.title", + "type": "string", + "tags": [], + "label": "title", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.status", + "type": "Enum", + "tags": [], + "label": "status", + "description": [], + "signature": [ + { + "pluginId": "@kbn/cases-components", + "scope": "common", + "docId": "kibKbnCasesComponentsPluginApi", + "section": "def-common.CaseStatuses", + "text": "CaseStatuses" + } + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.totalComments", + "type": "number", + "tags": [], + "label": "totalComments", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.createdAt", + "type": "string", + "tags": [], + "label": "createdAt", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipContentProps.createdBy", + "type": "Object", + "tags": [], + "label": "createdBy", + "description": [], + "signature": [ + "{ username?: string | undefined; fullName?: string | undefined; }" + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps", + "type": "Interface", + "tags": [], + "label": "CaseTooltipProps", + "description": [], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps.children", + "type": "CompoundType", + "tags": [], + "label": "children", + "description": [], + "signature": [ + "boolean | React.ReactChild | React.ReactFragment | React.ReactPortal | null | undefined" + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps.content", + "type": "Object", + "tags": [], + "label": "content", + "description": [], + "signature": [ + { + "pluginId": "@kbn/cases-components", + "scope": "common", + "docId": "kibKbnCasesComponentsPluginApi", + "section": "def-common.CaseTooltipContentProps", + "text": "CaseTooltipContentProps" + } + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps.dataTestSubj", + "type": "string", + "tags": [], + "label": "dataTestSubj", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps.className", + "type": "string", + "tags": [], + "label": "className", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cases-components", + "id": "def-common.CaseTooltipProps.loading", + "type": "CompoundType", + "tags": [], + "label": "loading", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "packages/kbn-cases-components/src/tooltip/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false } ], - "interfaces": [], "enums": [ { "parentPluginId": "@kbn/cases-components", diff --git a/api_docs/kbn_cases_components.mdx b/api_docs/kbn_cases_components.mdx index 46d446cbc675c..6b2e9df19fa43 100644 --- a/api_docs/kbn_cases_components.mdx +++ b/api_docs/kbn_cases_components.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-cases-components title: "@kbn/cases-components" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/cases-components plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/cases-components'] --- import kbnCasesComponentsObj from './kbn_cases_components.devdocs.json'; @@ -21,13 +21,16 @@ Contact [Owner missing] for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 4 | 0 | 3 | 0 | +| 19 | 0 | 17 | 0 | ## Common ### Functions +### Interfaces + + ### Enums diff --git a/api_docs/kbn_cell_actions.devdocs.json b/api_docs/kbn_cell_actions.devdocs.json new file mode 100644 index 0000000000000..4441df2e08ef2 --- /dev/null +++ b/api_docs/kbn_cell_actions.devdocs.json @@ -0,0 +1,330 @@ +{ + "id": "@kbn/cell-actions", + "client": { + "classes": [], + "functions": [], + "interfaces": [], + "enums": [], + "misc": [], + "objects": [] + }, + "server": { + "classes": [], + "functions": [], + "interfaces": [], + "enums": [], + "misc": [], + "objects": [] + }, + "common": { + "classes": [], + "functions": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActions", + "type": "Function", + "tags": [], + "label": "CellActions", + "description": [], + "signature": [ + "({ field, triggerId, children, mode, showActionTooltips, visibleCellActions, metadata, }: React.PropsWithChildren<", + "CellActionsProps", + ">) => JSX.Element" + ], + "path": "packages/kbn-cell-actions/src/components/cell_actions.tsx", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActions.$1", + "type": "CompoundType", + "tags": [], + "label": "{\n field,\n triggerId,\n children,\n mode,\n showActionTooltips = true,\n visibleCellActions = 3,\n metadata,\n}", + "description": [], + "signature": [ + "React.PropsWithChildren<", + "CellActionsProps", + ">" + ], + "path": "packages/kbn-cell-actions/src/components/cell_actions.tsx", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionsProvider", + "type": "Function", + "tags": [], + "label": "CellActionsProvider", + "description": [], + "signature": [ + "({ children, getTriggerCompatibleActions, }: React.PropsWithChildren<", + "CellActionsProviderProps", + ">) => JSX.Element" + ], + "path": "packages/kbn-cell-actions/src/context/cell_actions_context.tsx", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionsProvider.$1", + "type": "CompoundType", + "tags": [], + "label": "{\n children,\n getTriggerCompatibleActions,\n}", + "description": [], + "signature": [ + "React.PropsWithChildren<", + "CellActionsProviderProps", + ">" + ], + "path": "packages/kbn-cell-actions/src/context/cell_actions_context.tsx", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.useDataGridColumnsCellActions", + "type": "Function", + "tags": [], + "label": "useDataGridColumnsCellActions", + "description": [], + "signature": [ + "({ fields, triggerId, metadata, }: ", + { + "pluginId": "@kbn/cell-actions", + "scope": "common", + "docId": "kibKbnCellActionsPluginApi", + "section": "def-common.UseDataGridColumnsCellActionsProps", + "text": "UseDataGridColumnsCellActionsProps" + }, + ") => ", + "EuiDataGridColumnCellAction", + "[][]" + ], + "path": "packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.useDataGridColumnsCellActions.$1", + "type": "Object", + "tags": [], + "label": "{\n fields,\n triggerId,\n metadata,\n}", + "description": [], + "signature": [ + { + "pluginId": "@kbn/cell-actions", + "scope": "common", + "docId": "kibKbnCellActionsPluginApi", + "section": "def-common.UseDataGridColumnsCellActionsProps", + "text": "UseDataGridColumnsCellActionsProps" + } + ], + "path": "packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + } + ], + "interfaces": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionExecutionContext", + "type": "Interface", + "tags": [], + "label": "CellActionExecutionContext", + "description": [], + "signature": [ + { + "pluginId": "@kbn/cell-actions", + "scope": "common", + "docId": "kibKbnCellActionsPluginApi", + "section": "def-common.CellActionExecutionContext", + "text": "CellActionExecutionContext" + }, + " extends ", + { + "pluginId": "uiActions", + "scope": "public", + "docId": "kibUiActionsPluginApi", + "section": "def-public.ActionExecutionContext", + "text": "ActionExecutionContext" + }, + "" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionExecutionContext.field", + "type": "Object", + "tags": [], + "label": "field", + "description": [], + "signature": [ + "CellActionField" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionExecutionContext.extraContentNodeRef", + "type": "Object", + "tags": [], + "label": "extraContentNodeRef", + "description": [ + "\nRef to a DOM node where the action can add custom HTML." + ], + "signature": [ + "React.MutableRefObject | undefined" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionExecutionContext.nodeRef", + "type": "Object", + "tags": [], + "label": "nodeRef", + "description": [ + "\nRef to the node where the cell action are rendered." + ], + "signature": [ + "React.MutableRefObject | undefined" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionExecutionContext.metadata", + "type": "Object", + "tags": [], + "label": "metadata", + "description": [ + "\nExtra configurations for actions." + ], + "signature": [ + "Record | undefined" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.UseDataGridColumnsCellActionsProps", + "type": "Interface", + "tags": [], + "label": "UseDataGridColumnsCellActionsProps", + "description": [], + "signature": [ + { + "pluginId": "@kbn/cell-actions", + "scope": "common", + "docId": "kibKbnCellActionsPluginApi", + "section": "def-common.UseDataGridColumnsCellActionsProps", + "text": "UseDataGridColumnsCellActionsProps" + }, + " extends Pick<", + "CellActionsProps", + ", \"metadata\" | \"triggerId\">" + ], + "path": "packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.UseDataGridColumnsCellActionsProps.fields", + "type": "Array", + "tags": [], + "label": "fields", + "description": [], + "signature": [ + "BulkField[]" + ], + "path": "packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "enums": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellActionsMode", + "type": "Enum", + "tags": [], + "label": "CellActionsMode", + "description": [], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "misc": [ + { + "parentPluginId": "@kbn/cell-actions", + "id": "def-common.CellAction", + "type": "Type", + "tags": [], + "label": "CellAction", + "description": [], + "signature": [ + { + "pluginId": "uiActions", + "scope": "public", + "docId": "kibUiActionsPluginApi", + "section": "def-public.Action", + "text": "Action" + }, + "<", + { + "pluginId": "@kbn/cell-actions", + "scope": "common", + "docId": "kibKbnCellActionsPluginApi", + "section": "def-common.CellActionExecutionContext", + "text": "CellActionExecutionContext" + }, + ">" + ], + "path": "packages/kbn-cell-actions/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "objects": [] + } +} \ No newline at end of file diff --git a/api_docs/kbn_cell_actions.mdx b/api_docs/kbn_cell_actions.mdx new file mode 100644 index 0000000000000..377d46d92f228 --- /dev/null +++ b/api_docs/kbn_cell_actions.mdx @@ -0,0 +1,39 @@ +--- +#### +#### This document is auto-generated and is meant to be viewed inside our experimental, new docs system. +#### Reach out in #docs-engineering for more info. +#### +id: kibKbnCellActionsPluginApi +slug: /kibana-dev-docs/api/kbn-cell-actions +title: "@kbn/cell-actions" +image: https://source.unsplash.com/400x175/?github +description: API docs for the @kbn/cell-actions plugin +date: 2023-01-23 +tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/cell-actions'] +--- +import kbnCellActionsObj from './kbn_cell_actions.devdocs.json'; + +Uniform components for displaying UI actions in data cells + +Contact [Owner missing] for questions regarding this plugin. + +**Code health stats** + +| Public API count | Any count | Items lacking comments | Missing exports | +|-------------------|-----------|------------------------|-----------------| +| 15 | 0 | 12 | 3 | + +## Common + +### Functions + + +### Interfaces + + +### Enums + + +### Consts, variables and types + + diff --git a/api_docs/kbn_chart_icons.mdx b/api_docs/kbn_chart_icons.mdx index b28431fa63c13..52af95292454a 100644 --- a/api_docs/kbn_chart_icons.mdx +++ b/api_docs/kbn_chart_icons.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-chart-icons title: "@kbn/chart-icons" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/chart-icons plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/chart-icons'] --- import kbnChartIconsObj from './kbn_chart_icons.devdocs.json'; diff --git a/api_docs/kbn_ci_stats_core.mdx b/api_docs/kbn_ci_stats_core.mdx index 7c1525d0c5053..c7505d1eced66 100644 --- a/api_docs/kbn_ci_stats_core.mdx +++ b/api_docs/kbn_ci_stats_core.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ci-stats-core title: "@kbn/ci-stats-core" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ci-stats-core plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ci-stats-core'] --- import kbnCiStatsCoreObj from './kbn_ci_stats_core.devdocs.json'; diff --git a/api_docs/kbn_ci_stats_performance_metrics.mdx b/api_docs/kbn_ci_stats_performance_metrics.mdx index 93475daa01c6c..54136bd2a7f49 100644 --- a/api_docs/kbn_ci_stats_performance_metrics.mdx +++ b/api_docs/kbn_ci_stats_performance_metrics.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ci-stats-performance-metrics title: "@kbn/ci-stats-performance-metrics" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ci-stats-performance-metrics plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ci-stats-performance-metrics'] --- import kbnCiStatsPerformanceMetricsObj from './kbn_ci_stats_performance_metrics.devdocs.json'; diff --git a/api_docs/kbn_ci_stats_reporter.mdx b/api_docs/kbn_ci_stats_reporter.mdx index 65db6ed620dae..8d2d4da328de4 100644 --- a/api_docs/kbn_ci_stats_reporter.mdx +++ b/api_docs/kbn_ci_stats_reporter.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ci-stats-reporter title: "@kbn/ci-stats-reporter" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ci-stats-reporter plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ci-stats-reporter'] --- import kbnCiStatsReporterObj from './kbn_ci_stats_reporter.devdocs.json'; diff --git a/api_docs/kbn_cli_dev_mode.mdx b/api_docs/kbn_cli_dev_mode.mdx index d3684ae9d7adb..5833acfb320bf 100644 --- a/api_docs/kbn_cli_dev_mode.mdx +++ b/api_docs/kbn_cli_dev_mode.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-cli-dev-mode title: "@kbn/cli-dev-mode" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/cli-dev-mode plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/cli-dev-mode'] --- import kbnCliDevModeObj from './kbn_cli_dev_mode.devdocs.json'; diff --git a/api_docs/kbn_coloring.mdx b/api_docs/kbn_coloring.mdx index 68418049a8a40..ce6d0657d130b 100644 --- a/api_docs/kbn_coloring.mdx +++ b/api_docs/kbn_coloring.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-coloring title: "@kbn/coloring" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/coloring plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/coloring'] --- import kbnColoringObj from './kbn_coloring.devdocs.json'; diff --git a/api_docs/kbn_config.mdx b/api_docs/kbn_config.mdx index 5f8daa694c280..476811ca4558b 100644 --- a/api_docs/kbn_config.mdx +++ b/api_docs/kbn_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-config title: "@kbn/config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/config'] --- import kbnConfigObj from './kbn_config.devdocs.json'; diff --git a/api_docs/kbn_config_mocks.mdx b/api_docs/kbn_config_mocks.mdx index 57f37f8c8d946..80231df093140 100644 --- a/api_docs/kbn_config_mocks.mdx +++ b/api_docs/kbn_config_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-config-mocks title: "@kbn/config-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/config-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/config-mocks'] --- import kbnConfigMocksObj from './kbn_config_mocks.devdocs.json'; diff --git a/api_docs/kbn_config_schema.mdx b/api_docs/kbn_config_schema.mdx index 84bbf658fb8cc..3d28d2b615eb6 100644 --- a/api_docs/kbn_config_schema.mdx +++ b/api_docs/kbn_config_schema.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-config-schema title: "@kbn/config-schema" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/config-schema plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/config-schema'] --- import kbnConfigSchemaObj from './kbn_config_schema.devdocs.json'; diff --git a/api_docs/kbn_content_management_content_editor.mdx b/api_docs/kbn_content_management_content_editor.mdx index 3ccc2ed171f63..5254c0366a748 100644 --- a/api_docs/kbn_content_management_content_editor.mdx +++ b/api_docs/kbn_content_management_content_editor.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-content-management-content-editor title: "@kbn/content-management-content-editor" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/content-management-content-editor plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/content-management-content-editor'] --- import kbnContentManagementContentEditorObj from './kbn_content_management_content_editor.devdocs.json'; diff --git a/api_docs/kbn_content_management_table_list.mdx b/api_docs/kbn_content_management_table_list.mdx index 68b8d15e41935..895bf144d26dc 100644 --- a/api_docs/kbn_content_management_table_list.mdx +++ b/api_docs/kbn_content_management_table_list.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-content-management-table-list title: "@kbn/content-management-table-list" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/content-management-table-list plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/content-management-table-list'] --- import kbnContentManagementTableListObj from './kbn_content_management_table_list.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_browser.mdx b/api_docs/kbn_core_analytics_browser.mdx index 7a1d91a0137da..3a32fe0dc523b 100644 --- a/api_docs/kbn_core_analytics_browser.mdx +++ b/api_docs/kbn_core_analytics_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-browser title: "@kbn/core-analytics-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-browser'] --- import kbnCoreAnalyticsBrowserObj from './kbn_core_analytics_browser.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_browser_internal.mdx b/api_docs/kbn_core_analytics_browser_internal.mdx index 3d2b49044c92f..cd7600238a5c6 100644 --- a/api_docs/kbn_core_analytics_browser_internal.mdx +++ b/api_docs/kbn_core_analytics_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-browser-internal title: "@kbn/core-analytics-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-browser-internal'] --- import kbnCoreAnalyticsBrowserInternalObj from './kbn_core_analytics_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_browser_mocks.mdx b/api_docs/kbn_core_analytics_browser_mocks.mdx index bc756a75cc153..848a7ab61c7f2 100644 --- a/api_docs/kbn_core_analytics_browser_mocks.mdx +++ b/api_docs/kbn_core_analytics_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-browser-mocks title: "@kbn/core-analytics-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-browser-mocks'] --- import kbnCoreAnalyticsBrowserMocksObj from './kbn_core_analytics_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_server.mdx b/api_docs/kbn_core_analytics_server.mdx index 9a8e864e75fad..39772b9012db3 100644 --- a/api_docs/kbn_core_analytics_server.mdx +++ b/api_docs/kbn_core_analytics_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-server title: "@kbn/core-analytics-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-server'] --- import kbnCoreAnalyticsServerObj from './kbn_core_analytics_server.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_server_internal.mdx b/api_docs/kbn_core_analytics_server_internal.mdx index 47fd0f6b5e19d..b0673db8e595c 100644 --- a/api_docs/kbn_core_analytics_server_internal.mdx +++ b/api_docs/kbn_core_analytics_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-server-internal title: "@kbn/core-analytics-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-server-internal'] --- import kbnCoreAnalyticsServerInternalObj from './kbn_core_analytics_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_analytics_server_mocks.mdx b/api_docs/kbn_core_analytics_server_mocks.mdx index 93b772ec2ccc5..931895d86d683 100644 --- a/api_docs/kbn_core_analytics_server_mocks.mdx +++ b/api_docs/kbn_core_analytics_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-analytics-server-mocks title: "@kbn/core-analytics-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-analytics-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-analytics-server-mocks'] --- import kbnCoreAnalyticsServerMocksObj from './kbn_core_analytics_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_application_browser.devdocs.json b/api_docs/kbn_core_application_browser.devdocs.json index 759b5a5c5c861..7804ba2910977 100644 --- a/api_docs/kbn_core_application_browser.devdocs.json +++ b/api_docs/kbn_core_application_browser.devdocs.json @@ -1200,12 +1200,10 @@ "parentPluginId": "@kbn/core-application-browser", "id": "def-common.AppMountParameters.onAppLeave", "type": "Function", - "tags": [ - "deprecated" - ], + "tags": [], "label": "onAppLeave", "description": [ - "\nA function that can be used to register a handler that will be called\nwhen the user is leaving the current application, allowing to\nprompt a confirmation message before actually changing the page.\n\nThis will be called either when the user goes to another application, or when\ntrying to close the tab or manually changing the url.\n" + "\nA function that can be used to register a handler that will be called\nwhen the user is leaving the current application, allowing to\nprompt a confirmation message before actually changing the page.\n\nThis will be called either when the user goes to another application, or when\ntrying to close the tab or manually changing the url.\n\n" ], "signature": [ "(handler: ", @@ -1219,87 +1217,8 @@ ") => void" ], "path": "packages/core/application/core-application-browser/src/app_mount.ts", - "deprecated": true, - "removeBy": "8.8.0", + "deprecated": false, "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" - }, - { - "plugin": "@kbn/core-application-browser-mocks", - "path": "packages/core/application/core-application-browser-mocks/src/application_service.mock.ts" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/components/visualize_top_nav.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/components/visualize_editor_common.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/app.tsx" - }, - { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/visualize_app/index.tsx" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/dashboard_app/types.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/plugin.tsx" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/types.ts" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/types.ts" - }, - { - "plugin": "lens", - "path": "x-pack/plugins/lens/public/app_plugin/mounter.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/render_app.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx" - }, - { - "plugin": "maps", - "path": "x-pack/plugins/maps/public/routes/map_page/map_page.tsx" - }, - { - "plugin": "ml", - "path": "x-pack/plugins/ml/public/application/app.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/plugin.tsx" - }, - { - "plugin": "security", - "path": "x-pack/plugins/security/public/authentication/logout/logout_app.test.ts" - }, - { - "plugin": "core", - "path": "src/core/public/mocks.ts" - } - ], "children": [ { "parentPluginId": "@kbn/core-application-browser", @@ -1924,9 +1843,7 @@ "parentPluginId": "@kbn/core-application-browser", "id": "def-common.AppLeaveHandler", "type": "Type", - "tags": [ - "deprecated" - ], + "tags": [], "label": "AppLeaveHandler", "description": [ "\nA handler that will be executed before leaving the application, either when\ngoing to another application or when closing the browser tab or manually changing\nthe url.\nShould return `confirm` to prompt a message to the user before leaving the page, or `default`\nto keep the default behavior (doing nothing).\n\nSee {@link AppMountParameters} for detailed usage examples.\n" @@ -1950,95 +1867,8 @@ } ], "path": "packages/core/application/core-application-browser/src/app_leave.ts", - "deprecated": true, - "removeBy": "8.8.0", + "deprecated": false, "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_container.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_router.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/ui/app_router.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_leave.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_leave.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" - }, - { - "plugin": "@kbn/core-application-browser-internal", - "path": "packages/core/application/core-application-browser-internal/src/application_service.tsx" - }, - { - "plugin": "core", - "path": "src/core/public/index.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/timelines/components/flyout/index.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/types.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/types.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/routes.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/routes.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/app/app.tsx" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts" - }, - { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/public/common/hooks/timeline/use_timeline_save_prompt.ts" - } - ], "returnComment": [], "children": [ { diff --git a/api_docs/kbn_core_application_browser.mdx b/api_docs/kbn_core_application_browser.mdx index 1e22382c5abff..1b000222f38df 100644 --- a/api_docs/kbn_core_application_browser.mdx +++ b/api_docs/kbn_core_application_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-application-browser title: "@kbn/core-application-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-application-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-application-browser'] --- import kbnCoreApplicationBrowserObj from './kbn_core_application_browser.devdocs.json'; diff --git a/api_docs/kbn_core_application_browser_internal.mdx b/api_docs/kbn_core_application_browser_internal.mdx index 4703e70fae435..19d0499b0d44b 100644 --- a/api_docs/kbn_core_application_browser_internal.mdx +++ b/api_docs/kbn_core_application_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-application-browser-internal title: "@kbn/core-application-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-application-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-application-browser-internal'] --- import kbnCoreApplicationBrowserInternalObj from './kbn_core_application_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_application_browser_mocks.mdx b/api_docs/kbn_core_application_browser_mocks.mdx index dfd0c1052b88f..13bca83e605e0 100644 --- a/api_docs/kbn_core_application_browser_mocks.mdx +++ b/api_docs/kbn_core_application_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-application-browser-mocks title: "@kbn/core-application-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-application-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-application-browser-mocks'] --- import kbnCoreApplicationBrowserMocksObj from './kbn_core_application_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_application_common.mdx b/api_docs/kbn_core_application_common.mdx index ec7b5806fff32..f99343223f08a 100644 --- a/api_docs/kbn_core_application_common.mdx +++ b/api_docs/kbn_core_application_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-application-common title: "@kbn/core-application-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-application-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-application-common'] --- import kbnCoreApplicationCommonObj from './kbn_core_application_common.devdocs.json'; diff --git a/api_docs/kbn_core_apps_browser_internal.mdx b/api_docs/kbn_core_apps_browser_internal.mdx index 5cc41d84c9f54..2f932e711b110 100644 --- a/api_docs/kbn_core_apps_browser_internal.mdx +++ b/api_docs/kbn_core_apps_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-apps-browser-internal title: "@kbn/core-apps-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-apps-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-apps-browser-internal'] --- import kbnCoreAppsBrowserInternalObj from './kbn_core_apps_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_apps_browser_mocks.mdx b/api_docs/kbn_core_apps_browser_mocks.mdx index c9b9a3e975aa1..1529828daf546 100644 --- a/api_docs/kbn_core_apps_browser_mocks.mdx +++ b/api_docs/kbn_core_apps_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-apps-browser-mocks title: "@kbn/core-apps-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-apps-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-apps-browser-mocks'] --- import kbnCoreAppsBrowserMocksObj from './kbn_core_apps_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_apps_server_internal.mdx b/api_docs/kbn_core_apps_server_internal.mdx index b9277c2c0284d..183c14f1074b8 100644 --- a/api_docs/kbn_core_apps_server_internal.mdx +++ b/api_docs/kbn_core_apps_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-apps-server-internal title: "@kbn/core-apps-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-apps-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-apps-server-internal'] --- import kbnCoreAppsServerInternalObj from './kbn_core_apps_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_base_browser_mocks.mdx b/api_docs/kbn_core_base_browser_mocks.mdx index 854eccc1b921f..2d43ce87eb23b 100644 --- a/api_docs/kbn_core_base_browser_mocks.mdx +++ b/api_docs/kbn_core_base_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-base-browser-mocks title: "@kbn/core-base-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-base-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-base-browser-mocks'] --- import kbnCoreBaseBrowserMocksObj from './kbn_core_base_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_base_common.mdx b/api_docs/kbn_core_base_common.mdx index 501a88d08e7a5..873cef04fdd0f 100644 --- a/api_docs/kbn_core_base_common.mdx +++ b/api_docs/kbn_core_base_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-base-common title: "@kbn/core-base-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-base-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-base-common'] --- import kbnCoreBaseCommonObj from './kbn_core_base_common.devdocs.json'; diff --git a/api_docs/kbn_core_base_server_internal.mdx b/api_docs/kbn_core_base_server_internal.mdx index e8b84dd1ac70f..098e8edbb8a96 100644 --- a/api_docs/kbn_core_base_server_internal.mdx +++ b/api_docs/kbn_core_base_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-base-server-internal title: "@kbn/core-base-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-base-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-base-server-internal'] --- import kbnCoreBaseServerInternalObj from './kbn_core_base_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_base_server_mocks.mdx b/api_docs/kbn_core_base_server_mocks.mdx index 9042e62c59bea..7b250f1e87214 100644 --- a/api_docs/kbn_core_base_server_mocks.mdx +++ b/api_docs/kbn_core_base_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-base-server-mocks title: "@kbn/core-base-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-base-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-base-server-mocks'] --- import kbnCoreBaseServerMocksObj from './kbn_core_base_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_capabilities_browser_mocks.mdx b/api_docs/kbn_core_capabilities_browser_mocks.mdx index 553496ecf484a..dc8063c1895e4 100644 --- a/api_docs/kbn_core_capabilities_browser_mocks.mdx +++ b/api_docs/kbn_core_capabilities_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-capabilities-browser-mocks title: "@kbn/core-capabilities-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-capabilities-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-capabilities-browser-mocks'] --- import kbnCoreCapabilitiesBrowserMocksObj from './kbn_core_capabilities_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_capabilities_common.mdx b/api_docs/kbn_core_capabilities_common.mdx index ef94ed601ba69..2eb70a4ab56b4 100644 --- a/api_docs/kbn_core_capabilities_common.mdx +++ b/api_docs/kbn_core_capabilities_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-capabilities-common title: "@kbn/core-capabilities-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-capabilities-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-capabilities-common'] --- import kbnCoreCapabilitiesCommonObj from './kbn_core_capabilities_common.devdocs.json'; diff --git a/api_docs/kbn_core_capabilities_server.mdx b/api_docs/kbn_core_capabilities_server.mdx index 82b52256af894..e2b31bbf1094f 100644 --- a/api_docs/kbn_core_capabilities_server.mdx +++ b/api_docs/kbn_core_capabilities_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-capabilities-server title: "@kbn/core-capabilities-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-capabilities-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-capabilities-server'] --- import kbnCoreCapabilitiesServerObj from './kbn_core_capabilities_server.devdocs.json'; diff --git a/api_docs/kbn_core_capabilities_server_mocks.mdx b/api_docs/kbn_core_capabilities_server_mocks.mdx index 7265551f32570..1b568f5f13fb3 100644 --- a/api_docs/kbn_core_capabilities_server_mocks.mdx +++ b/api_docs/kbn_core_capabilities_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-capabilities-server-mocks title: "@kbn/core-capabilities-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-capabilities-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-capabilities-server-mocks'] --- import kbnCoreCapabilitiesServerMocksObj from './kbn_core_capabilities_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_chrome_browser.devdocs.json b/api_docs/kbn_core_chrome_browser.devdocs.json index 11d74117c8415..f5c7db656e790 100644 --- a/api_docs/kbn_core_chrome_browser.devdocs.json +++ b/api_docs/kbn_core_chrome_browser.devdocs.json @@ -422,6 +422,22 @@ "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-chrome-browser", + "id": "def-common.ChromeHelpExtensionMenuCustomLink.external", + "type": "CompoundType", + "tags": [], + "label": "external", + "description": [ + "\nOpens link in new tab" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/chrome/core-chrome-browser/src/help_extension.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false diff --git a/api_docs/kbn_core_chrome_browser.mdx b/api_docs/kbn_core_chrome_browser.mdx index a9b56861226b4..f472ed6332be7 100644 --- a/api_docs/kbn_core_chrome_browser.mdx +++ b/api_docs/kbn_core_chrome_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-chrome-browser title: "@kbn/core-chrome-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-chrome-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-chrome-browser'] --- import kbnCoreChromeBrowserObj from './kbn_core_chrome_browser.devdocs.json'; @@ -21,7 +21,7 @@ Contact Kibana Core for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 119 | 0 | 46 | 0 | +| 120 | 0 | 46 | 0 | ## Common diff --git a/api_docs/kbn_core_chrome_browser_mocks.mdx b/api_docs/kbn_core_chrome_browser_mocks.mdx index 984143fca593b..210d293b7643f 100644 --- a/api_docs/kbn_core_chrome_browser_mocks.mdx +++ b/api_docs/kbn_core_chrome_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-chrome-browser-mocks title: "@kbn/core-chrome-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-chrome-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-chrome-browser-mocks'] --- import kbnCoreChromeBrowserMocksObj from './kbn_core_chrome_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_config_server_internal.mdx b/api_docs/kbn_core_config_server_internal.mdx index 94965fbf1999c..f9497e608049b 100644 --- a/api_docs/kbn_core_config_server_internal.mdx +++ b/api_docs/kbn_core_config_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-config-server-internal title: "@kbn/core-config-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-config-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-config-server-internal'] --- import kbnCoreConfigServerInternalObj from './kbn_core_config_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_browser.mdx b/api_docs/kbn_core_custom_branding_browser.mdx index 1c6283499631f..c41905d6975c7 100644 --- a/api_docs/kbn_core_custom_branding_browser.mdx +++ b/api_docs/kbn_core_custom_branding_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-browser title: "@kbn/core-custom-branding-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-browser'] --- import kbnCoreCustomBrandingBrowserObj from './kbn_core_custom_branding_browser.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_browser_internal.mdx b/api_docs/kbn_core_custom_branding_browser_internal.mdx index a27c16ddc13d9..4f962aece5402 100644 --- a/api_docs/kbn_core_custom_branding_browser_internal.mdx +++ b/api_docs/kbn_core_custom_branding_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-browser-internal title: "@kbn/core-custom-branding-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-browser-internal'] --- import kbnCoreCustomBrandingBrowserInternalObj from './kbn_core_custom_branding_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_browser_mocks.mdx b/api_docs/kbn_core_custom_branding_browser_mocks.mdx index 21a6de75a1d12..28552060b6c6b 100644 --- a/api_docs/kbn_core_custom_branding_browser_mocks.mdx +++ b/api_docs/kbn_core_custom_branding_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-browser-mocks title: "@kbn/core-custom-branding-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-browser-mocks'] --- import kbnCoreCustomBrandingBrowserMocksObj from './kbn_core_custom_branding_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_common.mdx b/api_docs/kbn_core_custom_branding_common.mdx index 5c15a6f9a7ebb..7add27a8fe2ce 100644 --- a/api_docs/kbn_core_custom_branding_common.mdx +++ b/api_docs/kbn_core_custom_branding_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-common title: "@kbn/core-custom-branding-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-common'] --- import kbnCoreCustomBrandingCommonObj from './kbn_core_custom_branding_common.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_server.mdx b/api_docs/kbn_core_custom_branding_server.mdx index 75e6dbee2b603..56d3987a24959 100644 --- a/api_docs/kbn_core_custom_branding_server.mdx +++ b/api_docs/kbn_core_custom_branding_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-server title: "@kbn/core-custom-branding-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-server'] --- import kbnCoreCustomBrandingServerObj from './kbn_core_custom_branding_server.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_server_internal.mdx b/api_docs/kbn_core_custom_branding_server_internal.mdx index 7a632f526d780..e2d93648e1814 100644 --- a/api_docs/kbn_core_custom_branding_server_internal.mdx +++ b/api_docs/kbn_core_custom_branding_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-server-internal title: "@kbn/core-custom-branding-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-server-internal'] --- import kbnCoreCustomBrandingServerInternalObj from './kbn_core_custom_branding_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_custom_branding_server_mocks.mdx b/api_docs/kbn_core_custom_branding_server_mocks.mdx index fa6b31f81e376..1819a2f2e49e6 100644 --- a/api_docs/kbn_core_custom_branding_server_mocks.mdx +++ b/api_docs/kbn_core_custom_branding_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-custom-branding-server-mocks title: "@kbn/core-custom-branding-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-custom-branding-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-custom-branding-server-mocks'] --- import kbnCoreCustomBrandingServerMocksObj from './kbn_core_custom_branding_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_browser.mdx b/api_docs/kbn_core_deprecations_browser.mdx index 6d9d0023e40bf..1d72cb261fe8f 100644 --- a/api_docs/kbn_core_deprecations_browser.mdx +++ b/api_docs/kbn_core_deprecations_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-browser title: "@kbn/core-deprecations-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-browser'] --- import kbnCoreDeprecationsBrowserObj from './kbn_core_deprecations_browser.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_browser_internal.mdx b/api_docs/kbn_core_deprecations_browser_internal.mdx index 716ff52e30287..4fa0c0e572d0f 100644 --- a/api_docs/kbn_core_deprecations_browser_internal.mdx +++ b/api_docs/kbn_core_deprecations_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-browser-internal title: "@kbn/core-deprecations-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-browser-internal'] --- import kbnCoreDeprecationsBrowserInternalObj from './kbn_core_deprecations_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_browser_mocks.mdx b/api_docs/kbn_core_deprecations_browser_mocks.mdx index 699205a6dff9e..2af5f8ccb7d28 100644 --- a/api_docs/kbn_core_deprecations_browser_mocks.mdx +++ b/api_docs/kbn_core_deprecations_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-browser-mocks title: "@kbn/core-deprecations-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-browser-mocks'] --- import kbnCoreDeprecationsBrowserMocksObj from './kbn_core_deprecations_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_common.mdx b/api_docs/kbn_core_deprecations_common.mdx index bbbac870d5335..553f8f1f00da6 100644 --- a/api_docs/kbn_core_deprecations_common.mdx +++ b/api_docs/kbn_core_deprecations_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-common title: "@kbn/core-deprecations-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-common'] --- import kbnCoreDeprecationsCommonObj from './kbn_core_deprecations_common.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_server.mdx b/api_docs/kbn_core_deprecations_server.mdx index b881647823acb..a32f121c72c7c 100644 --- a/api_docs/kbn_core_deprecations_server.mdx +++ b/api_docs/kbn_core_deprecations_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-server title: "@kbn/core-deprecations-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-server'] --- import kbnCoreDeprecationsServerObj from './kbn_core_deprecations_server.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_server_internal.mdx b/api_docs/kbn_core_deprecations_server_internal.mdx index 3d17713b3d95d..9d052148bbe1e 100644 --- a/api_docs/kbn_core_deprecations_server_internal.mdx +++ b/api_docs/kbn_core_deprecations_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-server-internal title: "@kbn/core-deprecations-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-server-internal'] --- import kbnCoreDeprecationsServerInternalObj from './kbn_core_deprecations_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_deprecations_server_mocks.mdx b/api_docs/kbn_core_deprecations_server_mocks.mdx index 158b5fcadc705..19cc520cdd97f 100644 --- a/api_docs/kbn_core_deprecations_server_mocks.mdx +++ b/api_docs/kbn_core_deprecations_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-deprecations-server-mocks title: "@kbn/core-deprecations-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-deprecations-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-deprecations-server-mocks'] --- import kbnCoreDeprecationsServerMocksObj from './kbn_core_deprecations_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_doc_links_browser.mdx b/api_docs/kbn_core_doc_links_browser.mdx index a8f16a527d839..cfe7fc58d8f26 100644 --- a/api_docs/kbn_core_doc_links_browser.mdx +++ b/api_docs/kbn_core_doc_links_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-doc-links-browser title: "@kbn/core-doc-links-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-doc-links-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-doc-links-browser'] --- import kbnCoreDocLinksBrowserObj from './kbn_core_doc_links_browser.devdocs.json'; diff --git a/api_docs/kbn_core_doc_links_browser_mocks.mdx b/api_docs/kbn_core_doc_links_browser_mocks.mdx index 3e59d579b7cdc..d3e5f36af222d 100644 --- a/api_docs/kbn_core_doc_links_browser_mocks.mdx +++ b/api_docs/kbn_core_doc_links_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-doc-links-browser-mocks title: "@kbn/core-doc-links-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-doc-links-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-doc-links-browser-mocks'] --- import kbnCoreDocLinksBrowserMocksObj from './kbn_core_doc_links_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_doc_links_server.mdx b/api_docs/kbn_core_doc_links_server.mdx index ea4d17d85e064..32f3a48ee9761 100644 --- a/api_docs/kbn_core_doc_links_server.mdx +++ b/api_docs/kbn_core_doc_links_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-doc-links-server title: "@kbn/core-doc-links-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-doc-links-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-doc-links-server'] --- import kbnCoreDocLinksServerObj from './kbn_core_doc_links_server.devdocs.json'; diff --git a/api_docs/kbn_core_doc_links_server_mocks.mdx b/api_docs/kbn_core_doc_links_server_mocks.mdx index 1085010c4f63e..0feff8677eb7f 100644 --- a/api_docs/kbn_core_doc_links_server_mocks.mdx +++ b/api_docs/kbn_core_doc_links_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-doc-links-server-mocks title: "@kbn/core-doc-links-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-doc-links-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-doc-links-server-mocks'] --- import kbnCoreDocLinksServerMocksObj from './kbn_core_doc_links_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_elasticsearch_client_server_internal.mdx b/api_docs/kbn_core_elasticsearch_client_server_internal.mdx index 9fac6a9393f54..9744c7e7fe8d9 100644 --- a/api_docs/kbn_core_elasticsearch_client_server_internal.mdx +++ b/api_docs/kbn_core_elasticsearch_client_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-elasticsearch-client-server-internal title: "@kbn/core-elasticsearch-client-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-elasticsearch-client-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-elasticsearch-client-server-internal'] --- import kbnCoreElasticsearchClientServerInternalObj from './kbn_core_elasticsearch_client_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_elasticsearch_client_server_mocks.mdx b/api_docs/kbn_core_elasticsearch_client_server_mocks.mdx index 8bb6d7854ab8c..d3fff24d4de39 100644 --- a/api_docs/kbn_core_elasticsearch_client_server_mocks.mdx +++ b/api_docs/kbn_core_elasticsearch_client_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-elasticsearch-client-server-mocks title: "@kbn/core-elasticsearch-client-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-elasticsearch-client-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-elasticsearch-client-server-mocks'] --- import kbnCoreElasticsearchClientServerMocksObj from './kbn_core_elasticsearch_client_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_elasticsearch_server.mdx b/api_docs/kbn_core_elasticsearch_server.mdx index e7243805529df..33e7486d780d9 100644 --- a/api_docs/kbn_core_elasticsearch_server.mdx +++ b/api_docs/kbn_core_elasticsearch_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-elasticsearch-server title: "@kbn/core-elasticsearch-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-elasticsearch-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-elasticsearch-server'] --- import kbnCoreElasticsearchServerObj from './kbn_core_elasticsearch_server.devdocs.json'; diff --git a/api_docs/kbn_core_elasticsearch_server_internal.mdx b/api_docs/kbn_core_elasticsearch_server_internal.mdx index 86a4704eca32b..cde7facd14d47 100644 --- a/api_docs/kbn_core_elasticsearch_server_internal.mdx +++ b/api_docs/kbn_core_elasticsearch_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-elasticsearch-server-internal title: "@kbn/core-elasticsearch-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-elasticsearch-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-elasticsearch-server-internal'] --- import kbnCoreElasticsearchServerInternalObj from './kbn_core_elasticsearch_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_elasticsearch_server_mocks.mdx b/api_docs/kbn_core_elasticsearch_server_mocks.mdx index 2d88b369bfd30..d3a5365988248 100644 --- a/api_docs/kbn_core_elasticsearch_server_mocks.mdx +++ b/api_docs/kbn_core_elasticsearch_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-elasticsearch-server-mocks title: "@kbn/core-elasticsearch-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-elasticsearch-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-elasticsearch-server-mocks'] --- import kbnCoreElasticsearchServerMocksObj from './kbn_core_elasticsearch_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_environment_server_internal.mdx b/api_docs/kbn_core_environment_server_internal.mdx index a29a8ec13fbd8..409cdcd49870c 100644 --- a/api_docs/kbn_core_environment_server_internal.mdx +++ b/api_docs/kbn_core_environment_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-environment-server-internal title: "@kbn/core-environment-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-environment-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-environment-server-internal'] --- import kbnCoreEnvironmentServerInternalObj from './kbn_core_environment_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_environment_server_mocks.mdx b/api_docs/kbn_core_environment_server_mocks.mdx index 0e0b159fa6821..b89670e17ae5f 100644 --- a/api_docs/kbn_core_environment_server_mocks.mdx +++ b/api_docs/kbn_core_environment_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-environment-server-mocks title: "@kbn/core-environment-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-environment-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-environment-server-mocks'] --- import kbnCoreEnvironmentServerMocksObj from './kbn_core_environment_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_browser.mdx b/api_docs/kbn_core_execution_context_browser.mdx index 0095a1f843e7c..37296a79ebb59 100644 --- a/api_docs/kbn_core_execution_context_browser.mdx +++ b/api_docs/kbn_core_execution_context_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-browser title: "@kbn/core-execution-context-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-browser'] --- import kbnCoreExecutionContextBrowserObj from './kbn_core_execution_context_browser.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_browser_internal.mdx b/api_docs/kbn_core_execution_context_browser_internal.mdx index 08ff3a8998203..d409c9739834c 100644 --- a/api_docs/kbn_core_execution_context_browser_internal.mdx +++ b/api_docs/kbn_core_execution_context_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-browser-internal title: "@kbn/core-execution-context-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-browser-internal'] --- import kbnCoreExecutionContextBrowserInternalObj from './kbn_core_execution_context_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_browser_mocks.mdx b/api_docs/kbn_core_execution_context_browser_mocks.mdx index 213b91f9f42b8..922fedcafe11e 100644 --- a/api_docs/kbn_core_execution_context_browser_mocks.mdx +++ b/api_docs/kbn_core_execution_context_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-browser-mocks title: "@kbn/core-execution-context-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-browser-mocks'] --- import kbnCoreExecutionContextBrowserMocksObj from './kbn_core_execution_context_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_common.mdx b/api_docs/kbn_core_execution_context_common.mdx index acdd53c71e2d7..1f5aabaa16619 100644 --- a/api_docs/kbn_core_execution_context_common.mdx +++ b/api_docs/kbn_core_execution_context_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-common title: "@kbn/core-execution-context-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-common'] --- import kbnCoreExecutionContextCommonObj from './kbn_core_execution_context_common.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_server.mdx b/api_docs/kbn_core_execution_context_server.mdx index ca79163131d9d..c8d9ee7269bc5 100644 --- a/api_docs/kbn_core_execution_context_server.mdx +++ b/api_docs/kbn_core_execution_context_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-server title: "@kbn/core-execution-context-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-server'] --- import kbnCoreExecutionContextServerObj from './kbn_core_execution_context_server.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_server_internal.mdx b/api_docs/kbn_core_execution_context_server_internal.mdx index 28c3c59b22d71..d585b6312d6d9 100644 --- a/api_docs/kbn_core_execution_context_server_internal.mdx +++ b/api_docs/kbn_core_execution_context_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-server-internal title: "@kbn/core-execution-context-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-server-internal'] --- import kbnCoreExecutionContextServerInternalObj from './kbn_core_execution_context_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_execution_context_server_mocks.mdx b/api_docs/kbn_core_execution_context_server_mocks.mdx index 034799a64176a..88c8a458f00fa 100644 --- a/api_docs/kbn_core_execution_context_server_mocks.mdx +++ b/api_docs/kbn_core_execution_context_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-execution-context-server-mocks title: "@kbn/core-execution-context-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-execution-context-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-execution-context-server-mocks'] --- import kbnCoreExecutionContextServerMocksObj from './kbn_core_execution_context_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_fatal_errors_browser.mdx b/api_docs/kbn_core_fatal_errors_browser.mdx index 1856b83401dd8..3054d95b86f6a 100644 --- a/api_docs/kbn_core_fatal_errors_browser.mdx +++ b/api_docs/kbn_core_fatal_errors_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-fatal-errors-browser title: "@kbn/core-fatal-errors-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-fatal-errors-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-fatal-errors-browser'] --- import kbnCoreFatalErrorsBrowserObj from './kbn_core_fatal_errors_browser.devdocs.json'; diff --git a/api_docs/kbn_core_fatal_errors_browser_mocks.mdx b/api_docs/kbn_core_fatal_errors_browser_mocks.mdx index 57ee12eb2cd76..886c87b57eee9 100644 --- a/api_docs/kbn_core_fatal_errors_browser_mocks.mdx +++ b/api_docs/kbn_core_fatal_errors_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-fatal-errors-browser-mocks title: "@kbn/core-fatal-errors-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-fatal-errors-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-fatal-errors-browser-mocks'] --- import kbnCoreFatalErrorsBrowserMocksObj from './kbn_core_fatal_errors_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_http_browser.mdx b/api_docs/kbn_core_http_browser.mdx index fde5d3fc2fa58..87b58d6de05c8 100644 --- a/api_docs/kbn_core_http_browser.mdx +++ b/api_docs/kbn_core_http_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-browser title: "@kbn/core-http-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-browser'] --- import kbnCoreHttpBrowserObj from './kbn_core_http_browser.devdocs.json'; diff --git a/api_docs/kbn_core_http_browser_internal.mdx b/api_docs/kbn_core_http_browser_internal.mdx index 413bd82ef9cae..0ef208f015bd3 100644 --- a/api_docs/kbn_core_http_browser_internal.mdx +++ b/api_docs/kbn_core_http_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-browser-internal title: "@kbn/core-http-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-browser-internal'] --- import kbnCoreHttpBrowserInternalObj from './kbn_core_http_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_http_browser_mocks.mdx b/api_docs/kbn_core_http_browser_mocks.mdx index 4034e8442c9e5..bf50cf4391221 100644 --- a/api_docs/kbn_core_http_browser_mocks.mdx +++ b/api_docs/kbn_core_http_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-browser-mocks title: "@kbn/core-http-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-browser-mocks'] --- import kbnCoreHttpBrowserMocksObj from './kbn_core_http_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_http_common.mdx b/api_docs/kbn_core_http_common.mdx index 2ebd60b4d3797..a277903e323c0 100644 --- a/api_docs/kbn_core_http_common.mdx +++ b/api_docs/kbn_core_http_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-common title: "@kbn/core-http-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-common'] --- import kbnCoreHttpCommonObj from './kbn_core_http_common.devdocs.json'; diff --git a/api_docs/kbn_core_http_context_server_mocks.mdx b/api_docs/kbn_core_http_context_server_mocks.mdx index 67e3bd22f002a..ee17e87ef09ca 100644 --- a/api_docs/kbn_core_http_context_server_mocks.mdx +++ b/api_docs/kbn_core_http_context_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-context-server-mocks title: "@kbn/core-http-context-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-context-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-context-server-mocks'] --- import kbnCoreHttpContextServerMocksObj from './kbn_core_http_context_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_http_request_handler_context_server.mdx b/api_docs/kbn_core_http_request_handler_context_server.mdx index be4e5d4f5f82b..94ca69a24b30f 100644 --- a/api_docs/kbn_core_http_request_handler_context_server.mdx +++ b/api_docs/kbn_core_http_request_handler_context_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-request-handler-context-server title: "@kbn/core-http-request-handler-context-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-request-handler-context-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-request-handler-context-server'] --- import kbnCoreHttpRequestHandlerContextServerObj from './kbn_core_http_request_handler_context_server.devdocs.json'; diff --git a/api_docs/kbn_core_http_resources_server.mdx b/api_docs/kbn_core_http_resources_server.mdx index 50e2ef853f595..954223310027d 100644 --- a/api_docs/kbn_core_http_resources_server.mdx +++ b/api_docs/kbn_core_http_resources_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-resources-server title: "@kbn/core-http-resources-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-resources-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-resources-server'] --- import kbnCoreHttpResourcesServerObj from './kbn_core_http_resources_server.devdocs.json'; diff --git a/api_docs/kbn_core_http_resources_server_internal.mdx b/api_docs/kbn_core_http_resources_server_internal.mdx index 299b9a0ba1e70..518aad2c5b609 100644 --- a/api_docs/kbn_core_http_resources_server_internal.mdx +++ b/api_docs/kbn_core_http_resources_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-resources-server-internal title: "@kbn/core-http-resources-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-resources-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-resources-server-internal'] --- import kbnCoreHttpResourcesServerInternalObj from './kbn_core_http_resources_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_http_resources_server_mocks.mdx b/api_docs/kbn_core_http_resources_server_mocks.mdx index 1669e41bc417a..dc3cd6de83c1e 100644 --- a/api_docs/kbn_core_http_resources_server_mocks.mdx +++ b/api_docs/kbn_core_http_resources_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-resources-server-mocks title: "@kbn/core-http-resources-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-resources-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-resources-server-mocks'] --- import kbnCoreHttpResourcesServerMocksObj from './kbn_core_http_resources_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_http_router_server_internal.mdx b/api_docs/kbn_core_http_router_server_internal.mdx index edf932e97d4c0..b3f7f41ffe833 100644 --- a/api_docs/kbn_core_http_router_server_internal.mdx +++ b/api_docs/kbn_core_http_router_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-router-server-internal title: "@kbn/core-http-router-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-router-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-router-server-internal'] --- import kbnCoreHttpRouterServerInternalObj from './kbn_core_http_router_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_http_router_server_mocks.mdx b/api_docs/kbn_core_http_router_server_mocks.mdx index fbf6cf1d13e4a..8c6969e813f2c 100644 --- a/api_docs/kbn_core_http_router_server_mocks.mdx +++ b/api_docs/kbn_core_http_router_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-router-server-mocks title: "@kbn/core-http-router-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-router-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-router-server-mocks'] --- import kbnCoreHttpRouterServerMocksObj from './kbn_core_http_router_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_http_server.mdx b/api_docs/kbn_core_http_server.mdx index 0c611c3ef3afa..d2526b5cb1059 100644 --- a/api_docs/kbn_core_http_server.mdx +++ b/api_docs/kbn_core_http_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-server title: "@kbn/core-http-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-server'] --- import kbnCoreHttpServerObj from './kbn_core_http_server.devdocs.json'; diff --git a/api_docs/kbn_core_http_server_internal.mdx b/api_docs/kbn_core_http_server_internal.mdx index 57b9b388f2762..e62536c2d2a4d 100644 --- a/api_docs/kbn_core_http_server_internal.mdx +++ b/api_docs/kbn_core_http_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-server-internal title: "@kbn/core-http-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-server-internal'] --- import kbnCoreHttpServerInternalObj from './kbn_core_http_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_http_server_mocks.devdocs.json b/api_docs/kbn_core_http_server_mocks.devdocs.json index 3e64bb2af2e99..03dcec7536ef2 100644 --- a/api_docs/kbn_core_http_server_mocks.devdocs.json +++ b/api_docs/kbn_core_http_server_mocks.devdocs.json @@ -886,7 +886,9 @@ "IncomingMessage", "; res: ", "ServerResponse", - "; }> | undefined; readonly route?: ", + "<", + "IncomingMessage", + ">; }> | undefined; readonly route?: ", { "pluginId": "@kbn/utility-types", "scope": "common", diff --git a/api_docs/kbn_core_http_server_mocks.mdx b/api_docs/kbn_core_http_server_mocks.mdx index 10904f85d851b..63b6a2407f6fc 100644 --- a/api_docs/kbn_core_http_server_mocks.mdx +++ b/api_docs/kbn_core_http_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-http-server-mocks title: "@kbn/core-http-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-http-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-http-server-mocks'] --- import kbnCoreHttpServerMocksObj from './kbn_core_http_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_i18n_browser.mdx b/api_docs/kbn_core_i18n_browser.mdx index 98b40f1bb4e9c..4c6d63a4828c5 100644 --- a/api_docs/kbn_core_i18n_browser.mdx +++ b/api_docs/kbn_core_i18n_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-i18n-browser title: "@kbn/core-i18n-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-i18n-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-i18n-browser'] --- import kbnCoreI18nBrowserObj from './kbn_core_i18n_browser.devdocs.json'; diff --git a/api_docs/kbn_core_i18n_browser_mocks.mdx b/api_docs/kbn_core_i18n_browser_mocks.mdx index 5da8faeb5e5dc..cf1254721cb5d 100644 --- a/api_docs/kbn_core_i18n_browser_mocks.mdx +++ b/api_docs/kbn_core_i18n_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-i18n-browser-mocks title: "@kbn/core-i18n-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-i18n-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-i18n-browser-mocks'] --- import kbnCoreI18nBrowserMocksObj from './kbn_core_i18n_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_i18n_server.mdx b/api_docs/kbn_core_i18n_server.mdx index 7d3b2d9bfcff9..625ceb08bcf09 100644 --- a/api_docs/kbn_core_i18n_server.mdx +++ b/api_docs/kbn_core_i18n_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-i18n-server title: "@kbn/core-i18n-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-i18n-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-i18n-server'] --- import kbnCoreI18nServerObj from './kbn_core_i18n_server.devdocs.json'; diff --git a/api_docs/kbn_core_i18n_server_internal.mdx b/api_docs/kbn_core_i18n_server_internal.mdx index 132a7a801d399..93bdcb9321d86 100644 --- a/api_docs/kbn_core_i18n_server_internal.mdx +++ b/api_docs/kbn_core_i18n_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-i18n-server-internal title: "@kbn/core-i18n-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-i18n-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-i18n-server-internal'] --- import kbnCoreI18nServerInternalObj from './kbn_core_i18n_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_i18n_server_mocks.mdx b/api_docs/kbn_core_i18n_server_mocks.mdx index 4d5420c4e6e17..10598881110bf 100644 --- a/api_docs/kbn_core_i18n_server_mocks.mdx +++ b/api_docs/kbn_core_i18n_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-i18n-server-mocks title: "@kbn/core-i18n-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-i18n-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-i18n-server-mocks'] --- import kbnCoreI18nServerMocksObj from './kbn_core_i18n_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_injected_metadata_browser_mocks.mdx b/api_docs/kbn_core_injected_metadata_browser_mocks.mdx index 9080d30136aba..2f88cec57f526 100644 --- a/api_docs/kbn_core_injected_metadata_browser_mocks.mdx +++ b/api_docs/kbn_core_injected_metadata_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-injected-metadata-browser-mocks title: "@kbn/core-injected-metadata-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-injected-metadata-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-injected-metadata-browser-mocks'] --- import kbnCoreInjectedMetadataBrowserMocksObj from './kbn_core_injected_metadata_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_integrations_browser_internal.mdx b/api_docs/kbn_core_integrations_browser_internal.mdx index bd6ff73af6705..2cba92c218bd4 100644 --- a/api_docs/kbn_core_integrations_browser_internal.mdx +++ b/api_docs/kbn_core_integrations_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-integrations-browser-internal title: "@kbn/core-integrations-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-integrations-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-integrations-browser-internal'] --- import kbnCoreIntegrationsBrowserInternalObj from './kbn_core_integrations_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_integrations_browser_mocks.mdx b/api_docs/kbn_core_integrations_browser_mocks.mdx index 9b58c3dd35662..c6f406e880793 100644 --- a/api_docs/kbn_core_integrations_browser_mocks.mdx +++ b/api_docs/kbn_core_integrations_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-integrations-browser-mocks title: "@kbn/core-integrations-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-integrations-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-integrations-browser-mocks'] --- import kbnCoreIntegrationsBrowserMocksObj from './kbn_core_integrations_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_lifecycle_browser.devdocs.json b/api_docs/kbn_core_lifecycle_browser.devdocs.json index 7dc5c13d4c1de..23c3e5ea7bcb4 100644 --- a/api_docs/kbn_core_lifecycle_browser.devdocs.json +++ b/api_docs/kbn_core_lifecycle_browser.devdocs.json @@ -529,10 +529,12 @@ "parentPluginId": "@kbn/core-lifecycle-browser", "id": "def-common.CoreStart.savedObjects", "type": "Object", - "tags": [], + "tags": [ + "deprecated" + ], "label": "savedObjects", "description": [ - "{@link SavedObjectsStart}" + "\n{@link SavedObjectsStart}" ], "signature": [ { @@ -544,8 +546,362 @@ } ], "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts", - "deprecated": false, - "trackAdoption": false + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugin_context.ts" + }, + { + "plugin": "@kbn/core-root-browser-internal", + "path": "packages/core/root/core-root-browser-internal/src/core_system.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/plugin.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/public/plugin.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/expressions/kibana_context.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/plugin.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/plugin.tsx" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/utils/get_visualization_instance.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object_service.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/index.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/index.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/lens_attribute_service.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/lens_attribute_service.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/visualization.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/visualization.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/mounter.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/embeddable/search_embeddable_factory.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/top_nav/open_search_panel.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/utils/persist_saved_search.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/hooks/use_discover_state.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/discover_main_route.tsx" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/discover_main_route.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "fileUpload", + "path": "x-pack/plugins/file_upload/public/kibana_services.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/kibana_services.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/app.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/platform.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/source_picker.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/source_modal.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/plugin.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_locations_api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_locations_api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/plugin.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/mount_management_section.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/plugin.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts" + }, + { + "plugin": "unifiedSearch", + "path": "src/plugins/unified_search/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/plugin.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/index_or_search/page.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/pages/components/datafeed_step/components/data_view/change_data_view.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/search_bar.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/components/guidance_panel/guidance_panel.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_create_security_dashboard_link.ts" + } + ] }, { "parentPluginId": "@kbn/core-lifecycle-browser", diff --git a/api_docs/kbn_core_lifecycle_browser.mdx b/api_docs/kbn_core_lifecycle_browser.mdx index f7999bb2cedb1..69e573268cbca 100644 --- a/api_docs/kbn_core_lifecycle_browser.mdx +++ b/api_docs/kbn_core_lifecycle_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-lifecycle-browser title: "@kbn/core-lifecycle-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-lifecycle-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-lifecycle-browser'] --- import kbnCoreLifecycleBrowserObj from './kbn_core_lifecycle_browser.devdocs.json'; diff --git a/api_docs/kbn_core_lifecycle_browser_mocks.mdx b/api_docs/kbn_core_lifecycle_browser_mocks.mdx index 10ee5e84a110f..274783a40d081 100644 --- a/api_docs/kbn_core_lifecycle_browser_mocks.mdx +++ b/api_docs/kbn_core_lifecycle_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-lifecycle-browser-mocks title: "@kbn/core-lifecycle-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-lifecycle-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-lifecycle-browser-mocks'] --- import kbnCoreLifecycleBrowserMocksObj from './kbn_core_lifecycle_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_lifecycle_server.mdx b/api_docs/kbn_core_lifecycle_server.mdx index 7b9c2274529de..cfdc040d4e0c1 100644 --- a/api_docs/kbn_core_lifecycle_server.mdx +++ b/api_docs/kbn_core_lifecycle_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-lifecycle-server title: "@kbn/core-lifecycle-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-lifecycle-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-lifecycle-server'] --- import kbnCoreLifecycleServerObj from './kbn_core_lifecycle_server.devdocs.json'; diff --git a/api_docs/kbn_core_lifecycle_server_mocks.mdx b/api_docs/kbn_core_lifecycle_server_mocks.mdx index f91800694fb6c..cc6400c24d1a2 100644 --- a/api_docs/kbn_core_lifecycle_server_mocks.mdx +++ b/api_docs/kbn_core_lifecycle_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-lifecycle-server-mocks title: "@kbn/core-lifecycle-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-lifecycle-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-lifecycle-server-mocks'] --- import kbnCoreLifecycleServerMocksObj from './kbn_core_lifecycle_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_logging_browser_mocks.mdx b/api_docs/kbn_core_logging_browser_mocks.mdx index d3e89324f66c6..df6588cb48cff 100644 --- a/api_docs/kbn_core_logging_browser_mocks.mdx +++ b/api_docs/kbn_core_logging_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-logging-browser-mocks title: "@kbn/core-logging-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-logging-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-logging-browser-mocks'] --- import kbnCoreLoggingBrowserMocksObj from './kbn_core_logging_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_logging_common_internal.mdx b/api_docs/kbn_core_logging_common_internal.mdx index 8d50db8b9f8b9..62a28a0da1b27 100644 --- a/api_docs/kbn_core_logging_common_internal.mdx +++ b/api_docs/kbn_core_logging_common_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-logging-common-internal title: "@kbn/core-logging-common-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-logging-common-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-logging-common-internal'] --- import kbnCoreLoggingCommonInternalObj from './kbn_core_logging_common_internal.devdocs.json'; diff --git a/api_docs/kbn_core_logging_server.mdx b/api_docs/kbn_core_logging_server.mdx index 6bec62f30078f..664842a6d95e1 100644 --- a/api_docs/kbn_core_logging_server.mdx +++ b/api_docs/kbn_core_logging_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-logging-server title: "@kbn/core-logging-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-logging-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-logging-server'] --- import kbnCoreLoggingServerObj from './kbn_core_logging_server.devdocs.json'; diff --git a/api_docs/kbn_core_logging_server_internal.mdx b/api_docs/kbn_core_logging_server_internal.mdx index 86de318294ced..93f4f02353be2 100644 --- a/api_docs/kbn_core_logging_server_internal.mdx +++ b/api_docs/kbn_core_logging_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-logging-server-internal title: "@kbn/core-logging-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-logging-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-logging-server-internal'] --- import kbnCoreLoggingServerInternalObj from './kbn_core_logging_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_logging_server_mocks.mdx b/api_docs/kbn_core_logging_server_mocks.mdx index bc0ed35b27bc7..84e9c85e97666 100644 --- a/api_docs/kbn_core_logging_server_mocks.mdx +++ b/api_docs/kbn_core_logging_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-logging-server-mocks title: "@kbn/core-logging-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-logging-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-logging-server-mocks'] --- import kbnCoreLoggingServerMocksObj from './kbn_core_logging_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_metrics_collectors_server_internal.mdx b/api_docs/kbn_core_metrics_collectors_server_internal.mdx index 919e61e9c951c..203ebe611de33 100644 --- a/api_docs/kbn_core_metrics_collectors_server_internal.mdx +++ b/api_docs/kbn_core_metrics_collectors_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-metrics-collectors-server-internal title: "@kbn/core-metrics-collectors-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-metrics-collectors-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-metrics-collectors-server-internal'] --- import kbnCoreMetricsCollectorsServerInternalObj from './kbn_core_metrics_collectors_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_metrics_collectors_server_mocks.mdx b/api_docs/kbn_core_metrics_collectors_server_mocks.mdx index fd768ebf4a0fe..49b197ea36757 100644 --- a/api_docs/kbn_core_metrics_collectors_server_mocks.mdx +++ b/api_docs/kbn_core_metrics_collectors_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-metrics-collectors-server-mocks title: "@kbn/core-metrics-collectors-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-metrics-collectors-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-metrics-collectors-server-mocks'] --- import kbnCoreMetricsCollectorsServerMocksObj from './kbn_core_metrics_collectors_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_metrics_server.devdocs.json b/api_docs/kbn_core_metrics_server.devdocs.json index f5463ed075e9a..af44534db740f 100644 --- a/api_docs/kbn_core_metrics_server.devdocs.json +++ b/api_docs/kbn_core_metrics_server.devdocs.json @@ -444,9 +444,7 @@ "parentPluginId": "@kbn/core-metrics-server", "id": "def-common.OpsMetrics.process", "type": "Object", - "tags": [ - "deprecated" - ], + "tags": [], "label": "process", "description": [ "\nProcess related metrics." @@ -461,79 +459,8 @@ } ], "path": "packages/core/metrics/core-metrics-server/src/metrics.ts", - "deprecated": true, - "removeBy": "8.8.0", - "trackAdoption": false, - "references": [ - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/ops_metrics_collector.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.ts" - }, - { - "plugin": "@kbn/core-status-server-internal", - "path": "packages/core/status/core-status-server-internal/src/routes/status.ts" - }, - { - "plugin": "@kbn/core-status-server-internal", - "path": "packages/core/status/core-status-server-internal/src/routes/status.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "@kbn/core-usage-data-server-internal", - "path": "packages/core/usage-data/core-usage-data-server-internal/src/core_usage_data_service.ts" - }, - { - "plugin": "monitoring", - "path": "x-pack/plugins/monitoring/server/kibana_monitoring/bulk_uploader.ts" - }, - { - "plugin": "kibanaUsageCollection", - "path": "src/plugins/kibana_usage_collection/server/collectors/ops_stats/ops_stats_collector.ts" - }, - { - "plugin": "@kbn/core-metrics-server-internal", - "path": "packages/core/metrics/core-metrics-server-internal/src/logging/get_ops_metrics_log.test.ts" - }, - { - "plugin": "@kbn/core-apps-browser-internal", - "path": "packages/core/apps/core-apps-browser-internal/src/status/lib/load_status.test.ts" - } - ] + "deprecated": false, + "trackAdoption": false }, { "parentPluginId": "@kbn/core-metrics-server", diff --git a/api_docs/kbn_core_metrics_server.mdx b/api_docs/kbn_core_metrics_server.mdx index f5a290cba9c07..4d882da48b403 100644 --- a/api_docs/kbn_core_metrics_server.mdx +++ b/api_docs/kbn_core_metrics_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-metrics-server title: "@kbn/core-metrics-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-metrics-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-metrics-server'] --- import kbnCoreMetricsServerObj from './kbn_core_metrics_server.devdocs.json'; diff --git a/api_docs/kbn_core_metrics_server_internal.mdx b/api_docs/kbn_core_metrics_server_internal.mdx index e1c3418dbe4ad..e2cb895ca1e8b 100644 --- a/api_docs/kbn_core_metrics_server_internal.mdx +++ b/api_docs/kbn_core_metrics_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-metrics-server-internal title: "@kbn/core-metrics-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-metrics-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-metrics-server-internal'] --- import kbnCoreMetricsServerInternalObj from './kbn_core_metrics_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_metrics_server_mocks.mdx b/api_docs/kbn_core_metrics_server_mocks.mdx index f9db5b936975c..49b847bc56d47 100644 --- a/api_docs/kbn_core_metrics_server_mocks.mdx +++ b/api_docs/kbn_core_metrics_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-metrics-server-mocks title: "@kbn/core-metrics-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-metrics-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-metrics-server-mocks'] --- import kbnCoreMetricsServerMocksObj from './kbn_core_metrics_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_mount_utils_browser.mdx b/api_docs/kbn_core_mount_utils_browser.mdx index ed482c62fdb5e..7454e4b96f39b 100644 --- a/api_docs/kbn_core_mount_utils_browser.mdx +++ b/api_docs/kbn_core_mount_utils_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-mount-utils-browser title: "@kbn/core-mount-utils-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-mount-utils-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-mount-utils-browser'] --- import kbnCoreMountUtilsBrowserObj from './kbn_core_mount_utils_browser.devdocs.json'; diff --git a/api_docs/kbn_core_node_server.mdx b/api_docs/kbn_core_node_server.mdx index 58aa145187b0f..8589ce61a40ca 100644 --- a/api_docs/kbn_core_node_server.mdx +++ b/api_docs/kbn_core_node_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-node-server title: "@kbn/core-node-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-node-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-node-server'] --- import kbnCoreNodeServerObj from './kbn_core_node_server.devdocs.json'; diff --git a/api_docs/kbn_core_node_server_internal.mdx b/api_docs/kbn_core_node_server_internal.mdx index b19aa9d576805..f3fbd7c7b5247 100644 --- a/api_docs/kbn_core_node_server_internal.mdx +++ b/api_docs/kbn_core_node_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-node-server-internal title: "@kbn/core-node-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-node-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-node-server-internal'] --- import kbnCoreNodeServerInternalObj from './kbn_core_node_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_node_server_mocks.mdx b/api_docs/kbn_core_node_server_mocks.mdx index 6d9f0d91d5f50..642b8b95caa79 100644 --- a/api_docs/kbn_core_node_server_mocks.mdx +++ b/api_docs/kbn_core_node_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-node-server-mocks title: "@kbn/core-node-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-node-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-node-server-mocks'] --- import kbnCoreNodeServerMocksObj from './kbn_core_node_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_notifications_browser.mdx b/api_docs/kbn_core_notifications_browser.mdx index 11558e0da9904..18afafa3e4e49 100644 --- a/api_docs/kbn_core_notifications_browser.mdx +++ b/api_docs/kbn_core_notifications_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-notifications-browser title: "@kbn/core-notifications-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-notifications-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-notifications-browser'] --- import kbnCoreNotificationsBrowserObj from './kbn_core_notifications_browser.devdocs.json'; diff --git a/api_docs/kbn_core_notifications_browser_internal.mdx b/api_docs/kbn_core_notifications_browser_internal.mdx index beefe02de8542..e762f3cc18337 100644 --- a/api_docs/kbn_core_notifications_browser_internal.mdx +++ b/api_docs/kbn_core_notifications_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-notifications-browser-internal title: "@kbn/core-notifications-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-notifications-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-notifications-browser-internal'] --- import kbnCoreNotificationsBrowserInternalObj from './kbn_core_notifications_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_notifications_browser_mocks.mdx b/api_docs/kbn_core_notifications_browser_mocks.mdx index f1ffa9132dd09..8d744247102dc 100644 --- a/api_docs/kbn_core_notifications_browser_mocks.mdx +++ b/api_docs/kbn_core_notifications_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-notifications-browser-mocks title: "@kbn/core-notifications-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-notifications-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-notifications-browser-mocks'] --- import kbnCoreNotificationsBrowserMocksObj from './kbn_core_notifications_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_overlays_browser.mdx b/api_docs/kbn_core_overlays_browser.mdx index c810f8c604ead..5fb5df0a165f4 100644 --- a/api_docs/kbn_core_overlays_browser.mdx +++ b/api_docs/kbn_core_overlays_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-overlays-browser title: "@kbn/core-overlays-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-overlays-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-overlays-browser'] --- import kbnCoreOverlaysBrowserObj from './kbn_core_overlays_browser.devdocs.json'; diff --git a/api_docs/kbn_core_overlays_browser_internal.mdx b/api_docs/kbn_core_overlays_browser_internal.mdx index 45a5f1cf98e40..9d736da13c6a2 100644 --- a/api_docs/kbn_core_overlays_browser_internal.mdx +++ b/api_docs/kbn_core_overlays_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-overlays-browser-internal title: "@kbn/core-overlays-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-overlays-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-overlays-browser-internal'] --- import kbnCoreOverlaysBrowserInternalObj from './kbn_core_overlays_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_overlays_browser_mocks.mdx b/api_docs/kbn_core_overlays_browser_mocks.mdx index 71208cc4065f1..84186f5aa5e8c 100644 --- a/api_docs/kbn_core_overlays_browser_mocks.mdx +++ b/api_docs/kbn_core_overlays_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-overlays-browser-mocks title: "@kbn/core-overlays-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-overlays-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-overlays-browser-mocks'] --- import kbnCoreOverlaysBrowserMocksObj from './kbn_core_overlays_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_plugins_browser.mdx b/api_docs/kbn_core_plugins_browser.mdx index 4978f12904366..09a935a357a96 100644 --- a/api_docs/kbn_core_plugins_browser.mdx +++ b/api_docs/kbn_core_plugins_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-plugins-browser title: "@kbn/core-plugins-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-plugins-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-plugins-browser'] --- import kbnCorePluginsBrowserObj from './kbn_core_plugins_browser.devdocs.json'; diff --git a/api_docs/kbn_core_plugins_browser_mocks.mdx b/api_docs/kbn_core_plugins_browser_mocks.mdx index b4823d53c0d4d..44e109ab96e0d 100644 --- a/api_docs/kbn_core_plugins_browser_mocks.mdx +++ b/api_docs/kbn_core_plugins_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-plugins-browser-mocks title: "@kbn/core-plugins-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-plugins-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-plugins-browser-mocks'] --- import kbnCorePluginsBrowserMocksObj from './kbn_core_plugins_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_plugins_server.mdx b/api_docs/kbn_core_plugins_server.mdx index bb8c81c975fdc..fe77adc758a76 100644 --- a/api_docs/kbn_core_plugins_server.mdx +++ b/api_docs/kbn_core_plugins_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-plugins-server title: "@kbn/core-plugins-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-plugins-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-plugins-server'] --- import kbnCorePluginsServerObj from './kbn_core_plugins_server.devdocs.json'; diff --git a/api_docs/kbn_core_plugins_server_mocks.mdx b/api_docs/kbn_core_plugins_server_mocks.mdx index 98f4cccbb535f..c64f8ce4218b7 100644 --- a/api_docs/kbn_core_plugins_server_mocks.mdx +++ b/api_docs/kbn_core_plugins_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-plugins-server-mocks title: "@kbn/core-plugins-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-plugins-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-plugins-server-mocks'] --- import kbnCorePluginsServerMocksObj from './kbn_core_plugins_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_preboot_server.mdx b/api_docs/kbn_core_preboot_server.mdx index da25ba8fed104..a476f68c9a39b 100644 --- a/api_docs/kbn_core_preboot_server.mdx +++ b/api_docs/kbn_core_preboot_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-preboot-server title: "@kbn/core-preboot-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-preboot-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-preboot-server'] --- import kbnCorePrebootServerObj from './kbn_core_preboot_server.devdocs.json'; diff --git a/api_docs/kbn_core_preboot_server_mocks.mdx b/api_docs/kbn_core_preboot_server_mocks.mdx index 5a844692e9412..00147b623fbee 100644 --- a/api_docs/kbn_core_preboot_server_mocks.mdx +++ b/api_docs/kbn_core_preboot_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-preboot-server-mocks title: "@kbn/core-preboot-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-preboot-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-preboot-server-mocks'] --- import kbnCorePrebootServerMocksObj from './kbn_core_preboot_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_rendering_browser_mocks.mdx b/api_docs/kbn_core_rendering_browser_mocks.mdx index f20cea4df6fc1..d462be6b5780a 100644 --- a/api_docs/kbn_core_rendering_browser_mocks.mdx +++ b/api_docs/kbn_core_rendering_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-rendering-browser-mocks title: "@kbn/core-rendering-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-rendering-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-rendering-browser-mocks'] --- import kbnCoreRenderingBrowserMocksObj from './kbn_core_rendering_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_rendering_server_internal.mdx b/api_docs/kbn_core_rendering_server_internal.mdx index 627a6b6162186..a35914791ff71 100644 --- a/api_docs/kbn_core_rendering_server_internal.mdx +++ b/api_docs/kbn_core_rendering_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-rendering-server-internal title: "@kbn/core-rendering-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-rendering-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-rendering-server-internal'] --- import kbnCoreRenderingServerInternalObj from './kbn_core_rendering_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_rendering_server_mocks.mdx b/api_docs/kbn_core_rendering_server_mocks.mdx index 0f25d646cc70a..c35af9a1a24f1 100644 --- a/api_docs/kbn_core_rendering_server_mocks.mdx +++ b/api_docs/kbn_core_rendering_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-rendering-server-mocks title: "@kbn/core-rendering-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-rendering-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-rendering-server-mocks'] --- import kbnCoreRenderingServerMocksObj from './kbn_core_rendering_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_root_server_internal.mdx b/api_docs/kbn_core_root_server_internal.mdx index 8f25db54eb5a2..9d0e6a16bdac0 100644 --- a/api_docs/kbn_core_root_server_internal.mdx +++ b/api_docs/kbn_core_root_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-root-server-internal title: "@kbn/core-root-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-root-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-root-server-internal'] --- import kbnCoreRootServerInternalObj from './kbn_core_root_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_api_browser.devdocs.json b/api_docs/kbn_core_saved_objects_api_browser.devdocs.json index 6485c348e62b3..27cd4d841d19d 100644 --- a/api_docs/kbn_core_saved_objects_api_browser.devdocs.json +++ b/api_docs/kbn_core_saved_objects_api_browser.devdocs.json @@ -24,7 +24,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.ResolvedSimpleSavedObject", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "ResolvedSimpleSavedObject", "description": [ "\nThis interface is a very simple wrapper for SavedObjects resolved from the server\nwith the {@link SavedObjectsClientContract}.\n" @@ -40,8 +42,178 @@ "" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/legacy_urls/types.ts" + }, + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/legacy_urls/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/common/ui/types.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/workpad.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -121,7 +293,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBatchResponse", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBatchResponse", "description": [ "\nBatch response for simple saved objects\n" @@ -137,8 +311,50 @@ "" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -170,7 +386,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkCreateObject", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkCreateObject", "description": [ "\nPer-object parameters for bulk create operation\n" @@ -193,8 +411,22 @@ } ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -232,14 +464,30 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkCreateOptions", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkCreateOptions", "description": [ "\nOptions for bulk create operation\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -264,14 +512,17 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkDeleteOptions", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkDeleteOptions", "description": [ "\nOptions for bulk delete operation\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -296,14 +547,26 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkDeleteResponse", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkDeleteResponse", "description": [ "\nReturn type of the Saved Objects `bulkDelete()` method.\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -335,14 +598,17 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkDeleteResponseItem", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkDeleteResponseItem", "description": [ "\nSingle item within the statuses array of the bulk delete response\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -413,7 +679,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkResolveResponse", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkResolveResponse", "description": [ "\nReturn type of the Saved Objects `bulkResolve()` method.\n" @@ -429,8 +697,14 @@ "" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -462,7 +736,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkUpdateObject", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkUpdateObject", "description": [ "\nPer-object parameters for bulk update operation\n" @@ -478,8 +754,22 @@ "" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -569,14 +859,22 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsBulkUpdateOptions", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsBulkUpdateOptions", "description": [ "\nOptions for bulk update operation\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -601,100 +899,852 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsClientContract", "description": [ "\nThe client-side SavedObjectsClient is a thin convenience library around the SavedObjects\nHTTP API for interacting with Saved Objects.\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.create", - "type": "Function", - "tags": [], - "label": "create", - "description": [ - "\nCreates an object\n" - ], - "signature": [ - "(type: string, attributes: T, options?: ", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsCreateOptions", - "text": "SavedObjectsCreateOptions" - }, - " | undefined) => Promise<", - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" - }, - ">" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.create.$1", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "- the type of object to create" - ], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.create.$2", - "type": "Uncategorized", - "tags": [], - "label": "attributes", - "description": [ - "- the attributes of the object" - ], - "signature": [ - "T" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.create.$3", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "{@link SavedObjectsCreateOptions }" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsCreateOptions", - "text": "SavedObjectsCreateOptions" - }, - " | undefined" - ], + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser", + "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/public/application/kibana_services.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/public/application/kibana_services.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/check_for_duplicate_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/plugin.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/plugin.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/plugin.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/check_for_duplicate_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/reference_editor.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/dimension_panel/dimension_panel.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/operations/definitions/index.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/dependency_cache.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/dependency_cache.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/save_modal.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/save_modal.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/store.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/store.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/use_workspace_loader.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/application.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/application.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/lib/api.ts" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/index.tsx" + }, + { + "plugin": "watcher", + "path": "x-pack/plugins/watcher/public/application/index.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/mocks.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/state_management/mocks.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts" + }, + { + "plugin": "visTypeTimeseries", + "path": "src/plugins/vis_types/timeseries/public/application/contexts/query_input_bar_context.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.create", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "create", + "description": [ + "\nCreates an object\n" + ], + "signature": [ + "(type: string, attributes: T, options?: ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsCreateOptions", + "text": "SavedObjectsCreateOptions" + }, + " | undefined) => Promise<", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + ">" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_saved_object.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.create.$1", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "- the type of object to create" + ], + "signature": [ + "string" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.create.$2", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "- the attributes of the object" + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.create.$3", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "{@link SavedObjectsCreateOptions }" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsCreateOptions", + "text": "SavedObjectsCreateOptions" + }, + " | undefined" + ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", "deprecated": false, "trackAdoption": false, @@ -709,7 +1759,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract.bulkCreate", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkCreate", "description": [ "\nCreates multiple objects at once\n" @@ -742,8 +1794,34 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/public/application/components/home_app.js" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -802,7 +1880,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract.delete", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "delete", "description": [ "\nDeletes an object\n" @@ -816,11 +1896,65 @@ "section": "def-common.SavedObjectsDeleteOptions", "text": "SavedObjectsDeleteOptions" }, - " | undefined) => Promise<{}>" + " | undefined) => Promise<{}>" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/build_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/visualize_app/components/visualize_listing.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_delete_saved_object.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -887,7 +2021,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract.bulkDelete", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkDelete", "description": [ "\nDeletes multiple documents at once" @@ -920,8 +2056,30 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/global_params/delete_param.tsx" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -987,7 +2145,8 @@ "property", "property", "property", - "property" + "property", + "deprecated" ], "label": "find", "description": [ @@ -1010,63 +2169,441 @@ "section": "def-common.SavedObjectsFindResponse", "text": "SavedObjectsFindResponse" }, - ">" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + ">" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/dashboards_service.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/check_for_duplicate_dashboard_title.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/index_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/recognize/resolvers.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/use_dashboard_button_href.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/overview/containers/overview_cti_links/index.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/monitor_config/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/manage_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/private_locations/hooks/use_location_monitors.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/hooks/use_monitor_name.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.test.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/list_filters/use_filters.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.find.$1", + "type": "Object", + "tags": [], + "label": "options", + "description": [ + "{@link SavedObjectsFindOptions }" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsFindOptions", + "text": "SavedObjectsFindOptions" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [ + "A find result with objects matching the specified search." + ] + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsClientContract.get", + "type": "Function", + "tags": [ + "deprecated" + ], + "label": "get", + "description": [ + "\nFetches a single object\n" + ], + "signature": [ + "(type: string, id: string) => Promise<", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + ">" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/lib/get_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/initialize_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/update_basic_attributes.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/util/index_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/jobs/new_job/job_from_lens/route_resolver.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/private_locations/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/state/private_locations/api.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.find.$1", - "type": "Object", - "tags": [], - "label": "options", - "description": [ - "{@link SavedObjectsFindOptions }" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsFindOptions", - "text": "SavedObjectsFindOptions" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [ - "A find result with objects matching the specified search." - ] - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsClientContract.get", - "type": "Function", - "tags": [], - "label": "get", - "description": [ - "\nFetches a single object\n" - ], - "signature": [ - "(type: string, id: string) => Promise<", + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" }, - ">" + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, - "trackAdoption": false, "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1111,7 +2648,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract.bulkGet", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkGet", "description": [ "\nReturns an array of objects by id\n" @@ -1136,8 +2675,26 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1173,7 +2730,8 @@ "id": "def-common.SavedObjectsClientContract.resolve", "type": "Function", "tags": [ - "note" + "note", + "deprecated" ], "label": "resolve", "description": [ @@ -1191,8 +2749,138 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1238,7 +2926,8 @@ "id": "def-common.SavedObjectsClientContract.bulkResolve", "type": "Function", "tags": [ - "note" + "note", + "deprecated" ], "label": "bulkResolve", "description": [ @@ -1264,8 +2953,30 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/assets.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/legacy_uptime/components/monitor_management/hooks/use_invalid_monitors.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_selector/use_recently_viewed_monitors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1302,7 +3013,8 @@ "type": "Function", "tags": [ "prop", - "prop" + "prop", + "deprecated" ], "label": "update", "description": [ @@ -1328,8 +3040,82 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1415,7 +3201,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsClientContract.bulkUpdate", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "bulkUpdate", "description": [ "\nUpdate multiple documents at once\n" @@ -1440,8 +3228,26 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1473,20 +3279,108 @@ ] } ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsCreateOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsCreateOptions", - "description": [ - "\nOptions for creating a saved object.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", - "deprecated": false, - "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsCreateOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsCreateOptions", + "description": [ + "\nOptions for creating a saved object.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -1589,28 +3483,328 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsDeleteOptions", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsDeleteOptions", "description": [ "\nOptions for deleting a saved object.\n" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsDeleteOptions.force", + "type": "CompoundType", + "tags": [], + "label": "force", + "description": [ + "Force deletion of an object that exists in multiple namespaces (default=false)" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindOptionsReference", + "type": "Interface", + "tags": [], + "label": "SavedObjectsFindOptionsReference", + "description": [ + "\nAn object reference for use in find operation options\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsDeleteOptions.force", - "type": "CompoundType", + "id": "def-common.SavedObjectsFindOptionsReference.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "The type of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindOptionsReference.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The ID of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindResponse", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsFindResponse", + "description": [ + "\nReturn type of the Saved Objects `find()` method.\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsFindResponse", + "text": "SavedObjectsFindResponse" + }, + " extends ", + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsBatchResponse", + "text": "SavedObjectsBatchResponse" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/saved_queries/use_saved_queries.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/use_packs.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/use_packs.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindResponse.aggregations", + "type": "Uncategorized", + "tags": [], + "label": "aggregations", + "description": [ + "aggregations from the search query" + ], + "signature": [ + "A | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindResponse.total", + "type": "number", + "tags": [], + "label": "total", + "description": [ + "total number of results" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindResponse.perPage", + "type": "number", + "tags": [], + "label": "perPage", + "description": [ + "number of results per page" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsFindResponse.page", + "type": "number", + "tags": [], + "label": "page", + "description": [ + "current page in results" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsUpdateOptions", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectsUpdateOptions", + "description": [ + "\nOptions for updating a saved object\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SavedObjectsUpdateOptions", + "text": "SavedObjectsUpdateOptions" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsUpdateOptions.version", + "type": "string", + "tags": [], + "label": "version", + "description": [ + "version of the saved object" + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsUpdateOptions.upsert", + "type": "Uncategorized", + "tags": [], + "label": "upsert", + "description": [ + "Alternative attributes for the saved object if upserting" + ], + "signature": [ + "Attributes | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-api-browser", + "id": "def-common.SavedObjectsUpdateOptions.references", + "type": "Array", "tags": [], - "label": "force", + "label": "references", "description": [ - "Force deletion of an object that exists in multiple namespaces (default=false)" + "Array of references to other saved objects" ], "signature": [ - "boolean | undefined" + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[] | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", "deprecated": false, "trackAdoption": false } @@ -1619,238 +3813,530 @@ }, { "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindOptionsReference", + "id": "def-common.SimpleSavedObject", "type": "Interface", - "tags": [], - "label": "SavedObjectsFindOptionsReference", + "tags": [ + "deprecated" + ], + "label": "SimpleSavedObject", "description": [ - "\nAn object reference for use in find operation options\n" + "\nVery simple wrapper for SavedObjects loaded from the server\nwith the {@link SavedObjectsClientContract}.\n\nIt provides basic functionality for creating/saving/deleting saved objects,\nbut doesn't include any type-specific implementations.\n" ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-api-browser", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", + "section": "def-common.SimpleSavedObject", + "text": "SimpleSavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", + "deprecated": true, "trackAdoption": false, - "children": [ + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "presentationUtil", + "path": "src/plugins/presentation_util/public/services/dashboards/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/vis_types/vis_type_alias_registry.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/find_dashboard_saved_objects.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_app/listing/dashboard_listing.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "aiops", + "path": "x-pack/plugins/aiops/public/application/utils/search_utils.ts" + }, + { + "plugin": "aiops", + "path": "x-pack/plugins/aiops/public/application/utils/search_utils.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/kibana.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/kibana.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/public/components/markdown_editor/plugins/lens/saved_objects_finder.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/maps_vis_type_alias.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/common/types/index.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/common/types/index.ts" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "dataVisualizer", + "path": "x-pack/plugins/data_visualizer/public/application/index_data_visualizer/index_data_visualizer.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/data_frame_analytics/pages/analytics_management/components/source_selection/source_selection.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/assets/types.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/public/services/drilldowns/abstract_dashboard_drilldown/components/collect_config_container.tsx" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/app_state.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/types/app_state.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/common/types/synthetics_monitor.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/types.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/hooks/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindOptionsReference.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "The type of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindOptionsReference.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The ID of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsFindResponse", - "description": [ - "\nReturn type of the Saved Objects `find()` method.\n" - ], - "signature": [ + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsFindResponse", - "text": "SavedObjectsFindResponse" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, - " extends ", { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsBatchResponse", - "text": "SavedObjectsBatchResponse" + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindResponse.aggregations", - "type": "Uncategorized", - "tags": [], - "label": "aggregations", - "description": [ - "aggregations from the search query" - ], - "signature": [ - "A | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindResponse.total", - "type": "number", - "tags": [], - "label": "total", - "description": [ - "total number of results" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindResponse.perPage", - "type": "number", - "tags": [], - "label": "perPage", - "description": [ - "number of results per page" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsFindResponse.page", - "type": "number", - "tags": [], - "label": "page", - "description": [ - "current page in results" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsUpdateOptions", - "type": "Interface", - "tags": [], - "label": "SavedObjectsUpdateOptions", - "description": [ - "\nOptions for updating a saved object\n" - ], - "signature": [ + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SavedObjectsUpdateOptions", - "text": "SavedObjectsUpdateOptions" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" }, - "" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsUpdateOptions.version", - "type": "string", - "tags": [], - "label": "version", - "description": [ - "version of the saved object" - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsUpdateOptions.upsert", - "type": "Uncategorized", - "tags": [], - "label": "upsert", - "description": [ - "Alternative attributes for the saved object if upserting" - ], - "signature": [ - "Attributes | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SavedObjectsUpdateOptions.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [ - "Array of references to other saved objects" - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-api-browser", - "id": "def-common.SimpleSavedObject", - "type": "Interface", - "tags": [], - "label": "SimpleSavedObject", - "description": [ - "\nVery simple wrapper for SavedObjects loaded from the server\nwith the {@link SavedObjectsClientContract}.\n\nIt provides basic functionality for creating/saving/deleting saved objects,\nbut doesn't include any type-specific implementations.\n" - ], - "signature": [ + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-api-browser", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsApiBrowserPluginApi", - "section": "def-common.SimpleSavedObject", - "text": "SimpleSavedObject" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" }, - "" + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + }, + { + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" + } ], - "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, - "trackAdoption": false, "children": [ { "parentPluginId": "@kbn/core-saved-objects-api-browser", @@ -2178,7 +4664,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SimpleSavedObject.save", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "save", "description": [ "\nSaves this object" @@ -2195,8 +4683,22 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + } + ], "children": [], "returnComment": [] }, @@ -2204,7 +4706,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SimpleSavedObject.delete", "type": "Function", - "tags": [], + "tags": [ + "deprecated" + ], "label": "delete", "description": [ "\nDeletes this object" @@ -2213,8 +4717,14 @@ "() => Promise<{}>" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + } + ], "children": [], "returnComment": [] } @@ -2228,7 +4738,9 @@ "parentPluginId": "@kbn/core-saved-objects-api-browser", "id": "def-common.SavedObjectsFindOptions", "type": "Type", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsFindOptions", "description": [ "\nBrowser options for finding saved objects\n" @@ -2271,8 +4783,50 @@ "[] | undefined; hasNoReferenceOperator?: \"AND\" | \"OR\" | undefined; defaultSearchOperator?: \"AND\" | \"OR\" | undefined; namespaces?: string[] | undefined; preference?: string | undefined; }" ], "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/find_objects.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/find_objects.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + }, + { + "plugin": "cloudSecurityPosture", + "path": "x-pack/plugins/cloud_security_posture/public/pages/rules/use_csp_rules.ts" + } + ], "initialIsOpen": false } ], diff --git a/api_docs/kbn_core_saved_objects_api_browser.mdx b/api_docs/kbn_core_saved_objects_api_browser.mdx index 08dfb4a4e80ac..0b08cf4d4b8d1 100644 --- a/api_docs/kbn_core_saved_objects_api_browser.mdx +++ b/api_docs/kbn_core_saved_objects_api_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-api-browser title: "@kbn/core-saved-objects-api-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-api-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-api-browser'] --- import kbnCoreSavedObjectsApiBrowserObj from './kbn_core_saved_objects_api_browser.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_api_server.mdx b/api_docs/kbn_core_saved_objects_api_server.mdx index 8beaef277c4ff..a6f7b8a32b308 100644 --- a/api_docs/kbn_core_saved_objects_api_server.mdx +++ b/api_docs/kbn_core_saved_objects_api_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-api-server title: "@kbn/core-saved-objects-api-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-api-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-api-server'] --- import kbnCoreSavedObjectsApiServerObj from './kbn_core_saved_objects_api_server.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_api_server_internal.mdx b/api_docs/kbn_core_saved_objects_api_server_internal.mdx index edf0c04a26b99..152bf3a7fcf09 100644 --- a/api_docs/kbn_core_saved_objects_api_server_internal.mdx +++ b/api_docs/kbn_core_saved_objects_api_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-api-server-internal title: "@kbn/core-saved-objects-api-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-api-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-api-server-internal'] --- import kbnCoreSavedObjectsApiServerInternalObj from './kbn_core_saved_objects_api_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_api_server_mocks.mdx b/api_docs/kbn_core_saved_objects_api_server_mocks.mdx index a86d42d0cb55f..5157ab0d0e8a4 100644 --- a/api_docs/kbn_core_saved_objects_api_server_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_api_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-api-server-mocks title: "@kbn/core-saved-objects-api-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-api-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-api-server-mocks'] --- import kbnCoreSavedObjectsApiServerMocksObj from './kbn_core_saved_objects_api_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_base_server_internal.mdx b/api_docs/kbn_core_saved_objects_base_server_internal.mdx index 18e39b36ce81e..f2d436180b986 100644 --- a/api_docs/kbn_core_saved_objects_base_server_internal.mdx +++ b/api_docs/kbn_core_saved_objects_base_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-base-server-internal title: "@kbn/core-saved-objects-base-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-base-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-base-server-internal'] --- import kbnCoreSavedObjectsBaseServerInternalObj from './kbn_core_saved_objects_base_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_base_server_mocks.mdx b/api_docs/kbn_core_saved_objects_base_server_mocks.mdx index 796eb5bdea3d1..a21e9f0c82eb6 100644 --- a/api_docs/kbn_core_saved_objects_base_server_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_base_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-base-server-mocks title: "@kbn/core-saved-objects-base-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-base-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-base-server-mocks'] --- import kbnCoreSavedObjectsBaseServerMocksObj from './kbn_core_saved_objects_base_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_browser.devdocs.json b/api_docs/kbn_core_saved_objects_browser.devdocs.json index 0211987b25cf8..81f2e469e47aa 100644 --- a/api_docs/kbn_core_saved_objects_browser.devdocs.json +++ b/api_docs/kbn_core_saved_objects_browser.devdocs.json @@ -24,12 +24,156 @@ "parentPluginId": "@kbn/core-saved-objects-browser", "id": "def-common.SavedObjectsStart", "type": "Interface", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsStart", "description": [], "path": "packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser", + "path": "packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/services.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/search_selection.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/new_vis_modal.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/types.ts" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/public/application/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/platform.ts" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "transform", + "path": "x-pack/plugins/transform/public/app/app_dependencies.tsx" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "core", + "path": "src/core/server/index.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-browser", diff --git a/api_docs/kbn_core_saved_objects_browser.mdx b/api_docs/kbn_core_saved_objects_browser.mdx index 2c0568f19555c..8de23a03d05b8 100644 --- a/api_docs/kbn_core_saved_objects_browser.mdx +++ b/api_docs/kbn_core_saved_objects_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-browser title: "@kbn/core-saved-objects-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-browser'] --- import kbnCoreSavedObjectsBrowserObj from './kbn_core_saved_objects_browser.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_browser_internal.devdocs.json b/api_docs/kbn_core_saved_objects_browser_internal.devdocs.json index 1158ef8e8e0ca..1510b6de85275 100644 --- a/api_docs/kbn_core_saved_objects_browser_internal.devdocs.json +++ b/api_docs/kbn_core_saved_objects_browser_internal.devdocs.json @@ -22,7 +22,9 @@ "parentPluginId": "@kbn/core-saved-objects-browser-internal", "id": "def-common.SavedObjectsService", "type": "Class", - "tags": [], + "tags": [ + "deprecated" + ], "label": "SavedObjectsService", "description": [], "signature": [ @@ -46,8 +48,30 @@ ">" ], "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-root-browser-internal", + "path": "packages/core/root/core-root-browser-internal/src/core_system.ts" + }, + { + "plugin": "@kbn/core-root-browser-internal", + "path": "packages/core/root/core-root-browser-internal/src/core_system.ts" + }, + { + "plugin": "@kbn/core-root-browser-internal", + "path": "packages/core/root/core-root-browser-internal/src/core_system.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-browser-internal", diff --git a/api_docs/kbn_core_saved_objects_browser_internal.mdx b/api_docs/kbn_core_saved_objects_browser_internal.mdx index aa74e3ee2fb07..93077b2ab4e1e 100644 --- a/api_docs/kbn_core_saved_objects_browser_internal.mdx +++ b/api_docs/kbn_core_saved_objects_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-browser-internal title: "@kbn/core-saved-objects-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-browser-internal'] --- import kbnCoreSavedObjectsBrowserInternalObj from './kbn_core_saved_objects_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_browser_mocks.devdocs.json b/api_docs/kbn_core_saved_objects_browser_mocks.devdocs.json index b2742a4480855..bc3340c763c9e 100644 --- a/api_docs/kbn_core_saved_objects_browser_mocks.devdocs.json +++ b/api_docs/kbn_core_saved_objects_browser_mocks.devdocs.json @@ -27,12 +27,76 @@ "parentPluginId": "@kbn/core-saved-objects-browser-mocks", "id": "def-common.savedObjectsServiceMock", "type": "Object", - "tags": [], + "tags": [ + "deprecated" + ], "label": "savedObjectsServiceMock", "description": [], "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-lifecycle-browser-mocks", + "path": "packages/core/lifecycle/core-lifecycle-browser-mocks/src/core_start.mock.ts" + }, + { + "plugin": "@kbn/core-lifecycle-browser-mocks", + "path": "packages/core/lifecycle/core-lifecycle-browser-mocks/src/core_start.mock.ts" + }, + { + "plugin": "core", + "path": "src/core/public/mocks.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.test.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/public/application/services/dashboard_service.test.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object.stub.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/dashboard_saved_object.stub.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/get_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/public/services/saved_searches/save_saved_searches.test.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts" + }, + { + "plugin": "@kbn/core-plugins-browser-internal", + "path": "packages/core/plugins/core-plugins-browser-internal/src/plugins_service.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-browser-mocks", @@ -81,12 +145,44 @@ "parentPluginId": "@kbn/core-saved-objects-browser-mocks", "id": "def-common.simpleSavedObjectMock", "type": "Object", - "tags": [], + "tags": [ + "deprecated" + ], "label": "simpleSavedObjectMock", "description": [], "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts", - "deprecated": false, + "deprecated": true, "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/mocks.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.test.ts" + } + ], "children": [ { "parentPluginId": "@kbn/core-saved-objects-browser-mocks", diff --git a/api_docs/kbn_core_saved_objects_browser_mocks.mdx b/api_docs/kbn_core_saved_objects_browser_mocks.mdx index 6f1e149283ef4..6802de7eda5cd 100644 --- a/api_docs/kbn_core_saved_objects_browser_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-browser-mocks title: "@kbn/core-saved-objects-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-browser-mocks'] --- import kbnCoreSavedObjectsBrowserMocksObj from './kbn_core_saved_objects_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_common.devdocs.json b/api_docs/kbn_core_saved_objects_common.devdocs.json index 983d666049736..c003cedc52ad2 100644 --- a/api_docs/kbn_core_saved_objects_common.devdocs.json +++ b/api_docs/kbn_core_saved_objects_common.devdocs.json @@ -22,229 +22,219 @@ "interfaces": [ { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject", + "id": "def-common.SavedObjectError", "type": "Interface", "tags": [], - "label": "SavedObject", + "label": "SavedObjectError", "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObject", - "text": "SavedObject" - }, - "" - ], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false, "children": [ { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.id", + "id": "def-common.SavedObjectError.error", "type": "string", "tags": [], - "label": "id", - "description": [ - "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" - ], + "label": "error", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.type", + "id": "def-common.SavedObjectError.message", "type": "string", "tags": [], - "label": "type", - "description": [ - " The type of Saved Object. Each plugin can define it's own custom Saved Object types." - ], + "label": "message", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.version", - "type": "string", + "id": "def-common.SavedObjectError.statusCode", + "type": "number", "tags": [], - "label": "version", - "description": [ - "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." - ], - "signature": [ - "string | undefined" - ], + "label": "statusCode", + "description": [], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.created_at", - "type": "string", + "id": "def-common.SavedObjectError.metadata", + "type": "Object", "tags": [], - "label": "created_at", - "description": [ - "Timestamp of the time this document had been created." - ], + "label": "metadata", + "description": [], "signature": [ - "string | undefined" + "Record | undefined" ], "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportActionRequiredWarning", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportActionRequiredWarning", + "description": [ + "\nA warning meant to notify that a specific user action is required to finalize the import\nof some type of object.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.updated_at", + "id": "def-common.SavedObjectsImportActionRequiredWarning.type", "type": "string", "tags": [], - "label": "updated_at", - "description": [ - "Timestamp of the last time this document had been updated." - ], + "label": "type", + "description": [], "signature": [ - "string | undefined" + "\"action_required\"" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.error", - "type": "Object", + "id": "def-common.SavedObjectsImportActionRequiredWarning.message", + "type": "string", "tags": [], - "label": "error", + "label": "message", "description": [ - "Error associated with this object, populated if an operation failed for this object." - ], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectError", - "text": "SavedObjectError" - }, - " | undefined" + "The translated message to display to the user." ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.attributes", - "type": "Uncategorized", + "id": "def-common.SavedObjectsImportActionRequiredWarning.actionPath", + "type": "string", "tags": [], - "label": "attributes", + "label": "actionPath", "description": [ - "The data for a Saved Object is stored as an object in the `attributes` property." - ], - "signature": [ - "T" + "The path (without the basePath) that the user should be redirect to address this warning." ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.references", - "type": "Array", + "id": "def-common.SavedObjectsImportActionRequiredWarning.buttonLabel", + "type": "string", "tags": [], - "label": "references", + "label": "buttonLabel", "description": [ - "{@inheritdoc SavedObjectReference}" + "An optional label to use for the link button. If unspecified, a default label will be used." ], "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectReference", - "text": "SavedObjectReference" - }, - "[]" + "string | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportAmbiguousConflictError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportAmbiguousConflictError", + "description": [ + "\nRepresents a failure to import due to a conflict, which can be resolved in different ways with an overwrite." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.migrationVersion", - "type": "Object", + "id": "def-common.SavedObjectsImportAmbiguousConflictError.type", + "type": "string", "tags": [], - "label": "migrationVersion", - "description": [ - "{@inheritdoc SavedObjectsMigrationVersion}" - ], + "label": "type", + "description": [], "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsMigrationVersion", - "text": "SavedObjectsMigrationVersion" - }, - " | undefined" + "\"ambiguous_conflict\"" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.coreMigrationVersion", - "type": "string", + "id": "def-common.SavedObjectsImportAmbiguousConflictError.destinations", + "type": "Array", "tags": [], - "label": "coreMigrationVersion", - "description": [ - "A semver value that is used when upgrading objects between Kibana versions." - ], + "label": "destinations", + "description": [], "signature": [ - "string | undefined" + "{ id: string; title?: string | undefined; updatedAt?: string | undefined; }[]" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false - }, + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportConflictError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportConflictError", + "description": [ + "\nRepresents a failure to import due to a conflict." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.namespaces", - "type": "Array", + "id": "def-common.SavedObjectsImportConflictError.type", + "type": "string", "tags": [], - "label": "namespaces", - "description": [ - "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." - ], + "label": "type", + "description": [], "signature": [ - "string[] | undefined" + "\"conflict\"" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObject.originId", + "id": "def-common.SavedObjectsImportConflictError.destinationId", "type": "string", "tags": [], - "label": "originId", - "description": [ - "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." - ], + "label": "destinationId", + "description": [], "signature": [ "string | undefined" ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", "deprecated": false, "trackAdoption": false } @@ -253,238 +243,3311 @@ }, { "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectAttributes", + "id": "def-common.SavedObjectsImportFailure", "type": "Interface", - "tags": [ - "deprecated" - ], - "label": "SavedObjectAttributes", + "tags": [], + "label": "SavedObjectsImportFailure", "description": [ - "\nThe data for a Saved Object is stored as an object in the `attributes`\nproperty.\n" + "\nRepresents a failure to import." ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": true, + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, "trackAdoption": false, - "references": [ + "children": [ { - "plugin": "core", - "path": "src/core/public/index.ts" + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportFailure.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportFailure.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportFailure.meta", + "type": "Object", + "tags": [], + "label": "meta", + "description": [], + "signature": [ + "{ title?: string | undefined; icon?: string | undefined; }" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportFailure.overwrite", + "type": "CompoundType", + "tags": [], + "label": "overwrite", + "description": [ + "\nIf `overwrite` is specified, an attempt was made to overwrite an existing object." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportFailure.error", + "type": "CompoundType", + "tags": [], + "label": "error", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportConflictError", + "text": "SavedObjectsImportConflictError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportAmbiguousConflictError", + "text": "SavedObjectsImportAmbiguousConflictError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportUnsupportedTypeError", + "text": "SavedObjectsImportUnsupportedTypeError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportMissingReferencesError", + "text": "SavedObjectsImportMissingReferencesError" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportUnknownError", + "text": "SavedObjectsImportUnknownError" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportMissingReferencesError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportMissingReferencesError", + "description": [ + "\nRepresents a failure to import due to missing references." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportMissingReferencesError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"missing_references\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportMissingReferencesError.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [], + "signature": [ + "{ type: string; id: string; }[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportResponse", + "description": [ + "\nThe response describing the result of an import." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse.success", + "type": "boolean", + "tags": [], + "label": "success", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse.successCount", + "type": "number", + "tags": [], + "label": "successCount", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse.successResults", + "type": "Array", + "tags": [], + "label": "successResults", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportSuccess", + "text": "SavedObjectsImportSuccess" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse.warnings", + "type": "Array", + "tags": [], + "label": "warnings", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportWarning", + "text": "SavedObjectsImportWarning" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportResponse.errors", + "type": "Array", + "tags": [], + "label": "errors", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsImportFailure", + "text": "SavedObjectsImportFailure" + }, + "[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportRetry", + "description": [ + "\nDescribes a retry operation for importing a saved object." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.overwrite", + "type": "boolean", + "tags": [], + "label": "overwrite", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.destinationId", + "type": "string", + "tags": [], + "label": "destinationId", + "description": [ + "\nThe object ID that will be created or overwritten. If not specified, the `id` field will be used." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.replaceReferences", + "type": "Array", + "tags": [], + "label": "replaceReferences", + "description": [], + "signature": [ + "{ type: string; from: string; to: string; }[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.createNewCopy", + "type": "CompoundType", + "tags": [], + "label": "createNewCopy", + "description": [ + "\nIf `createNewCopy` is specified, the new object has a new (undefined) origin ID. This is only needed for the case where\n`createNewCopies` mode is disabled and ambiguous source conflicts are detected." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportRetry.ignoreMissingReferences", + "type": "CompoundType", + "tags": [], + "label": "ignoreMissingReferences", + "description": [ + "\nIf `ignoreMissingReferences` is specified, reference validation will be skipped for this object." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSimpleWarning", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportSimpleWarning", + "description": [ + "\nA simple informative warning that will be displayed to the user.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSimpleWarning.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"simple\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSimpleWarning.message", + "type": "string", + "tags": [], + "label": "message", + "description": [ + "The translated message to display to the user" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportSuccess", + "description": [ + "\nRepresents a successful import." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.destinationId", + "type": "string", + "tags": [], + "label": "destinationId", + "description": [ + "\nIf `destinationId` is specified, the new object has a new ID that is different from the import ID." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.createNewCopy", + "type": "CompoundType", + "tags": [ + "deprecated" + ], + "label": "createNewCopy", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "spaces", + "path": "x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts" + } + ] + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.meta", + "type": "Object", + "tags": [], + "label": "meta", + "description": [], + "signature": [ + "{ title?: string | undefined; icon?: string | undefined; }" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportSuccess.overwrite", + "type": "CompoundType", + "tags": [], + "label": "overwrite", + "description": [ + "\nIf `overwrite` is specified, this object overwrote an existing one (or will do so, in the case of a pending resolution)." + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnknownError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportUnknownError", + "description": [ + "\nRepresents a failure to import due to an unknown reason." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnknownError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"unknown\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnknownError.message", + "type": "string", + "tags": [], + "label": "message", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnknownError.statusCode", + "type": "number", + "tags": [], + "label": "statusCode", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnsupportedTypeError", + "type": "Interface", + "tags": [], + "label": "SavedObjectsImportUnsupportedTypeError", + "description": [ + "\nRepresents a failure to import due to having an unsupported saved object type." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsImportUnsupportedTypeError.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"unsupported_type\"" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsMigrationVersion", + "type": "Interface", + "tags": [], + "label": "SavedObjectsMigrationVersion", + "description": [ + "\nInformation about the migrations that have been applied to this SavedObject.\nWhen Kibana starts up, KibanaMigrator detects outdated documents and\nmigrates them based on this value. For each migration that has been applied,\nthe plugin's name is used as a key and the latest migration version as the\nvalue.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectsMigrationVersion.Unnamed", + "type": "IndexSignature", + "tags": [], + "label": "[pluginName: string]: string", + "description": [ + "The plugin name and version string" + ], + "signature": [ + "[pluginName: string]: string" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectTypeIdTuple", + "type": "Interface", + "tags": [], + "label": "SavedObjectTypeIdTuple", + "description": [ + "\nAn identifier for a saved object within a space.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectTypeIdTuple.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The id of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectTypeIdTuple.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + "The type of the saved object" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "enums": [], + "misc": [ + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObject", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObject", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/base.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/find.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "home", + "path": "src/plugins/home/server/services/sample_data/sample_data_registry.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/types.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/common/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/index.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/query/route_handler_context.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/server/utils.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "discover", + "path": "src/plugins/discover/public/application/main/components/layout/__stories__/get_layout_props.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/public/saved_objects_client_wrapper.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/data_views.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/public/search/session/sessions_mgmt/lib/api.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "savedObjectsFinder", + "path": "src/plugins/saved_objects_finder/public/finder/saved_object_finder.tsx" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/services/kibana/workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/public/components/home/hooks/use_upload_workpad.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/packs/types.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/routes/saved_queries/list/index.tsx" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "osquery", + "path": "x-pack/plugins/osquery/public/assets/use_assets_status.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/utils.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/public/common/containers/dashboards/use_security_dashboards_table.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-mocks", + "path": "packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/encryption.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/extensions/security.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/export.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/saved_objects_management.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/saved_objects_client.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/collect_multi_namespace_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/update_objects_spaces.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/collect_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_objects_filter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/split_overwrites.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/validate_references.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/errors.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/utils.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/import.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + }, + { + "plugin": "apm", + "path": "x-pack/plugins/apm/server/routes/settings/apm_indices/route.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "lists", + "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.mock.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/host_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/saved_object/user_risk_score_dashboards.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_details/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "upgradeAssistant", + "path": "x-pack/plugins/upgrade_assistant/common/types.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_view.stub.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/server/lib/find_relationships.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "data", + "path": "src/plugins/data/server/search/saved_objects/search_session_migration.test.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "security", + "path": "x-pack/plugins/security/server/saved_objects/saved_objects_security_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "encryptedSavedObjects", + "path": "x-pack/plugins/encrypted_saved_objects/server/saved_objects/saved_objects_encryption_extension.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/server/embeddable/make_lens_embeddable_factory.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/utils.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/authorization/authorization.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "cases", + "path": "x-pack/plugins/cases/server/common/types.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/api.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/effects.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/state/monitor_list/index.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/public/apps/synthetics/components/settings/hooks/use_params_list.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "synthetics", + "path": "x-pack/plugins/synthetics/server/routes/monitor_cruds/bulk_cruds/delete_monitor_bulk.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/test_helpers.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/tests/bulk_disable.test.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/server/services/agents/action.mock.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "observability", + "path": "x-pack/plugins/observability/server/services/slo/fixtures/slo.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-browser-internal", + "path": "packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/internal_bulk_resolve.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.security_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/apply_export_transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/collect_exported_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/saved_objects_exporter.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/sort_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/export/utils.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/import_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-ui-settings-server-internal", + "path": "packages/core/ui-settings/core-ui-settings-server-internal/src/saved_objects/transforms.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/create_saved_objects.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/execute_import_hooks.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/extract_errors.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/get_import_state_map_for_retries.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/regenerate_ids.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/import_dashboards.test.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectAttribute", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttribute", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "advancedSettings", + "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" + }, + { + "plugin": "advancedSettings", + "path": "src/plugins/advanced_settings/public/management_app/lib/to_editable_config.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "triggersActionsUi", + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_reducer.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.13/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectAttributes", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttributes", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/types.ts" + }, + { + "plugin": "embeddable", + "path": "src/plugins/embeddable/public/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + }, + { + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "infra", + "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "graph", + "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/common/types.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/common/types.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/modules.ts" + }, + { + "plugin": "ml", + "path": "x-pack/plugins/ml/common/types/modules.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + }, + { + "plugin": "@kbn/core-saved-objects-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectAttributeSingle", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttributeSingle", + "description": [], + "signature": [ + "string | number | boolean | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributes", + "text": "SavedObjectAttributes" + }, + " | null | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "core", + "path": "src/core/types/index.ts" + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-common", + "id": "def-common.SavedObjectReference", + "type": "Type", + "tags": [ + "deprecated" + ], + "label": "SavedObjectReference", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/bulk_create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-server", + "path": "packages/core/saved-objects/core-saved-objects-api-server/src/apis/create.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts" + }, + { + "plugin": "@kbn/core-saved-objects-api-browser", + "path": "packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts" + }, + { + "plugin": "core", + "path": "src/core/public/index.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" + }, + { + "plugin": "savedObjects", + "path": "src/plugins/saved_objects/public/types.ts" }, { "plugin": "savedObjects", "path": "src/plugins/saved_objects/public/types.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/types.ts" + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/services/types/record.ts" + }, + { + "plugin": "savedObjectsManagement", + "path": "src/plugins/saved_objects_management/public/services/types/record.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/saved_visualization_references.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + }, + { + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/create_source.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/find_object_by_title.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/ui_api/get_table_column_definition.tsx" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/panel/panel_header/panel_actions/add_panel/add_panel_flyout.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/lib/embeddables/default_embeddable_factory_provider.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" }, { - "plugin": "embeddable", - "path": "src/plugins/embeddable/public/types.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/state_management/selectors.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/find_object_by_title.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/utils.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/loader.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_visualize_utils.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/wizard/search_selection/show_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.tsx" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable_factory.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/embeddable/visualize_embeddable.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/epm.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/types.ts" }, { - "plugin": "fleet", - "path": "x-pack/plugins/fleet/common/types/models/settings.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_find_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/visualizations/xy/state_helpers.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/text_based/text_based_languages.tsx" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/text_based/text_based_languages.tsx" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_create_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/save_modal_container.tsx" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/save_modal_container.tsx" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_get_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/persistence/saved_object_store.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/hooks/use_update_saved_object.tsx" + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" }, { - "plugin": "infra", - "path": "x-pack/plugins/infra/public/containers/saved_view/saved_view.tsx" + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + "plugin": "fleet", + "path": "x-pack/plugins/fleet/common/types/models/epm.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/shareable_runtime/types.ts" + "plugin": "graph", + "path": "x-pack/plugins/graph/public/services/persistence/saved_workspace_references.ts" }, { "plugin": "graph", @@ -496,1435 +3559,729 @@ }, { "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + "path": "x-pack/plugins/graph/public/types/persistence.ts" }, { "plugin": "graph", - "path": "x-pack/plugins/graph/public/helpers/saved_workspace_utils.ts" + "path": "x-pack/plugins/graph/public/types/persistence.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/public/datasources/form_based/form_based.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/bwc/types.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/bwc/types.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/saved_object.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/extract_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/decorator/inject_tag_references.test.ts" }, { - "plugin": "savedObjects", - "path": "src/plugins/saved_objects/public/saved_object/helpers/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/public/utils/saved_objects_utils/save_with_confirmation.test.ts" + "plugin": "@kbn/core-saved-objects-server", + "path": "packages/core/saved-objects/core-saved-objects-server/src/serialization.ts" }, { "plugin": "core", - "path": "src/core/server/index.ts" + "path": "src/core/types/index.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "kibanaUtils", + "path": "src/plugins/kibana_utils/common/persistable_state/types.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/actions_client.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/expression_functions/expression_function.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/service/expressions_services.ts" }, { - "plugin": "actions", - "path": "x-pack/plugins/actions/server/types.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "dataViews", + "path": "src/plugins/data_views/common/expressions/load_index_pattern.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/expressions/kibana_context.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/expressions/kibana_context.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/common/rule.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/extract_references.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/filters/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "data", + "path": "src/plugins/data/common/query/persistable_state.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/types.ts" + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/migrate_base_input.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/inject.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + "plugin": "embeddable", + "path": "src/plugins/embeddable/common/lib/inject.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, { - "plugin": "canvas", - "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "savedObjectsTaggingOss", + "path": "src/plugins/saved_objects_tagging_oss/public/api.ts" }, { - "plugin": "enterpriseSearch", - "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/controls_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" }, { - "plugin": "securitySolution", - "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" }, { - "plugin": "taskManager", - "path": "x-pack/plugins/task_manager/server/task_store.test.ts" + "plugin": "visualizations", + "path": "src/plugins/visualizations/public/utils/saved_visualization_references/timeseries_references.ts" }, { - "plugin": "taskManager", - "path": "x-pack/plugins/task_manager/server/task_store.test.ts" + "plugin": "dashboard", + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" }, { "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" }, { "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" }, { "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, { "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, { "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + "path": "src/plugins/dashboard/common/dashboard_container/persistable_state/dashboard_container_references.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/options_list/options_list_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "plugin": "savedSearch", - "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "plugin": "savedSearch", - "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/range_slider/range_slider_persistable_state.ts" }, { - "plugin": "core", - "path": "src/core/types/index.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "plugin": "visualizations", - "path": "src/plugins/visualizations/common/types.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/time_slider/time_slider_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "controls", + "path": "src/plugins/controls/common/control_group/control_group_persistable_state.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/common/dashboard_saved_object/persistable_state/dashboard_saved_object_references.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.ts" }, { - "plugin": "ml", - "path": "x-pack/plugins/ml/common/types/modules.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.11/index.ts" + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/components/connected/tag_list.tsx" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/components/connected/tag_list.tsx" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/action_factory.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/services/ui_actions_service_enhancements.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/public/dynamic_actions/dynamic_action_enhancement.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, { - "plugin": "alerting", - "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, { - "plugin": "dashboard", - "path": "src/plugins/dashboard/public/services/dashboard_saved_object/lib/save_dashboard_state_to_saved_object.ts" + "plugin": "lens", + "path": "x-pack/plugins/lens/common/embeddable_factory/index.ts" }, { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, { - "plugin": "@kbn/core-saved-objects-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-server-internal/src/routes/legacy_import_export/lib/collect_references_deep.test.ts" - } - ], - "children": [ + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectAttributes.Unnamed", - "type": "IndexSignature", - "tags": [], - "label": "[key: string]: SavedObjectAttribute", - "description": [], - "signature": [ - "[key: string]: ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttribute", - "text": "SavedObjectAttribute" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectError", - "type": "Interface", - "tags": [], - "label": "SavedObjectError", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectError.error", - "type": "string", - "tags": [], - "label": "error", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectError.message", - "type": "string", - "tags": [], - "label": "message", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "maps", + "path": "x-pack/plugins/maps/common/migrations/references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectError.statusCode", - "type": "number", - "tags": [], - "label": "statusCode", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectError.metadata", - "type": "Object", - "tags": [], - "label": "metadata", - "description": [], - "signature": [ - "Record | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectReference", - "type": "Interface", - "tags": [], - "label": "SavedObjectReference", - "description": [ - "\nA reference to another saved object.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "maps", + "path": "x-pack/plugins/maps/public/map_attribute_service.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectReference.name", - "type": "string", - "tags": [], - "label": "name", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectReference.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "maps", + "path": "x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectReference.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportActionRequiredWarning", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportActionRequiredWarning", - "description": [ - "\nA warning meant to notify that a specific user action is required to finalize the import\nof some type of object.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportActionRequiredWarning.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"action_required\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_lens.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportActionRequiredWarning.message", - "type": "string", - "tags": [], - "label": "message", - "description": [ - "The translated message to display to the user." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportActionRequiredWarning.actionPath", - "type": "string", - "tags": [], - "label": "actionPath", - "description": [ - "The path (without the basePath) that the user should be redirect to address this warning." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_map.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportActionRequiredWarning.buttonLabel", - "type": "string", - "tags": [], - "label": "buttonLabel", - "description": [ - "An optional label to use for the link button. If unspecified, a default label will be used." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportAmbiguousConflictError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportAmbiguousConflictError", - "description": [ - "\nRepresents a failure to import due to a conflict, which can be resolved in different ways with an overwrite." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportAmbiguousConflictError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"ambiguous_conflict\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_search.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportAmbiguousConflictError.destinations", - "type": "Array", - "tags": [], - "label": "destinations", - "description": [], - "signature": [ - "{ id: string; title?: string | undefined; updatedAt?: string | undefined; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportConflictError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportConflictError", - "description": [ - "\nRepresents a failure to import due to a conflict." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportConflictError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"conflict\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/saved_visualization.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportConflictError.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportFailure", - "description": [ - "\nRepresents a failure to import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "canvas", + "path": "x-pack/plugins/canvas/canvas_plugin_src/functions/external/embeddable.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure.meta", - "type": "Object", - "tags": [], - "label": "meta", - "description": [], - "signature": [ - "{ title?: string | undefined; icon?: string | undefined; }" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "\nIf `overwrite` is specified, an attempt was made to overwrite an existing object." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportFailure.error", - "type": "CompoundType", - "tags": [], - "label": "error", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportConflictError", - "text": "SavedObjectsImportConflictError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportAmbiguousConflictError", - "text": "SavedObjectsImportAmbiguousConflictError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportUnsupportedTypeError", - "text": "SavedObjectsImportUnsupportedTypeError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportMissingReferencesError", - "text": "SavedObjectsImportMissingReferencesError" - }, - " | ", - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportUnknownError", - "text": "SavedObjectsImportUnknownError" - } - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportMissingReferencesError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportMissingReferencesError", - "description": [ - "\nRepresents a failure to import due to missing references." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "cases", + "path": "x-pack/plugins/cases/server/attachment_framework/so_references.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportMissingReferencesError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"missing_references\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportMissingReferencesError.references", - "type": "Array", - "tags": [], - "label": "references", - "description": [], - "signature": [ - "{ type: string; id: string; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportResponse", - "description": [ - "\nThe response describing the result of an import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse.success", - "type": "boolean", - "tags": [], - "label": "success", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "cases", + "path": "x-pack/plugins/cases/server/services/so_references.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse.successCount", - "type": "number", - "tags": [], - "label": "successCount", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse.successResults", - "type": "Array", - "tags": [], - "label": "successResults", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportSuccess", - "text": "SavedObjectsImportSuccess" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" + }, + { + "plugin": "dashboardEnhanced", + "path": "x-pack/plugins/dashboard_enhanced/common/drilldowns/dashboard_drilldown/dashboard_drilldown_persistable_state.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" + }, + { + "plugin": "uiActionsEnhanced", + "path": "src/plugins/ui_actions_enhanced/server/dynamic_action_enhancement.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/references.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" + }, + { + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/public/utils.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse.warnings", - "type": "Array", - "tags": [], - "label": "warnings", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportWarning", - "text": "SavedObjectsImportWarning" - }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportResponse.errors", - "type": "Array", - "tags": [], - "label": "errors", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectsImportFailure", - "text": "SavedObjectsImportFailure" - }, - "[] | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportRetry", - "description": [ - "\nDescribes a retry operation for importing a saved object." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "savedObjectsTagging", + "path": "x-pack/plugins/saved_objects_tagging/common/test_utils/index.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "globalSearchProviders", + "path": "x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "globalSearchProviders", + "path": "x-pack/plugins/global_search_providers/server/providers/saved_objects/map_object_to_result.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.overwrite", - "type": "boolean", - "tags": [], - "label": "overwrite", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/persistable_state.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [ - "\nThe object ID that will be created or overwritten. If not specified, the `id` field will be used." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "dataViews", + "path": "src/plugins/data_views/common/data_views/persistable_state.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.replaceReferences", - "type": "Array", - "tags": [], - "label": "replaceReferences", - "description": [], - "signature": [ - "{ type: string; from: string; to: string; }[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.createNewCopy", - "type": "CompoundType", - "tags": [], - "label": "createNewCopy", - "description": [ - "\nIf `createNewCopy` is specified, the new object has a new (undefined) origin ID. This is only needed for the case where\n`createNewCopies` mode is disabled and ambiguous source conflicts are detected." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportRetry.ignoreMissingReferences", - "type": "CompoundType", - "tags": [], - "label": "ignoreMissingReferences", - "description": [ - "\nIf `ignoreMissingReferences` is specified, reference validation will be skipped for this object." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSimpleWarning", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportSimpleWarning", - "description": [ - "\nA simple informative warning that will be displayed to the user.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "expressions", + "path": "src/plugins/expressions/common/executor/executor.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSimpleWarning.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"simple\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSimpleWarning.message", - "type": "string", - "tags": [], - "label": "message", - "description": [ - "The translated message to display to the user" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportSuccess", - "description": [ - "\nRepresents a successful import." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "data", + "path": "src/plugins/data/common/search/search_source/inject_references.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.id", - "type": "string", - "tags": [], - "label": "id", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.15/index.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.destinationId", - "type": "string", - "tags": [], - "label": "destinationId", - "description": [ - "\nIf `destinationId` is specified, the new object has a new ID that is different from the import ID." - ], - "signature": [ - "string | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/migrations/7.16/index.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/common/locator/locator.ts" + }, + { + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/share_action.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.createNewCopy", - "type": "CompoundType", - "tags": [ - "deprecated" - ], - "label": "createNewCopy", - "description": [], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": true, - "trackAdoption": false, - "references": [ - { - "plugin": "spaces", - "path": "x-pack/plugins/spaces/public/copy_saved_objects_to_space/components/copy_to_space_flyout_internal.tsx" - }, - { - "plugin": "savedObjectsManagement", - "path": "src/plugins/saved_objects_management/public/lib/resolve_import_errors.ts" - } - ] + "plugin": "lens", + "path": "x-pack/plugins/lens/public/app_plugin/share_action.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.meta", - "type": "Object", - "tags": [], - "label": "meta", - "description": [], - "signature": [ - "{ title?: string | undefined; icon?: string | undefined; }" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportSuccess.overwrite", - "type": "CompoundType", - "tags": [], - "label": "overwrite", - "description": [ - "\nIf `overwrite` is specified, this object overwrote an existing one (or will do so, in the case of a pending resolution)." - ], - "signature": [ - "boolean | undefined" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnknownError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportUnknownError", - "description": [ - "\nRepresents a failure to import due to an unknown reason." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/test_helpers/repository.test.common.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnknownError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"unknown\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnknownError.message", - "type": "string", - "tags": [], - "label": "message", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnknownError.statusCode", - "type": "number", - "tags": [], - "label": "statusCode", - "description": [], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnsupportedTypeError", - "type": "Interface", - "tags": [], - "label": "SavedObjectsImportUnsupportedTypeError", - "description": [ - "\nRepresents a failure to import due to having an unsupported saved object type." - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsImportUnsupportedTypeError.type", - "type": "string", - "tags": [], - "label": "type", - "description": [], - "signature": [ - "\"unsupported_type\"" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects_imports.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsMigrationVersion", - "type": "Interface", - "tags": [], - "label": "SavedObjectsMigrationVersion", - "description": [ - "\nInformation about the migrations that have been applied to this SavedObject.\nWhen Kibana starts up, KibanaMigrator detects outdated documents and\nmigrates them based on this value. For each migration that has been applied,\nthe plugin's name is used as a key and the latest migration version as the\nvalue.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectsMigrationVersion.Unnamed", - "type": "IndexSignature", - "tags": [], - "label": "[pluginName: string]: string", - "description": [ - "The plugin name and version string" - ], - "signature": [ - "[pluginName: string]: string" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectTypeIdTuple", - "type": "Interface", - "tags": [], - "label": "SavedObjectTypeIdTuple", - "description": [ - "\nAn identifier for a saved object within a space.\n" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ + "plugin": "@kbn/core-saved-objects-api-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.test.ts" + }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectTypeIdTuple.id", - "type": "string", - "tags": [], - "label": "id", - "description": [ - "The id of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" }, { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectTypeIdTuple.type", - "type": "string", - "tags": [], - "label": "type", - "description": [ - "The type of the saved object" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/types.ts", - "deprecated": false, - "trackAdoption": false - } - ], - "initialIsOpen": false - } - ], - "enums": [], - "misc": [ - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectAttribute", - "type": "Type", - "tags": [], - "label": "SavedObjectAttribute", - "description": [ - "\nType definition for a Saved Object attribute value\n" - ], - "signature": [ + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/resolve_import_errors.test.ts" + }, { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributeSingle", - "text": "SavedObjectAttributeSingle" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" }, - " | ", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributeSingle", - "text": "SavedObjectAttributeSingle" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_conflicts.test.ts" }, - "[]" - ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, - "initialIsOpen": false - }, - { - "parentPluginId": "@kbn/core-saved-objects-common", - "id": "def-common.SavedObjectAttributeSingle", - "type": "Type", - "tags": [], - "label": "SavedObjectAttributeSingle", - "description": [ - "\nDon't use this type, it's simply a helper type for {@link SavedObjectAttribute}\n" - ], - "signature": [ - "string | number | boolean | ", { - "pluginId": "@kbn/core-saved-objects-common", - "scope": "common", - "docId": "kibKbnCoreSavedObjectsCommonPluginApi", - "section": "def-common.SavedObjectAttributes", - "text": "SavedObjectAttributes" + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" }, - " | null | undefined" + { + "plugin": "@kbn/core-saved-objects-import-export-server-internal", + "path": "packages/core/saved-objects/core-saved-objects-import-export-server-internal/src/import/lib/check_origin_conflicts.test.ts" + } ], - "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts", - "deprecated": false, - "trackAdoption": false, "initialIsOpen": false }, { diff --git a/api_docs/kbn_core_saved_objects_common.mdx b/api_docs/kbn_core_saved_objects_common.mdx index d1c0294fb578c..ffccec3a507d7 100644 --- a/api_docs/kbn_core_saved_objects_common.mdx +++ b/api_docs/kbn_core_saved_objects_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-common title: "@kbn/core-saved-objects-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-common'] --- import kbnCoreSavedObjectsCommonObj from './kbn_core_saved_objects_common.devdocs.json'; @@ -21,7 +21,7 @@ Contact Kibana Core for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 83 | 0 | 39 | 0 | +| 67 | 0 | 39 | 0 | ## Common diff --git a/api_docs/kbn_core_saved_objects_import_export_server_internal.mdx b/api_docs/kbn_core_saved_objects_import_export_server_internal.mdx index c1185b7d88516..cc62d033aa6e8 100644 --- a/api_docs/kbn_core_saved_objects_import_export_server_internal.mdx +++ b/api_docs/kbn_core_saved_objects_import_export_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-import-export-server-internal title: "@kbn/core-saved-objects-import-export-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-import-export-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-import-export-server-internal'] --- import kbnCoreSavedObjectsImportExportServerInternalObj from './kbn_core_saved_objects_import_export_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_import_export_server_mocks.mdx b/api_docs/kbn_core_saved_objects_import_export_server_mocks.mdx index 67740d149c206..5cab7b35648b8 100644 --- a/api_docs/kbn_core_saved_objects_import_export_server_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_import_export_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-import-export-server-mocks title: "@kbn/core-saved-objects-import-export-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-import-export-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-import-export-server-mocks'] --- import kbnCoreSavedObjectsImportExportServerMocksObj from './kbn_core_saved_objects_import_export_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_migration_server_internal.mdx b/api_docs/kbn_core_saved_objects_migration_server_internal.mdx index 784c791d9af39..b1821791a0b20 100644 --- a/api_docs/kbn_core_saved_objects_migration_server_internal.mdx +++ b/api_docs/kbn_core_saved_objects_migration_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-migration-server-internal title: "@kbn/core-saved-objects-migration-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-migration-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-migration-server-internal'] --- import kbnCoreSavedObjectsMigrationServerInternalObj from './kbn_core_saved_objects_migration_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_migration_server_mocks.mdx b/api_docs/kbn_core_saved_objects_migration_server_mocks.mdx index 00fa3c64e050c..f5272120b5478 100644 --- a/api_docs/kbn_core_saved_objects_migration_server_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_migration_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-migration-server-mocks title: "@kbn/core-saved-objects-migration-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-migration-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-migration-server-mocks'] --- import kbnCoreSavedObjectsMigrationServerMocksObj from './kbn_core_saved_objects_migration_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_server.devdocs.json b/api_docs/kbn_core_saved_objects_server.devdocs.json index 648c4df4ccffd..bda94ef25320a 100644 --- a/api_docs/kbn_core_saved_objects_server.devdocs.json +++ b/api_docs/kbn_core_saved_objects_server.devdocs.json @@ -2257,6 +2257,522 @@ ], "initialIsOpen": false }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject", + "type": "Interface", + "tags": [], + "label": "SavedObject", + "description": [], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObject", + "text": "SavedObject" + }, + "" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "The ID of this Saved Object, guaranteed to be unique for all objects of the same `type`" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.type", + "type": "string", + "tags": [], + "label": "type", + "description": [ + " The type of Saved Object. Each plugin can define it's own custom Saved Object types." + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.version", + "type": "string", + "tags": [], + "label": "version", + "description": [ + "An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.created_at", + "type": "string", + "tags": [], + "label": "created_at", + "description": [ + "Timestamp of the time this document had been created." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.updated_at", + "type": "string", + "tags": [], + "label": "updated_at", + "description": [ + "Timestamp of the last time this document had been updated." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.error", + "type": "Object", + "tags": [], + "label": "error", + "description": [ + "Error associated with this object, populated if an operation failed for this object." + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectError", + "text": "SavedObjectError" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.attributes", + "type": "Uncategorized", + "tags": [], + "label": "attributes", + "description": [ + "The data for a Saved Object is stored as an object in the `attributes` property." + ], + "signature": [ + "T" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.references", + "type": "Array", + "tags": [], + "label": "references", + "description": [ + "{@inheritdoc SavedObjectReference}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectReference", + "text": "SavedObjectReference" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.migrationVersion", + "type": "Object", + "tags": [], + "label": "migrationVersion", + "description": [ + "{@inheritdoc SavedObjectsMigrationVersion}" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectsMigrationVersion", + "text": "SavedObjectsMigrationVersion" + }, + " | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.coreMigrationVersion", + "type": "string", + "tags": [], + "label": "coreMigrationVersion", + "description": [ + "A semver value that is used when upgrading objects between Kibana versions." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.namespaces", + "type": "Array", + "tags": [], + "label": "namespaces", + "description": [ + "\nSpace(s) that this saved object exists in. This attribute is not used for \"global\" saved object types which are registered with\n`namespaceType: 'agnostic'`." + ], + "signature": [ + "string[] | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObject.originId", + "type": "string", + "tags": [], + "label": "originId", + "description": [ + "\nThe ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration\nfrom a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import\nto ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given\nspace." + ], + "signature": [ + "string | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectAttributes", + "type": "Interface", + "tags": [ + "deprecated" + ], + "label": "SavedObjectAttributes", + "description": [ + "\nThe data for a Saved Object is stored as an object in the `attributes`\nproperty.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": true, + "trackAdoption": false, + "references": [ + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts" + }, + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts" + }, + { + "plugin": "@kbn/core-saved-objects-common", + "path": "packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts" + }, + { + "plugin": "core", + "path": "src/core/server/index.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/actions_client.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "actions", + "path": "x-pack/plugins/actions/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/common/rule.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/saved_objects/geo_containment/migrations.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/rules_client/common/inject_references.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "alerting", + "path": "x-pack/plugins/alerting/server/types.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/server/routes/custom_elements/find.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + }, + { + "plugin": "canvas", + "path": "x-pack/plugins/canvas/server/routes/workpad/find.ts" + }, + { + "plugin": "enterpriseSearch", + "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + }, + { + "plugin": "enterpriseSearch", + "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + }, + { + "plugin": "enterpriseSearch", + "path": "x-pack/plugins/enterprise_search/server/collectors/lib/telemetry.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_types.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + }, + { + "plugin": "securitySolution", + "path": "x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_migrations.ts" + }, + { + "plugin": "taskManager", + "path": "x-pack/plugins/task_manager/server/task_store.test.ts" + }, + { + "plugin": "taskManager", + "path": "x-pack/plugins/task_manager/server/task_store.test.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_extract_panel_references.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/dashboard_telemetry_collection_task.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/dashboard_telemetry.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + }, + { + "plugin": "dashboard", + "path": "src/plugins/dashboard/server/usage/find_by_value_embeddables.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + }, + { + "plugin": "savedSearch", + "path": "src/plugins/saved_search/server/saved_objects/search_migrations.ts" + } + ], + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectAttributes.Unnamed", + "type": "IndexSignature", + "tags": [], + "label": "[key: string]: SavedObjectAttribute", + "description": [], + "signature": [ + "[key: string]: ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttribute", + "text": "SavedObjectAttribute" + } + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "@kbn/core-saved-objects-server", "id": "def-common.SavedObjectExportBaseOptions", @@ -2488,6 +3004,55 @@ ], "initialIsOpen": false }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectReference", + "type": "Interface", + "tags": [], + "label": "SavedObjectReference", + "description": [ + "\nA reference to another saved object.\n" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectReference.name", + "type": "string", + "tags": [], + "label": "name", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectReference.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectReference.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "@kbn/core-saved-objects-server", "id": "def-common.SavedObjectsClientProviderOptions", @@ -3196,63 +3761,6 @@ ], "returnComment": [] }, - { - "parentPluginId": "@kbn/core-saved-objects-server", - "id": "def-common.SavedObjectsMigrationLogger.warning", - "type": "Function", - "tags": [ - "deprecated" - ], - "label": "warning", - "description": [], - "signature": [ - "(msg: string) => void" - ], - "path": "packages/core/saved-objects/core-saved-objects-server/src/migration.ts", - "deprecated": true, - "removeBy": "8.8.0", - "trackAdoption": false, - "references": [ - { - "plugin": "maps", - "path": "x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts" - }, - { - "plugin": "dashboard", - "path": "src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts" - }, - { - "plugin": "@kbn/core-saved-objects-migration-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts" - }, - { - "plugin": "@kbn/core-saved-objects-migration-server-internal", - "path": "packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts" - } - ], - "children": [ - { - "parentPluginId": "@kbn/core-saved-objects-server", - "id": "def-common.SavedObjectsMigrationLogger.warning.$1", - "type": "string", - "tags": [], - "label": "msg", - "description": [], - "signature": [ - "string" - ], - "path": "packages/core/saved-objects/core-saved-objects-server/src/migration.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - }, { "parentPluginId": "@kbn/core-saved-objects-server", "id": "def-common.SavedObjectsMigrationLogger.warn", @@ -5819,6 +6327,63 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectAttribute", + "type": "Type", + "tags": [], + "label": "SavedObjectAttribute", + "description": [ + "\nType definition for a Saved Object attribute value\n" + ], + "signature": [ + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + " | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributeSingle", + "text": "SavedObjectAttributeSingle" + }, + "[]" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/core-saved-objects-server", + "id": "def-common.SavedObjectAttributeSingle", + "type": "Type", + "tags": [], + "label": "SavedObjectAttributeSingle", + "description": [ + "\nDon't use this type, it's simply a helper type for {@link SavedObjectAttribute}\n" + ], + "signature": [ + "string | number | boolean | ", + { + "pluginId": "@kbn/core-saved-objects-common", + "scope": "common", + "docId": "kibKbnCoreSavedObjectsCommonPluginApi", + "section": "def-common.SavedObjectAttributes", + "text": "SavedObjectAttributes" + }, + " | null | undefined" + ], + "path": "packages/core/saved-objects/core-saved-objects-common/src/server_types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "@kbn/core-saved-objects-server", "id": "def-common.SavedObjectMigrationFn", diff --git a/api_docs/kbn_core_saved_objects_server.mdx b/api_docs/kbn_core_saved_objects_server.mdx index 6b96a0a34fd1f..498d44f20b7b1 100644 --- a/api_docs/kbn_core_saved_objects_server.mdx +++ b/api_docs/kbn_core_saved_objects_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-server title: "@kbn/core-saved-objects-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-server'] --- import kbnCoreSavedObjectsServerObj from './kbn_core_saved_objects_server.devdocs.json'; @@ -21,7 +21,7 @@ Contact Kibana Core for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 306 | 0 | 92 | 1 | +| 325 | 0 | 95 | 1 | ## Common diff --git a/api_docs/kbn_core_saved_objects_server_internal.mdx b/api_docs/kbn_core_saved_objects_server_internal.mdx index 01a010a304a27..65f6a11727c7d 100644 --- a/api_docs/kbn_core_saved_objects_server_internal.mdx +++ b/api_docs/kbn_core_saved_objects_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-server-internal title: "@kbn/core-saved-objects-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-server-internal'] --- import kbnCoreSavedObjectsServerInternalObj from './kbn_core_saved_objects_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_server_mocks.mdx b/api_docs/kbn_core_saved_objects_server_mocks.mdx index 2d9e1ef718fd5..443f548de4864 100644 --- a/api_docs/kbn_core_saved_objects_server_mocks.mdx +++ b/api_docs/kbn_core_saved_objects_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-server-mocks title: "@kbn/core-saved-objects-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-server-mocks'] --- import kbnCoreSavedObjectsServerMocksObj from './kbn_core_saved_objects_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_saved_objects_utils_server.mdx b/api_docs/kbn_core_saved_objects_utils_server.mdx index 839fa91de9e28..e08eda23d4c2a 100644 --- a/api_docs/kbn_core_saved_objects_utils_server.mdx +++ b/api_docs/kbn_core_saved_objects_utils_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-saved-objects-utils-server title: "@kbn/core-saved-objects-utils-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-saved-objects-utils-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-utils-server'] --- import kbnCoreSavedObjectsUtilsServerObj from './kbn_core_saved_objects_utils_server.devdocs.json'; diff --git a/api_docs/kbn_core_status_common.mdx b/api_docs/kbn_core_status_common.mdx index 3474e6cfda010..e5652924ff4db 100644 --- a/api_docs/kbn_core_status_common.mdx +++ b/api_docs/kbn_core_status_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-status-common title: "@kbn/core-status-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-status-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-status-common'] --- import kbnCoreStatusCommonObj from './kbn_core_status_common.devdocs.json'; diff --git a/api_docs/kbn_core_status_common_internal.mdx b/api_docs/kbn_core_status_common_internal.mdx index 624fc57ccd82f..b6e53b6f864f7 100644 --- a/api_docs/kbn_core_status_common_internal.mdx +++ b/api_docs/kbn_core_status_common_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-status-common-internal title: "@kbn/core-status-common-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-status-common-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-status-common-internal'] --- import kbnCoreStatusCommonInternalObj from './kbn_core_status_common_internal.devdocs.json'; diff --git a/api_docs/kbn_core_status_server.mdx b/api_docs/kbn_core_status_server.mdx index bb8d3763f3960..3ffd9064a22da 100644 --- a/api_docs/kbn_core_status_server.mdx +++ b/api_docs/kbn_core_status_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-status-server title: "@kbn/core-status-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-status-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-status-server'] --- import kbnCoreStatusServerObj from './kbn_core_status_server.devdocs.json'; diff --git a/api_docs/kbn_core_status_server_internal.mdx b/api_docs/kbn_core_status_server_internal.mdx index dfa000761cd67..2987aadb73ffa 100644 --- a/api_docs/kbn_core_status_server_internal.mdx +++ b/api_docs/kbn_core_status_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-status-server-internal title: "@kbn/core-status-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-status-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-status-server-internal'] --- import kbnCoreStatusServerInternalObj from './kbn_core_status_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_status_server_mocks.mdx b/api_docs/kbn_core_status_server_mocks.mdx index 1831961324062..376a850657143 100644 --- a/api_docs/kbn_core_status_server_mocks.mdx +++ b/api_docs/kbn_core_status_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-status-server-mocks title: "@kbn/core-status-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-status-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-status-server-mocks'] --- import kbnCoreStatusServerMocksObj from './kbn_core_status_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_test_helpers_deprecations_getters.mdx b/api_docs/kbn_core_test_helpers_deprecations_getters.mdx index d91b1cee3531b..4796e7fc71691 100644 --- a/api_docs/kbn_core_test_helpers_deprecations_getters.mdx +++ b/api_docs/kbn_core_test_helpers_deprecations_getters.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-test-helpers-deprecations-getters title: "@kbn/core-test-helpers-deprecations-getters" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-test-helpers-deprecations-getters plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-test-helpers-deprecations-getters'] --- import kbnCoreTestHelpersDeprecationsGettersObj from './kbn_core_test_helpers_deprecations_getters.devdocs.json'; diff --git a/api_docs/kbn_core_test_helpers_http_setup_browser.mdx b/api_docs/kbn_core_test_helpers_http_setup_browser.mdx index 91fa65dfece1f..8d108bf8ebea8 100644 --- a/api_docs/kbn_core_test_helpers_http_setup_browser.mdx +++ b/api_docs/kbn_core_test_helpers_http_setup_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-test-helpers-http-setup-browser title: "@kbn/core-test-helpers-http-setup-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-test-helpers-http-setup-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-test-helpers-http-setup-browser'] --- import kbnCoreTestHelpersHttpSetupBrowserObj from './kbn_core_test_helpers_http_setup_browser.devdocs.json'; diff --git a/api_docs/kbn_core_test_helpers_kbn_server.mdx b/api_docs/kbn_core_test_helpers_kbn_server.mdx index ef31947b0fd9a..9d1522dc7f37f 100644 --- a/api_docs/kbn_core_test_helpers_kbn_server.mdx +++ b/api_docs/kbn_core_test_helpers_kbn_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-test-helpers-kbn-server title: "@kbn/core-test-helpers-kbn-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-test-helpers-kbn-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-test-helpers-kbn-server'] --- import kbnCoreTestHelpersKbnServerObj from './kbn_core_test_helpers_kbn_server.devdocs.json'; diff --git a/api_docs/kbn_core_test_helpers_so_type_serializer.mdx b/api_docs/kbn_core_test_helpers_so_type_serializer.mdx index 5f1dacc24c5ea..4b677a212118c 100644 --- a/api_docs/kbn_core_test_helpers_so_type_serializer.mdx +++ b/api_docs/kbn_core_test_helpers_so_type_serializer.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-test-helpers-so-type-serializer title: "@kbn/core-test-helpers-so-type-serializer" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-test-helpers-so-type-serializer plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-test-helpers-so-type-serializer'] --- import kbnCoreTestHelpersSoTypeSerializerObj from './kbn_core_test_helpers_so_type_serializer.devdocs.json'; diff --git a/api_docs/kbn_core_test_helpers_test_utils.mdx b/api_docs/kbn_core_test_helpers_test_utils.mdx index 28fad63abb437..984f1a813ecf0 100644 --- a/api_docs/kbn_core_test_helpers_test_utils.mdx +++ b/api_docs/kbn_core_test_helpers_test_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-test-helpers-test-utils title: "@kbn/core-test-helpers-test-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-test-helpers-test-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-test-helpers-test-utils'] --- import kbnCoreTestHelpersTestUtilsObj from './kbn_core_test_helpers_test_utils.devdocs.json'; diff --git a/api_docs/kbn_core_theme_browser.mdx b/api_docs/kbn_core_theme_browser.mdx index 17e55440712d6..5fde0f497a4f6 100644 --- a/api_docs/kbn_core_theme_browser.mdx +++ b/api_docs/kbn_core_theme_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-theme-browser title: "@kbn/core-theme-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-theme-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-theme-browser'] --- import kbnCoreThemeBrowserObj from './kbn_core_theme_browser.devdocs.json'; diff --git a/api_docs/kbn_core_theme_browser_internal.mdx b/api_docs/kbn_core_theme_browser_internal.mdx index ba7ba8935ebba..2917abdc32db5 100644 --- a/api_docs/kbn_core_theme_browser_internal.mdx +++ b/api_docs/kbn_core_theme_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-theme-browser-internal title: "@kbn/core-theme-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-theme-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-theme-browser-internal'] --- import kbnCoreThemeBrowserInternalObj from './kbn_core_theme_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_theme_browser_mocks.mdx b/api_docs/kbn_core_theme_browser_mocks.mdx index e9598f9c1e9d2..a117efe0aa9ad 100644 --- a/api_docs/kbn_core_theme_browser_mocks.mdx +++ b/api_docs/kbn_core_theme_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-theme-browser-mocks title: "@kbn/core-theme-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-theme-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-theme-browser-mocks'] --- import kbnCoreThemeBrowserMocksObj from './kbn_core_theme_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_browser.mdx b/api_docs/kbn_core_ui_settings_browser.mdx index 23e3a16ce535b..7a064c001fddd 100644 --- a/api_docs/kbn_core_ui_settings_browser.mdx +++ b/api_docs/kbn_core_ui_settings_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-browser title: "@kbn/core-ui-settings-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-browser'] --- import kbnCoreUiSettingsBrowserObj from './kbn_core_ui_settings_browser.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_browser_internal.mdx b/api_docs/kbn_core_ui_settings_browser_internal.mdx index 79a6c7bec0d46..9f60fb3ca5655 100644 --- a/api_docs/kbn_core_ui_settings_browser_internal.mdx +++ b/api_docs/kbn_core_ui_settings_browser_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-browser-internal title: "@kbn/core-ui-settings-browser-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-browser-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-browser-internal'] --- import kbnCoreUiSettingsBrowserInternalObj from './kbn_core_ui_settings_browser_internal.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_browser_mocks.mdx b/api_docs/kbn_core_ui_settings_browser_mocks.mdx index 24e00dfbad876..025fe2b2ccd85 100644 --- a/api_docs/kbn_core_ui_settings_browser_mocks.mdx +++ b/api_docs/kbn_core_ui_settings_browser_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-browser-mocks title: "@kbn/core-ui-settings-browser-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-browser-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-browser-mocks'] --- import kbnCoreUiSettingsBrowserMocksObj from './kbn_core_ui_settings_browser_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_common.mdx b/api_docs/kbn_core_ui_settings_common.mdx index 1c8cf205577e9..12f827a8d3e22 100644 --- a/api_docs/kbn_core_ui_settings_common.mdx +++ b/api_docs/kbn_core_ui_settings_common.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-common title: "@kbn/core-ui-settings-common" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-common plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-common'] --- import kbnCoreUiSettingsCommonObj from './kbn_core_ui_settings_common.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_server.mdx b/api_docs/kbn_core_ui_settings_server.mdx index f1c9e0625f931..6ac60a431b027 100644 --- a/api_docs/kbn_core_ui_settings_server.mdx +++ b/api_docs/kbn_core_ui_settings_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-server title: "@kbn/core-ui-settings-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-server'] --- import kbnCoreUiSettingsServerObj from './kbn_core_ui_settings_server.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_server_internal.mdx b/api_docs/kbn_core_ui_settings_server_internal.mdx index 11fd534bf739f..db6593bca5669 100644 --- a/api_docs/kbn_core_ui_settings_server_internal.mdx +++ b/api_docs/kbn_core_ui_settings_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-server-internal title: "@kbn/core-ui-settings-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-server-internal'] --- import kbnCoreUiSettingsServerInternalObj from './kbn_core_ui_settings_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_ui_settings_server_mocks.mdx b/api_docs/kbn_core_ui_settings_server_mocks.mdx index 67887568fc9e1..9af9f2624fdd3 100644 --- a/api_docs/kbn_core_ui_settings_server_mocks.mdx +++ b/api_docs/kbn_core_ui_settings_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-ui-settings-server-mocks title: "@kbn/core-ui-settings-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-ui-settings-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-ui-settings-server-mocks'] --- import kbnCoreUiSettingsServerMocksObj from './kbn_core_ui_settings_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_core_usage_data_server.mdx b/api_docs/kbn_core_usage_data_server.mdx index f530d638eb8c7..76075508b2a44 100644 --- a/api_docs/kbn_core_usage_data_server.mdx +++ b/api_docs/kbn_core_usage_data_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-usage-data-server title: "@kbn/core-usage-data-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-usage-data-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-usage-data-server'] --- import kbnCoreUsageDataServerObj from './kbn_core_usage_data_server.devdocs.json'; diff --git a/api_docs/kbn_core_usage_data_server_internal.mdx b/api_docs/kbn_core_usage_data_server_internal.mdx index f813dc823bc69..9f06f3559ee29 100644 --- a/api_docs/kbn_core_usage_data_server_internal.mdx +++ b/api_docs/kbn_core_usage_data_server_internal.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-usage-data-server-internal title: "@kbn/core-usage-data-server-internal" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-usage-data-server-internal plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-usage-data-server-internal'] --- import kbnCoreUsageDataServerInternalObj from './kbn_core_usage_data_server_internal.devdocs.json'; diff --git a/api_docs/kbn_core_usage_data_server_mocks.mdx b/api_docs/kbn_core_usage_data_server_mocks.mdx index 2fbda680a7447..54536fb0a1d4f 100644 --- a/api_docs/kbn_core_usage_data_server_mocks.mdx +++ b/api_docs/kbn_core_usage_data_server_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-usage-data-server-mocks title: "@kbn/core-usage-data-server-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/core-usage-data-server-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-usage-data-server-mocks'] --- import kbnCoreUsageDataServerMocksObj from './kbn_core_usage_data_server_mocks.devdocs.json'; diff --git a/api_docs/kbn_crypto.mdx b/api_docs/kbn_crypto.mdx index d5f8c38095405..496c0c4f87d85 100644 --- a/api_docs/kbn_crypto.mdx +++ b/api_docs/kbn_crypto.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-crypto title: "@kbn/crypto" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/crypto plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/crypto'] --- import kbnCryptoObj from './kbn_crypto.devdocs.json'; diff --git a/api_docs/kbn_crypto_browser.mdx b/api_docs/kbn_crypto_browser.mdx index 1fca7db9a6df4..d107ebc63b5fb 100644 --- a/api_docs/kbn_crypto_browser.mdx +++ b/api_docs/kbn_crypto_browser.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-crypto-browser title: "@kbn/crypto-browser" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/crypto-browser plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/crypto-browser'] --- import kbnCryptoBrowserObj from './kbn_crypto_browser.devdocs.json'; diff --git a/api_docs/kbn_cypress_config.mdx b/api_docs/kbn_cypress_config.mdx index a5de64a2bdf75..9ef92d10cc3e0 100644 --- a/api_docs/kbn_cypress_config.mdx +++ b/api_docs/kbn_cypress_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-cypress-config title: "@kbn/cypress-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/cypress-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/cypress-config'] --- import kbnCypressConfigObj from './kbn_cypress_config.devdocs.json'; diff --git a/api_docs/kbn_datemath.mdx b/api_docs/kbn_datemath.mdx index 7826eeb2fb7cb..39e105ac7457b 100644 --- a/api_docs/kbn_datemath.mdx +++ b/api_docs/kbn_datemath.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-datemath title: "@kbn/datemath" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/datemath plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/datemath'] --- import kbnDatemathObj from './kbn_datemath.devdocs.json'; diff --git a/api_docs/kbn_dev_cli_errors.mdx b/api_docs/kbn_dev_cli_errors.mdx index 97a1670b755cb..b4d658801f863 100644 --- a/api_docs/kbn_dev_cli_errors.mdx +++ b/api_docs/kbn_dev_cli_errors.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-dev-cli-errors title: "@kbn/dev-cli-errors" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/dev-cli-errors plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/dev-cli-errors'] --- import kbnDevCliErrorsObj from './kbn_dev_cli_errors.devdocs.json'; diff --git a/api_docs/kbn_dev_cli_runner.mdx b/api_docs/kbn_dev_cli_runner.mdx index 49ba0ef192712..9a20fc6293d54 100644 --- a/api_docs/kbn_dev_cli_runner.mdx +++ b/api_docs/kbn_dev_cli_runner.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-dev-cli-runner title: "@kbn/dev-cli-runner" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/dev-cli-runner plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/dev-cli-runner'] --- import kbnDevCliRunnerObj from './kbn_dev_cli_runner.devdocs.json'; diff --git a/api_docs/kbn_dev_proc_runner.mdx b/api_docs/kbn_dev_proc_runner.mdx index 59cca04ae2899..36b94669e7b4d 100644 --- a/api_docs/kbn_dev_proc_runner.mdx +++ b/api_docs/kbn_dev_proc_runner.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-dev-proc-runner title: "@kbn/dev-proc-runner" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/dev-proc-runner plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/dev-proc-runner'] --- import kbnDevProcRunnerObj from './kbn_dev_proc_runner.devdocs.json'; diff --git a/api_docs/kbn_dev_utils.mdx b/api_docs/kbn_dev_utils.mdx index 18c3fc286ded3..1701745ef59cf 100644 --- a/api_docs/kbn_dev_utils.mdx +++ b/api_docs/kbn_dev_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-dev-utils title: "@kbn/dev-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/dev-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/dev-utils'] --- import kbnDevUtilsObj from './kbn_dev_utils.devdocs.json'; diff --git a/api_docs/kbn_doc_links.devdocs.json b/api_docs/kbn_doc_links.devdocs.json index 0aa153c9d4a60..02ef2e3f1f149 100644 --- a/api_docs/kbn_doc_links.devdocs.json +++ b/api_docs/kbn_doc_links.devdocs.json @@ -300,7 +300,7 @@ "label": "enterpriseSearch", "description": [], "signature": [ - "{ readonly apiKeys: string; readonly bulkApi: string; readonly configuration: string; readonly connectors: string; readonly connectorsMongoDB: string; readonly connectorsMySQL: string; readonly connectorsWorkplaceSearch: string; readonly crawlerManaging: string; readonly crawlerOverview: string; readonly deployTrainedModels: string; readonly documentLevelSecurity: string; readonly ingestPipelines: string; readonly languageAnalyzers: string; readonly languageClients: string; readonly licenseManagement: string; readonly machineLearningStart: string; readonly mailService: string; readonly start: string; readonly syncRules: string; readonly troubleshootSetup: string; readonly usersAccess: string; }" + "{ readonly apiKeys: string; readonly behavioralAnalyticsEvents: string; readonly bulkApi: string; readonly configuration: string; readonly connectors: string; readonly connectorsMongoDB: string; readonly connectorsMySQL: string; readonly connectorsWorkplaceSearch: string; readonly crawlerManaging: string; readonly crawlerOverview: string; readonly deployTrainedModels: string; readonly documentLevelSecurity: string; readonly ingestPipelines: string; readonly languageAnalyzers: string; readonly languageClients: string; readonly licenseManagement: string; readonly machineLearningStart: string; readonly mailService: string; readonly start: string; readonly syncRules: string; readonly troubleshootSetup: string; readonly usersAccess: string; }" ], "path": "packages/kbn-doc-links/src/types.ts", "deprecated": false, diff --git a/api_docs/kbn_doc_links.mdx b/api_docs/kbn_doc_links.mdx index 497b5f3f9eeb4..e842cad2f799a 100644 --- a/api_docs/kbn_doc_links.mdx +++ b/api_docs/kbn_doc_links.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-doc-links title: "@kbn/doc-links" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/doc-links plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/doc-links'] --- import kbnDocLinksObj from './kbn_doc_links.devdocs.json'; diff --git a/api_docs/kbn_docs_utils.mdx b/api_docs/kbn_docs_utils.mdx index 552bfc7e0c495..10110ac3f8cac 100644 --- a/api_docs/kbn_docs_utils.mdx +++ b/api_docs/kbn_docs_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-docs-utils title: "@kbn/docs-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/docs-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/docs-utils'] --- import kbnDocsUtilsObj from './kbn_docs_utils.devdocs.json'; diff --git a/api_docs/kbn_ebt_tools.mdx b/api_docs/kbn_ebt_tools.mdx index 85a90b1877ea8..31c1ab1c0d5d0 100644 --- a/api_docs/kbn_ebt_tools.mdx +++ b/api_docs/kbn_ebt_tools.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ebt-tools title: "@kbn/ebt-tools" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ebt-tools plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ebt-tools'] --- import kbnEbtToolsObj from './kbn_ebt_tools.devdocs.json'; diff --git a/api_docs/kbn_ecs.mdx b/api_docs/kbn_ecs.mdx index 946e9dd861339..124c46468f7ee 100644 --- a/api_docs/kbn_ecs.mdx +++ b/api_docs/kbn_ecs.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ecs title: "@kbn/ecs" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ecs plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ecs'] --- import kbnEcsObj from './kbn_ecs.devdocs.json'; diff --git a/api_docs/kbn_es.mdx b/api_docs/kbn_es.mdx index dd46d09c687b3..d641daaad2c71 100644 --- a/api_docs/kbn_es.mdx +++ b/api_docs/kbn_es.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-es title: "@kbn/es" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/es plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es'] --- import kbnEsObj from './kbn_es.devdocs.json'; diff --git a/api_docs/kbn_es_archiver.mdx b/api_docs/kbn_es_archiver.mdx index a91e2406184fd..23d0777f86cfb 100644 --- a/api_docs/kbn_es_archiver.mdx +++ b/api_docs/kbn_es_archiver.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-es-archiver title: "@kbn/es-archiver" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/es-archiver plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-archiver'] --- import kbnEsArchiverObj from './kbn_es_archiver.devdocs.json'; diff --git a/api_docs/kbn_es_errors.mdx b/api_docs/kbn_es_errors.mdx index cf0c657dcde33..c6fd6f8989ba1 100644 --- a/api_docs/kbn_es_errors.mdx +++ b/api_docs/kbn_es_errors.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-es-errors title: "@kbn/es-errors" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/es-errors plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-errors'] --- import kbnEsErrorsObj from './kbn_es_errors.devdocs.json'; diff --git a/api_docs/kbn_es_query.devdocs.json b/api_docs/kbn_es_query.devdocs.json index 775b0dc995f1a..73c14e298d98e 100644 --- a/api_docs/kbn_es_query.devdocs.json +++ b/api_docs/kbn_es_query.devdocs.json @@ -2201,6 +2201,129 @@ "returnComment": [], "initialIsOpen": false }, + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.filterToQueryDsl", + "type": "Function", + "tags": [], + "label": "filterToQueryDsl", + "description": [], + "signature": [ + "(filter: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + }, + ", inputDataViews: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewBase", + "text": "DataViewBase" + }, + " | ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewBase", + "text": "DataViewBase" + }, + "[] | undefined, options: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.EsQueryFiltersConfig", + "text": "EsQueryFiltersConfig" + }, + ") => ", + "QueryDslQueryContainer" + ], + "path": "packages/kbn-es-query/src/es_query/from_filters.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.filterToQueryDsl.$1", + "type": "Object", + "tags": [], + "label": "filter", + "description": [], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + } + ], + "path": "packages/kbn-es-query/src/es_query/from_filters.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + }, + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.filterToQueryDsl.$2", + "type": "CompoundType", + "tags": [], + "label": "inputDataViews", + "description": [], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewBase", + "text": "DataViewBase" + }, + " | ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.DataViewBase", + "text": "DataViewBase" + }, + "[] | undefined" + ], + "path": "packages/kbn-es-query/src/es_query/from_filters.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + }, + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.filterToQueryDsl.$3", + "type": "Object", + "tags": [], + "label": "options", + "description": [], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.EsQueryFiltersConfig", + "text": "EsQueryFiltersConfig" + } + ], + "path": "packages/kbn-es-query/src/es_query/from_filters.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [], + "initialIsOpen": false + }, { "parentPluginId": "@kbn/es-query", "id": "def-common.fromCombinedFilter", @@ -4047,7 +4170,7 @@ "section": "def-common.Filter", "text": "Filter" }, - ", field?: string | undefined, operator?: FilterOperator | undefined, params?: any) => { meta: { key: string | undefined; field: string | undefined; params: { query: undefined; }; value: undefined; type: undefined; alias?: string | null | undefined; disabled?: boolean | undefined; negate?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; }; query: undefined; $state?: { store: ", + ", field?: string | undefined, operator?: FilterOperator | undefined, params?: any, fieldType?: string | undefined) => { meta: { key: string | undefined; field: string | undefined; params: { query: undefined; }; value: undefined; type: undefined; alias?: string | null | undefined; disabled?: boolean | undefined; negate?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; }; query: undefined; $state?: { store: ", { "pluginId": "@kbn/es-query", "scope": "common", @@ -4063,7 +4186,7 @@ "section": "def-common.FilterStateStore", "text": "FilterStateStore" }, - "; } | undefined; } | { meta: { negate: boolean | undefined; type: string | undefined; params: any; alias?: string | null | undefined; disabled?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; key?: string | undefined; value?: string | undefined; }; query: { range: { [x: string]: any; }; }; $state?: { store: ", + "; } | undefined; } | { meta: { negate: boolean | undefined; type: string | undefined; params: { gte: string | number | undefined; lt: string | number | undefined; }; alias?: string | null | undefined; disabled?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; key?: string | undefined; value?: string | undefined; }; query: { range: { [x: string]: { gte: string | number | undefined; lt: string | number | undefined; }; }; }; $state?: { store: ", { "pluginId": "@kbn/es-query", "scope": "common", @@ -4079,7 +4202,7 @@ "section": "def-common.FilterStateStore", "text": "FilterStateStore" }, - "; } | undefined; } | { meta: { negate: boolean | undefined; type: string | undefined; params: any; alias?: string | null | undefined; disabled?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; key?: string | undefined; value?: string | undefined; }; query: { match_phrase: { [x: string]: any; }; }; $state?: { store: ", + "; } | undefined; } | { meta: { negate: boolean | undefined; type: string | undefined; params: any; value: undefined; alias?: string | null | undefined; disabled?: boolean | undefined; controlledBy?: string | undefined; group?: string | undefined; index?: string | undefined; isMultiIndex?: boolean | undefined; key?: string | undefined; }; query: { match_phrase: { [x: string]: any; }; }; $state?: { store: ", { "pluginId": "@kbn/es-query", "scope": "common", @@ -4158,6 +4281,21 @@ "deprecated": false, "trackAdoption": false, "isRequired": true + }, + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.updateFilter.$5", + "type": "string", + "tags": [], + "label": "fieldType", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/kbn-es-query/src/filters/helpers/update_filter.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false } ], "returnComment": [], @@ -4624,6 +4762,22 @@ "path": "packages/kbn-es-query/src/kuery/types.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "@kbn/es-query", + "id": "def-common.KueryQueryOptions.caseInsensitive", + "type": "CompoundType", + "tags": [], + "label": "caseInsensitive", + "description": [ + "\nWhether term-level queries should be treated as case-insensitive or not. For example, `agent.keyword: foobar` won't\nmatch a value of \"FooBar\" unless this parameter is `true`.\n(See https://www.elastic.co/guide/en/elasticsearch/reference/8.6/query-dsl-term-query.html#term-field-params)" + ], + "signature": [ + "boolean | undefined" + ], + "path": "packages/kbn-es-query/src/kuery/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false diff --git a/api_docs/kbn_es_query.mdx b/api_docs/kbn_es_query.mdx index 39c6febada4c2..fd96d569985ee 100644 --- a/api_docs/kbn_es_query.mdx +++ b/api_docs/kbn_es_query.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-es-query title: "@kbn/es-query" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/es-query plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-query'] --- import kbnEsQueryObj from './kbn_es_query.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Owner missing] for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 244 | 2 | 187 | 13 | +| 250 | 2 | 192 | 13 | ## Common diff --git a/api_docs/kbn_es_types.mdx b/api_docs/kbn_es_types.mdx index 231527940d8a8..7927337a93174 100644 --- a/api_docs/kbn_es_types.mdx +++ b/api_docs/kbn_es_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-es-types title: "@kbn/es-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/es-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-types'] --- import kbnEsTypesObj from './kbn_es_types.devdocs.json'; diff --git a/api_docs/kbn_eslint_plugin_imports.mdx b/api_docs/kbn_eslint_plugin_imports.mdx index 78c526bf9dca0..1deab7ed261f5 100644 --- a/api_docs/kbn_eslint_plugin_imports.mdx +++ b/api_docs/kbn_eslint_plugin_imports.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-eslint-plugin-imports title: "@kbn/eslint-plugin-imports" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/eslint-plugin-imports plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/eslint-plugin-imports'] --- import kbnEslintPluginImportsObj from './kbn_eslint_plugin_imports.devdocs.json'; diff --git a/api_docs/kbn_field_types.mdx b/api_docs/kbn_field_types.mdx index b13003b359db1..7b31fab5cdbb2 100644 --- a/api_docs/kbn_field_types.mdx +++ b/api_docs/kbn_field_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-field-types title: "@kbn/field-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/field-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/field-types'] --- import kbnFieldTypesObj from './kbn_field_types.devdocs.json'; diff --git a/api_docs/kbn_find_used_node_modules.mdx b/api_docs/kbn_find_used_node_modules.mdx index 3cb02a2abd6d6..51be1282f94a4 100644 --- a/api_docs/kbn_find_used_node_modules.mdx +++ b/api_docs/kbn_find_used_node_modules.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-find-used-node-modules title: "@kbn/find-used-node-modules" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/find-used-node-modules plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/find-used-node-modules'] --- import kbnFindUsedNodeModulesObj from './kbn_find_used_node_modules.devdocs.json'; diff --git a/api_docs/kbn_ftr_common_functional_services.mdx b/api_docs/kbn_ftr_common_functional_services.mdx index fc15431579673..7254847469eea 100644 --- a/api_docs/kbn_ftr_common_functional_services.mdx +++ b/api_docs/kbn_ftr_common_functional_services.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ftr-common-functional-services title: "@kbn/ftr-common-functional-services" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ftr-common-functional-services plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ftr-common-functional-services'] --- import kbnFtrCommonFunctionalServicesObj from './kbn_ftr_common_functional_services.devdocs.json'; diff --git a/api_docs/kbn_generate.mdx b/api_docs/kbn_generate.mdx index 8fd22f8be9f7d..db0c85be22a92 100644 --- a/api_docs/kbn_generate.mdx +++ b/api_docs/kbn_generate.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-generate title: "@kbn/generate" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/generate plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/generate'] --- import kbnGenerateObj from './kbn_generate.devdocs.json'; diff --git a/api_docs/kbn_get_repo_files.mdx b/api_docs/kbn_get_repo_files.mdx index 27fafda0b4973..571a2b46d4265 100644 --- a/api_docs/kbn_get_repo_files.mdx +++ b/api_docs/kbn_get_repo_files.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-get-repo-files title: "@kbn/get-repo-files" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/get-repo-files plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/get-repo-files'] --- import kbnGetRepoFilesObj from './kbn_get_repo_files.devdocs.json'; diff --git a/api_docs/kbn_guided_onboarding.devdocs.json b/api_docs/kbn_guided_onboarding.devdocs.json index 7932c979d41a2..09b27f31eede7 100644 --- a/api_docs/kbn_guided_onboarding.devdocs.json +++ b/api_docs/kbn_guided_onboarding.devdocs.json @@ -200,6 +200,113 @@ } ], "interfaces": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig", + "type": "Interface", + "tags": [], + "label": "GuideConfig", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.title", + "type": "string", + "tags": [], + "label": "title", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.guideName", + "type": "string", + "tags": [], + "label": "guideName", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.telemetryId", + "type": "string", + "tags": [], + "label": "telemetryId", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.docs", + "type": "Object", + "tags": [], + "label": "docs", + "description": [], + "signature": [ + "{ text: string; url: string; } | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.completedGuideRedirectLocation", + "type": "Object", + "tags": [], + "label": "completedGuideRedirectLocation", + "description": [], + "signature": [ + "{ appID: string; path: string; } | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.GuideConfig.steps", + "type": "Array", + "tags": [], + "label": "steps", + "description": [], + "signature": [ + { + "pluginId": "@kbn/guided-onboarding", + "scope": "common", + "docId": "kibKbnGuidedOnboardingPluginApi", + "section": "def-common.StepConfig", + "text": "StepConfig" + }, + "[]" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "@kbn/guided-onboarding", "id": "def-common.GuideState", @@ -310,7 +417,214 @@ "label": "status", "description": [], "signature": [ - "\"complete\" | \"in_progress\" | \"inactive\" | \"active\" | \"ready_to_complete\"" + "\"complete\" | \"in_progress\" | \"active\" | \"inactive\" | \"ready_to_complete\"" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig", + "type": "Interface", + "tags": [], + "label": "StepConfig", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.id", + "type": "CompoundType", + "tags": [], + "label": "id", + "description": [], + "signature": [ + "\"add_data\" | \"view_dashboard\" | \"tour_observability\" | \"rules\" | \"alertsCases\" | \"search_experience\" | \"step1\" | \"step2\" | \"step3\"" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.title", + "type": "string", + "tags": [], + "label": "title", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.description", + "type": "CompoundType", + "tags": [], + "label": "description", + "description": [], + "signature": [ + "string | ", + { + "pluginId": "@kbn/guided-onboarding", + "scope": "common", + "docId": "kibKbnGuidedOnboardingPluginApi", + "section": "def-common.StepDescriptionWithLink", + "text": "StepDescriptionWithLink" + }, + " | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.descriptionList", + "type": "Array", + "tags": [], + "label": "descriptionList", + "description": [], + "signature": [ + "(string | ", + { + "pluginId": "@kbn/guided-onboarding", + "scope": "common", + "docId": "kibKbnGuidedOnboardingPluginApi", + "section": "def-common.StepDescriptionWithLink", + "text": "StepDescriptionWithLink" + }, + ")[] | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.location", + "type": "Object", + "tags": [], + "label": "location", + "description": [], + "signature": [ + "{ appID: string; path: string; } | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.status", + "type": "CompoundType", + "tags": [], + "label": "status", + "description": [], + "signature": [ + { + "pluginId": "@kbn/guided-onboarding", + "scope": "common", + "docId": "kibKbnGuidedOnboardingPluginApi", + "section": "def-common.StepStatus", + "text": "StepStatus" + }, + " | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.integration", + "type": "string", + "tags": [], + "label": "integration", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepConfig.manualCompletion", + "type": "Object", + "tags": [], + "label": "manualCompletion", + "description": [], + "signature": [ + "{ title: string; description: string; readyToCompleteOnNavigation?: boolean | undefined; } | undefined" + ], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepDescriptionWithLink", + "type": "Interface", + "tags": [], + "label": "StepDescriptionWithLink", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepDescriptionWithLink.descriptionText", + "type": "string", + "tags": [], + "label": "descriptionText", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepDescriptionWithLink.linkText", + "type": "string", + "tags": [], + "label": "linkText", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepDescriptionWithLink.linkUrl", + "type": "string", + "tags": [], + "label": "linkUrl", + "description": [], + "path": "packages/kbn-guided-onboarding/src/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.StepDescriptionWithLink.isLinkExternal", + "type": "CompoundType", + "tags": [], + "label": "isLinkExternal", + "description": [], + "signature": [ + "boolean | undefined" ], "path": "packages/kbn-guided-onboarding/src/types.ts", "deprecated": false, @@ -394,14 +708,172 @@ "\nAllowed states for each step in a guide:\n inactive: Step has not started\n active: Step is ready to start (i.e., the guide has been started)\n in_progress: Step has been started and is in progress\n ready_to_complete: Step can be manually completed\n complete: Step has been completed" ], "signature": [ - "\"complete\" | \"in_progress\" | \"inactive\" | \"active\" | \"ready_to_complete\"" + "\"complete\" | \"in_progress\" | \"active\" | \"inactive\" | \"ready_to_complete\"" ], "path": "packages/kbn-guided-onboarding/src/types.ts", "deprecated": false, "trackAdoption": false, "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideId", + "type": "CompoundType", + "tags": [], + "label": "testGuideId", + "description": [], + "signature": [ + "\"search\" | \"kubernetes\" | \"siem\" | \"testGuide\"" + ], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false } ], - "objects": [] + "objects": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig", + "type": "Object", + "tags": [], + "label": "testGuideConfig", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.title", + "type": "string", + "tags": [], + "label": "title", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.description", + "type": "string", + "tags": [], + "label": "description", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.guideName", + "type": "string", + "tags": [], + "label": "guideName", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.telemetryId", + "type": "string", + "tags": [], + "label": "telemetryId", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.completedGuideRedirectLocation", + "type": "Object", + "tags": [], + "label": "completedGuideRedirectLocation", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.completedGuideRedirectLocation.appID", + "type": "string", + "tags": [], + "label": "appID", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.completedGuideRedirectLocation.path", + "type": "string", + "tags": [], + "label": "path", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.docs", + "type": "Object", + "tags": [], + "label": "docs", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.docs.text", + "type": "string", + "tags": [], + "label": "text", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.docs.url", + "type": "string", + "tags": [], + "label": "url", + "description": [], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + } + ] + }, + { + "parentPluginId": "@kbn/guided-onboarding", + "id": "def-common.testGuideConfig.steps", + "type": "Array", + "tags": [], + "label": "steps", + "description": [], + "signature": [ + "({ id: \"step1\"; title: string; descriptionList: string[]; location: { appID: string; path: string; }; integration: string; } | { id: \"step2\"; title: string; descriptionList: (string | { descriptionText: string; linkText: string; linkUrl: string; isLinkExternal: true; })[]; location: { appID: string; path: string; }; manualCompletion: { title: string; description: string; readyToCompleteOnNavigation: true; }; } | { id: \"step3\"; title: string; description: string; manualCompletion: { title: string; description: string; }; location: { appID: string; path: string; }; })[]" + ], + "path": "packages/kbn-guided-onboarding/src/common/test_guide_config.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ] } } \ No newline at end of file diff --git a/api_docs/kbn_guided_onboarding.mdx b/api_docs/kbn_guided_onboarding.mdx index ed378e26f9b7b..38490c1d489fb 100644 --- a/api_docs/kbn_guided_onboarding.mdx +++ b/api_docs/kbn_guided_onboarding.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-guided-onboarding title: "@kbn/guided-onboarding" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/guided-onboarding plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/guided-onboarding'] --- import kbnGuidedOnboardingObj from './kbn_guided_onboarding.devdocs.json'; @@ -21,10 +21,13 @@ Contact [Owner missing] for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 23 | 0 | 21 | 1 | +| 58 | 0 | 56 | 1 | ## Common +### Objects + + ### Functions diff --git a/api_docs/kbn_handlebars.mdx b/api_docs/kbn_handlebars.mdx index 2ef7dde4835e6..a05df194e13d6 100644 --- a/api_docs/kbn_handlebars.mdx +++ b/api_docs/kbn_handlebars.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-handlebars title: "@kbn/handlebars" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/handlebars plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/handlebars'] --- import kbnHandlebarsObj from './kbn_handlebars.devdocs.json'; diff --git a/api_docs/kbn_hapi_mocks.devdocs.json b/api_docs/kbn_hapi_mocks.devdocs.json index b6bc88b0ceafc..ea6ed36bfa580 100644 --- a/api_docs/kbn_hapi_mocks.devdocs.json +++ b/api_docs/kbn_hapi_mocks.devdocs.json @@ -248,7 +248,9 @@ "IncomingMessage", "; res: ", "ServerResponse", - "; }> | undefined; readonly route?: ", + "<", + "IncomingMessage", + ">; }> | undefined; readonly route?: ", { "pluginId": "@kbn/utility-types", "scope": "common", diff --git a/api_docs/kbn_hapi_mocks.mdx b/api_docs/kbn_hapi_mocks.mdx index 28133b495dc25..a8c67ce4dea25 100644 --- a/api_docs/kbn_hapi_mocks.mdx +++ b/api_docs/kbn_hapi_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-hapi-mocks title: "@kbn/hapi-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/hapi-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/hapi-mocks'] --- import kbnHapiMocksObj from './kbn_hapi_mocks.devdocs.json'; diff --git a/api_docs/kbn_health_gateway_server.mdx b/api_docs/kbn_health_gateway_server.mdx index 33cdb9c49636c..0c9e6106d5c29 100644 --- a/api_docs/kbn_health_gateway_server.mdx +++ b/api_docs/kbn_health_gateway_server.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-health-gateway-server title: "@kbn/health-gateway-server" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/health-gateway-server plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/health-gateway-server'] --- import kbnHealthGatewayServerObj from './kbn_health_gateway_server.devdocs.json'; diff --git a/api_docs/kbn_home_sample_data_card.mdx b/api_docs/kbn_home_sample_data_card.mdx index b23a5b2295bac..3d0ce27a18630 100644 --- a/api_docs/kbn_home_sample_data_card.mdx +++ b/api_docs/kbn_home_sample_data_card.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-home-sample-data-card title: "@kbn/home-sample-data-card" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/home-sample-data-card plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/home-sample-data-card'] --- import kbnHomeSampleDataCardObj from './kbn_home_sample_data_card.devdocs.json'; diff --git a/api_docs/kbn_home_sample_data_tab.mdx b/api_docs/kbn_home_sample_data_tab.mdx index 705b0b9e506fb..f0589392ae3ed 100644 --- a/api_docs/kbn_home_sample_data_tab.mdx +++ b/api_docs/kbn_home_sample_data_tab.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-home-sample-data-tab title: "@kbn/home-sample-data-tab" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/home-sample-data-tab plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/home-sample-data-tab'] --- import kbnHomeSampleDataTabObj from './kbn_home_sample_data_tab.devdocs.json'; diff --git a/api_docs/kbn_i18n.mdx b/api_docs/kbn_i18n.mdx index 7ef77c3383825..1a62fe290d58f 100644 --- a/api_docs/kbn_i18n.mdx +++ b/api_docs/kbn_i18n.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-i18n title: "@kbn/i18n" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/i18n plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/i18n'] --- import kbnI18nObj from './kbn_i18n.devdocs.json'; diff --git a/api_docs/kbn_i18n_react.mdx b/api_docs/kbn_i18n_react.mdx index 414cefd95eecd..7c60554aaa4c9 100644 --- a/api_docs/kbn_i18n_react.mdx +++ b/api_docs/kbn_i18n_react.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-i18n-react title: "@kbn/i18n-react" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/i18n-react plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/i18n-react'] --- import kbnI18nReactObj from './kbn_i18n_react.devdocs.json'; diff --git a/api_docs/kbn_import_resolver.mdx b/api_docs/kbn_import_resolver.mdx index 8a7eeabb8e15e..1ec60d6cf613e 100644 --- a/api_docs/kbn_import_resolver.mdx +++ b/api_docs/kbn_import_resolver.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-import-resolver title: "@kbn/import-resolver" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/import-resolver plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/import-resolver'] --- import kbnImportResolverObj from './kbn_import_resolver.devdocs.json'; diff --git a/api_docs/kbn_interpreter.mdx b/api_docs/kbn_interpreter.mdx index 0e39c1a319bcb..b1ce63fe6e33a 100644 --- a/api_docs/kbn_interpreter.mdx +++ b/api_docs/kbn_interpreter.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-interpreter title: "@kbn/interpreter" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/interpreter plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/interpreter'] --- import kbnInterpreterObj from './kbn_interpreter.devdocs.json'; diff --git a/api_docs/kbn_io_ts_utils.mdx b/api_docs/kbn_io_ts_utils.mdx index f4a245b05e601..92d85b85d6c58 100644 --- a/api_docs/kbn_io_ts_utils.mdx +++ b/api_docs/kbn_io_ts_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-io-ts-utils title: "@kbn/io-ts-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/io-ts-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/io-ts-utils'] --- import kbnIoTsUtilsObj from './kbn_io_ts_utils.devdocs.json'; diff --git a/api_docs/kbn_jest_serializers.mdx b/api_docs/kbn_jest_serializers.mdx index 42ec6f839193e..cf02593010ffa 100644 --- a/api_docs/kbn_jest_serializers.mdx +++ b/api_docs/kbn_jest_serializers.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-jest-serializers title: "@kbn/jest-serializers" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/jest-serializers plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/jest-serializers'] --- import kbnJestSerializersObj from './kbn_jest_serializers.devdocs.json'; diff --git a/api_docs/kbn_journeys.mdx b/api_docs/kbn_journeys.mdx index ae7af9171acba..6e75fe6e27191 100644 --- a/api_docs/kbn_journeys.mdx +++ b/api_docs/kbn_journeys.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-journeys title: "@kbn/journeys" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/journeys plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/journeys'] --- import kbnJourneysObj from './kbn_journeys.devdocs.json'; diff --git a/api_docs/kbn_json_ast.mdx b/api_docs/kbn_json_ast.mdx index cc094ba17bfa3..cd8e2019d316f 100644 --- a/api_docs/kbn_json_ast.mdx +++ b/api_docs/kbn_json_ast.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-json-ast title: "@kbn/json-ast" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/json-ast plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/json-ast'] --- import kbnJsonAstObj from './kbn_json_ast.devdocs.json'; diff --git a/api_docs/kbn_kibana_manifest_schema.mdx b/api_docs/kbn_kibana_manifest_schema.mdx index 8b903a91a5f63..0e9c0ceeacf0b 100644 --- a/api_docs/kbn_kibana_manifest_schema.mdx +++ b/api_docs/kbn_kibana_manifest_schema.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-kibana-manifest-schema title: "@kbn/kibana-manifest-schema" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/kibana-manifest-schema plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/kibana-manifest-schema'] --- import kbnKibanaManifestSchemaObj from './kbn_kibana_manifest_schema.devdocs.json'; diff --git a/api_docs/kbn_language_documentation_popover.mdx b/api_docs/kbn_language_documentation_popover.mdx index 52b091bbccecc..3a07b50a034d8 100644 --- a/api_docs/kbn_language_documentation_popover.mdx +++ b/api_docs/kbn_language_documentation_popover.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-language-documentation-popover title: "@kbn/language-documentation-popover" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/language-documentation-popover plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/language-documentation-popover'] --- import kbnLanguageDocumentationPopoverObj from './kbn_language_documentation_popover.devdocs.json'; diff --git a/api_docs/kbn_logging.mdx b/api_docs/kbn_logging.mdx index 347f5b3cd1859..979b3532a0cbd 100644 --- a/api_docs/kbn_logging.mdx +++ b/api_docs/kbn_logging.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-logging title: "@kbn/logging" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/logging plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/logging'] --- import kbnLoggingObj from './kbn_logging.devdocs.json'; diff --git a/api_docs/kbn_logging_mocks.mdx b/api_docs/kbn_logging_mocks.mdx index af67c36031f19..79f513ec72e95 100644 --- a/api_docs/kbn_logging_mocks.mdx +++ b/api_docs/kbn_logging_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-logging-mocks title: "@kbn/logging-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/logging-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/logging-mocks'] --- import kbnLoggingMocksObj from './kbn_logging_mocks.devdocs.json'; diff --git a/api_docs/kbn_managed_vscode_config.mdx b/api_docs/kbn_managed_vscode_config.mdx index 11cb3133f7649..5f33dafa82588 100644 --- a/api_docs/kbn_managed_vscode_config.mdx +++ b/api_docs/kbn_managed_vscode_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-managed-vscode-config title: "@kbn/managed-vscode-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/managed-vscode-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/managed-vscode-config'] --- import kbnManagedVscodeConfigObj from './kbn_managed_vscode_config.devdocs.json'; diff --git a/api_docs/kbn_mapbox_gl.mdx b/api_docs/kbn_mapbox_gl.mdx index cc7ec831f8402..1a2cab74c82b3 100644 --- a/api_docs/kbn_mapbox_gl.mdx +++ b/api_docs/kbn_mapbox_gl.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-mapbox-gl title: "@kbn/mapbox-gl" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/mapbox-gl plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/mapbox-gl'] --- import kbnMapboxGlObj from './kbn_mapbox_gl.devdocs.json'; diff --git a/api_docs/kbn_ml_agg_utils.mdx b/api_docs/kbn_ml_agg_utils.mdx index 121c169d68fde..5e400664bc9ba 100644 --- a/api_docs/kbn_ml_agg_utils.mdx +++ b/api_docs/kbn_ml_agg_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-agg-utils title: "@kbn/ml-agg-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-agg-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-agg-utils'] --- import kbnMlAggUtilsObj from './kbn_ml_agg_utils.devdocs.json'; diff --git a/api_docs/kbn_ml_date_picker.mdx b/api_docs/kbn_ml_date_picker.mdx index 23fb42075a7b6..ca520e74ffd3f 100644 --- a/api_docs/kbn_ml_date_picker.mdx +++ b/api_docs/kbn_ml_date_picker.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-date-picker title: "@kbn/ml-date-picker" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-date-picker plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-date-picker'] --- import kbnMlDatePickerObj from './kbn_ml_date_picker.devdocs.json'; diff --git a/api_docs/kbn_ml_is_defined.mdx b/api_docs/kbn_ml_is_defined.mdx index dc66bb9da70de..0eb5d578d1e94 100644 --- a/api_docs/kbn_ml_is_defined.mdx +++ b/api_docs/kbn_ml_is_defined.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-is-defined title: "@kbn/ml-is-defined" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-is-defined plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-is-defined'] --- import kbnMlIsDefinedObj from './kbn_ml_is_defined.devdocs.json'; diff --git a/api_docs/kbn_ml_is_populated_object.mdx b/api_docs/kbn_ml_is_populated_object.mdx index b426af00bcee9..9e6074d54406a 100644 --- a/api_docs/kbn_ml_is_populated_object.mdx +++ b/api_docs/kbn_ml_is_populated_object.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-is-populated-object title: "@kbn/ml-is-populated-object" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-is-populated-object plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-is-populated-object'] --- import kbnMlIsPopulatedObjectObj from './kbn_ml_is_populated_object.devdocs.json'; diff --git a/api_docs/kbn_ml_local_storage.mdx b/api_docs/kbn_ml_local_storage.mdx index 22af5b56fb4f7..4689081d128e6 100644 --- a/api_docs/kbn_ml_local_storage.mdx +++ b/api_docs/kbn_ml_local_storage.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-local-storage title: "@kbn/ml-local-storage" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-local-storage plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-local-storage'] --- import kbnMlLocalStorageObj from './kbn_ml_local_storage.devdocs.json'; diff --git a/api_docs/kbn_ml_nested_property.mdx b/api_docs/kbn_ml_nested_property.mdx index 376504b80e9e6..eda64de3f028e 100644 --- a/api_docs/kbn_ml_nested_property.mdx +++ b/api_docs/kbn_ml_nested_property.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-nested-property title: "@kbn/ml-nested-property" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-nested-property plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-nested-property'] --- import kbnMlNestedPropertyObj from './kbn_ml_nested_property.devdocs.json'; diff --git a/api_docs/kbn_ml_query_utils.mdx b/api_docs/kbn_ml_query_utils.mdx index a14cccd178498..c0b13e9c7227d 100644 --- a/api_docs/kbn_ml_query_utils.mdx +++ b/api_docs/kbn_ml_query_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-query-utils title: "@kbn/ml-query-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-query-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-query-utils'] --- import kbnMlQueryUtilsObj from './kbn_ml_query_utils.devdocs.json'; diff --git a/api_docs/kbn_ml_string_hash.mdx b/api_docs/kbn_ml_string_hash.mdx index e0f7f02c73ef8..e04d96f9a1876 100644 --- a/api_docs/kbn_ml_string_hash.mdx +++ b/api_docs/kbn_ml_string_hash.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-string-hash title: "@kbn/ml-string-hash" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-string-hash plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-string-hash'] --- import kbnMlStringHashObj from './kbn_ml_string_hash.devdocs.json'; diff --git a/api_docs/kbn_ml_url_state.mdx b/api_docs/kbn_ml_url_state.mdx index 6758e1e73f64d..18ab9ffa8e811 100644 --- a/api_docs/kbn_ml_url_state.mdx +++ b/api_docs/kbn_ml_url_state.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ml-url-state title: "@kbn/ml-url-state" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ml-url-state plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-url-state'] --- import kbnMlUrlStateObj from './kbn_ml_url_state.devdocs.json'; diff --git a/api_docs/kbn_monaco.mdx b/api_docs/kbn_monaco.mdx index 0d5e4ad9300c6..7320d0544bdb7 100644 --- a/api_docs/kbn_monaco.mdx +++ b/api_docs/kbn_monaco.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-monaco title: "@kbn/monaco" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/monaco plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/monaco'] --- import kbnMonacoObj from './kbn_monaco.devdocs.json'; diff --git a/api_docs/kbn_optimizer.mdx b/api_docs/kbn_optimizer.mdx index 79d35bdd1e9cf..f3297ae4678c7 100644 --- a/api_docs/kbn_optimizer.mdx +++ b/api_docs/kbn_optimizer.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-optimizer title: "@kbn/optimizer" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/optimizer plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/optimizer'] --- import kbnOptimizerObj from './kbn_optimizer.devdocs.json'; diff --git a/api_docs/kbn_optimizer_webpack_helpers.mdx b/api_docs/kbn_optimizer_webpack_helpers.mdx index 5aa1aaf5ba654..9d47cab3d0a48 100644 --- a/api_docs/kbn_optimizer_webpack_helpers.mdx +++ b/api_docs/kbn_optimizer_webpack_helpers.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-optimizer-webpack-helpers title: "@kbn/optimizer-webpack-helpers" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/optimizer-webpack-helpers plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/optimizer-webpack-helpers'] --- import kbnOptimizerWebpackHelpersObj from './kbn_optimizer_webpack_helpers.devdocs.json'; diff --git a/api_docs/kbn_osquery_io_ts_types.mdx b/api_docs/kbn_osquery_io_ts_types.mdx index d962fac1cb4b4..5546f8af65834 100644 --- a/api_docs/kbn_osquery_io_ts_types.mdx +++ b/api_docs/kbn_osquery_io_ts_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-osquery-io-ts-types title: "@kbn/osquery-io-ts-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/osquery-io-ts-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/osquery-io-ts-types'] --- import kbnOsqueryIoTsTypesObj from './kbn_osquery_io_ts_types.devdocs.json'; diff --git a/api_docs/kbn_performance_testing_dataset_extractor.mdx b/api_docs/kbn_performance_testing_dataset_extractor.mdx index 8dee161f1e31c..fcbc28f5c082e 100644 --- a/api_docs/kbn_performance_testing_dataset_extractor.mdx +++ b/api_docs/kbn_performance_testing_dataset_extractor.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-performance-testing-dataset-extractor title: "@kbn/performance-testing-dataset-extractor" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/performance-testing-dataset-extractor plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/performance-testing-dataset-extractor'] --- import kbnPerformanceTestingDatasetExtractorObj from './kbn_performance_testing_dataset_extractor.devdocs.json'; diff --git a/api_docs/kbn_plugin_generator.mdx b/api_docs/kbn_plugin_generator.mdx index c1453c2409471..dbb2a8bb00093 100644 --- a/api_docs/kbn_plugin_generator.mdx +++ b/api_docs/kbn_plugin_generator.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-plugin-generator title: "@kbn/plugin-generator" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/plugin-generator plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/plugin-generator'] --- import kbnPluginGeneratorObj from './kbn_plugin_generator.devdocs.json'; diff --git a/api_docs/kbn_plugin_helpers.mdx b/api_docs/kbn_plugin_helpers.mdx index 1d6fa74785b7c..f84da983ddfc4 100644 --- a/api_docs/kbn_plugin_helpers.mdx +++ b/api_docs/kbn_plugin_helpers.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-plugin-helpers title: "@kbn/plugin-helpers" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/plugin-helpers plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/plugin-helpers'] --- import kbnPluginHelpersObj from './kbn_plugin_helpers.devdocs.json'; diff --git a/api_docs/kbn_react_field.mdx b/api_docs/kbn_react_field.mdx index a8c6595cc3397..bb775ec7f6518 100644 --- a/api_docs/kbn_react_field.mdx +++ b/api_docs/kbn_react_field.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-react-field title: "@kbn/react-field" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/react-field plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/react-field'] --- import kbnReactFieldObj from './kbn_react_field.devdocs.json'; diff --git a/api_docs/kbn_repo_file_maps.mdx b/api_docs/kbn_repo_file_maps.mdx index a76455e4c917d..67c9ae2a153af 100644 --- a/api_docs/kbn_repo_file_maps.mdx +++ b/api_docs/kbn_repo_file_maps.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-repo-file-maps title: "@kbn/repo-file-maps" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/repo-file-maps plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/repo-file-maps'] --- import kbnRepoFileMapsObj from './kbn_repo_file_maps.devdocs.json'; diff --git a/api_docs/kbn_repo_linter.mdx b/api_docs/kbn_repo_linter.mdx index 935ac1afb3bb6..47cd7750790c2 100644 --- a/api_docs/kbn_repo_linter.mdx +++ b/api_docs/kbn_repo_linter.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-repo-linter title: "@kbn/repo-linter" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/repo-linter plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/repo-linter'] --- import kbnRepoLinterObj from './kbn_repo_linter.devdocs.json'; diff --git a/api_docs/kbn_repo_path.mdx b/api_docs/kbn_repo_path.mdx index b8ebeaf09d6e9..1b95e4143d6a5 100644 --- a/api_docs/kbn_repo_path.mdx +++ b/api_docs/kbn_repo_path.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-repo-path title: "@kbn/repo-path" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/repo-path plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/repo-path'] --- import kbnRepoPathObj from './kbn_repo_path.devdocs.json'; diff --git a/api_docs/kbn_repo_source_classifier.mdx b/api_docs/kbn_repo_source_classifier.mdx index 731aaa7088d34..be3e88db7f552 100644 --- a/api_docs/kbn_repo_source_classifier.mdx +++ b/api_docs/kbn_repo_source_classifier.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-repo-source-classifier title: "@kbn/repo-source-classifier" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/repo-source-classifier plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/repo-source-classifier'] --- import kbnRepoSourceClassifierObj from './kbn_repo_source_classifier.devdocs.json'; diff --git a/api_docs/kbn_rison.mdx b/api_docs/kbn_rison.mdx index d4df97fc0e847..d6bcd91d7110f 100644 --- a/api_docs/kbn_rison.mdx +++ b/api_docs/kbn_rison.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-rison title: "@kbn/rison" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/rison plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/rison'] --- import kbnRisonObj from './kbn_rison.devdocs.json'; diff --git a/api_docs/kbn_rule_data_utils.devdocs.json b/api_docs/kbn_rule_data_utils.devdocs.json index 02fdc483391ff..2882bd4b1b87b 100644 --- a/api_docs/kbn_rule_data_utils.devdocs.json +++ b/api_docs/kbn_rule_data_utils.devdocs.json @@ -1266,7 +1266,7 @@ "label": "AlertStatus", "description": [], "signature": [ - "\"active\" | \"recovered\"" + "\"recovered\" | \"active\"" ], "path": "packages/kbn-rule-data-utils/src/alerts_as_data_status.ts", "deprecated": false, diff --git a/api_docs/kbn_rule_data_utils.mdx b/api_docs/kbn_rule_data_utils.mdx index 479c3a3f1b7c1..54c70b242db52 100644 --- a/api_docs/kbn_rule_data_utils.mdx +++ b/api_docs/kbn_rule_data_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-rule-data-utils title: "@kbn/rule-data-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/rule-data-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/rule-data-utils'] --- import kbnRuleDataUtilsObj from './kbn_rule_data_utils.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_autocomplete.devdocs.json b/api_docs/kbn_securitysolution_autocomplete.devdocs.json index 5f57ad28f5f73..365830c784ff3 100644 --- a/api_docs/kbn_securitysolution_autocomplete.devdocs.json +++ b/api_docs/kbn_securitysolution_autocomplete.devdocs.json @@ -842,7 +842,7 @@ "label": "smallLists", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" + "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" ], "path": "packages/kbn-securitysolution-autocomplete/src/field_value_lists/index.tsx", "deprecated": false, @@ -856,7 +856,7 @@ "label": "largeLists", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" + "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" ], "path": "packages/kbn-securitysolution-autocomplete/src/field_value_lists/index.tsx", "deprecated": false, diff --git a/api_docs/kbn_securitysolution_autocomplete.mdx b/api_docs/kbn_securitysolution_autocomplete.mdx index 99ee0ddc47034..59a965a6c4099 100644 --- a/api_docs/kbn_securitysolution_autocomplete.mdx +++ b/api_docs/kbn_securitysolution_autocomplete.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-autocomplete title: "@kbn/securitysolution-autocomplete" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-autocomplete plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-autocomplete'] --- import kbnSecuritysolutionAutocompleteObj from './kbn_securitysolution_autocomplete.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_es_utils.mdx b/api_docs/kbn_securitysolution_es_utils.mdx index 860b4d4bdbb33..28b54b60bbaa5 100644 --- a/api_docs/kbn_securitysolution_es_utils.mdx +++ b/api_docs/kbn_securitysolution_es_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-es-utils title: "@kbn/securitysolution-es-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-es-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-es-utils'] --- import kbnSecuritysolutionEsUtilsObj from './kbn_securitysolution_es_utils.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_exception_list_components.devdocs.json b/api_docs/kbn_securitysolution_exception_list_components.devdocs.json index 83973455bda55..6e10def35b04f 100644 --- a/api_docs/kbn_securitysolution_exception_list_components.devdocs.json +++ b/api_docs/kbn_securitysolution_exception_list_components.devdocs.json @@ -721,7 +721,7 @@ "label": "item", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-exception-list-components/src/exception_item_card/header/index.tsx", "deprecated": false, @@ -788,7 +788,7 @@ "label": "item", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-exception-list-components/src/exception_item_card/meta/index.tsx", "deprecated": false, @@ -904,7 +904,7 @@ "label": "exceptionItem", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-exception-list-components/src/exception_item_card/exception_item_card.tsx", "deprecated": false, @@ -1095,7 +1095,7 @@ "label": "onEditException", "description": [], "signature": [ - "(item: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void" + "(item: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void" ], "path": "packages/kbn-securitysolution-exception-list-components/src/exception_item_card/exception_item_card.tsx", "deprecated": false, @@ -1109,7 +1109,7 @@ "label": "item", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-exception-list-components/src/exception_item_card/exception_item_card.tsx", "deprecated": false, diff --git a/api_docs/kbn_securitysolution_exception_list_components.mdx b/api_docs/kbn_securitysolution_exception_list_components.mdx index d3ba5df20a821..59fcefcdfa11c 100644 --- a/api_docs/kbn_securitysolution_exception_list_components.mdx +++ b/api_docs/kbn_securitysolution_exception_list_components.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-exception-list-components title: "@kbn/securitysolution-exception-list-components" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-exception-list-components plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-exception-list-components'] --- import kbnSecuritysolutionExceptionListComponentsObj from './kbn_securitysolution_exception_list_components.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_hook_utils.mdx b/api_docs/kbn_securitysolution_hook_utils.mdx index 28738aa7dad04..7bc28e5151305 100644 --- a/api_docs/kbn_securitysolution_hook_utils.mdx +++ b/api_docs/kbn_securitysolution_hook_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-hook-utils title: "@kbn/securitysolution-hook-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-hook-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-hook-utils'] --- import kbnSecuritysolutionHookUtilsObj from './kbn_securitysolution_hook_utils.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_io_ts_alerting_types.devdocs.json b/api_docs/kbn_securitysolution_io_ts_alerting_types.devdocs.json index 12a248d480308..37adc65cf7fee 100644 --- a/api_docs/kbn_securitysolution_io_ts_alerting_types.devdocs.json +++ b/api_docs/kbn_securitysolution_io_ts_alerting_types.devdocs.json @@ -1218,7 +1218,7 @@ "tags": [], "label": "DefaultUuid", "description": [ - "\nTypes the DefaultUuid as:\n - If null or undefined, then a default string uuid.v4() will be\n created otherwise it will be checked just against an empty string" + "\nTypes the DefaultUuid as:\n - If null or undefined, then a default string uuidv4() will be\n created otherwise it will be checked just against an empty string" ], "signature": [ "Type", diff --git a/api_docs/kbn_securitysolution_io_ts_alerting_types.mdx b/api_docs/kbn_securitysolution_io_ts_alerting_types.mdx index e38964fec0bba..38e354a34d909 100644 --- a/api_docs/kbn_securitysolution_io_ts_alerting_types.mdx +++ b/api_docs/kbn_securitysolution_io_ts_alerting_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-io-ts-alerting-types title: "@kbn/securitysolution-io-ts-alerting-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-io-ts-alerting-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-io-ts-alerting-types'] --- import kbnSecuritysolutionIoTsAlertingTypesObj from './kbn_securitysolution_io_ts_alerting_types.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_io_ts_list_types.devdocs.json b/api_docs/kbn_securitysolution_io_ts_list_types.devdocs.json index 9bcbaf8108ab8..f54dfcd7e0da2 100644 --- a/api_docs/kbn_securitysolution_io_ts_list_types.devdocs.json +++ b/api_docs/kbn_securitysolution_io_ts_list_types.devdocs.json @@ -27,7 +27,7 @@ "label": "updateExceptionListItemValidate", "description": [], "signature": [ - "(schema: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => string[]" + "(schema: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => string[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_validation/index.ts", "deprecated": false, @@ -41,7 +41,7 @@ "label": "schema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_validation/index.ts", "deprecated": false, @@ -60,7 +60,7 @@ "label": "validateComments", "description": [], "signature": [ - "(item: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => string[]" + "(item: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => string[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_validation/index.ts", "deprecated": false, @@ -74,7 +74,7 @@ "label": "item", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_validation/index.ts", "deprecated": false, @@ -162,7 +162,7 @@ "label": "listItem", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/typescript_types/index.ts", "deprecated": false, @@ -718,7 +718,7 @@ "label": "exceptions", "description": [], "signature": [ - "({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]" + "({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/typescript_types/index.ts", "deprecated": false, @@ -1589,7 +1589,7 @@ "label": "exceptions", "description": [], "signature": [ - "({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]" + "({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/typescript_types/index.ts", "deprecated": false, @@ -1847,7 +1847,7 @@ "label": "listItem", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/typescript_types/index.ts", "deprecated": false, @@ -1945,7 +1945,7 @@ "label": "exceptions", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/typescript_types/index.ts", "deprecated": false, @@ -2617,7 +2617,7 @@ "label": "CreateEndpointListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"included\"; type: \"wildcard\"; value: string; } | { entries: ({ field: string; operator: \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"included\"; type: \"match_any\"; value: string[]; })[]; field: string; type: \"nested\"; })[]; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; meta: object | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"os_types\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"included\"; type: \"wildcard\"; value: string; } | { entries: ({ field: string; operator: \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"included\"; type: \"match_any\"; value: string[]; })[]; field: string; type: \"nested\"; })[]; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; meta: object | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"os_types\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_endpoint_list_item_schema/index.ts", "deprecated": false, @@ -2647,7 +2647,7 @@ "label": "CreateExceptionListItemSchema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_exception_list_item_schema/index.ts", "deprecated": false, @@ -2662,7 +2662,7 @@ "label": "CreateExceptionListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_exception_list_item_schema/index.ts", "deprecated": false, @@ -2737,7 +2737,7 @@ "label": "CreateListSchema", "description": [], "signature": [ - "{ description: string; name: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; } & { deserializer?: string | undefined; id?: string | undefined; meta?: object | undefined; serializer?: string | undefined; version?: number | undefined; }" + "{ description: string; name: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; } & { deserializer?: string | undefined; id?: string | undefined; meta?: object | undefined; serializer?: string | undefined; version?: number | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_list_schema/index.ts", "deprecated": false, @@ -2752,7 +2752,7 @@ "label": "CreateListSchemaDecoded", "description": [], "signature": [ - "{ name: string; description: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; id: string | undefined; meta: object | undefined; serializer: string | undefined; deserializer: string | undefined; } & { version: number; }" + "{ name: string; description: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; id: string | undefined; meta: object | undefined; serializer: string | undefined; deserializer: string | undefined; } & { version: number; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_list_schema/index.ts", "deprecated": false, @@ -2767,7 +2767,7 @@ "label": "CreateRuleExceptionListItemSchema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; list_id?: undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; list_id?: undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_rule_exception_item_schema/index.ts", "deprecated": false, @@ -2782,7 +2782,7 @@ "label": "CreateRuleExceptionListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; list_id: undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; comments: { comment: string; }[] | undefined; item_id: string | undefined; list_id: undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: { comment: string; }[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/create_rule_exception_item_schema/index.ts", "deprecated": false, @@ -3097,7 +3097,7 @@ "label": "EntriesArray", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/entries/index.ts", "deprecated": false, @@ -3112,7 +3112,7 @@ "label": "EntriesArrayOrUndefined", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[] | undefined" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[] | undefined" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/entries/index.ts", "deprecated": false, @@ -3127,7 +3127,7 @@ "label": "Entry", "description": [], "signature": [ - "{ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }" + "{ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/entries/index.ts", "deprecated": false, @@ -3157,7 +3157,7 @@ "label": "EntryList", "description": [], "signature": [ - "{ field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; }" + "{ field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/entries_list/index.ts", "deprecated": false, @@ -3247,7 +3247,7 @@ "label": "ExceptionListItemSchema", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/exception_list_item_schema/index.ts", "deprecated": false, @@ -3592,7 +3592,7 @@ "label": "FoundAllListItemsSchema", "description": [], "signature": [ - "{ data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; total: number; }" + "{ data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; total: number; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/found_all_list_items_schema/index.ts", "deprecated": false, @@ -3607,7 +3607,7 @@ "label": "FoundExceptionListItemSchema", "description": [], "signature": [ - "{ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }" + "{ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/found_exception_list_item_schema/index.ts", "deprecated": false, @@ -3637,7 +3637,7 @@ "label": "FoundListItemSchema", "description": [], "signature": [ - "{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; page: number; per_page: number; total: number; }" + "{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; page: number; per_page: number; total: number; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/found_list_item_schema/index.ts", "deprecated": false, @@ -3652,7 +3652,7 @@ "label": "FoundListsBySizeSchema", "description": [], "signature": [ - "{ largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }" + "{ largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/found_lists_by_size_schema/index.ts", "deprecated": false, @@ -3667,7 +3667,7 @@ "label": "FoundListSchema", "description": [], "signature": [ - "{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }" + "{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/found_list_schema/index.ts", "deprecated": false, @@ -3682,7 +3682,7 @@ "label": "GetExceptionFilterSchema", "description": [], "signature": [ - "({ exception_list_ids: { exception_list_id: string; namespace_type: \"single\" | \"agnostic\"; }[]; type: \"exception_list_ids\"; } | { exceptions: ({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]; type: \"exception_items\"; }) & { alias?: string | undefined; chunk_size?: number | undefined; exclude_exceptions?: boolean | undefined; }" + "({ exception_list_ids: { exception_list_id: string; namespace_type: \"single\" | \"agnostic\"; }[]; type: \"exception_list_ids\"; } | { exceptions: ({ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }))[]; type: \"exception_items\"; }) & { alias?: string | undefined; chunk_size?: number | undefined; exclude_exceptions?: boolean | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/get_exception_filter_schema/index.ts", "deprecated": false, @@ -3802,7 +3802,7 @@ "label": "ImportExceptionListItemSchema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; item_id: string; list_id: string; name: string; type: \"simple\"; } & { id?: string | undefined; comments?: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[] | undefined; created_at?: string | undefined; updated_at?: string | undefined; created_by?: string | undefined; updated_by?: string | undefined; _version?: string | undefined; tie_breaker_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; item_id: string; list_id: string; name: string; type: \"simple\"; } & { id?: string | undefined; comments?: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[] | undefined; created_at?: string | undefined; updated_at?: string | undefined; created_by?: string | undefined; updated_by?: string | undefined; _version?: string | undefined; tie_breaker_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/import_exception_item_schema/index.ts", "deprecated": false, @@ -3817,7 +3817,7 @@ "label": "ImportExceptionListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; item_id: string; list_id: string; name: string; type: \"simple\"; } & { id?: string | undefined; comments?: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[] | undefined; created_at?: string | undefined; updated_at?: string | undefined; created_by?: string | undefined; updated_by?: string | undefined; _version?: string | undefined; tie_breaker_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; item_id: string; list_id: string; name: string; type: \"simple\"; } & { id?: string | undefined; comments?: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[] | undefined; created_at?: string | undefined; updated_at?: string | undefined; created_by?: string | undefined; updated_by?: string | undefined; _version?: string | undefined; tie_breaker_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"item_id\" | \"namespace_type\"> & { comments: (({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; }) | { comment: string; })[]; tags: string[]; item_id: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/import_exception_item_schema/index.ts", "deprecated": false, @@ -3877,7 +3877,7 @@ "label": "ImportListItemQuerySchema", "description": [], "signature": [ - "{ deserializer: string | undefined; list_id: string | undefined; serializer: string | undefined; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined; }" + "{ deserializer: string | undefined; list_id: string | undefined; serializer: string | undefined; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/import_list_item_query_schema/index.ts", "deprecated": false, @@ -3892,7 +3892,7 @@ "label": "ImportListItemQuerySchemaEncoded", "description": [], "signature": [ - "{ deserializer?: string | undefined; list_id?: string | undefined; serializer?: string | undefined; type?: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined; }" + "{ deserializer?: string | undefined; list_id?: string | undefined; serializer?: string | undefined; type?: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/import_list_item_query_schema/index.ts", "deprecated": false, @@ -4042,7 +4042,7 @@ "label": "ListArraySchema", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" + "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/list_schema/index.ts", "deprecated": false, @@ -4087,7 +4087,7 @@ "label": "ListItemArraySchema", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]" + "{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/list_item_schema/index.ts", "deprecated": false, @@ -4117,7 +4117,7 @@ "label": "ListItemSchema", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }" + "{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/list_item_schema/index.ts", "deprecated": false, @@ -4147,7 +4147,7 @@ "label": "ListSchema", "description": [], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }" + "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/list_schema/index.ts", "deprecated": false, @@ -4372,7 +4372,7 @@ "label": "NonEmptyEntriesArray", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/non_empty_entries_array/index.ts", "deprecated": false, @@ -4387,7 +4387,7 @@ "label": "NonEmptyEntriesArrayDecoded", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/non_empty_entries_array/index.ts", "deprecated": false, @@ -4822,7 +4822,7 @@ "label": "SearchListItemArraySchema", "description": [], "signature": [ - "{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }[]" + "{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }[]" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/search_list_item_schema/index.ts", "deprecated": false, @@ -4837,7 +4837,7 @@ "label": "SearchListItemSchema", "description": [], "signature": [ - "{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }" + "{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/response/search_list_item_schema/index.ts", "deprecated": false, @@ -5002,7 +5002,7 @@ "label": "Type", "description": [], "signature": [ - "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"" + "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/type/index.ts", "deprecated": false, @@ -5017,7 +5017,7 @@ "label": "TypeOrUndefined", "description": [], "signature": [ - "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined" + "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/type/index.ts", "deprecated": false, @@ -5077,7 +5077,7 @@ "label": "UpdateEndpointListItemSchema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_endpoint_list_item_schema/index.ts", "deprecated": false, @@ -5092,7 +5092,7 @@ "label": "UpdateEndpointListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; _version: string | undefined; comments: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id: string | undefined; item_id: string | undefined; meta: object | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\"> & { comments: ({ comment: string; } & { id?: string | undefined; })[]; tags: string[]; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; _version: string | undefined; comments: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id: string | undefined; item_id: string | undefined; meta: object | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\"> & { comments: ({ comment: string; } & { id?: string | undefined; })[]; tags: string[]; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_endpoint_list_item_schema/index.ts", "deprecated": false, @@ -5107,7 +5107,7 @@ "label": "UpdateExceptionListItemSchema", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_schema/index.ts", "deprecated": false, @@ -5122,7 +5122,7 @@ "label": "UpdateExceptionListItemSchemaDecoded", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; _version: string | undefined; comments: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id: string | undefined; item_id: string | undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"namespace_type\" | \"os_types\"> & { comments: ({ comment: string; } & { id?: string | undefined; })[]; tags: string[]; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; _version: string | undefined; comments: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id: string | undefined; item_id: string | undefined; meta: object | undefined; namespace_type: \"single\" | \"agnostic\" | undefined; os_types: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags: string[] | undefined; }, \"tags\" | \"entries\" | \"comments\" | \"namespace_type\" | \"os_types\"> & { comments: ({ comment: string; } & { id?: string | undefined; })[]; tags: string[]; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; }" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/request/update_exception_list_item_schema/index.ts", "deprecated": false, @@ -5677,7 +5677,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", "Type", "; name: ", "StringC", @@ -5845,7 +5845,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", "StringC", "; type: ", "KeyofC", @@ -7252,7 +7252,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", "Type", "; name: ", "StringC", @@ -8521,7 +8521,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; list_id: ", "Type", "; name: ", "StringC", @@ -8808,7 +8808,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; item_id: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; item_id: ", "Type", "; list_id: ", "Type", @@ -9848,7 +9848,7 @@ ], "signature": [ "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>" + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>" ], "path": "packages/kbn-securitysolution-io-ts-list-types/src/common/non_empty_entries_array/index.ts", "deprecated": false, @@ -10858,7 +10858,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", "StringC", "; type: ", "KeyofC", @@ -10912,7 +10912,7 @@ "StringC", "; entries: ", "Type", - "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", + "<({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[], unknown>; name: ", "StringC", "; type: ", "KeyofC", diff --git a/api_docs/kbn_securitysolution_io_ts_list_types.mdx b/api_docs/kbn_securitysolution_io_ts_list_types.mdx index b4c274a317c2b..69ec65afd9277 100644 --- a/api_docs/kbn_securitysolution_io_ts_list_types.mdx +++ b/api_docs/kbn_securitysolution_io_ts_list_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-io-ts-list-types title: "@kbn/securitysolution-io-ts-list-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-io-ts-list-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-io-ts-list-types'] --- import kbnSecuritysolutionIoTsListTypesObj from './kbn_securitysolution_io_ts_list_types.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_io_ts_types.devdocs.json b/api_docs/kbn_securitysolution_io_ts_types.devdocs.json index 8a14e911325af..36efacff31bf4 100644 --- a/api_docs/kbn_securitysolution_io_ts_types.devdocs.json +++ b/api_docs/kbn_securitysolution_io_ts_types.devdocs.json @@ -850,7 +850,7 @@ "tags": [], "label": "DefaultUuid", "description": [ - "\nTypes the DefaultUuid as:\n - If null or undefined, then a default string uuid.v4() will be\n created otherwise it will be checked just against an empty string" + "\nTypes the DefaultUuid as:\n - If null or undefined, then a default string uuidv4() will be\n created otherwise it will be checked just against an empty string" ], "signature": [ "Type", diff --git a/api_docs/kbn_securitysolution_io_ts_types.mdx b/api_docs/kbn_securitysolution_io_ts_types.mdx index c0ce6c9eedf72..1b57af66bd2b4 100644 --- a/api_docs/kbn_securitysolution_io_ts_types.mdx +++ b/api_docs/kbn_securitysolution_io_ts_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-io-ts-types title: "@kbn/securitysolution-io-ts-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-io-ts-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-io-ts-types'] --- import kbnSecuritysolutionIoTsTypesObj from './kbn_securitysolution_io_ts_types.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_io_ts_utils.mdx b/api_docs/kbn_securitysolution_io_ts_utils.mdx index d6a7be6272d81..e6262fd1f7da2 100644 --- a/api_docs/kbn_securitysolution_io_ts_utils.mdx +++ b/api_docs/kbn_securitysolution_io_ts_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-io-ts-utils title: "@kbn/securitysolution-io-ts-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-io-ts-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-io-ts-utils'] --- import kbnSecuritysolutionIoTsUtilsObj from './kbn_securitysolution_io_ts_utils.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_list_api.devdocs.json b/api_docs/kbn_securitysolution_list_api.devdocs.json index cd8334e742dda..44699631fbffc 100644 --- a/api_docs/kbn_securitysolution_list_api.devdocs.json +++ b/api_docs/kbn_securitysolution_list_api.devdocs.json @@ -82,7 +82,7 @@ "section": "def-common.AddExceptionListItemProps", "text": "AddExceptionListItemProps" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-api/src/api/index.ts", "deprecated": false, @@ -270,7 +270,7 @@ "section": "def-common.ApiCallByIdProps", "text": "ApiCallByIdProps" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-api/src/api/index.ts", "deprecated": false, @@ -317,7 +317,7 @@ "section": "def-common.DeleteListParams", "text": "DeleteListParams" }, - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "packages/kbn-securitysolution-list-api/src/list_api/index.ts", "deprecated": false, @@ -509,7 +509,7 @@ "section": "def-common.ApiCallByIdProps", "text": "ApiCallByIdProps" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-api/src/api/index.ts", "deprecated": false, @@ -556,7 +556,7 @@ "section": "def-common.ApiCallByListIdProps", "text": "ApiCallByListIdProps" }, - ") => Promise<{ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }>" + ") => Promise<{ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }>" ], "path": "packages/kbn-securitysolution-list-api/src/api/index.ts", "deprecated": false, @@ -650,7 +650,7 @@ "section": "def-common.FindListsParams", "text": "FindListsParams" }, - ") => Promise<{ largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }>" + ") => Promise<{ largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }>" ], "path": "packages/kbn-securitysolution-list-api/src/list_api/index.ts", "deprecated": false, @@ -697,7 +697,7 @@ "section": "def-common.FindListsParams", "text": "FindListsParams" }, - ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" + ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" ], "path": "packages/kbn-securitysolution-list-api/src/list_api/index.ts", "deprecated": false, @@ -862,7 +862,7 @@ "section": "def-common.ImportListParams", "text": "ImportListParams" }, - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "packages/kbn-securitysolution-list-api/src/list_api/index.ts", "deprecated": false, @@ -1072,7 +1072,7 @@ "section": "def-common.UpdateExceptionListItemProps", "text": "UpdateExceptionListItemProps" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-api/src/api/index.ts", "deprecated": false, @@ -1471,7 +1471,7 @@ "label": "type", "description": [], "signature": [ - "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined" + "\"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\" | undefined" ], "path": "packages/kbn-securitysolution-list-api/src/list_api/types.ts", "deprecated": false, diff --git a/api_docs/kbn_securitysolution_list_api.mdx b/api_docs/kbn_securitysolution_list_api.mdx index 83f80419db12d..b605738ffcc4e 100644 --- a/api_docs/kbn_securitysolution_list_api.mdx +++ b/api_docs/kbn_securitysolution_list_api.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-list-api title: "@kbn/securitysolution-list-api" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-list-api plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-list-api'] --- import kbnSecuritysolutionListApiObj from './kbn_securitysolution_list_api.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_list_constants.mdx b/api_docs/kbn_securitysolution_list_constants.mdx index e71dcaa48e28f..371ac74d47282 100644 --- a/api_docs/kbn_securitysolution_list_constants.mdx +++ b/api_docs/kbn_securitysolution_list_constants.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-list-constants title: "@kbn/securitysolution-list-constants" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-list-constants plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-list-constants'] --- import kbnSecuritysolutionListConstantsObj from './kbn_securitysolution_list_constants.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_list_hooks.devdocs.json b/api_docs/kbn_securitysolution_list_hooks.devdocs.json index befcfaaecfb13..a9290e1b6ed6b 100644 --- a/api_docs/kbn_securitysolution_list_hooks.devdocs.json +++ b/api_docs/kbn_securitysolution_list_hooks.devdocs.json @@ -29,7 +29,7 @@ "\nThis adds an id to the incoming exception item entries as ReactJS prefers to have\nan id added to them for use as a stable id. Later if we decide to change the data\nmodel to have id's within the array then this code should be removed. If not, then\nthis code should stay as an adapter for ReactJS.\n\nThis does break the type system slightly as we are lying a bit to the type system as we return\nthe same exceptionItem as we have previously but are augmenting the arrays with an id which TypeScript\ndoesn't mind us doing here. However, downstream you will notice that you have an id when the type\ndoes not indicate it. In that case use (ExceptionItem & { id: string }) temporarily if you're using the id. If you're not,\nyou can ignore the id and just use the normal TypeScript with ReactJS.\n" ], "signature": [ - "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -45,7 +45,7 @@ "The exceptionItem to add an id to the threat matches." ], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -68,7 +68,7 @@ "\nThis removes createdAt, createdBy from the exceptionItem if a comment was added to\nthe Exception item, and return the comment message with id to prevent creating the commet\ntwice" ], "signature": [ - "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })) => { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })) => { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -84,7 +84,7 @@ "The exceptionItem to remove createdAt, createdBy from the comments array." ], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -107,7 +107,7 @@ "\nThis removes an id from the exceptionItem entries as ReactJS prefers to have\nan id added to them for use as a stable id. Later if we decide to change the data\nmodel to have id's within the array then this code should be removed. If not, then\nthis code should stay as an adapter for ReactJS.\n" ], "signature": [ - "(exceptionItem: T) => T" + "(exceptionItem: T) => T" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -146,7 +146,7 @@ "\nTransforms the output of rules to compensate for technical debt or UI concerns such as\nReactJS preferences for having ids within arrays if the data is not modeled that way.\n\nIf you add a new transform of the input called \"myNewTransform\" do it\nin the form of:\nflow(addIdToExceptionItemEntries, myNewTransform)(exceptionItem)\n" ], "signature": [ - "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -162,7 +162,7 @@ "The exceptionItem to transform the output of" ], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -183,7 +183,7 @@ "label": "transformNewItemOutput", "description": [], "signature": [ - "(exceptionItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "(exceptionItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) => { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -197,7 +197,7 @@ "label": "exceptionItem", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -218,7 +218,7 @@ "\nTransforms the output of exception items to compensate for technical debt or UI concerns such as\nReactJS preferences for having ids within arrays if the data is not modeled that way.\n\nIf you add a new transform of the output called \"myNewTransform\" do it\nin the form of:\nflow(removeIdFromExceptionItemsEntries, myNewTransform)(exceptionItem)\n" ], "signature": [ - "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" + "(exceptionItem: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })) => { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -234,7 +234,7 @@ "The exceptionItem to transform the output of" ], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" ], "path": "packages/kbn-securitysolution-list-hooks/src/transforms/index.ts", "deprecated": false, @@ -407,7 +407,7 @@ "section": "def-common.DeleteListParams", "text": "DeleteListParams" }, - ">], { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ">], { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_delete_list/index.ts", "deprecated": false, @@ -545,7 +545,7 @@ "section": "def-common.FindListsParams", "text": "FindListsParams" }, - ">], { cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" + ">], { cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_find_lists/index.ts", "deprecated": false, @@ -586,7 +586,7 @@ "section": "def-common.FindListsParams", "text": "FindListsParams" }, - ">], { largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }>" + ">], { largeLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; smallLists: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_find_lists_by_size/index.ts", "deprecated": false, @@ -627,7 +627,7 @@ "section": "def-common.ImportListParams", "text": "ImportListParams" }, - ">], { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ">], { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_import_list/index.ts", "deprecated": false, @@ -851,7 +851,7 @@ "label": "addExceptionListItem", "description": [], "signature": [ - "(arg: { listItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }; }) => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + "(arg: { listItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }; }) => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -876,7 +876,7 @@ "label": "listItem", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -895,7 +895,7 @@ "label": "updateExceptionListItem", "description": [], "signature": [ - "(arg: { listItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }; }) => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + "(arg: { listItem: { description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }; }) => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -920,7 +920,7 @@ "label": "listItem", "description": [], "signature": [ - "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" + "{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -1039,7 +1039,7 @@ "section": "def-common.ApiCallMemoProps", "text": "ApiCallMemoProps" }, - " & { onSuccess: (arg: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void; }) => Promise" + " & { onSuccess: (arg: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void; }) => Promise" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -1060,7 +1060,7 @@ "section": "def-common.ApiCallMemoProps", "text": "ApiCallMemoProps" }, - " & { onSuccess: (arg: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void; }" + " & { onSuccess: (arg: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }) => void; }" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_api/index.ts", "deprecated": false, @@ -1423,7 +1423,7 @@ "label": "ReturnPersistExceptionItem", "description": [], "signature": [ - "[PersistReturnExceptionItem, React.Dispatch<({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | null>]" + "[PersistReturnExceptionItem, React.Dispatch<({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { _version?: string | undefined; comments?: ({ comment: string; } & { id?: string | undefined; })[] | undefined; id?: string | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | null>]" ], "path": "packages/kbn-securitysolution-list-hooks/src/use_persist_exception_item/index.ts", "deprecated": false, diff --git a/api_docs/kbn_securitysolution_list_hooks.mdx b/api_docs/kbn_securitysolution_list_hooks.mdx index 504aaf822c381..32147fbf4a55c 100644 --- a/api_docs/kbn_securitysolution_list_hooks.mdx +++ b/api_docs/kbn_securitysolution_list_hooks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-list-hooks title: "@kbn/securitysolution-list-hooks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-list-hooks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-list-hooks'] --- import kbnSecuritysolutionListHooksObj from './kbn_securitysolution_list_hooks.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_list_utils.devdocs.json b/api_docs/kbn_securitysolution_list_utils.devdocs.json index e874763d9e630..4fe323489c217 100644 --- a/api_docs/kbn_securitysolution_list_utils.devdocs.json +++ b/api_docs/kbn_securitysolution_list_utils.devdocs.json @@ -27,7 +27,7 @@ "label": "addIdToEntries", "description": [], "signature": [ - "(entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]) => ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "(entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]) => ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-list-utils/src/helpers/index.ts", "deprecated": false, @@ -41,7 +41,7 @@ "label": "entries", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-list-utils/src/helpers/index.ts", "deprecated": false, @@ -314,7 +314,7 @@ "section": "def-common.FormattedBuilderEntry", "text": "FormattedBuilderEntry" }, - ") => ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }) & { id?: string | undefined; }" + ") => ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }) & { id?: string | undefined; }" ], "path": "packages/kbn-securitysolution-list-utils/src/helpers/index.ts", "deprecated": false, @@ -474,7 +474,7 @@ "section": "def-common.FormattedBuilderEntry", "text": "FormattedBuilderEntry" }, - ", newField: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }) => { index: number; updatedEntry: ", + ", newField: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }) => { index: number; updatedEntry: ", { "pluginId": "@kbn/securitysolution-list-utils", "scope": "common", @@ -521,7 +521,7 @@ "- newly selected list" ], "signature": [ - "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }" + "{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }" ], "path": "packages/kbn-securitysolution-list-utils/src/helpers/index.ts", "deprecated": false, @@ -2108,7 +2108,7 @@ "label": "hasLargeValueList", "description": [], "signature": [ - "(entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]) => boolean" + "(entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]) => boolean" ], "path": "packages/kbn-securitysolution-list-utils/src/has_large_value_list/index.ts", "deprecated": false, @@ -2122,7 +2122,7 @@ "label": "entries", "description": [], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "packages/kbn-securitysolution-list-utils/src/has_large_value_list/index.ts", "deprecated": false, @@ -2779,7 +2779,7 @@ "label": "BuilderEntry", "description": [], "signature": [ - "(({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }) & { id?: string | undefined; }) | ", + "(({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; }) & { id?: string | undefined; }) | ", { "pluginId": "@kbn/securitysolution-list-utils", "scope": "common", @@ -2840,7 +2840,7 @@ "label": "CreateExceptionListItemBuilderSchema", "description": [], "signature": [ - "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }, \"entries\" | \"meta\" | \"list_id\" | \"namespace_type\"> & { meta: { temporaryUuid: string; }; entries: ", + "Omit<{ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }, \"entries\" | \"meta\" | \"list_id\" | \"namespace_type\"> & { meta: { temporaryUuid: string; }; entries: ", { "pluginId": "@kbn/securitysolution-list-utils", "scope": "common", @@ -2966,7 +2966,7 @@ "label": "ExceptionListItemBuilderSchema", "description": [], "signature": [ - "Omit<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }, \"entries\"> & { entries: ", + "Omit<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }, \"entries\"> & { entries: ", { "pluginId": "@kbn/securitysolution-list-utils", "scope": "common", @@ -3033,7 +3033,7 @@ "label": "ExceptionsBuilderReturnExceptionItem", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; list_id?: undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; list_id: string; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; }) | ({ description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; name: string; type: \"simple\"; } & { comments?: { comment: string; }[] | undefined; item_id?: string | undefined; list_id?: undefined; meta?: object | undefined; namespace_type?: \"single\" | \"agnostic\" | undefined; os_types?: (\"windows\" | \"linux\" | \"macos\")[] | undefined; tags?: string[] | undefined; })" ], "path": "packages/kbn-securitysolution-list-utils/src/types/index.ts", "deprecated": false, diff --git a/api_docs/kbn_securitysolution_list_utils.mdx b/api_docs/kbn_securitysolution_list_utils.mdx index d7fdfddfd55e3..f2af83a6ab71a 100644 --- a/api_docs/kbn_securitysolution_list_utils.mdx +++ b/api_docs/kbn_securitysolution_list_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-list-utils title: "@kbn/securitysolution-list-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-list-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-list-utils'] --- import kbnSecuritysolutionListUtilsObj from './kbn_securitysolution_list_utils.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_rules.mdx b/api_docs/kbn_securitysolution_rules.mdx index 1a323a4fc946b..b50cf28def8b0 100644 --- a/api_docs/kbn_securitysolution_rules.mdx +++ b/api_docs/kbn_securitysolution_rules.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-rules title: "@kbn/securitysolution-rules" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-rules plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-rules'] --- import kbnSecuritysolutionRulesObj from './kbn_securitysolution_rules.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_t_grid.mdx b/api_docs/kbn_securitysolution_t_grid.mdx index a3bde43cc2357..f78cca87ae209 100644 --- a/api_docs/kbn_securitysolution_t_grid.mdx +++ b/api_docs/kbn_securitysolution_t_grid.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-t-grid title: "@kbn/securitysolution-t-grid" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-t-grid plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-t-grid'] --- import kbnSecuritysolutionTGridObj from './kbn_securitysolution_t_grid.devdocs.json'; diff --git a/api_docs/kbn_securitysolution_utils.mdx b/api_docs/kbn_securitysolution_utils.mdx index 52a0bec2e889a..ab4c98e6d53c2 100644 --- a/api_docs/kbn_securitysolution_utils.mdx +++ b/api_docs/kbn_securitysolution_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-securitysolution-utils title: "@kbn/securitysolution-utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/securitysolution-utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/securitysolution-utils'] --- import kbnSecuritysolutionUtilsObj from './kbn_securitysolution_utils.devdocs.json'; diff --git a/api_docs/kbn_server_http_tools.mdx b/api_docs/kbn_server_http_tools.mdx index f92973a7e3112..70f2390cc5d4c 100644 --- a/api_docs/kbn_server_http_tools.mdx +++ b/api_docs/kbn_server_http_tools.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-server-http-tools title: "@kbn/server-http-tools" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/server-http-tools plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/server-http-tools'] --- import kbnServerHttpToolsObj from './kbn_server_http_tools.devdocs.json'; diff --git a/api_docs/kbn_server_route_repository.mdx b/api_docs/kbn_server_route_repository.mdx index 99a7870efbd1e..c72fd19fc9b91 100644 --- a/api_docs/kbn_server_route_repository.mdx +++ b/api_docs/kbn_server_route_repository.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-server-route-repository title: "@kbn/server-route-repository" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/server-route-repository plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/server-route-repository'] --- import kbnServerRouteRepositoryObj from './kbn_server_route_repository.devdocs.json'; diff --git a/api_docs/kbn_shared_svg.mdx b/api_docs/kbn_shared_svg.mdx index c31ad5facdcd6..271e40a1c7c08 100644 --- a/api_docs/kbn_shared_svg.mdx +++ b/api_docs/kbn_shared_svg.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-svg title: "@kbn/shared-svg" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-svg plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-svg'] --- import kbnSharedSvgObj from './kbn_shared_svg.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_avatar_solution.mdx b/api_docs/kbn_shared_ux_avatar_solution.mdx index 0cc2cf33ea16e..0bb24cdb1f261 100644 --- a/api_docs/kbn_shared_ux_avatar_solution.mdx +++ b/api_docs/kbn_shared_ux_avatar_solution.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-avatar-solution title: "@kbn/shared-ux-avatar-solution" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-avatar-solution plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-avatar-solution'] --- import kbnSharedUxAvatarSolutionObj from './kbn_shared_ux_avatar_solution.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_avatar_user_profile_components.mdx b/api_docs/kbn_shared_ux_avatar_user_profile_components.mdx index 81d4b27323172..baac2ac3b249f 100644 --- a/api_docs/kbn_shared_ux_avatar_user_profile_components.mdx +++ b/api_docs/kbn_shared_ux_avatar_user_profile_components.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-avatar-user-profile-components title: "@kbn/shared-ux-avatar-user-profile-components" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-avatar-user-profile-components plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-avatar-user-profile-components'] --- import kbnSharedUxAvatarUserProfileComponentsObj from './kbn_shared_ux_avatar_user_profile_components.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_button_exit_full_screen.mdx b/api_docs/kbn_shared_ux_button_exit_full_screen.mdx index d27e59abd681d..f1575d2ec0d7c 100644 --- a/api_docs/kbn_shared_ux_button_exit_full_screen.mdx +++ b/api_docs/kbn_shared_ux_button_exit_full_screen.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-button-exit-full-screen title: "@kbn/shared-ux-button-exit-full-screen" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-button-exit-full-screen plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-button-exit-full-screen'] --- import kbnSharedUxButtonExitFullScreenObj from './kbn_shared_ux_button_exit_full_screen.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_button_exit_full_screen_mocks.mdx b/api_docs/kbn_shared_ux_button_exit_full_screen_mocks.mdx index 4979d187db7aa..ab031950e37c5 100644 --- a/api_docs/kbn_shared_ux_button_exit_full_screen_mocks.mdx +++ b/api_docs/kbn_shared_ux_button_exit_full_screen_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-button-exit-full-screen-mocks title: "@kbn/shared-ux-button-exit-full-screen-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-button-exit-full-screen-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-button-exit-full-screen-mocks'] --- import kbnSharedUxButtonExitFullScreenMocksObj from './kbn_shared_ux_button_exit_full_screen_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_button_toolbar.mdx b/api_docs/kbn_shared_ux_button_toolbar.mdx index 4c3c00ba0080c..56a4ef437baa0 100644 --- a/api_docs/kbn_shared_ux_button_toolbar.mdx +++ b/api_docs/kbn_shared_ux_button_toolbar.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-button-toolbar title: "@kbn/shared-ux-button-toolbar" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-button-toolbar plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-button-toolbar'] --- import kbnSharedUxButtonToolbarObj from './kbn_shared_ux_button_toolbar.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_card_no_data.devdocs.json b/api_docs/kbn_shared_ux_card_no_data.devdocs.json index 3f9b08b643f7a..df30d7bd4fca6 100644 --- a/api_docs/kbn_shared_ux_card_no_data.devdocs.json +++ b/api_docs/kbn_shared_ux_card_no_data.devdocs.json @@ -186,7 +186,7 @@ "signature": [ "{ children?: React.ReactNode; description?: React.ReactNode; category?: string | undefined; onError?: React.ReactEventHandler | undefined; hidden?: boolean | undefined; icon?: React.ReactElement<", "EuiIconProps", - ", string | React.JSXElementConstructor> | null | undefined; id?: string | undefined; image?: string | React.ReactElement> | undefined; className?: string | undefined; title?: boolean | React.ReactChild | React.ReactFragment | React.ReactPortal | undefined; onChange?: React.FormEventHandler | undefined; onKeyDown?: React.KeyboardEventHandler | undefined; onClick?: React.MouseEventHandler | undefined; security?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"url\" | \"tel\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", + ", string | React.JSXElementConstructor> | null | undefined; id?: string | undefined; image?: string | React.ReactElement> | undefined; className?: string | undefined; title?: boolean | React.ReactChild | React.ReactFragment | React.ReactPortal | undefined; onChange?: React.FormEventHandler | undefined; onKeyDown?: React.KeyboardEventHandler | undefined; onClick?: React.MouseEventHandler | undefined; security?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"tel\" | \"url\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", "Interpolation", "<", "Theme", diff --git a/api_docs/kbn_shared_ux_card_no_data.mdx b/api_docs/kbn_shared_ux_card_no_data.mdx index f8bc508555762..c9b627ea2778a 100644 --- a/api_docs/kbn_shared_ux_card_no_data.mdx +++ b/api_docs/kbn_shared_ux_card_no_data.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-card-no-data title: "@kbn/shared-ux-card-no-data" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-card-no-data plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-card-no-data'] --- import kbnSharedUxCardNoDataObj from './kbn_shared_ux_card_no_data.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_card_no_data_mocks.mdx b/api_docs/kbn_shared_ux_card_no_data_mocks.mdx index d10aed549cf85..9ea7d653fc311 100644 --- a/api_docs/kbn_shared_ux_card_no_data_mocks.mdx +++ b/api_docs/kbn_shared_ux_card_no_data_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-card-no-data-mocks title: "@kbn/shared-ux-card-no-data-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-card-no-data-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-card-no-data-mocks'] --- import kbnSharedUxCardNoDataMocksObj from './kbn_shared_ux_card_no_data_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_context.mdx b/api_docs/kbn_shared_ux_file_context.mdx index a6853aecb6b50..c601160e9c0e3 100644 --- a/api_docs/kbn_shared_ux_file_context.mdx +++ b/api_docs/kbn_shared_ux_file_context.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-context title: "@kbn/shared-ux-file-context" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-context plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-context'] --- import kbnSharedUxFileContextObj from './kbn_shared_ux_file_context.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_image.mdx b/api_docs/kbn_shared_ux_file_image.mdx index 95d5d7e3e211e..4091baad1d0a6 100644 --- a/api_docs/kbn_shared_ux_file_image.mdx +++ b/api_docs/kbn_shared_ux_file_image.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-image title: "@kbn/shared-ux-file-image" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-image plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-image'] --- import kbnSharedUxFileImageObj from './kbn_shared_ux_file_image.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_image_mocks.mdx b/api_docs/kbn_shared_ux_file_image_mocks.mdx index 36a4c751df96b..c46ec896a61af 100644 --- a/api_docs/kbn_shared_ux_file_image_mocks.mdx +++ b/api_docs/kbn_shared_ux_file_image_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-image-mocks title: "@kbn/shared-ux-file-image-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-image-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-image-mocks'] --- import kbnSharedUxFileImageMocksObj from './kbn_shared_ux_file_image_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_mocks.mdx b/api_docs/kbn_shared_ux_file_mocks.mdx index 9ea068bfbfe5a..3dcd98229eef4 100644 --- a/api_docs/kbn_shared_ux_file_mocks.mdx +++ b/api_docs/kbn_shared_ux_file_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-mocks title: "@kbn/shared-ux-file-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-mocks'] --- import kbnSharedUxFileMocksObj from './kbn_shared_ux_file_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_picker.mdx b/api_docs/kbn_shared_ux_file_picker.mdx index 8b117a4ddf395..6d7ad8f51789c 100644 --- a/api_docs/kbn_shared_ux_file_picker.mdx +++ b/api_docs/kbn_shared_ux_file_picker.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-picker title: "@kbn/shared-ux-file-picker" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-picker plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-picker'] --- import kbnSharedUxFilePickerObj from './kbn_shared_ux_file_picker.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_upload.mdx b/api_docs/kbn_shared_ux_file_upload.mdx index 07a81f3b0229c..9bd718ec11706 100644 --- a/api_docs/kbn_shared_ux_file_upload.mdx +++ b/api_docs/kbn_shared_ux_file_upload.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-upload title: "@kbn/shared-ux-file-upload" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-upload plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-upload'] --- import kbnSharedUxFileUploadObj from './kbn_shared_ux_file_upload.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_file_util.mdx b/api_docs/kbn_shared_ux_file_util.mdx index 00c3c595176a0..fb858c3a998d2 100644 --- a/api_docs/kbn_shared_ux_file_util.mdx +++ b/api_docs/kbn_shared_ux_file_util.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-file-util title: "@kbn/shared-ux-file-util" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-file-util plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-file-util'] --- import kbnSharedUxFileUtilObj from './kbn_shared_ux_file_util.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_link_redirect_app.mdx b/api_docs/kbn_shared_ux_link_redirect_app.mdx index f35cde586224f..90f08d26ce0b6 100644 --- a/api_docs/kbn_shared_ux_link_redirect_app.mdx +++ b/api_docs/kbn_shared_ux_link_redirect_app.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-link-redirect-app title: "@kbn/shared-ux-link-redirect-app" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-link-redirect-app plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-link-redirect-app'] --- import kbnSharedUxLinkRedirectAppObj from './kbn_shared_ux_link_redirect_app.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_link_redirect_app_mocks.mdx b/api_docs/kbn_shared_ux_link_redirect_app_mocks.mdx index c72d360d77c7e..b6b5778243097 100644 --- a/api_docs/kbn_shared_ux_link_redirect_app_mocks.mdx +++ b/api_docs/kbn_shared_ux_link_redirect_app_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-link-redirect-app-mocks title: "@kbn/shared-ux-link-redirect-app-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-link-redirect-app-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-link-redirect-app-mocks'] --- import kbnSharedUxLinkRedirectAppMocksObj from './kbn_shared_ux_link_redirect_app_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_markdown.mdx b/api_docs/kbn_shared_ux_markdown.mdx index 63e8718fd8ae4..21523bac6f413 100644 --- a/api_docs/kbn_shared_ux_markdown.mdx +++ b/api_docs/kbn_shared_ux_markdown.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-markdown title: "@kbn/shared-ux-markdown" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-markdown plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-markdown'] --- import kbnSharedUxMarkdownObj from './kbn_shared_ux_markdown.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_markdown_mocks.devdocs.json b/api_docs/kbn_shared_ux_markdown_mocks.devdocs.json index addc3f7f83a31..0f5ffb13f1421 100644 --- a/api_docs/kbn_shared_ux_markdown_mocks.devdocs.json +++ b/api_docs/kbn_shared_ux_markdown_mocks.devdocs.json @@ -433,7 +433,7 @@ "label": "getServices", "description": [], "signature": [ - "() => { children?: React.ReactNode; value?: string | undefined; onError?: React.ReactEventHandler | undefined; hidden?: boolean | undefined; color?: string | undefined; id?: string | undefined; className?: string | undefined; title?: string | undefined; onChange?: ((value: string) => void) | undefined; onKeyDown?: React.KeyboardEventHandler | undefined; onClick?: React.MouseEventHandler | undefined; security?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"url\" | \"tel\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", + "() => { children?: React.ReactNode; value?: string | undefined; onError?: React.ReactEventHandler | undefined; hidden?: boolean | undefined; color?: string | undefined; id?: string | undefined; className?: string | undefined; title?: string | undefined; onChange?: ((value: string) => void) | undefined; onKeyDown?: React.KeyboardEventHandler | undefined; onClick?: React.MouseEventHandler | undefined; security?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"tel\" | \"url\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", "Interpolation", "<", "Theme", diff --git a/api_docs/kbn_shared_ux_markdown_mocks.mdx b/api_docs/kbn_shared_ux_markdown_mocks.mdx index ab5fad6a46ee5..1f326700d14a3 100644 --- a/api_docs/kbn_shared_ux_markdown_mocks.mdx +++ b/api_docs/kbn_shared_ux_markdown_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-markdown-mocks title: "@kbn/shared-ux-markdown-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-markdown-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-markdown-mocks'] --- import kbnSharedUxMarkdownMocksObj from './kbn_shared_ux_markdown_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_analytics_no_data.mdx b/api_docs/kbn_shared_ux_page_analytics_no_data.mdx index 857889a9b5f64..88be05c18afa6 100644 --- a/api_docs/kbn_shared_ux_page_analytics_no_data.mdx +++ b/api_docs/kbn_shared_ux_page_analytics_no_data.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-analytics-no-data title: "@kbn/shared-ux-page-analytics-no-data" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-analytics-no-data plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-analytics-no-data'] --- import kbnSharedUxPageAnalyticsNoDataObj from './kbn_shared_ux_page_analytics_no_data.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_analytics_no_data_mocks.mdx b/api_docs/kbn_shared_ux_page_analytics_no_data_mocks.mdx index 459c55296eaf9..74152788e10e7 100644 --- a/api_docs/kbn_shared_ux_page_analytics_no_data_mocks.mdx +++ b/api_docs/kbn_shared_ux_page_analytics_no_data_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-analytics-no-data-mocks title: "@kbn/shared-ux-page-analytics-no-data-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-analytics-no-data-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-analytics-no-data-mocks'] --- import kbnSharedUxPageAnalyticsNoDataMocksObj from './kbn_shared_ux_page_analytics_no_data_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_kibana_no_data.mdx b/api_docs/kbn_shared_ux_page_kibana_no_data.mdx index d0f4517a77aa5..594ac5aa94e00 100644 --- a/api_docs/kbn_shared_ux_page_kibana_no_data.mdx +++ b/api_docs/kbn_shared_ux_page_kibana_no_data.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-kibana-no-data title: "@kbn/shared-ux-page-kibana-no-data" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-kibana-no-data plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-kibana-no-data'] --- import kbnSharedUxPageKibanaNoDataObj from './kbn_shared_ux_page_kibana_no_data.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_kibana_no_data_mocks.mdx b/api_docs/kbn_shared_ux_page_kibana_no_data_mocks.mdx index b0f0c766c9f41..d0bc1d4e016ed 100644 --- a/api_docs/kbn_shared_ux_page_kibana_no_data_mocks.mdx +++ b/api_docs/kbn_shared_ux_page_kibana_no_data_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-kibana-no-data-mocks title: "@kbn/shared-ux-page-kibana-no-data-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-kibana-no-data-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-kibana-no-data-mocks'] --- import kbnSharedUxPageKibanaNoDataMocksObj from './kbn_shared_ux_page_kibana_no_data_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_kibana_template.mdx b/api_docs/kbn_shared_ux_page_kibana_template.mdx index 04abc17211078..ce6ff349ee370 100644 --- a/api_docs/kbn_shared_ux_page_kibana_template.mdx +++ b/api_docs/kbn_shared_ux_page_kibana_template.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-kibana-template title: "@kbn/shared-ux-page-kibana-template" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-kibana-template plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-kibana-template'] --- import kbnSharedUxPageKibanaTemplateObj from './kbn_shared_ux_page_kibana_template.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_kibana_template_mocks.mdx b/api_docs/kbn_shared_ux_page_kibana_template_mocks.mdx index b1c9d1040a340..48b2e927b75f0 100644 --- a/api_docs/kbn_shared_ux_page_kibana_template_mocks.mdx +++ b/api_docs/kbn_shared_ux_page_kibana_template_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-kibana-template-mocks title: "@kbn/shared-ux-page-kibana-template-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-kibana-template-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-kibana-template-mocks'] --- import kbnSharedUxPageKibanaTemplateMocksObj from './kbn_shared_ux_page_kibana_template_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_no_data.mdx b/api_docs/kbn_shared_ux_page_no_data.mdx index 23040234719fc..f8bd74793a86f 100644 --- a/api_docs/kbn_shared_ux_page_no_data.mdx +++ b/api_docs/kbn_shared_ux_page_no_data.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-no-data title: "@kbn/shared-ux-page-no-data" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-no-data plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-no-data'] --- import kbnSharedUxPageNoDataObj from './kbn_shared_ux_page_no_data.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_no_data_config.mdx b/api_docs/kbn_shared_ux_page_no_data_config.mdx index 875878ce3e4d4..3032aa1c15822 100644 --- a/api_docs/kbn_shared_ux_page_no_data_config.mdx +++ b/api_docs/kbn_shared_ux_page_no_data_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-no-data-config title: "@kbn/shared-ux-page-no-data-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-no-data-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-no-data-config'] --- import kbnSharedUxPageNoDataConfigObj from './kbn_shared_ux_page_no_data_config.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_no_data_config_mocks.mdx b/api_docs/kbn_shared_ux_page_no_data_config_mocks.mdx index 7c58fc99b257c..e8d023533e891 100644 --- a/api_docs/kbn_shared_ux_page_no_data_config_mocks.mdx +++ b/api_docs/kbn_shared_ux_page_no_data_config_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-no-data-config-mocks title: "@kbn/shared-ux-page-no-data-config-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-no-data-config-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-no-data-config-mocks'] --- import kbnSharedUxPageNoDataConfigMocksObj from './kbn_shared_ux_page_no_data_config_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_no_data_mocks.mdx b/api_docs/kbn_shared_ux_page_no_data_mocks.mdx index 2fd36f09dce7e..729c1581c4277 100644 --- a/api_docs/kbn_shared_ux_page_no_data_mocks.mdx +++ b/api_docs/kbn_shared_ux_page_no_data_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-no-data-mocks title: "@kbn/shared-ux-page-no-data-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-no-data-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-no-data-mocks'] --- import kbnSharedUxPageNoDataMocksObj from './kbn_shared_ux_page_no_data_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_page_solution_nav.mdx b/api_docs/kbn_shared_ux_page_solution_nav.mdx index ff5a74c44862b..0bd68b9280d32 100644 --- a/api_docs/kbn_shared_ux_page_solution_nav.mdx +++ b/api_docs/kbn_shared_ux_page_solution_nav.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-page-solution-nav title: "@kbn/shared-ux-page-solution-nav" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-page-solution-nav plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-page-solution-nav'] --- import kbnSharedUxPageSolutionNavObj from './kbn_shared_ux_page_solution_nav.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_prompt_no_data_views.mdx b/api_docs/kbn_shared_ux_prompt_no_data_views.mdx index f9d1c59554fef..36c550d5909b0 100644 --- a/api_docs/kbn_shared_ux_prompt_no_data_views.mdx +++ b/api_docs/kbn_shared_ux_prompt_no_data_views.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-prompt-no-data-views title: "@kbn/shared-ux-prompt-no-data-views" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-prompt-no-data-views plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-prompt-no-data-views'] --- import kbnSharedUxPromptNoDataViewsObj from './kbn_shared_ux_prompt_no_data_views.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_prompt_no_data_views_mocks.mdx b/api_docs/kbn_shared_ux_prompt_no_data_views_mocks.mdx index ca74d483aba71..f44f46d1bf3e2 100644 --- a/api_docs/kbn_shared_ux_prompt_no_data_views_mocks.mdx +++ b/api_docs/kbn_shared_ux_prompt_no_data_views_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-prompt-no-data-views-mocks title: "@kbn/shared-ux-prompt-no-data-views-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-prompt-no-data-views-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-prompt-no-data-views-mocks'] --- import kbnSharedUxPromptNoDataViewsMocksObj from './kbn_shared_ux_prompt_no_data_views_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_prompt_not_found.mdx b/api_docs/kbn_shared_ux_prompt_not_found.mdx index 3cbac583be707..7b4b611ba7494 100644 --- a/api_docs/kbn_shared_ux_prompt_not_found.mdx +++ b/api_docs/kbn_shared_ux_prompt_not_found.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-prompt-not-found title: "@kbn/shared-ux-prompt-not-found" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-prompt-not-found plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-prompt-not-found'] --- import kbnSharedUxPromptNotFoundObj from './kbn_shared_ux_prompt_not_found.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_router.mdx b/api_docs/kbn_shared_ux_router.mdx index 6ed4111aad6de..f2f10aaa70902 100644 --- a/api_docs/kbn_shared_ux_router.mdx +++ b/api_docs/kbn_shared_ux_router.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-router title: "@kbn/shared-ux-router" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-router plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-router'] --- import kbnSharedUxRouterObj from './kbn_shared_ux_router.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_router_mocks.mdx b/api_docs/kbn_shared_ux_router_mocks.mdx index 73ee7c278039f..875eeebf03863 100644 --- a/api_docs/kbn_shared_ux_router_mocks.mdx +++ b/api_docs/kbn_shared_ux_router_mocks.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-router-mocks title: "@kbn/shared-ux-router-mocks" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-router-mocks plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-router-mocks'] --- import kbnSharedUxRouterMocksObj from './kbn_shared_ux_router_mocks.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_storybook_config.mdx b/api_docs/kbn_shared_ux_storybook_config.mdx index 66d3d901b7213..954c13d4b4c88 100644 --- a/api_docs/kbn_shared_ux_storybook_config.mdx +++ b/api_docs/kbn_shared_ux_storybook_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-storybook-config title: "@kbn/shared-ux-storybook-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-storybook-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-storybook-config'] --- import kbnSharedUxStorybookConfigObj from './kbn_shared_ux_storybook_config.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_storybook_mock.mdx b/api_docs/kbn_shared_ux_storybook_mock.mdx index bf9443c6b484e..ea21ea7c03bc9 100644 --- a/api_docs/kbn_shared_ux_storybook_mock.mdx +++ b/api_docs/kbn_shared_ux_storybook_mock.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-storybook-mock title: "@kbn/shared-ux-storybook-mock" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-storybook-mock plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-storybook-mock'] --- import kbnSharedUxStorybookMockObj from './kbn_shared_ux_storybook_mock.devdocs.json'; diff --git a/api_docs/kbn_shared_ux_utility.mdx b/api_docs/kbn_shared_ux_utility.mdx index 30ef884c27b21..6239fedcc9cbd 100644 --- a/api_docs/kbn_shared_ux_utility.mdx +++ b/api_docs/kbn_shared_ux_utility.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-shared-ux-utility title: "@kbn/shared-ux-utility" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/shared-ux-utility plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-utility'] --- import kbnSharedUxUtilityObj from './kbn_shared_ux_utility.devdocs.json'; diff --git a/api_docs/kbn_slo_schema.devdocs.json b/api_docs/kbn_slo_schema.devdocs.json index 9265aaaddf614..1b706b4d3d789 100644 --- a/api_docs/kbn_slo_schema.devdocs.json +++ b/api_docs/kbn_slo_schema.devdocs.json @@ -467,6 +467,36 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "@kbn/slo-schema", + "id": "def-common.FetchHistoricalSummaryParams", + "type": "Type", + "tags": [], + "label": "FetchHistoricalSummaryParams", + "description": [], + "signature": [ + "{ sloIds: string[]; }" + ], + "path": "packages/kbn-slo-schema/src/rest_specs/slo.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/slo-schema", + "id": "def-common.FetchHistoricalSummaryResponse", + "type": "Type", + "tags": [], + "label": "FetchHistoricalSummaryResponse", + "description": [], + "signature": [ + "{ [x: string]: { date: string; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; sliValue: number; status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; }[]; }" + ], + "path": "packages/kbn-slo-schema/src/rest_specs/slo.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "@kbn/slo-schema", "id": "def-common.FindSLOParams", @@ -1159,6 +1189,74 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "@kbn/slo-schema", + "id": "def-common.fetchHistoricalSummaryParamsSchema", + "type": "Object", + "tags": [], + "label": "fetchHistoricalSummaryParamsSchema", + "description": [], + "signature": [ + "TypeC", + "<{ body: ", + "TypeC", + "<{ sloIds: ", + "ArrayC", + "<", + "StringC", + ">; }>; }>" + ], + "path": "packages/kbn-slo-schema/src/rest_specs/slo.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/slo-schema", + "id": "def-common.fetchHistoricalSummaryResponseSchema", + "type": "Object", + "tags": [], + "label": "fetchHistoricalSummaryResponseSchema", + "description": [], + "signature": [ + "RecordC", + "<", + "StringC", + ", ", + "ArrayC", + "<", + "TypeC", + "<{ date: ", + "Type", + "; errorBudget: ", + "TypeC", + "<{ initial: ", + "NumberC", + "; consumed: ", + "NumberC", + "; remaining: ", + "NumberC", + "; isEstimated: ", + "BooleanC", + "; }>; sliValue: ", + "NumberC", + "; status: ", + "UnionC", + "<[", + "LiteralC", + "<\"NO_DATA\">, ", + "LiteralC", + "<\"HEALTHY\">, ", + "LiteralC", + "<\"DEGRADING\">, ", + "LiteralC", + "<\"VIOLATED\">]>; }>>>" + ], + "path": "packages/kbn-slo-schema/src/rest_specs/slo.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "@kbn/slo-schema", "id": "def-common.findSLOParamsSchema", @@ -1707,6 +1805,46 @@ "trackAdoption": false, "initialIsOpen": false }, + { + "parentPluginId": "@kbn/slo-schema", + "id": "def-common.historicalSummarySchema", + "type": "Object", + "tags": [], + "label": "historicalSummarySchema", + "description": [], + "signature": [ + "TypeC", + "<{ date: ", + "Type", + "; errorBudget: ", + "TypeC", + "<{ initial: ", + "NumberC", + "; consumed: ", + "NumberC", + "; remaining: ", + "NumberC", + "; isEstimated: ", + "BooleanC", + "; }>; sliValue: ", + "NumberC", + "; status: ", + "UnionC", + "<[", + "LiteralC", + "<\"NO_DATA\">, ", + "LiteralC", + "<\"HEALTHY\">, ", + "LiteralC", + "<\"DEGRADING\">, ", + "LiteralC", + "<\"VIOLATED\">]>; }>" + ], + "path": "packages/kbn-slo-schema/src/schema/indicators.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, { "parentPluginId": "@kbn/slo-schema", "id": "def-common.indicatorDataSchema", diff --git a/api_docs/kbn_slo_schema.mdx b/api_docs/kbn_slo_schema.mdx index 794f45af5522f..4826a46c18d1b 100644 --- a/api_docs/kbn_slo_schema.mdx +++ b/api_docs/kbn_slo_schema.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-slo-schema title: "@kbn/slo-schema" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/slo-schema plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/slo-schema'] --- import kbnSloSchemaObj from './kbn_slo_schema.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Owner missing] for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 67 | 0 | 67 | 0 | +| 72 | 0 | 72 | 0 | ## Common diff --git a/api_docs/kbn_some_dev_log.mdx b/api_docs/kbn_some_dev_log.mdx index 158ae23491ca3..b1ce48eac65ce 100644 --- a/api_docs/kbn_some_dev_log.mdx +++ b/api_docs/kbn_some_dev_log.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-some-dev-log title: "@kbn/some-dev-log" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/some-dev-log plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/some-dev-log'] --- import kbnSomeDevLogObj from './kbn_some_dev_log.devdocs.json'; diff --git a/api_docs/kbn_std.mdx b/api_docs/kbn_std.mdx index 39b8251386511..a88939913f538 100644 --- a/api_docs/kbn_std.mdx +++ b/api_docs/kbn_std.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-std title: "@kbn/std" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/std plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/std'] --- import kbnStdObj from './kbn_std.devdocs.json'; diff --git a/api_docs/kbn_stdio_dev_helpers.mdx b/api_docs/kbn_stdio_dev_helpers.mdx index 8b16e8ea37c0a..0e70e03dd440d 100644 --- a/api_docs/kbn_stdio_dev_helpers.mdx +++ b/api_docs/kbn_stdio_dev_helpers.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-stdio-dev-helpers title: "@kbn/stdio-dev-helpers" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/stdio-dev-helpers plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/stdio-dev-helpers'] --- import kbnStdioDevHelpersObj from './kbn_stdio_dev_helpers.devdocs.json'; diff --git a/api_docs/kbn_storybook.mdx b/api_docs/kbn_storybook.mdx index 67f0f89961e6e..3b468a59d4690 100644 --- a/api_docs/kbn_storybook.mdx +++ b/api_docs/kbn_storybook.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-storybook title: "@kbn/storybook" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/storybook plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/storybook'] --- import kbnStorybookObj from './kbn_storybook.devdocs.json'; diff --git a/api_docs/kbn_telemetry_tools.mdx b/api_docs/kbn_telemetry_tools.mdx index 3bec1c372797e..674fb0b25ffa8 100644 --- a/api_docs/kbn_telemetry_tools.mdx +++ b/api_docs/kbn_telemetry_tools.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-telemetry-tools title: "@kbn/telemetry-tools" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/telemetry-tools plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/telemetry-tools'] --- import kbnTelemetryToolsObj from './kbn_telemetry_tools.devdocs.json'; diff --git a/api_docs/kbn_test.mdx b/api_docs/kbn_test.mdx index b5910d0efa06d..8bc63b61812ae 100644 --- a/api_docs/kbn_test.mdx +++ b/api_docs/kbn_test.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-test title: "@kbn/test" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/test plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/test'] --- import kbnTestObj from './kbn_test.devdocs.json'; diff --git a/api_docs/kbn_test_jest_helpers.mdx b/api_docs/kbn_test_jest_helpers.mdx index d80d0423cafbe..db8abf09889d8 100644 --- a/api_docs/kbn_test_jest_helpers.mdx +++ b/api_docs/kbn_test_jest_helpers.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-test-jest-helpers title: "@kbn/test-jest-helpers" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/test-jest-helpers plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/test-jest-helpers'] --- import kbnTestJestHelpersObj from './kbn_test_jest_helpers.devdocs.json'; diff --git a/api_docs/kbn_test_subj_selector.mdx b/api_docs/kbn_test_subj_selector.mdx index 765f188ad85aa..cf8b64c5240a6 100644 --- a/api_docs/kbn_test_subj_selector.mdx +++ b/api_docs/kbn_test_subj_selector.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-test-subj-selector title: "@kbn/test-subj-selector" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/test-subj-selector plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/test-subj-selector'] --- import kbnTestSubjSelectorObj from './kbn_test_subj_selector.devdocs.json'; diff --git a/api_docs/kbn_tooling_log.mdx b/api_docs/kbn_tooling_log.mdx index b4437b59ae07e..82d2693bbba43 100644 --- a/api_docs/kbn_tooling_log.mdx +++ b/api_docs/kbn_tooling_log.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-tooling-log title: "@kbn/tooling-log" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/tooling-log plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/tooling-log'] --- import kbnToolingLogObj from './kbn_tooling_log.devdocs.json'; diff --git a/api_docs/kbn_ts_projects.mdx b/api_docs/kbn_ts_projects.mdx index 9cb03d97de316..1534dd1aeb107 100644 --- a/api_docs/kbn_ts_projects.mdx +++ b/api_docs/kbn_ts_projects.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ts-projects title: "@kbn/ts-projects" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ts-projects plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ts-projects'] --- import kbnTsProjectsObj from './kbn_ts_projects.devdocs.json'; diff --git a/api_docs/kbn_typed_react_router_config.mdx b/api_docs/kbn_typed_react_router_config.mdx index d620260268d87..3f48fac5959e2 100644 --- a/api_docs/kbn_typed_react_router_config.mdx +++ b/api_docs/kbn_typed_react_router_config.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-typed-react-router-config title: "@kbn/typed-react-router-config" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/typed-react-router-config plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/typed-react-router-config'] --- import kbnTypedReactRouterConfigObj from './kbn_typed_react_router_config.devdocs.json'; diff --git a/api_docs/kbn_ui_actions_browser.devdocs.json b/api_docs/kbn_ui_actions_browser.devdocs.json new file mode 100644 index 0000000000000..26107aced0326 --- /dev/null +++ b/api_docs/kbn_ui_actions_browser.devdocs.json @@ -0,0 +1,355 @@ +{ + "id": "@kbn/ui-actions-browser", + "client": { + "classes": [], + "functions": [], + "interfaces": [], + "enums": [], + "misc": [], + "objects": [] + }, + "server": { + "classes": [], + "functions": [], + "interfaces": [], + "enums": [], + "misc": [], + "objects": [] + }, + "common": { + "classes": [], + "functions": [], + "interfaces": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable", + "type": "Interface", + "tags": [], + "label": "Presentable", + "description": [ + "\nRepresents something that can be displayed to user in UI." + ], + "signature": [ + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.Presentable", + "text": "Presentable" + }, + "" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.id", + "type": "string", + "tags": [], + "label": "id", + "description": [ + "\nID that uniquely identifies this object." + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.order", + "type": "number", + "tags": [], + "label": "order", + "description": [ + "\nDetermines the display order in relation to other items. Higher numbers are\ndisplayed first." + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.MenuItem", + "type": "Function", + "tags": [], + "label": "MenuItem", + "description": [ + "\nComponent to render when displaying this entity as a context menu item.\nIf not provided, `getDisplayName` will be used instead." + ], + "signature": [ + "React.FC<{ context: Context; }> | undefined" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getIconType", + "type": "Function", + "tags": [], + "label": "getIconType", + "description": [ + "\nOptional EUI icon type that can be displayed along with the title." + ], + "signature": [ + "(context: Context) => string | undefined" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getIconType.$1", + "type": "Uncategorized", + "tags": [], + "label": "context", + "description": [], + "signature": [ + "Context" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getDisplayName", + "type": "Function", + "tags": [], + "label": "getDisplayName", + "description": [ + "\nReturns a title to be displayed to the user." + ], + "signature": [ + "(context: Context) => string" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getDisplayName.$1", + "type": "Uncategorized", + "tags": [], + "label": "context", + "description": [], + "signature": [ + "Context" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getDisplayNameTooltip", + "type": "Function", + "tags": [], + "label": "getDisplayNameTooltip", + "description": [ + "\nReturns tooltip text which should be displayed when user hovers this object.\nShould return empty string if tooltip should not be displayed." + ], + "signature": [ + "((context: Context) => string) | undefined" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getDisplayNameTooltip.$1", + "type": "Uncategorized", + "tags": [], + "label": "context", + "description": [], + "signature": [ + "Context" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getHref", + "type": "Function", + "tags": [], + "label": "getHref", + "description": [ + "\nThis method should return a link if this item can be clicked on. The link\nis used to navigate user if user middle-clicks it or Ctrl + clicks or\nright-clicks and selects \"Open in new tab\"." + ], + "signature": [ + "((context: Context) => Promise) | undefined" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.getHref.$1", + "type": "Uncategorized", + "tags": [], + "label": "context", + "description": [], + "signature": [ + "Context" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.isCompatible", + "type": "Function", + "tags": [], + "label": "isCompatible", + "description": [ + "\nReturns a promise that resolves to true if this item is compatible given\nthe context and should be displayed to user, otherwise resolves to false." + ], + "signature": [ + "(context: Context) => Promise" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.isCompatible.$1", + "type": "Uncategorized", + "tags": [], + "label": "context", + "description": [], + "signature": [ + "Context" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": true + } + ], + "returnComment": [] + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.Presentable.grouping", + "type": "Array", + "tags": [], + "label": "grouping", + "description": [ + "\nGrouping where this item should appear as a submenu. Each entry is a new\nsub-menu level. For example, used to show drilldowns and sharing options\nin panel context menu in a sub-menu." + ], + "signature": [ + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGrouping", + "text": "PresentableGrouping" + }, + " | undefined" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.PresentableGroup", + "type": "Interface", + "tags": [], + "label": "PresentableGroup", + "description": [], + "signature": [ + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGroup", + "text": "PresentableGroup" + }, + " extends Partial, \"order\" | \"getDisplayName\" | \"getIconType\" | \"getDisplayNameTooltip\">>" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.PresentableGroup.id", + "type": "string", + "tags": [], + "label": "id", + "description": [], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + } + ], + "enums": [], + "misc": [ + { + "parentPluginId": "@kbn/ui-actions-browser", + "id": "def-common.PresentableGrouping", + "type": "Type", + "tags": [], + "label": "PresentableGrouping", + "description": [], + "signature": [ + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGroup", + "text": "PresentableGroup" + }, + "[]" + ], + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + } + ], + "objects": [] + } +} \ No newline at end of file diff --git a/api_docs/kbn_ui_actions_browser.mdx b/api_docs/kbn_ui_actions_browser.mdx new file mode 100644 index 0000000000000..dc0896b76d2ad --- /dev/null +++ b/api_docs/kbn_ui_actions_browser.mdx @@ -0,0 +1,33 @@ +--- +#### +#### This document is auto-generated and is meant to be viewed inside our experimental, new docs system. +#### Reach out in #docs-engineering for more info. +#### +id: kibKbnUiActionsBrowserPluginApi +slug: /kibana-dev-docs/api/kbn-ui-actions-browser +title: "@kbn/ui-actions-browser" +image: https://source.unsplash.com/400x175/?github +description: API docs for the @kbn/ui-actions-browser plugin +date: 2023-01-23 +tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ui-actions-browser'] +--- +import kbnUiActionsBrowserObj from './kbn_ui_actions_browser.devdocs.json'; + + + +Contact [Owner missing] for questions regarding this plugin. + +**Code health stats** + +| Public API count | Any count | Items lacking comments | Missing exports | +|-------------------|-----------|------------------------|-----------------| +| 18 | 0 | 8 | 0 | + +## Common + +### Interfaces + + +### Consts, variables and types + + diff --git a/api_docs/kbn_ui_shared_deps_src.devdocs.json b/api_docs/kbn_ui_shared_deps_src.devdocs.json index e2bd3bbca50a9..98f272fbfe6f9 100644 --- a/api_docs/kbn_ui_shared_deps_src.devdocs.json +++ b/api_docs/kbn_ui_shared_deps_src.devdocs.json @@ -436,6 +436,17 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "@kbn/ui-shared-deps-src", + "id": "def-common.externals.uuid", + "type": "string", + "tags": [], + "label": "uuid", + "description": [], + "path": "packages/kbn-ui-shared-deps-src/src/definitions.js", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "@kbn/ui-shared-deps-src", "id": "def-common.externals.kbnanalytics", diff --git a/api_docs/kbn_ui_shared_deps_src.mdx b/api_docs/kbn_ui_shared_deps_src.mdx index 115d244a57ec4..d235a96b1940c 100644 --- a/api_docs/kbn_ui_shared_deps_src.mdx +++ b/api_docs/kbn_ui_shared_deps_src.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ui-shared-deps-src title: "@kbn/ui-shared-deps-src" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ui-shared-deps-src plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ui-shared-deps-src'] --- import kbnUiSharedDepsSrcObj from './kbn_ui_shared_deps_src.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Owner missing] for questions regarding this plugin. | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 44 | 0 | 35 | 0 | +| 45 | 0 | 36 | 0 | ## Common diff --git a/api_docs/kbn_ui_theme.mdx b/api_docs/kbn_ui_theme.mdx index d01cd4c11695d..2062c1cec80bd 100644 --- a/api_docs/kbn_ui_theme.mdx +++ b/api_docs/kbn_ui_theme.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-ui-theme title: "@kbn/ui-theme" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/ui-theme plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ui-theme'] --- import kbnUiThemeObj from './kbn_ui_theme.devdocs.json'; diff --git a/api_docs/kbn_user_profile_components.mdx b/api_docs/kbn_user_profile_components.mdx index 7d5c8452b438c..ec8b39956d5f3 100644 --- a/api_docs/kbn_user_profile_components.mdx +++ b/api_docs/kbn_user_profile_components.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-user-profile-components title: "@kbn/user-profile-components" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/user-profile-components plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/user-profile-components'] --- import kbnUserProfileComponentsObj from './kbn_user_profile_components.devdocs.json'; diff --git a/api_docs/kbn_utility_types.mdx b/api_docs/kbn_utility_types.mdx index 2e48c18c48968..1427c0d970bf2 100644 --- a/api_docs/kbn_utility_types.mdx +++ b/api_docs/kbn_utility_types.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-utility-types title: "@kbn/utility-types" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/utility-types plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/utility-types'] --- import kbnUtilityTypesObj from './kbn_utility_types.devdocs.json'; diff --git a/api_docs/kbn_utility_types_jest.mdx b/api_docs/kbn_utility_types_jest.mdx index 1851fff1a0ccf..d2240f2ca4d6b 100644 --- a/api_docs/kbn_utility_types_jest.mdx +++ b/api_docs/kbn_utility_types_jest.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-utility-types-jest title: "@kbn/utility-types-jest" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/utility-types-jest plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/utility-types-jest'] --- import kbnUtilityTypesJestObj from './kbn_utility_types_jest.devdocs.json'; diff --git a/api_docs/kbn_utils.mdx b/api_docs/kbn_utils.mdx index 74b9284e28c9a..25cb237a4adeb 100644 --- a/api_docs/kbn_utils.mdx +++ b/api_docs/kbn_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-utils title: "@kbn/utils" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/utils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/utils'] --- import kbnUtilsObj from './kbn_utils.devdocs.json'; diff --git a/api_docs/kbn_yarn_lock_validator.mdx b/api_docs/kbn_yarn_lock_validator.mdx index 4fee855414f49..cffb97c1d533b 100644 --- a/api_docs/kbn_yarn_lock_validator.mdx +++ b/api_docs/kbn_yarn_lock_validator.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-yarn-lock-validator title: "@kbn/yarn-lock-validator" image: https://source.unsplash.com/400x175/?github description: API docs for the @kbn/yarn-lock-validator plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/yarn-lock-validator'] --- import kbnYarnLockValidatorObj from './kbn_yarn_lock_validator.devdocs.json'; diff --git a/api_docs/kibana_overview.mdx b/api_docs/kibana_overview.mdx index 3319e2d2b4bce..85b8bd0f9880d 100644 --- a/api_docs/kibana_overview.mdx +++ b/api_docs/kibana_overview.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kibanaOverview title: "kibanaOverview" image: https://source.unsplash.com/400x175/?github description: API docs for the kibanaOverview plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'kibanaOverview'] --- import kibanaOverviewObj from './kibana_overview.devdocs.json'; diff --git a/api_docs/kibana_react.mdx b/api_docs/kibana_react.mdx index b1320400e59c8..751d6620108ae 100644 --- a/api_docs/kibana_react.mdx +++ b/api_docs/kibana_react.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kibanaReact title: "kibanaReact" image: https://source.unsplash.com/400x175/?github description: API docs for the kibanaReact plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'kibanaReact'] --- import kibanaReactObj from './kibana_react.devdocs.json'; diff --git a/api_docs/kibana_utils.mdx b/api_docs/kibana_utils.mdx index f4856bf7b1e1b..118b109e5689b 100644 --- a/api_docs/kibana_utils.mdx +++ b/api_docs/kibana_utils.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kibanaUtils title: "kibanaUtils" image: https://source.unsplash.com/400x175/?github description: API docs for the kibanaUtils plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'kibanaUtils'] --- import kibanaUtilsObj from './kibana_utils.devdocs.json'; diff --git a/api_docs/kubernetes_security.mdx b/api_docs/kubernetes_security.mdx index befe0d85db8b8..95212ed32d42a 100644 --- a/api_docs/kubernetes_security.mdx +++ b/api_docs/kubernetes_security.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kubernetesSecurity title: "kubernetesSecurity" image: https://source.unsplash.com/400x175/?github description: API docs for the kubernetesSecurity plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'kubernetesSecurity'] --- import kubernetesSecurityObj from './kubernetes_security.devdocs.json'; diff --git a/api_docs/lens.devdocs.json b/api_docs/lens.devdocs.json index 58d9a9d2ac2ee..2a328fffb3a3e 100644 --- a/api_docs/lens.devdocs.json +++ b/api_docs/lens.devdocs.json @@ -9143,6 +9143,8 @@ "description": [], "signature": [ "(", + "LensByReferenceInput", + " | ", { "pluginId": "lens", "scope": "public", @@ -9150,8 +9152,6 @@ "section": "def-public.TypedLensByValueInput", "text": "TypedLensByValueInput" }, - " | ", - "LensByReferenceInput", ") & { withDefaultActions?: boolean | undefined; extraActions?: ", { "pluginId": "uiActions", @@ -10630,6 +10630,27 @@ "path": "x-pack/plugins/lens/server/plugin.tsx", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "lens", + "id": "def-server.PluginSetupContract.share", + "type": "Object", + "tags": [], + "label": "share", + "description": [], + "signature": [ + { + "pluginId": "share", + "scope": "server", + "docId": "kibSharePluginApi", + "section": "def-server.SharePluginSetup", + "text": "SharePluginSetup" + }, + " | undefined" + ], + "path": "x-pack/plugins/lens/server/plugin.tsx", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -11720,6 +11741,22 @@ "section": "def-common.TimeRange", "text": "TimeRange" }, + " | undefined, filters: ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + }, + "[] | undefined, refreshInterval: ", + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataQueryPluginApi", + "section": "def-common.RefreshInterval", + "text": "RefreshInterval" + }, " | undefined) => string" ], "path": "x-pack/plugins/lens/common/constants.ts", @@ -11762,6 +11799,50 @@ "deprecated": false, "trackAdoption": false, "isRequired": false + }, + { + "parentPluginId": "lens", + "id": "def-common.getEditPath.$3", + "type": "Array", + "tags": [], + "label": "filters", + "description": [], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + }, + "[] | undefined" + ], + "path": "x-pack/plugins/lens/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false + }, + { + "parentPluginId": "lens", + "id": "def-common.getEditPath.$4", + "type": "Object", + "tags": [], + "label": "refreshInterval", + "description": [], + "signature": [ + { + "pluginId": "data", + "scope": "common", + "docId": "kibDataQueryPluginApi", + "section": "def-common.RefreshInterval", + "text": "RefreshInterval" + }, + " | undefined" + ], + "path": "x-pack/plugins/lens/common/constants.ts", + "deprecated": false, + "trackAdoption": false, + "isRequired": false } ], "returnComment": [], diff --git a/api_docs/lens.mdx b/api_docs/lens.mdx index c6f7f545ffa88..dea24ab0fa93b 100644 --- a/api_docs/lens.mdx +++ b/api_docs/lens.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/lens title: "lens" image: https://source.unsplash.com/400x175/?github description: API docs for the lens plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'lens'] --- import lensObj from './lens.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualization | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 695 | 0 | 599 | 50 | +| 698 | 0 | 602 | 50 | ## Client diff --git a/api_docs/license_api_guard.mdx b/api_docs/license_api_guard.mdx index 6c6fe37d2eaaa..54678407a88b3 100644 --- a/api_docs/license_api_guard.mdx +++ b/api_docs/license_api_guard.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/licenseApiGuard title: "licenseApiGuard" image: https://source.unsplash.com/400x175/?github description: API docs for the licenseApiGuard plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'licenseApiGuard'] --- import licenseApiGuardObj from './license_api_guard.devdocs.json'; diff --git a/api_docs/license_management.mdx b/api_docs/license_management.mdx index 5dd4fd210c139..7a327d7e8cd80 100644 --- a/api_docs/license_management.mdx +++ b/api_docs/license_management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/licenseManagement title: "licenseManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the licenseManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'licenseManagement'] --- import licenseManagementObj from './license_management.devdocs.json'; diff --git a/api_docs/licensing.mdx b/api_docs/licensing.mdx index fe6b127d726b6..50959f0188676 100644 --- a/api_docs/licensing.mdx +++ b/api_docs/licensing.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/licensing title: "licensing" image: https://source.unsplash.com/400x175/?github description: API docs for the licensing plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'licensing'] --- import licensingObj from './licensing.devdocs.json'; diff --git a/api_docs/lists.devdocs.json b/api_docs/lists.devdocs.json index 6233f803836c3..711eb0bcf6a20 100644 --- a/api_docs/lists.devdocs.json +++ b/api_docs/lists.devdocs.json @@ -345,7 +345,7 @@ "label": "exceptionsToDelete", "description": [], "signature": [ - "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]" + "{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]" ], "path": "x-pack/plugins/lists/public/exceptions/components/builder/exception_items_renderer.tsx", "deprecated": false, @@ -622,7 +622,7 @@ "signature": [ "({ itemId, id, namespaceType, }: ", "GetExceptionListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -700,7 +700,7 @@ "signature": [ "({ comments, description, entries, itemId, meta, name, osTypes, tags, type, }: ", "CreateEndpointListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -776,7 +776,7 @@ "signature": [ "({ _version, comments, description, entries, id, itemId, meta, name, osTypes, tags, type, }: ", "UpdateEndpointListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -814,7 +814,7 @@ "signature": [ "({ itemId, id, }: ", "GetEndpointListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -972,7 +972,7 @@ "section": "def-server.CreateExceptionListItemOptions", "text": "CreateExceptionListItemOptions" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1022,7 +1022,7 @@ "section": "def-server.UpdateExceptionListItemOptions", "text": "UpdateExceptionListItemOptions" }, - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1066,7 +1066,7 @@ "signature": [ "({ id, itemId, namespaceType, }: ", "DeleteExceptionListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1140,7 +1140,7 @@ "signature": [ "({ id, itemId, }: ", "DeleteEndpointListItemOptions", - ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" + ") => Promise<{ _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1176,7 +1176,7 @@ "signature": [ "({ listId, filter, perPage, pit, page, search, searchAfter, sortField, sortOrder, namespaceType, }: ", "FindExceptionListItemOptions", - ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" + ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1214,7 +1214,7 @@ "signature": [ "({ listId, filter, perPage, pit, page, search, searchAfter, sortField, sortOrder, namespaceType, }: ", "FindExceptionListsItemOptions", - ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" + ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1252,7 +1252,7 @@ "signature": [ "({ perPage, pit, page, searchAfter, sortField, sortOrder, valueListId, }: ", "FindValueListExceptionListsItems", - ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" + ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1328,7 +1328,7 @@ "signature": [ "({ filter, perPage, page, pit, search, searchAfter, sortField, sortOrder, }: ", "FindEndpointListItemOptions", - ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" + ") => Promise<({ data: { _version: string | undefined; comments: ({ comment: string; created_at: string; created_by: string; id: string; } & { updated_at?: string | undefined; updated_by?: string | undefined; })[]; created_at: string; created_by: string; description: string; entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]; id: string; item_id: string; list_id: string; meta: object | undefined; name: string; namespace_type: \"single\" | \"agnostic\"; os_types: (\"windows\" | \"linux\" | \"macos\")[]; tags: string[]; tie_breaker_id: string; type: \"simple\"; updated_at: string; updated_by: string; }[]; page: number; per_page: number; total: number; } & { pit?: string | undefined; }) | null>" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client.ts", "deprecated": false, @@ -1814,7 +1814,7 @@ "signature": [ "({ id }: ", "GetListOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -1852,7 +1852,7 @@ "signature": [ "({ id, deserializer, immutable, serializer, name, description, type, meta, version, }: ", "CreateListOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -1890,7 +1890,7 @@ "signature": [ "({ id, deserializer, serializer, name, description, immutable, type, meta, version, }: ", "CreateListIfItDoesNotExistOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2408,7 +2408,7 @@ "signature": [ "({ id }: ", "DeleteListItemOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2446,7 +2446,7 @@ "signature": [ "({ listId, value, type, }: ", "DeleteListItemByValueOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2484,7 +2484,7 @@ "signature": [ "({ id }: ", "DeleteListOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2558,7 +2558,7 @@ "signature": [ "({ deserializer, serializer, type, listId, stream, meta, version, }: ", "ImportListItemsToStreamOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2594,7 +2594,7 @@ "signature": [ "({ listId, value, type, }: ", "GetListItemByValueOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2632,7 +2632,7 @@ "signature": [ "({ id, deserializer, serializer, listId, value, type, meta, }: ", "CreateListItemOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2668,7 +2668,7 @@ "signature": [ "({ _version, id, value, meta, }: ", "UpdateListItemOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2704,7 +2704,7 @@ "signature": [ "({ _version, id, name, description, meta, version, }: ", "UpdateListOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2740,7 +2740,7 @@ "signature": [ "({ id }: ", "GetListItemOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2778,7 +2778,7 @@ "signature": [ "({ type, listId, value, }: ", "GetListItemsByValueOptions", - ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" + ") => Promise<{ _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2816,7 +2816,7 @@ "signature": [ "({ type, listId, value, }: ", "SearchListItemByValuesOptions", - ") => Promise<{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }[]>" + ") => Promise<{ items: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; value: unknown; }[]>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2854,7 +2854,7 @@ "signature": [ "({ filter, currentIndexPosition, perPage, page, sortField, sortOrder, searchAfter, runtimeMappings, }: ", "FindListOptions", - ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" + ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; description: string; deserializer: string | undefined; id: string; immutable: boolean; meta: object | undefined; name: string; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; version: number; }[]; page: number; per_page: number; total: number; }>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2892,7 +2892,7 @@ "signature": [ "({ listId, filter, currentIndexPosition, perPage, page, runtimeMappings, sortField, sortOrder, searchAfter, }: ", "FindListItemOptions", - ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; page: number; per_page: number; total: number; } | null>" + ") => Promise<{ cursor: string; data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; page: number; per_page: number; total: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2928,7 +2928,7 @@ "signature": [ "({ listId, filter, sortField, sortOrder, }: ", "FindAllListItemsOptions", - ") => Promise<{ data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; total: number; } | null>" + ") => Promise<{ data: { _version: string | undefined; created_at: string; created_by: string; deserializer: string | undefined; id: string; list_id: string; meta: object | undefined; serializer: string | undefined; tie_breaker_id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; updated_at: string; updated_by: string; value: string; }[]; total: number; } | null>" ], "path": "x-pack/plugins/lists/server/services/lists/list_client.ts", "deprecated": false, @@ -2997,7 +2997,7 @@ "an array with the exception list item entries" ], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client_types.ts", "deprecated": false, @@ -3309,7 +3309,7 @@ "item exception entries logic" ], "signature": [ - "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"binary\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" + "({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; list: { id: string; type: \"boolean\" | \"date\" | \"keyword\" | \"ip\" | \"text\" | \"geo_point\" | \"geo_shape\" | \"date_nanos\" | \"binary\" | \"long\" | \"double\" | \"date_range\" | \"ip_range\" | \"shape\" | \"short\" | \"byte\" | \"float\" | \"half_float\" | \"integer\" | \"double_range\" | \"float_range\" | \"integer_range\" | \"long_range\"; }; operator: \"excluded\" | \"included\"; type: \"list\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; } | { entries: ({ field: string; operator: \"excluded\" | \"included\"; type: \"match\"; value: string; } | { field: string; operator: \"excluded\" | \"included\"; type: \"match_any\"; value: string[]; } | { field: string; operator: \"excluded\" | \"included\"; type: \"exists\"; })[]; field: string; type: \"nested\"; } | { field: string; operator: \"excluded\" | \"included\"; type: \"wildcard\"; value: string; })[]" ], "path": "x-pack/plugins/lists/server/services/exception_lists/exception_list_client_types.ts", "deprecated": false, diff --git a/api_docs/lists.mdx b/api_docs/lists.mdx index 10ccad3ad9e43..3bf51da3689eb 100644 --- a/api_docs/lists.mdx +++ b/api_docs/lists.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/lists title: "lists" image: https://source.unsplash.com/400x175/?github description: API docs for the lists plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'lists'] --- import listsObj from './lists.devdocs.json'; diff --git a/api_docs/management.mdx b/api_docs/management.mdx index 8f06ef12a04e1..3843f133a7c0b 100644 --- a/api_docs/management.mdx +++ b/api_docs/management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/management title: "management" image: https://source.unsplash.com/400x175/?github description: API docs for the management plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'management'] --- import managementObj from './management.devdocs.json'; diff --git a/api_docs/maps.mdx b/api_docs/maps.mdx index 0f8f719fed732..308a442d84406 100644 --- a/api_docs/maps.mdx +++ b/api_docs/maps.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/maps title: "maps" image: https://source.unsplash.com/400x175/?github description: API docs for the maps plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'maps'] --- import mapsObj from './maps.devdocs.json'; diff --git a/api_docs/maps_ems.mdx b/api_docs/maps_ems.mdx index 7e7322fe5a6b7..df2378722a4fd 100644 --- a/api_docs/maps_ems.mdx +++ b/api_docs/maps_ems.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/mapsEms title: "mapsEms" image: https://source.unsplash.com/400x175/?github description: API docs for the mapsEms plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'mapsEms'] --- import mapsEmsObj from './maps_ems.devdocs.json'; diff --git a/api_docs/ml.mdx b/api_docs/ml.mdx index c1a756160e3f9..b862c56eda85c 100644 --- a/api_docs/ml.mdx +++ b/api_docs/ml.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/ml title: "ml" image: https://source.unsplash.com/400x175/?github description: API docs for the ml plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'ml'] --- import mlObj from './ml.devdocs.json'; diff --git a/api_docs/monitoring.mdx b/api_docs/monitoring.mdx index e5f0ada08a1d7..7037c88bc93f1 100644 --- a/api_docs/monitoring.mdx +++ b/api_docs/monitoring.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/monitoring title: "monitoring" image: https://source.unsplash.com/400x175/?github description: API docs for the monitoring plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'monitoring'] --- import monitoringObj from './monitoring.devdocs.json'; diff --git a/api_docs/monitoring_collection.mdx b/api_docs/monitoring_collection.mdx index a45045adf2798..9759dd3c2cf73 100644 --- a/api_docs/monitoring_collection.mdx +++ b/api_docs/monitoring_collection.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/monitoringCollection title: "monitoringCollection" image: https://source.unsplash.com/400x175/?github description: API docs for the monitoringCollection plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'monitoringCollection'] --- import monitoringCollectionObj from './monitoring_collection.devdocs.json'; diff --git a/api_docs/navigation.mdx b/api_docs/navigation.mdx index d0e2e08ab8143..d0595e73e6ae1 100644 --- a/api_docs/navigation.mdx +++ b/api_docs/navigation.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/navigation title: "navigation" image: https://source.unsplash.com/400x175/?github description: API docs for the navigation plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'navigation'] --- import navigationObj from './navigation.devdocs.json'; diff --git a/api_docs/newsfeed.mdx b/api_docs/newsfeed.mdx index 0f95e9d9c0130..65ae4a25bb31f 100644 --- a/api_docs/newsfeed.mdx +++ b/api_docs/newsfeed.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/newsfeed title: "newsfeed" image: https://source.unsplash.com/400x175/?github description: API docs for the newsfeed plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'newsfeed'] --- import newsfeedObj from './newsfeed.devdocs.json'; diff --git a/api_docs/notifications.mdx b/api_docs/notifications.mdx index 29537e5dd1aa3..b340b24159c7e 100644 --- a/api_docs/notifications.mdx +++ b/api_docs/notifications.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/notifications title: "notifications" image: https://source.unsplash.com/400x175/?github description: API docs for the notifications plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'notifications'] --- import notificationsObj from './notifications.devdocs.json'; diff --git a/api_docs/observability.devdocs.json b/api_docs/observability.devdocs.json index 42fb1de6e0340..d779d39400a3f 100644 --- a/api_docs/observability.devdocs.json +++ b/api_docs/observability.devdocs.json @@ -53,6 +53,98 @@ "returnComment": [], "initialIsOpen": false }, + { + "parentPluginId": "observability", + "id": "def-public.convertTo", + "type": "Function", + "tags": [], + "label": "convertTo", + "description": [ + "\nConverts a microseconds value into the unit defined." + ], + "signature": [ + "({\n unit,\n microseconds,\n defaultValue = NOT_AVAILABLE_LABEL,\n extended,\n}: { unit: DurationTimeUnit; microseconds: ", + "Maybe", + "; defaultValue?: string | undefined; extended?: boolean | undefined; }) => ConvertedDuration" + ], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "observability", + "id": "def-public.convertTo.$1", + "type": "Object", + "tags": [], + "label": "{\n unit,\n microseconds,\n defaultValue = NOT_AVAILABLE_LABEL,\n extended,\n}", + "description": [], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "observability", + "id": "def-public.convertTo.$1.unit", + "type": "CompoundType", + "tags": [], + "label": "unit", + "description": [], + "signature": [ + "\"microseconds\" | ", + "TimeUnit" + ], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.convertTo.$1.microseconds", + "type": "CompoundType", + "tags": [], + "label": "microseconds", + "description": [], + "signature": [ + "number | null | undefined" + ], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.convertTo.$1.defaultValue", + "type": "string", + "tags": [], + "label": "defaultValue", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.convertTo.$1.extended", + "type": "CompoundType", + "tags": [], + "label": "extended", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "x-pack/plugins/observability/common/utils/formatters/duration.ts", + "deprecated": false, + "trackAdoption": false + } + ] + } + ], + "returnComment": [], + "initialIsOpen": false + }, { "parentPluginId": "observability", "id": "def-public.createEsParams", @@ -3846,19 +3938,37 @@ "children": [ { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.usageCollection", + "id": "def-public.ObservabilityPublicPluginsStart.actionTypeRegistry", "type": "Object", "tags": [], - "label": "usageCollection", + "label": "actionTypeRegistry", "description": [], "signature": [ + "{ get: (id: string) => ", { - "pluginId": "usageCollection", + "pluginId": "triggersActionsUi", "scope": "public", - "docId": "kibUsageCollectionPluginApi", - "section": "def-public.UsageCollectionSetup", - "text": "UsageCollectionSetup" - } + "docId": "kibTriggersActionsUiPluginApi", + "section": "def-public.ActionTypeModel", + "text": "ActionTypeModel" + }, + "; list: () => ", + { + "pluginId": "triggersActionsUi", + "scope": "public", + "docId": "kibTriggersActionsUiPluginApi", + "section": "def-public.ActionTypeModel", + "text": "ActionTypeModel" + }, + "[]; has: (id: string) => boolean; register: (objectType: ", + { + "pluginId": "triggersActionsUi", + "scope": "public", + "docId": "kibTriggersActionsUiPluginApi", + "section": "def-public.ActionTypeModel", + "text": "ActionTypeModel" + }, + ") => void; }" ], "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, @@ -3886,19 +3996,22 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.embeddable", - "type": "Object", + "id": "def-public.ObservabilityPublicPluginsStart.charts", + "type": "CompoundType", "tags": [], - "label": "embeddable", + "label": "charts", "description": [], "signature": [ { - "pluginId": "embeddable", + "pluginId": "charts", "scope": "public", - "docId": "kibEmbeddablePluginApi", - "section": "def-public.EmbeddableStart", - "text": "EmbeddableStart" - } + "docId": "kibChartsPluginApi", + "section": "def-public.ChartsPluginSetup", + "text": "ChartsPluginSetup" + }, + " & { activeCursor: ", + "ActiveCursor", + "; }" ], "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, @@ -3906,20 +4019,19 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.home", + "id": "def-public.ObservabilityPublicPluginsStart.data", "type": "Object", "tags": [], - "label": "home", + "label": "data", "description": [], "signature": [ { - "pluginId": "home", + "pluginId": "data", "scope": "public", - "docId": "kibHomePluginApi", - "section": "def-public.HomePublicPluginStart", - "text": "HomePublicPluginStart" - }, - " | undefined" + "docId": "kibDataPluginApi", + "section": "def-public.DataPublicPluginStart", + "text": "DataPublicPluginStart" + } ], "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, @@ -3927,39 +4039,19 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.share", - "type": "CompoundType", + "id": "def-public.ObservabilityPublicPluginsStart.dataViews", + "type": "Object", "tags": [], - "label": "share", + "label": "dataViews", "description": [], "signature": [ - "{ toggleShareContextMenu: (options: ", - { - "pluginId": "share", - "scope": "public", - "docId": "kibSharePluginApi", - "section": "def-public.ShowShareMenuOptions", - "text": "ShowShareMenuOptions" - }, - ") => void; } & { url: ", { - "pluginId": "share", + "pluginId": "dataViews", "scope": "public", - "docId": "kibSharePluginApi", - "section": "def-public.BrowserUrlService", - "text": "BrowserUrlService" - }, - "; navigate(options: ", - "RedirectOptions", - "<", - { - "pluginId": "@kbn/utility-types", - "scope": "common", - "docId": "kibKbnUtilityTypesPluginApi", - "section": "def-common.SerializableRecord", - "text": "SerializableRecord" - }, - ">): void; }" + "docId": "kibDataViewsPluginApi", + "section": "def-public.DataViewsServicePublic", + "text": "DataViewsServicePublic" + } ], "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, @@ -3967,18 +4059,18 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.triggersActionsUi", + "id": "def-public.ObservabilityPublicPluginsStart.discover", "type": "Object", "tags": [], - "label": "triggersActionsUi", + "label": "discover", "description": [], "signature": [ { - "pluginId": "triggersActionsUi", + "pluginId": "discover", "scope": "public", - "docId": "kibTriggersActionsUiPluginApi", - "section": "def-public.TriggersAndActionsUIPublicPluginStart", - "text": "TriggersAndActionsUIPublicPluginStart" + "docId": "kibDiscoverPluginApi", + "section": "def-public.DiscoverStart", + "text": "DiscoverStart" } ], "path": "x-pack/plugins/observability/public/plugin.ts", @@ -3987,18 +4079,18 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.data", + "id": "def-public.ObservabilityPublicPluginsStart.embeddable", "type": "Object", "tags": [], - "label": "data", + "label": "embeddable", "description": [], "signature": [ { - "pluginId": "data", + "pluginId": "embeddable", "scope": "public", - "docId": "kibDataPluginApi", - "section": "def-public.DataPublicPluginStart", - "text": "DataPublicPluginStart" + "docId": "kibEmbeddablePluginApi", + "section": "def-public.EmbeddableStart", + "text": "EmbeddableStart" } ], "path": "x-pack/plugins/observability/public/plugin.ts", @@ -4007,18 +4099,18 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.dataViews", + "id": "def-public.ObservabilityPublicPluginsStart.guidedOnboarding", "type": "Object", "tags": [], - "label": "dataViews", + "label": "guidedOnboarding", "description": [], "signature": [ { - "pluginId": "dataViews", + "pluginId": "guidedOnboarding", "scope": "public", - "docId": "kibDataViewsPluginApi", - "section": "def-public.DataViewsServicePublic", - "text": "DataViewsServicePublic" + "docId": "kibGuidedOnboardingPluginApi", + "section": "def-public.GuidedOnboardingPluginStart", + "text": "GuidedOnboardingPluginStart" } ], "path": "x-pack/plugins/observability/public/plugin.ts", @@ -4047,18 +4139,18 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.discover", + "id": "def-public.ObservabilityPublicPluginsStart.licensing", "type": "Object", "tags": [], - "label": "discover", + "label": "licensing", "description": [], "signature": [ { - "pluginId": "discover", + "pluginId": "licensing", "scope": "public", - "docId": "kibDiscoverPluginApi", - "section": "def-public.DiscoverStart", - "text": "DiscoverStart" + "docId": "kibLicensingPluginApi", + "section": "def-public.LicensingPluginStart", + "text": "LicensingPluginStart" } ], "path": "x-pack/plugins/observability/public/plugin.ts", @@ -4127,44 +4219,6 @@ "deprecated": false, "trackAdoption": false }, - { - "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.actionTypeRegistry", - "type": "Object", - "tags": [], - "label": "actionTypeRegistry", - "description": [], - "signature": [ - "{ get: (id: string) => ", - { - "pluginId": "triggersActionsUi", - "scope": "public", - "docId": "kibTriggersActionsUiPluginApi", - "section": "def-public.ActionTypeModel", - "text": "ActionTypeModel" - }, - "; list: () => ", - { - "pluginId": "triggersActionsUi", - "scope": "public", - "docId": "kibTriggersActionsUiPluginApi", - "section": "def-public.ActionTypeModel", - "text": "ActionTypeModel" - }, - "[]; has: (id: string) => boolean; register: (objectType: ", - { - "pluginId": "triggersActionsUi", - "scope": "public", - "docId": "kibTriggersActionsUiPluginApi", - "section": "def-public.ActionTypeModel", - "text": "ActionTypeModel" - }, - ") => void; }" - ], - "path": "x-pack/plugins/observability/public/plugin.ts", - "deprecated": false, - "trackAdoption": false - }, { "parentPluginId": "observability", "id": "def-public.ObservabilityPublicPluginsStart.security", @@ -4187,19 +4241,39 @@ }, { "parentPluginId": "observability", - "id": "def-public.ObservabilityPublicPluginsStart.guidedOnboarding", - "type": "Object", + "id": "def-public.ObservabilityPublicPluginsStart.share", + "type": "CompoundType", "tags": [], - "label": "guidedOnboarding", + "label": "share", "description": [], "signature": [ + "{ toggleShareContextMenu: (options: ", { - "pluginId": "guidedOnboarding", + "pluginId": "share", "scope": "public", - "docId": "kibGuidedOnboardingPluginApi", - "section": "def-public.GuidedOnboardingPluginStart", - "text": "GuidedOnboardingPluginStart" - } + "docId": "kibSharePluginApi", + "section": "def-public.ShowShareMenuOptions", + "text": "ShowShareMenuOptions" + }, + ") => void; } & { url: ", + { + "pluginId": "share", + "scope": "public", + "docId": "kibSharePluginApi", + "section": "def-public.BrowserUrlService", + "text": "BrowserUrlService" + }, + "; navigate(options: ", + "RedirectOptions", + "<", + { + "pluginId": "@kbn/utility-types", + "scope": "common", + "docId": "kibKbnUtilityTypesPluginApi", + "section": "def-common.SerializableRecord", + "text": "SerializableRecord" + }, + ">): void; }" ], "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, @@ -4224,6 +4298,67 @@ "path": "x-pack/plugins/observability/public/plugin.ts", "deprecated": false, "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.ObservabilityPublicPluginsStart.triggersActionsUi", + "type": "Object", + "tags": [], + "label": "triggersActionsUi", + "description": [], + "signature": [ + { + "pluginId": "triggersActionsUi", + "scope": "public", + "docId": "kibTriggersActionsUiPluginApi", + "section": "def-public.TriggersAndActionsUIPublicPluginStart", + "text": "TriggersAndActionsUIPublicPluginStart" + } + ], + "path": "x-pack/plugins/observability/public/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.ObservabilityPublicPluginsStart.usageCollection", + "type": "Object", + "tags": [], + "label": "usageCollection", + "description": [], + "signature": [ + { + "pluginId": "usageCollection", + "scope": "public", + "docId": "kibUsageCollectionPluginApi", + "section": "def-public.UsageCollectionSetup", + "text": "UsageCollectionSetup" + } + ], + "path": "x-pack/plugins/observability/public/plugin.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "observability", + "id": "def-public.ObservabilityPublicPluginsStart.home", + "type": "Object", + "tags": [], + "label": "home", + "description": [], + "signature": [ + { + "pluginId": "home", + "scope": "public", + "docId": "kibHomePluginApi", + "section": "def-public.HomePublicPluginStart", + "text": "HomePublicPluginStart" + }, + " | undefined" + ], + "path": "x-pack/plugins/observability/public/plugin.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -9641,115 +9776,7 @@ "label": "ObservabilityAPIReturnType", "description": [], "signature": [ - "{ \"GET /api/observability/slos\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"GET /api/observability/slos\", ", - "PartialC", - "<{ query: ", - "PartialC", - "<{ name: ", - "StringC", - "; indicatorTypes: ", - "Type", - "; page: ", - "StringC", - "; perPage: ", - "StringC", - "; sortBy: ", - "UnionC", - "<[", - "LiteralC", - "<\"name\">, ", - "LiteralC", - "<\"indicatorType\">]>; sortDirection: ", - "UnionC", - "<[", - "LiteralC", - "<\"asc\">, ", - "LiteralC", - "<\"desc\">]>; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", { page: number; perPage: number; total: number; results: ({ id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; })[]; }, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"DELETE /api/observability/slos/{id}\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"DELETE /api/observability/slos/{id}\", ", - "TypeC", - "<{ path: ", - "TypeC", - "<{ id: ", - "StringC", - "; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", void, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"GET /api/observability/slos/{id}\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"GET /api/observability/slos/{id}\", ", - "TypeC", - "<{ path: ", - "TypeC", - "<{ id: ", - "StringC", - "; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", { id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; }, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"PUT /api/observability/slos/{id}\"?: ", + "{ \"PUT /api/observability/slos/{id}\"?: ", { "pluginId": "@kbn/server-route-repository", "scope": "public", @@ -9969,7 +9996,7 @@ "section": "def-server.ObservabilityRouteCreateOptions", "text": "ObservabilityRouteCreateOptions" }, - "> | undefined; \"POST /api/observability/slos\"?: ", + "> | undefined; \"POST /internal/observability/slos/_historical_summary\"?: ", { "pluginId": "@kbn/server-route-repository", "scope": "public", @@ -9977,48 +10004,188 @@ "section": "def-public.ServerRoute", "text": "ServerRoute" }, - "<\"POST /api/observability/slos\", ", + "<\"POST /internal/observability/slos/_historical_summary\", ", "TypeC", "<{ body: ", - "IntersectionC", - "<[", "TypeC", - "<{ name: ", - "StringC", - "; description: ", + "<{ sloIds: ", + "ArrayC", + "<", "StringC", - "; indicator: ", - "UnionC", - "<[", + ">; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { [x: string]: { date: string; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; sliValue: number; status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; }[]; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"GET /api/observability/slos/{id}\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /api/observability/slos/{id}\", ", "TypeC", - "<{ type: ", - "LiteralC", - "<\"sli.apm.transactionDuration\">; params: ", - "IntersectionC", - "<[", + "<{ path: ", "TypeC", - "<{ environment: ", - "UnionC", - "<[", - "LiteralC", - "<\"*\">, ", - "StringC", - "]>; service: ", - "UnionC", - "<[", - "LiteralC", - "<\"*\">, ", - "StringC", - "]>; transactionType: ", - "UnionC", - "<[", - "LiteralC", - "<\"*\">, ", + "<{ id: ", "StringC", - "]>; transactionName: ", - "UnionC", - "<[", - "LiteralC", + "; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"GET /api/observability/slos\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /api/observability/slos\", ", + "PartialC", + "<{ query: ", + "PartialC", + "<{ name: ", + "StringC", + "; indicatorTypes: ", + "Type", + "; page: ", + "StringC", + "; perPage: ", + "StringC", + "; sortBy: ", + "UnionC", + "<[", + "LiteralC", + "<\"name\">, ", + "LiteralC", + "<\"indicatorType\">]>; sortDirection: ", + "UnionC", + "<[", + "LiteralC", + "<\"asc\">, ", + "LiteralC", + "<\"desc\">]>; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { page: number; perPage: number; total: number; results: ({ id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; })[]; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"DELETE /api/observability/slos/{id}\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"DELETE /api/observability/slos/{id}\", ", + "TypeC", + "<{ path: ", + "TypeC", + "<{ id: ", + "StringC", + "; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", void, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"POST /api/observability/slos\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"POST /api/observability/slos\", ", + "TypeC", + "<{ body: ", + "IntersectionC", + "<[", + "TypeC", + "<{ name: ", + "StringC", + "; description: ", + "StringC", + "; indicator: ", + "UnionC", + "<[", + "TypeC", + "<{ type: ", + "LiteralC", + "<\"sli.apm.transactionDuration\">; params: ", + "IntersectionC", + "<[", + "TypeC", + "<{ environment: ", + "UnionC", + "<[", + "LiteralC", + "<\"*\">, ", + "StringC", + "]>; service: ", + "UnionC", + "<[", + "LiteralC", + "<\"*\">, ", + "StringC", + "]>; transactionType: ", + "UnionC", + "<[", + "LiteralC", + "<\"*\">, ", + "StringC", + "]>; transactionName: ", + "UnionC", + "<[", + "LiteralC", "<\"*\">, ", "StringC", "]>; 'threshold.us': ", @@ -10263,115 +10430,7 @@ "label": "ObservabilityServerRouteRepository", "description": [], "signature": [ - "{ \"GET /api/observability/slos\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"GET /api/observability/slos\", ", - "PartialC", - "<{ query: ", - "PartialC", - "<{ name: ", - "StringC", - "; indicatorTypes: ", - "Type", - "; page: ", - "StringC", - "; perPage: ", - "StringC", - "; sortBy: ", - "UnionC", - "<[", - "LiteralC", - "<\"name\">, ", - "LiteralC", - "<\"indicatorType\">]>; sortDirection: ", - "UnionC", - "<[", - "LiteralC", - "<\"asc\">, ", - "LiteralC", - "<\"desc\">]>; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", { page: number; perPage: number; total: number; results: ({ id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; })[]; }, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"DELETE /api/observability/slos/{id}\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"DELETE /api/observability/slos/{id}\", ", - "TypeC", - "<{ path: ", - "TypeC", - "<{ id: ", - "StringC", - "; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", void, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"GET /api/observability/slos/{id}\"?: ", - { - "pluginId": "@kbn/server-route-repository", - "scope": "public", - "docId": "kibKbnServerRouteRepositoryPluginApi", - "section": "def-public.ServerRoute", - "text": "ServerRoute" - }, - "<\"GET /api/observability/slos/{id}\", ", - "TypeC", - "<{ path: ", - "TypeC", - "<{ id: ", - "StringC", - "; }>; }>, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteHandlerResources", - "text": "ObservabilityRouteHandlerResources" - }, - ", { id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; }, ", - { - "pluginId": "observability", - "scope": "server", - "docId": "kibObservabilityPluginApi", - "section": "def-server.ObservabilityRouteCreateOptions", - "text": "ObservabilityRouteCreateOptions" - }, - "> | undefined; \"PUT /api/observability/slos/{id}\"?: ", + "{ \"PUT /api/observability/slos/{id}\"?: ", { "pluginId": "@kbn/server-route-repository", "scope": "public", @@ -10591,6 +10650,146 @@ "section": "def-server.ObservabilityRouteCreateOptions", "text": "ObservabilityRouteCreateOptions" }, + "> | undefined; \"POST /internal/observability/slos/_historical_summary\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"POST /internal/observability/slos/_historical_summary\", ", + "TypeC", + "<{ body: ", + "TypeC", + "<{ sloIds: ", + "ArrayC", + "<", + "StringC", + ">; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { [x: string]: { date: string; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; sliValue: number; status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; }[]; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"GET /api/observability/slos/{id}\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /api/observability/slos/{id}\", ", + "TypeC", + "<{ path: ", + "TypeC", + "<{ id: ", + "StringC", + "; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"GET /api/observability/slos\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"GET /api/observability/slos\", ", + "PartialC", + "<{ query: ", + "PartialC", + "<{ name: ", + "StringC", + "; indicatorTypes: ", + "Type", + "; page: ", + "StringC", + "; perPage: ", + "StringC", + "; sortBy: ", + "UnionC", + "<[", + "LiteralC", + "<\"name\">, ", + "LiteralC", + "<\"indicatorType\">]>; sortDirection: ", + "UnionC", + "<[", + "LiteralC", + "<\"asc\">, ", + "LiteralC", + "<\"desc\">]>; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", { page: number; perPage: number; total: number; results: ({ id: string; name: string; description: string; indicator: { type: \"sli.apm.transactionDuration\"; params: { environment: string; service: string; transactionType: string; transactionName: string; 'threshold.us': number; } & { index?: string | undefined; }; } | { type: \"sli.apm.transactionErrorRate\"; params: { environment: string; service: string; transactionType: string; transactionName: string; } & { goodStatusCodes?: (\"2xx\" | \"3xx\" | \"4xx\" | \"5xx\")[] | undefined; index?: string | undefined; }; } | { type: \"sli.kql.custom\"; params: { index: string; filter: string; good: string; total: string; }; }; timeWindow: { duration: string; isRolling: boolean; } | { duration: string; calendar: { startTime: string; }; }; budgetingMethod: \"occurrences\" | \"timeslices\"; objective: { target: number; } & { timesliceTarget?: number | undefined; timesliceWindow?: string | undefined; }; revision: number; settings: { timestampField: string; syncDelay: string; frequency: string; }; createdAt: string; updatedAt: string; } & { summary: { status: \"NO_DATA\" | \"HEALTHY\" | \"DEGRADING\" | \"VIOLATED\"; sliValue: number; errorBudget: { initial: number; consumed: number; remaining: number; isEstimated: boolean; }; }; })[]; }, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, + "> | undefined; \"DELETE /api/observability/slos/{id}\"?: ", + { + "pluginId": "@kbn/server-route-repository", + "scope": "public", + "docId": "kibKbnServerRouteRepositoryPluginApi", + "section": "def-public.ServerRoute", + "text": "ServerRoute" + }, + "<\"DELETE /api/observability/slos/{id}\", ", + "TypeC", + "<{ path: ", + "TypeC", + "<{ id: ", + "StringC", + "; }>; }>, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteHandlerResources", + "text": "ObservabilityRouteHandlerResources" + }, + ", void, ", + { + "pluginId": "observability", + "scope": "server", + "docId": "kibObservabilityPluginApi", + "section": "def-server.ObservabilityRouteCreateOptions", + "text": "ObservabilityRouteCreateOptions" + }, "> | undefined; \"POST /api/observability/slos\"?: ", { "pluginId": "@kbn/server-route-repository", diff --git a/api_docs/observability.mdx b/api_docs/observability.mdx index 4ef8210200fd0..8d3b351cc81d9 100644 --- a/api_docs/observability.mdx +++ b/api_docs/observability.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/observability title: "observability" image: https://source.unsplash.com/400x175/?github description: API docs for the observability plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'observability'] --- import observabilityObj from './observability.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Observability UI](https://github.com/orgs/elastic/teams/observability-u | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 597 | 41 | 592 | 31 | +| 605 | 41 | 599 | 32 | ## Client diff --git a/api_docs/osquery.mdx b/api_docs/osquery.mdx index 5a669d9a70758..b8b6553813101 100644 --- a/api_docs/osquery.mdx +++ b/api_docs/osquery.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/osquery title: "osquery" image: https://source.unsplash.com/400x175/?github description: API docs for the osquery plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'osquery'] --- import osqueryObj from './osquery.devdocs.json'; diff --git a/api_docs/plugin_directory.mdx b/api_docs/plugin_directory.mdx index fbdf7597026ef..52b572450a0e0 100644 --- a/api_docs/plugin_directory.mdx +++ b/api_docs/plugin_directory.mdx @@ -7,7 +7,7 @@ id: kibDevDocsPluginDirectory slug: /kibana-dev-docs/api-meta/plugin-api-directory title: Directory description: Directory of public APIs available through plugins or packages. -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana'] --- @@ -15,13 +15,13 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | Count | Plugins or Packages with a
public API | Number of teams | |--------------|----------|------------------------| -| 559 | 461 | 42 | +| 561 | 463 | 42 | ### Public API health stats | API Count | Any Count | Missing comments | Missing exports | |--------------|----------|-----------------|--------| -| 34354 | 526 | 24000 | 1191 | +| 34429 | 526 | 24089 | 1200 | ## Plugin Directory @@ -30,16 +30,16 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 220 | 8 | 215 | 24 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 36 | 1 | 32 | 2 | | | [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) | AIOps plugin maintained by ML team. | 12 | 0 | 1 | 2 | -| | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 434 | 0 | 425 | 37 | -| | [APM UI](https://github.com/orgs/elastic/teams/apm-ui) | The user interface for Elastic APM | 42 | 0 | 42 | 59 | +| | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 465 | 0 | 456 | 38 | +| | [APM UI](https://github.com/orgs/elastic/teams/apm-ui) | The user interface for Elastic APM | 42 | 0 | 42 | 61 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 9 | 0 | 9 | 0 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Considering using bfetch capabilities when fetching large amounts of data. This services supports batching HTTP requests and streaming responses back. | 89 | 1 | 74 | 2 | | | [Kibana Presentation](https://github.com/orgs/elastic/teams/kibana-presentation) | Adds Canvas application to Kibana | 9 | 0 | 8 | 3 | | | [ResponseOps](https://github.com/orgs/elastic/teams/response-ops) | The Case management system in Kibana | 87 | 0 | 71 | 28 | | | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualizations) | - | 267 | 16 | 252 | 9 | -| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 39 | 0 | 11 | 0 | +| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 41 | 0 | 11 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | Chat available on Elastic Cloud deployments for quicker assistance. | 1 | 0 | 0 | 0 | -| | [Platform Onboarding](https://github.com/orgs/elastic/teams/platform-onboarding) | Static migration page where self-managed users can see text/copy about migrating to Elastic Cloud | 7 | 1 | 7 | 1 | +| | [Platform Onboarding](https://github.com/orgs/elastic/teams/platform-onboarding) | Static migration page where self-managed users can see text/copy about migrating to Elastic Cloud | 8 | 1 | 8 | 1 | | | [Cloud Native Integrations](https://github.com/orgs/elastic/teams/sec-cloudnative-integrations) | Defend for Containers | 2 | 0 | 2 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/@elastic/kibana-core) | Provides the necessary APIs to implement A/B testing scenarios, fetching the variations in configuration and reporting back metrics to track conversion rates of the experiments. | 12 | 0 | 0 | 0 | | cloudFullStory | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | When Kibana runs on Elastic Cloud, this plugin registers FullStory as a shipper for telemetry. | 0 | 0 | 0 | 0 | @@ -48,22 +48,22 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Cloud Security Posture](https://github.com/orgs/elastic/teams/cloud-posture-security) | The cloud security posture plugin | 17 | 0 | 2 | 2 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 13 | 0 | 13 | 1 | | | [Kibana Presentation](https://github.com/orgs/elastic/teams/kibana-presentation) | The Controls Plugin contains embeddable components intended to create a simple query interface for end users, and a powerful editing suite that allows dashboard authors to build controls | 264 | 0 | 260 | 9 | -| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 2823 | 17 | 1019 | 0 | +| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 2806 | 17 | 1017 | 0 | | crossClusterReplication | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 0 | 0 | 0 | 0 | | customBranding | [global-experience](https://github.com/orgs/elastic/teams/kibana-global-experience) | Enables customization of Kibana | 0 | 0 | 0 | 0 | | | [Fleet](https://github.com/orgs/elastic/teams/fleet) | Add custom data integrations so they can be displayed in the Fleet integrations app | 107 | 0 | 88 | 1 | | | [Kibana Presentation](https://github.com/orgs/elastic/teams/kibana-presentation) | Adds the Dashboard app to Kibana | 113 | 0 | 109 | 2 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | - | 54 | 0 | 51 | 0 | -| | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | Data services are useful for searching and querying data from Elasticsearch. Helpful utilities include: a re-usable react query bar, KQL autocomplete, async search, Data Views (Index Patterns) and field formatters. | 3300 | 119 | 2578 | 27 | +| | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | Data services are useful for searching and querying data from Elasticsearch. Helpful utilities include: a re-usable react query bar, KQL autocomplete, async search, Data Views (Index Patterns) and field formatters. | 3276 | 119 | 2578 | 27 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | This plugin provides the ability to create data views via a modal flyout inside Kibana apps | 16 | 0 | 7 | 0 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Reusable data view field editor across Kibana | 72 | 0 | 33 | 0 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Data view management app | 2 | 0 | 2 | 0 | -| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Data services are useful for searching and querying data from Elasticsearch. Helpful utilities include: a re-usable react query bar, KQL autocomplete, async search, Data Views (Index Patterns) and field formatters. | 1032 | 0 | 231 | 2 | +| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Data services are useful for searching and querying data from Elasticsearch. Helpful utilities include: a re-usable react query bar, KQL autocomplete, async search, Data Views (Index Patterns) and field formatters. | 1020 | 0 | 231 | 2 | | | [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) | The Data Visualizer tools help you understand your data, by analyzing the metrics and fields in a log file or an existing Elasticsearch index. | 28 | 3 | 24 | 1 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 10 | 0 | 8 | 2 | | | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | This plugin contains the Discover application and the saved search embeddable. | 107 | 0 | 88 | 7 | | | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | - | 37 | 0 | 35 | 2 | -| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds embeddables service to Kibana | 524 | 8 | 423 | 4 | +| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds embeddables service to Kibana | 522 | 8 | 421 | 4 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Extends embeddable plugin with more functionality | 14 | 0 | 14 | 0 | | | [Platform Security](https://github.com/orgs/elastic/teams/kibana-security) | This plugin provides encryption and decryption utilities for saved objects containing sensitive information. | 51 | 0 | 44 | 0 | | | [Enterprise Search](https://github.com/orgs/elastic/teams/enterprise-search-frontend) | Adds dashboards for discovering and managing Enterprise Search products. | 9 | 0 | 9 | 0 | @@ -84,20 +84,20 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualizations) | Expression Tagcloud plugin adds a `tagcloud` renderer and function to the expression plugin. The renderer will display the `Wordcloud` chart. | 7 | 0 | 7 | 0 | | | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualizations) | Expression XY plugin adds a `xy` renderer and function to the expression plugin. The renderer will display the `xy` chart. | 170 | 0 | 160 | 13 | | | [Visualizations](https://github.com/orgs/elastic/teams/kibana-visualizations) | Adds expression runtime to Kibana | 2205 | 74 | 1746 | 5 | -| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 227 | 0 | 96 | 2 | +| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 236 | 0 | 100 | 2 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Index pattern fields and ambiguous values formatters | 288 | 26 | 249 | 3 | | | [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) | The file upload plugin contains components and services for uploading a file, analyzing its data, and then importing the data into an Elasticsearch index. Supported file types include CSV, TSV, newline-delimited JSON and GeoJSON. | 62 | 0 | 62 | 2 | | | [@elastic/kibana-app-services](https://github.com/orgs/elastic/teams/team:AppServicesUx) | File upload, download, sharing, and serving over HTTP implementation in Kibana. | 254 | 1 | 45 | 5 | -| | [@elastic/kibana-global-experience](https://github.com/orgs/elastic/teams/@elastic/kibana-global-experience) | Simple UI for managing files in Kibana | 2 | 1 | 2 | 0 | -| | [Fleet](https://github.com/orgs/elastic/teams/fleet) | - | 1036 | 3 | 931 | 23 | +| | [@elastic/appex-sharedux](https://github.com/orgs/elastic/teams/@elastic/appex-sharedux) | Simple UI for managing files in Kibana | 2 | 1 | 2 | 0 | +| | [Fleet](https://github.com/orgs/elastic/teams/fleet) | - | 1039 | 3 | 934 | 24 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 68 | 0 | 14 | 5 | | globalSearchBar | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 0 | 0 | 0 | 0 | | globalSearchProviders | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 0 | 0 | 0 | 0 | | graph | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | - | 0 | 0 | 0 | 0 | | grokdebugger | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 0 | 0 | 0 | 0 | -| | [Journey Onboarding](https://github.com/orgs/elastic/teams/platform-onboarding) | Guided onboarding framework | 103 | 0 | 102 | 0 | +| | [Journey Onboarding](https://github.com/orgs/elastic/teams/platform-onboarding) | Guided onboarding framework | 56 | 0 | 55 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 143 | 0 | 104 | 0 | -| | [@elastic/kibana-global-experience](https://github.com/orgs/elastic/teams/@elastic/kibana-global-experience) | Image embeddable | 3 | 0 | 3 | 1 | +| | [@elastic/appex-sharedux](https://github.com/orgs/elastic/teams/@elastic/appex-sharedux) | Image embeddable | 3 | 0 | 3 | 1 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 4 | 0 | 4 | 0 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 177 | 0 | 172 | 3 | | | [Logs and Metrics UI](https://github.com/orgs/elastic/teams/logs-metrics-ui) | This plugin visualizes data from Filebeat and Metricbeat, and integrates with other Observability solutions | 42 | 0 | 39 | 8 | @@ -110,7 +110,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | kibanaUsageCollection | [Kibana Telemetry](https://github.com/orgs/elastic/teams/kibana-telemetry) | - | 0 | 0 | 0 | 0 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | - | 609 | 3 | 416 | 9 | | | [Security Team](https://github.com/orgs/elastic/teams/security-team) | - | 3 | 0 | 3 | 1 | -| | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualizations) | Visualization editor allowing to quickly and easily configure compelling visualizations to use on dashboards and canvas workpads. Exposes components to embed visualizations and link into the Lens editor from within other apps in Kibana. | 695 | 0 | 599 | 50 | +| | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-visualizations) | Visualization editor allowing to quickly and easily configure compelling visualizations to use on dashboards and canvas workpads. Exposes components to embed visualizations and link into the Lens editor from within other apps in Kibana. | 698 | 0 | 602 | 50 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 8 | 0 | 8 | 0 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 3 | 0 | 3 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 117 | 0 | 42 | 10 | @@ -125,7 +125,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | - | 34 | 0 | 34 | 2 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 17 | 0 | 17 | 0 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | - | 2 | 0 | 2 | 1 | -| | [Observability UI](https://github.com/orgs/elastic/teams/observability-ui) | - | 597 | 41 | 592 | 31 | +| | [Observability UI](https://github.com/orgs/elastic/teams/observability-ui) | - | 605 | 41 | 599 | 32 | | | [Security asset management](https://github.com/orgs/elastic/teams/security-asset-management) | - | 24 | 0 | 24 | 7 | | painlessLab | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 0 | 0 | 0 | 0 | | | [Kibana Presentation](https://github.com/orgs/elastic/teams/kibana-presentation) | The Presentation Utility Plugin is a set of common, shared components and toolkits for solutions within the Presentation space, (e.g. Dashboards, Canvas). | 217 | 7 | 161 | 11 | @@ -135,7 +135,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 21 | 0 | 21 | 0 | | | [RAC](https://github.com/orgs/elastic/teams/rac) | - | 241 | 0 | 213 | 10 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | - | 24 | 0 | 19 | 2 | -| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 197 | 2 | 156 | 5 | +| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 196 | 2 | 155 | 5 | | | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | - | 16 | 0 | 16 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 130 | 0 | 117 | 0 | | | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 79 | 0 | 73 | 3 | @@ -145,9 +145,9 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Kibana Reporting Services](https://github.com/orgs/elastic/teams/kibana-reporting-services) | Kibana Screenshotting Plugin | 27 | 0 | 8 | 4 | | searchprofiler | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 0 | 0 | 0 | 0 | | | [Platform Security](https://github.com/orgs/elastic/teams/kibana-security) | This plugin provides authentication and authorization features, and exposes functionality to understand the capabilities of the currently authenticated user. | 269 | 0 | 89 | 0 | -| | [Security solution](https://github.com/orgs/elastic/teams/security-solution) | - | 113 | 0 | 76 | 29 | +| | [Security solution](https://github.com/orgs/elastic/teams/security-solution) | - | 113 | 0 | 73 | 28 | | | [Security Team](https://github.com/orgs/elastic/teams/security-team) | - | 7 | 0 | 7 | 1 | -| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds URL Service and sharing capabilities to Kibana | 115 | 0 | 56 | 10 | +| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds URL Service and sharing capabilities to Kibana | 118 | 0 | 59 | 10 | | | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 22 | 1 | 22 | 1 | | | [Platform Security](https://github.com/orgs/elastic/teams/kibana-security) | This plugin provides the Spaces feature, which allows saved objects to be organized into meaningful categories. | 260 | 0 | 64 | 0 | | | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 12 | 0 | 12 | 2 | @@ -158,15 +158,15 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Kibana Telemetry](https://github.com/orgs/elastic/teams/kibana-telemetry) | - | 31 | 0 | 26 | 6 | | | [Kibana Telemetry](https://github.com/orgs/elastic/teams/kibana-telemetry) | - | 1 | 0 | 1 | 0 | | | [Kibana Telemetry](https://github.com/orgs/elastic/teams/kibana-telemetry) | - | 5 | 0 | 0 | 0 | -| | [Protections Experience Team](https://github.com/orgs/elastic/teams/protections-experience) | Elastic threat intelligence helps you see if you are open to or have been subject to current or historical known threats | 34 | 0 | 14 | 3 | +| | [Protections Experience Team](https://github.com/orgs/elastic/teams/protections-experience) | Elastic threat intelligence helps you see if you are open to or have been subject to current or historical known threats | 35 | 0 | 15 | 5 | | | [Security solution](https://github.com/orgs/elastic/teams/security-solution) | - | 257 | 1 | 214 | 21 | | | [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) | This plugin provides access to the transforms features provided by Elastic. Transforms enable you to convert existing Elasticsearch indices into summarized indices, which provide opportunities for new insights and analytics. | 4 | 0 | 4 | 1 | | translations | [Kibana Localization](https://github.com/orgs/elastic/teams/kibana-localization) | - | 0 | 0 | 0 | 0 | -| | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 579 | 11 | 550 | 53 | -| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds UI Actions service to Kibana | 144 | 2 | 99 | 12 | +| | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 586 | 11 | 557 | 53 | +| | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds UI Actions service to Kibana | 144 | 2 | 99 | 11 | | | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Extends UI Actions plugin with more functionality | 206 | 0 | 140 | 9 | | | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | Contains functionality for the field list which can be integrated into apps | 270 | 0 | 245 | 7 | -| | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | The `unifiedHistogram` plugin provides UI components to create a layout including a resizable histogram and a main display. | 52 | 0 | 15 | 0 | +| | [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-discovery) | The `unifiedHistogram` plugin provides UI components to create a layout including a resizable histogram and a main display. | 63 | 0 | 16 | 1 | | | [Visualizations](https://github.com/orgs/elastic/teams/kibana-visualizations) | Contains all the key functionality of Kibana's unified search experience.Contains all the key functionality of Kibana's unified search experience. | 134 | 2 | 99 | 20 | | upgradeAssistant | [Stack Management](https://github.com/orgs/elastic/teams/kibana-stack-management) | - | 0 | 0 | 0 | 0 | | urlDrilldown | [App Services](https://github.com/orgs/elastic/teams/kibana-app-services) | Adds drilldown implementations to Kibana | 0 | 0 | 0 | 0 | @@ -209,7 +209,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Owner missing] | Elastic APM trace data generator | 152 | 0 | 152 | 16 | | | [Owner missing] | - | 11 | 0 | 11 | 0 | | | [Owner missing] | - | 10 | 0 | 10 | 0 | -| | [Owner missing] | - | 4 | 0 | 3 | 0 | +| | [Owner missing] | - | 19 | 0 | 17 | 0 | +| | [Owner missing] | Uniform components for displaying UI actions in data cells | 15 | 0 | 12 | 3 | | | [Owner missing] | - | 76 | 0 | 76 | 0 | | | [Owner missing] | - | 7 | 0 | 2 | 0 | | | [Owner missing] | - | 3 | 0 | 3 | 0 | @@ -242,7 +243,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | Kibana Core | - | 5 | 0 | 0 | 0 | | | Kibana Core | - | 16 | 0 | 7 | 0 | | | Kibana Core | - | 6 | 0 | 6 | 0 | -| | Kibana Core | - | 119 | 0 | 46 | 0 | +| | Kibana Core | - | 120 | 0 | 46 | 0 | | | Kibana Core | - | 3 | 0 | 3 | 0 | | | Kibana Core | - | 4 | 0 | 4 | 0 | | | [Owner missing] | - | 8 | 0 | 8 | 0 | @@ -344,12 +345,12 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | Kibana Core | - | 2 | 0 | 1 | 0 | | | Kibana Core | - | 6 | 0 | 6 | 0 | | | Kibana Core | - | 7 | 0 | 7 | 0 | -| | Kibana Core | - | 83 | 0 | 39 | 0 | +| | Kibana Core | - | 67 | 0 | 39 | 0 | | | Kibana Core | - | 25 | 0 | 23 | 0 | | | Kibana Core | - | 4 | 0 | 4 | 0 | | | Kibana Core | - | 112 | 0 | 79 | 45 | | | Kibana Core | - | 12 | 0 | 12 | 0 | -| | Kibana Core | - | 306 | 0 | 92 | 1 | +| | Kibana Core | - | 325 | 0 | 95 | 1 | | | Kibana Core | - | 69 | 0 | 69 | 4 | | | Kibana Core | - | 14 | 0 | 14 | 0 | | | Kibana Core | - | 108 | 1 | 84 | 0 | @@ -391,7 +392,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Owner missing] | - | 4 | 0 | 4 | 0 | | | [Owner missing] | - | 27 | 0 | 14 | 1 | | | Kibana Core | - | 7 | 0 | 3 | 0 | -| | [Owner missing] | - | 244 | 2 | 187 | 13 | +| | [Owner missing] | - | 250 | 2 | 192 | 13 | | | Kibana Core | - | 11 | 0 | 11 | 0 | | | [Owner missing] | - | 2 | 0 | 1 | 0 | | | [Owner missing] | - | 20 | 0 | 16 | 0 | @@ -399,7 +400,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Owner missing] | - | 29 | 0 | 29 | 1 | | | [Owner missing] | - | 1 | 0 | 0 | 0 | | | [Owner missing] | - | 6 | 0 | 0 | 0 | -| | [Owner missing] | - | 23 | 0 | 21 | 1 | +| | [Owner missing] | - | 58 | 0 | 56 | 1 | | | [Owner missing] | - | 19 | 1 | 12 | 0 | | | [Owner missing] | - | 3 | 0 | 3 | 0 | | | Kibana Core | - | 1 | 0 | 1 | 0 | @@ -497,7 +498,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Owner missing] | - | 2 | 0 | 0 | 0 | | | [Owner missing] | - | 15 | 0 | 4 | 0 | | | [Owner missing] | - | 9 | 0 | 3 | 0 | -| | [Owner missing] | SLO io-ts schema definition and common models shared between public and server. | 67 | 0 | 67 | 0 | +| | [Owner missing] | SLO io-ts schema definition and common models shared between public and server. | 72 | 0 | 72 | 0 | | | [Owner missing] | - | 20 | 0 | 12 | 0 | | | Kibana Core | - | 97 | 1 | 64 | 1 | | | [Owner missing] | - | 4 | 0 | 2 | 0 | @@ -509,7 +510,8 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana'] | | [Owner missing] | - | 72 | 0 | 55 | 0 | | | [Owner missing] | - | 39 | 0 | 26 | 1 | | | [Owner missing] | - | 83 | 0 | 83 | 1 | -| | [Owner missing] | - | 44 | 0 | 35 | 0 | +| | [Owner missing] | - | 18 | 0 | 8 | 0 | +| | [Owner missing] | - | 45 | 0 | 36 | 0 | | | [Owner missing] | - | 7 | 0 | 6 | 0 | | | [Owner missing] | - | 58 | 0 | 5 | 0 | | | [Owner missing] | - | 34 | 0 | 14 | 1 | diff --git a/api_docs/presentation_util.mdx b/api_docs/presentation_util.mdx index a3f8bc3c01fd1..26e7e1c57f347 100644 --- a/api_docs/presentation_util.mdx +++ b/api_docs/presentation_util.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/presentationUtil title: "presentationUtil" image: https://source.unsplash.com/400x175/?github description: API docs for the presentationUtil plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'presentationUtil'] --- import presentationUtilObj from './presentation_util.devdocs.json'; diff --git a/api_docs/profiling.mdx b/api_docs/profiling.mdx index 559faae0ac435..90201aa39ea32 100644 --- a/api_docs/profiling.mdx +++ b/api_docs/profiling.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/profiling title: "profiling" image: https://source.unsplash.com/400x175/?github description: API docs for the profiling plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'profiling'] --- import profilingObj from './profiling.devdocs.json'; diff --git a/api_docs/remote_clusters.mdx b/api_docs/remote_clusters.mdx index e28f623a9c8d5..a6124e49fcec0 100644 --- a/api_docs/remote_clusters.mdx +++ b/api_docs/remote_clusters.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/remoteClusters title: "remoteClusters" image: https://source.unsplash.com/400x175/?github description: API docs for the remoteClusters plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'remoteClusters'] --- import remoteClustersObj from './remote_clusters.devdocs.json'; diff --git a/api_docs/reporting.mdx b/api_docs/reporting.mdx index 62aea27ba58e5..6816029fa7124 100644 --- a/api_docs/reporting.mdx +++ b/api_docs/reporting.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/reporting title: "reporting" image: https://source.unsplash.com/400x175/?github description: API docs for the reporting plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'reporting'] --- import reportingObj from './reporting.devdocs.json'; diff --git a/api_docs/rollup.mdx b/api_docs/rollup.mdx index 6c1bb0516d713..4a0fe211a6884 100644 --- a/api_docs/rollup.mdx +++ b/api_docs/rollup.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/rollup title: "rollup" image: https://source.unsplash.com/400x175/?github description: API docs for the rollup plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'rollup'] --- import rollupObj from './rollup.devdocs.json'; diff --git a/api_docs/rule_registry.devdocs.json b/api_docs/rule_registry.devdocs.json index 6e833df7641ed..cc9725bb52f3d 100644 --- a/api_docs/rule_registry.devdocs.json +++ b/api_docs/rule_registry.devdocs.json @@ -3174,7 +3174,7 @@ "description": [], "signature": [ "(T & ", - "CommonAlertFields800", + "CommonAlertFields870", " & { _id: string; _index: string; })[]" ], "path": "x-pack/plugins/rule_registry/server/utils/persistence_types.ts", diff --git a/api_docs/rule_registry.mdx b/api_docs/rule_registry.mdx index 66718bab2f614..cd5bb058babca 100644 --- a/api_docs/rule_registry.mdx +++ b/api_docs/rule_registry.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/ruleRegistry title: "ruleRegistry" image: https://source.unsplash.com/400x175/?github description: API docs for the ruleRegistry plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'ruleRegistry'] --- import ruleRegistryObj from './rule_registry.devdocs.json'; diff --git a/api_docs/runtime_fields.mdx b/api_docs/runtime_fields.mdx index 4ed481e35bdf2..9e4c1c5da5b86 100644 --- a/api_docs/runtime_fields.mdx +++ b/api_docs/runtime_fields.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/runtimeFields title: "runtimeFields" image: https://source.unsplash.com/400x175/?github description: API docs for the runtimeFields plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'runtimeFields'] --- import runtimeFieldsObj from './runtime_fields.devdocs.json'; diff --git a/api_docs/saved_objects.devdocs.json b/api_docs/saved_objects.devdocs.json index 2796fdc987cdc..6a616ff9a150a 100644 --- a/api_docs/saved_objects.devdocs.json +++ b/api_docs/saved_objects.devdocs.json @@ -1280,7 +1280,7 @@ "label": "showSaveModal", "description": [], "signature": [ - "(saveModal: React.ReactElement>, I18nContext: ({ children }: { children: React.ReactNode; }) => JSX.Element, Wrapper: React.FC<{}> | undefined) => void" + "(saveModal: React.ReactElement>, Wrapper: React.FC<{}> | undefined) => void" ], "path": "src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx", "deprecated": false, @@ -1306,21 +1306,6 @@ "id": "def-public.showSaveModal.$2", "type": "Function", "tags": [], - "label": "I18nContext", - "description": [], - "signature": [ - "({ children }: { children: React.ReactNode; }) => JSX.Element" - ], - "path": "src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - }, - { - "parentPluginId": "savedObjects", - "id": "def-public.showSaveModal.$3", - "type": "Function", - "tags": [], "label": "Wrapper", "description": [], "signature": [ diff --git a/api_docs/saved_objects.mdx b/api_docs/saved_objects.mdx index 13abe7a2a1e96..e51aa85cd0f3e 100644 --- a/api_docs/saved_objects.mdx +++ b/api_docs/saved_objects.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedObjects title: "savedObjects" image: https://source.unsplash.com/400x175/?github description: API docs for the savedObjects plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjects'] --- import savedObjectsObj from './saved_objects.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) for que | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 197 | 2 | 156 | 5 | +| 196 | 2 | 155 | 5 | ## Client diff --git a/api_docs/saved_objects_finder.mdx b/api_docs/saved_objects_finder.mdx index c6e1655f619b7..c187fc74f315e 100644 --- a/api_docs/saved_objects_finder.mdx +++ b/api_docs/saved_objects_finder.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedObjectsFinder title: "savedObjectsFinder" image: https://source.unsplash.com/400x175/?github description: API docs for the savedObjectsFinder plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjectsFinder'] --- import savedObjectsFinderObj from './saved_objects_finder.devdocs.json'; diff --git a/api_docs/saved_objects_management.devdocs.json b/api_docs/saved_objects_management.devdocs.json index 79c0a5fb5865f..022f4de195bcc 100644 --- a/api_docs/saved_objects_management.devdocs.json +++ b/api_docs/saved_objects_management.devdocs.json @@ -310,7 +310,7 @@ "section": "def-public.SavedObjectsManagementRecord", "text": "SavedObjectsManagementRecord" }, - "; headers?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"url\" | \"tel\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", + "; headers?: string | undefined; defaultValue?: string | number | readonly string[] | undefined; lang?: string | undefined; defaultChecked?: boolean | undefined; suppressContentEditableWarning?: boolean | undefined; suppressHydrationWarning?: boolean | undefined; accessKey?: string | undefined; contentEditable?: \"inherit\" | Booleanish | undefined; contextMenu?: string | undefined; dir?: string | undefined; draggable?: Booleanish | undefined; placeholder?: string | undefined; slot?: string | undefined; spellCheck?: Booleanish | undefined; style?: React.CSSProperties | undefined; tabIndex?: number | undefined; translate?: \"no\" | \"yes\" | undefined; radioGroup?: string | undefined; role?: React.AriaRole | undefined; about?: string | undefined; datatype?: string | undefined; inlist?: any; prefix?: string | undefined; property?: string | undefined; resource?: string | undefined; typeof?: string | undefined; vocab?: string | undefined; autoCapitalize?: string | undefined; autoCorrect?: string | undefined; autoSave?: string | undefined; itemProp?: string | undefined; itemScope?: boolean | undefined; itemType?: string | undefined; itemID?: string | undefined; itemRef?: string | undefined; results?: number | undefined; unselectable?: \"on\" | \"off\" | undefined; inputMode?: \"none\" | \"email\" | \"search\" | \"text\" | \"tel\" | \"url\" | \"numeric\" | \"decimal\" | undefined; is?: string | undefined; 'aria-activedescendant'?: string | undefined; 'aria-atomic'?: Booleanish | undefined; 'aria-autocomplete'?: \"none\" | \"list\" | \"inline\" | \"both\" | undefined; 'aria-busy'?: Booleanish | undefined; 'aria-checked'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-colcount'?: number | undefined; 'aria-colindex'?: number | undefined; 'aria-colspan'?: number | undefined; 'aria-controls'?: string | undefined; 'aria-current'?: boolean | \"date\" | \"location\" | \"time\" | \"page\" | \"false\" | \"true\" | \"step\" | undefined; 'aria-describedby'?: string | undefined; 'aria-details'?: string | undefined; 'aria-disabled'?: Booleanish | undefined; 'aria-dropeffect'?: \"none\" | \"copy\" | \"link\" | \"execute\" | \"move\" | \"popup\" | undefined; 'aria-errormessage'?: string | undefined; 'aria-expanded'?: Booleanish | undefined; 'aria-flowto'?: string | undefined; 'aria-grabbed'?: Booleanish | undefined; 'aria-haspopup'?: boolean | \"grid\" | \"menu\" | \"false\" | \"true\" | \"dialog\" | \"listbox\" | \"tree\" | undefined; 'aria-hidden'?: Booleanish | undefined; 'aria-invalid'?: boolean | \"false\" | \"true\" | \"grammar\" | \"spelling\" | undefined; 'aria-keyshortcuts'?: string | undefined; 'aria-label'?: string | undefined; 'aria-labelledby'?: string | undefined; 'aria-level'?: number | undefined; 'aria-live'?: \"off\" | \"assertive\" | \"polite\" | undefined; 'aria-modal'?: Booleanish | undefined; 'aria-multiline'?: Booleanish | undefined; 'aria-multiselectable'?: Booleanish | undefined; 'aria-orientation'?: \"horizontal\" | \"vertical\" | undefined; 'aria-owns'?: string | undefined; 'aria-placeholder'?: string | undefined; 'aria-posinset'?: number | undefined; 'aria-pressed'?: boolean | \"mixed\" | \"false\" | \"true\" | undefined; 'aria-readonly'?: Booleanish | undefined; 'aria-relevant'?: \"all\" | \"text\" | \"additions\" | \"additions removals\" | \"additions text\" | \"removals\" | \"removals additions\" | \"removals text\" | \"text additions\" | \"text removals\" | undefined; 'aria-required'?: Booleanish | undefined; 'aria-roledescription'?: string | undefined; 'aria-rowcount'?: number | undefined; 'aria-rowindex'?: number | undefined; 'aria-rowspan'?: number | undefined; 'aria-selected'?: Booleanish | undefined; 'aria-setsize'?: number | undefined; 'aria-sort'?: \"none\" | \"other\" | \"ascending\" | \"descending\" | undefined; 'aria-valuemax'?: number | undefined; 'aria-valuemin'?: number | undefined; 'aria-valuenow'?: number | undefined; 'aria-valuetext'?: string | undefined; dangerouslySetInnerHTML?: { __html: string; } | undefined; onCopy?: React.ClipboardEventHandler | undefined; onCopyCapture?: React.ClipboardEventHandler | undefined; onCut?: React.ClipboardEventHandler | undefined; onCutCapture?: React.ClipboardEventHandler | undefined; onPaste?: React.ClipboardEventHandler | undefined; onPasteCapture?: React.ClipboardEventHandler | undefined; onCompositionEnd?: React.CompositionEventHandler | undefined; onCompositionEndCapture?: React.CompositionEventHandler | undefined; onCompositionStart?: React.CompositionEventHandler | undefined; onCompositionStartCapture?: React.CompositionEventHandler | undefined; onCompositionUpdate?: React.CompositionEventHandler | undefined; onCompositionUpdateCapture?: React.CompositionEventHandler | undefined; onFocus?: React.FocusEventHandler | undefined; onFocusCapture?: React.FocusEventHandler | undefined; onBlur?: React.FocusEventHandler | undefined; onBlurCapture?: React.FocusEventHandler | undefined; onChangeCapture?: React.FormEventHandler | undefined; onBeforeInput?: React.FormEventHandler | undefined; onBeforeInputCapture?: React.FormEventHandler | undefined; onInput?: React.FormEventHandler | undefined; onInputCapture?: React.FormEventHandler | undefined; onReset?: React.FormEventHandler | undefined; onResetCapture?: React.FormEventHandler | undefined; onSubmit?: React.FormEventHandler | undefined; onSubmitCapture?: React.FormEventHandler | undefined; onInvalid?: React.FormEventHandler | undefined; onInvalidCapture?: React.FormEventHandler | undefined; onLoad?: React.ReactEventHandler | undefined; onLoadCapture?: React.ReactEventHandler | undefined; onErrorCapture?: React.ReactEventHandler | undefined; onKeyDownCapture?: React.KeyboardEventHandler | undefined; onKeyPress?: React.KeyboardEventHandler | undefined; onKeyPressCapture?: React.KeyboardEventHandler | undefined; onKeyUp?: React.KeyboardEventHandler | undefined; onKeyUpCapture?: React.KeyboardEventHandler | undefined; onAbort?: React.ReactEventHandler | undefined; onAbortCapture?: React.ReactEventHandler | undefined; onCanPlay?: React.ReactEventHandler | undefined; onCanPlayCapture?: React.ReactEventHandler | undefined; onCanPlayThrough?: React.ReactEventHandler | undefined; onCanPlayThroughCapture?: React.ReactEventHandler | undefined; onDurationChange?: React.ReactEventHandler | undefined; onDurationChangeCapture?: React.ReactEventHandler | undefined; onEmptied?: React.ReactEventHandler | undefined; onEmptiedCapture?: React.ReactEventHandler | undefined; onEncrypted?: React.ReactEventHandler | undefined; onEncryptedCapture?: React.ReactEventHandler | undefined; onEnded?: React.ReactEventHandler | undefined; onEndedCapture?: React.ReactEventHandler | undefined; onLoadedData?: React.ReactEventHandler | undefined; onLoadedDataCapture?: React.ReactEventHandler | undefined; onLoadedMetadata?: React.ReactEventHandler | undefined; onLoadedMetadataCapture?: React.ReactEventHandler | undefined; onLoadStart?: React.ReactEventHandler | undefined; onLoadStartCapture?: React.ReactEventHandler | undefined; onPause?: React.ReactEventHandler | undefined; onPauseCapture?: React.ReactEventHandler | undefined; onPlay?: React.ReactEventHandler | undefined; onPlayCapture?: React.ReactEventHandler | undefined; onPlaying?: React.ReactEventHandler | undefined; onPlayingCapture?: React.ReactEventHandler | undefined; onProgress?: React.ReactEventHandler | undefined; onProgressCapture?: React.ReactEventHandler | undefined; onRateChange?: React.ReactEventHandler | undefined; onRateChangeCapture?: React.ReactEventHandler | undefined; onSeeked?: React.ReactEventHandler | undefined; onSeekedCapture?: React.ReactEventHandler | undefined; onSeeking?: React.ReactEventHandler | undefined; onSeekingCapture?: React.ReactEventHandler | undefined; onStalled?: React.ReactEventHandler | undefined; onStalledCapture?: React.ReactEventHandler | undefined; onSuspend?: React.ReactEventHandler | undefined; onSuspendCapture?: React.ReactEventHandler | undefined; onTimeUpdate?: React.ReactEventHandler | undefined; onTimeUpdateCapture?: React.ReactEventHandler | undefined; onVolumeChange?: React.ReactEventHandler | undefined; onVolumeChangeCapture?: React.ReactEventHandler | undefined; onWaiting?: React.ReactEventHandler | undefined; onWaitingCapture?: React.ReactEventHandler | undefined; onAuxClick?: React.MouseEventHandler | undefined; onAuxClickCapture?: React.MouseEventHandler | undefined; onClickCapture?: React.MouseEventHandler | undefined; onContextMenu?: React.MouseEventHandler | undefined; onContextMenuCapture?: React.MouseEventHandler | undefined; onDoubleClick?: React.MouseEventHandler | undefined; onDoubleClickCapture?: React.MouseEventHandler | undefined; onDrag?: React.DragEventHandler | undefined; onDragCapture?: React.DragEventHandler | undefined; onDragEnd?: React.DragEventHandler | undefined; onDragEndCapture?: React.DragEventHandler | undefined; onDragEnter?: React.DragEventHandler | undefined; onDragEnterCapture?: React.DragEventHandler | undefined; onDragExit?: React.DragEventHandler | undefined; onDragExitCapture?: React.DragEventHandler | undefined; onDragLeave?: React.DragEventHandler | undefined; onDragLeaveCapture?: React.DragEventHandler | undefined; onDragOver?: React.DragEventHandler | undefined; onDragOverCapture?: React.DragEventHandler | undefined; onDragStart?: React.DragEventHandler | undefined; onDragStartCapture?: React.DragEventHandler | undefined; onDrop?: React.DragEventHandler | undefined; onDropCapture?: React.DragEventHandler | undefined; onMouseDown?: React.MouseEventHandler | undefined; onMouseDownCapture?: React.MouseEventHandler | undefined; onMouseEnter?: React.MouseEventHandler | undefined; onMouseLeave?: React.MouseEventHandler | undefined; onMouseMove?: React.MouseEventHandler | undefined; onMouseMoveCapture?: React.MouseEventHandler | undefined; onMouseOut?: React.MouseEventHandler | undefined; onMouseOutCapture?: React.MouseEventHandler | undefined; onMouseOver?: React.MouseEventHandler | undefined; onMouseOverCapture?: React.MouseEventHandler | undefined; onMouseUp?: React.MouseEventHandler | undefined; onMouseUpCapture?: React.MouseEventHandler | undefined; onSelect?: React.ReactEventHandler | undefined; onSelectCapture?: React.ReactEventHandler | undefined; onTouchCancel?: React.TouchEventHandler | undefined; onTouchCancelCapture?: React.TouchEventHandler | undefined; onTouchEnd?: React.TouchEventHandler | undefined; onTouchEndCapture?: React.TouchEventHandler | undefined; onTouchMove?: React.TouchEventHandler | undefined; onTouchMoveCapture?: React.TouchEventHandler | undefined; onTouchStart?: React.TouchEventHandler | undefined; onTouchStartCapture?: React.TouchEventHandler | undefined; onPointerDown?: React.PointerEventHandler | undefined; onPointerDownCapture?: React.PointerEventHandler | undefined; onPointerMove?: React.PointerEventHandler | undefined; onPointerMoveCapture?: React.PointerEventHandler | undefined; onPointerUp?: React.PointerEventHandler | undefined; onPointerUpCapture?: React.PointerEventHandler | undefined; onPointerCancel?: React.PointerEventHandler | undefined; onPointerCancelCapture?: React.PointerEventHandler | undefined; onPointerEnter?: React.PointerEventHandler | undefined; onPointerEnterCapture?: React.PointerEventHandler | undefined; onPointerLeave?: React.PointerEventHandler | undefined; onPointerLeaveCapture?: React.PointerEventHandler | undefined; onPointerOver?: React.PointerEventHandler | undefined; onPointerOverCapture?: React.PointerEventHandler | undefined; onPointerOut?: React.PointerEventHandler | undefined; onPointerOutCapture?: React.PointerEventHandler | undefined; onGotPointerCapture?: React.PointerEventHandler | undefined; onGotPointerCaptureCapture?: React.PointerEventHandler | undefined; onLostPointerCapture?: React.PointerEventHandler | undefined; onLostPointerCaptureCapture?: React.PointerEventHandler | undefined; onScroll?: React.UIEventHandler | undefined; onScrollCapture?: React.UIEventHandler | undefined; onWheel?: React.WheelEventHandler | undefined; onWheelCapture?: React.WheelEventHandler | undefined; onAnimationStart?: React.AnimationEventHandler | undefined; onAnimationStartCapture?: React.AnimationEventHandler | undefined; onAnimationEnd?: React.AnimationEventHandler | undefined; onAnimationEndCapture?: React.AnimationEventHandler | undefined; onAnimationIteration?: React.AnimationEventHandler | undefined; onAnimationIterationCapture?: React.AnimationEventHandler | undefined; onTransitionEnd?: React.TransitionEventHandler | undefined; onTransitionEndCapture?: React.TransitionEventHandler | undefined; 'data-test-subj'?: string | undefined; css?: ", "Interpolation", "<", "Theme", diff --git a/api_docs/saved_objects_management.mdx b/api_docs/saved_objects_management.mdx index f5f903181d9d6..f181460eda726 100644 --- a/api_docs/saved_objects_management.mdx +++ b/api_docs/saved_objects_management.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedObjectsManagement title: "savedObjectsManagement" image: https://source.unsplash.com/400x175/?github description: API docs for the savedObjectsManagement plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjectsManagement'] --- import savedObjectsManagementObj from './saved_objects_management.devdocs.json'; diff --git a/api_docs/saved_objects_tagging.mdx b/api_docs/saved_objects_tagging.mdx index 13b93868ca83d..893fbb88ed64f 100644 --- a/api_docs/saved_objects_tagging.mdx +++ b/api_docs/saved_objects_tagging.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedObjectsTagging title: "savedObjectsTagging" image: https://source.unsplash.com/400x175/?github description: API docs for the savedObjectsTagging plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjectsTagging'] --- import savedObjectsTaggingObj from './saved_objects_tagging.devdocs.json'; diff --git a/api_docs/saved_objects_tagging_oss.mdx b/api_docs/saved_objects_tagging_oss.mdx index 6aa37cc43d8e4..86d1e07bdf8ca 100644 --- a/api_docs/saved_objects_tagging_oss.mdx +++ b/api_docs/saved_objects_tagging_oss.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedObjectsTaggingOss title: "savedObjectsTaggingOss" image: https://source.unsplash.com/400x175/?github description: API docs for the savedObjectsTaggingOss plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjectsTaggingOss'] --- import savedObjectsTaggingOssObj from './saved_objects_tagging_oss.devdocs.json'; diff --git a/api_docs/saved_search.mdx b/api_docs/saved_search.mdx index 2578683f40c68..48c1a4fc3605c 100644 --- a/api_docs/saved_search.mdx +++ b/api_docs/saved_search.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/savedSearch title: "savedSearch" image: https://source.unsplash.com/400x175/?github description: API docs for the savedSearch plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedSearch'] --- import savedSearchObj from './saved_search.devdocs.json'; diff --git a/api_docs/screenshot_mode.mdx b/api_docs/screenshot_mode.mdx index 386e6ddb76293..9b1d4ee4f94d2 100644 --- a/api_docs/screenshot_mode.mdx +++ b/api_docs/screenshot_mode.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/screenshotMode title: "screenshotMode" image: https://source.unsplash.com/400x175/?github description: API docs for the screenshotMode plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'screenshotMode'] --- import screenshotModeObj from './screenshot_mode.devdocs.json'; diff --git a/api_docs/screenshotting.mdx b/api_docs/screenshotting.mdx index 3cda0ae2441b8..8646d20df3da2 100644 --- a/api_docs/screenshotting.mdx +++ b/api_docs/screenshotting.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/screenshotting title: "screenshotting" image: https://source.unsplash.com/400x175/?github description: API docs for the screenshotting plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'screenshotting'] --- import screenshottingObj from './screenshotting.devdocs.json'; diff --git a/api_docs/security.mdx b/api_docs/security.mdx index 7a1042600f630..34a52cb1cce44 100644 --- a/api_docs/security.mdx +++ b/api_docs/security.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/security title: "security" image: https://source.unsplash.com/400x175/?github description: API docs for the security plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'security'] --- import securityObj from './security.devdocs.json'; diff --git a/api_docs/security_solution.devdocs.json b/api_docs/security_solution.devdocs.json index 8e51ac05f833a..71cad56d90bfc 100644 --- a/api_docs/security_solution.devdocs.json +++ b/api_docs/security_solution.devdocs.json @@ -45,13 +45,44 @@ "deprecated": false, "trackAdoption": false, "children": [ + { + "parentPluginId": "securitySolution", + "id": "def-public.Plugin.kibanaBranch", + "type": "string", + "tags": [], + "label": "kibanaBranch", + "description": [ + "\nThe current Kibana branch. e.g. 'main'" + ], + "path": "x-pack/plugins/security_solution/public/plugin.tsx", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "securitySolution", "id": "def-public.Plugin.kibanaVersion", "type": "string", "tags": [], "label": "kibanaVersion", - "description": [], + "description": [ + "\nThe current Kibana version. e.g. '8.0.0' or '8.0.0-SNAPSHOT'" + ], + "path": "x-pack/plugins/security_solution/public/plugin.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "securitySolution", + "id": "def-public.Plugin.prebuiltRulesPackageVersion", + "type": "string", + "tags": [], + "label": "prebuiltRulesPackageVersion", + "description": [ + "\nFor internal use. Specify which version of the Detection Rules fleet package to install\nwhen upgrading rules. If not provided, the latest compatible package will be installed,\nor if running from a dev environment or -SNAPSHOT build, the latest pre-release package\nwill be used (if fleet is available or not within an airgapped environment).\n\nNote: This is for `upgrade only`, which occurs by means of the `useUpgradeSecurityPackages`\nhook when navigating to a Security Solution page. The package version specified in\n`fleet_packages.json` in project root will always be installed first on Kibana start if\nthe package is not already installed." + ], + "signature": [ + "string | undefined" + ], "path": "x-pack/plugins/security_solution/public/plugin.tsx", "deprecated": false, "trackAdoption": false @@ -1931,54 +1962,6 @@ "children": [], "returnComment": [] }, - { - "parentPluginId": "securitySolution", - "id": "def-server.SecuritySolutionApiRequestHandlerContext.getScopedFleetServices", - "type": "Function", - "tags": [], - "label": "getScopedFleetServices", - "description": [], - "signature": [ - "(req: ", - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.KibanaRequest", - "text": "KibanaRequest" - }, - ") => ", - "EndpointScopedFleetServicesInterface" - ], - "path": "x-pack/plugins/security_solution/server/types.ts", - "deprecated": false, - "trackAdoption": false, - "children": [ - { - "parentPluginId": "securitySolution", - "id": "def-server.SecuritySolutionApiRequestHandlerContext.getScopedFleetServices.$1", - "type": "Object", - "tags": [], - "label": "req", - "description": [], - "signature": [ - { - "pluginId": "@kbn/core-http-server", - "scope": "common", - "docId": "kibKbnCoreHttpServerPluginApi", - "section": "def-common.KibanaRequest", - "text": "KibanaRequest" - }, - "" - ], - "path": "x-pack/plugins/security_solution/server/types.ts", - "deprecated": false, - "trackAdoption": false, - "isRequired": true - } - ], - "returnComment": [] - }, { "parentPluginId": "securitySolution", "id": "def-server.SecuritySolutionApiRequestHandlerContext.getQueryRuleAdditionalOptions", @@ -2007,7 +1990,7 @@ "label": "ConfigType", "description": [], "signature": [ - "Readonly<{} & { signalsIndex: string; maxRuleImportExportSize: number; maxRuleImportPayloadBytes: number; maxTimelineImportExportSize: number; maxTimelineImportPayloadBytes: number; alertMergeStrategy: \"allFields\" | \"missingFields\" | \"noFields\"; alertIgnoreFields: string[]; enableExperimental: string[]; packagerTaskInterval: string; }> & { experimentalFeatures: ", + "Readonly<{ prebuiltRulesPackageVersion?: string | undefined; } & { signalsIndex: string; maxRuleImportExportSize: number; maxRuleImportPayloadBytes: number; maxTimelineImportExportSize: number; maxTimelineImportPayloadBytes: number; alertMergeStrategy: \"allFields\" | \"missingFields\" | \"noFields\"; alertIgnoreFields: string[]; enableExperimental: string[]; packagerTaskInterval: string; }> & { experimentalFeatures: ", "ExperimentalFeatures", "; }" ], diff --git a/api_docs/security_solution.mdx b/api_docs/security_solution.mdx index 551484f337c39..467e61b1e1703 100644 --- a/api_docs/security_solution.mdx +++ b/api_docs/security_solution.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/securitySolution title: "securitySolution" image: https://source.unsplash.com/400x175/?github description: API docs for the securitySolution plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'securitySolution'] --- import securitySolutionObj from './security_solution.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Security solution](https://github.com/orgs/elastic/teams/security-solut | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 113 | 0 | 76 | 29 | +| 113 | 0 | 73 | 28 | ## Client diff --git a/api_docs/session_view.mdx b/api_docs/session_view.mdx index 66f2fb2bd830a..6f2a5232ed000 100644 --- a/api_docs/session_view.mdx +++ b/api_docs/session_view.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/sessionView title: "sessionView" image: https://source.unsplash.com/400x175/?github description: API docs for the sessionView plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'sessionView'] --- import sessionViewObj from './session_view.devdocs.json'; diff --git a/api_docs/share.devdocs.json b/api_docs/share.devdocs.json index effab6c42e299..6601c08555872 100644 --- a/api_docs/share.devdocs.json +++ b/api_docs/share.devdocs.json @@ -864,6 +864,20 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "share", + "id": "def-public.ShareContext.shareableUrlForSavedObject", + "type": "string", + "tags": [], + "label": "shareableUrlForSavedObject", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/share/public/types.ts", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "share", "id": "def-public.ShareContext.sharingData", @@ -950,6 +964,20 @@ } ], "returnComment": [] + }, + { + "parentPluginId": "share", + "id": "def-public.ShareContext.disabledShareUrl", + "type": "CompoundType", + "tags": [], + "label": "disabledShareUrl", + "description": [], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/share/public/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -1241,6 +1269,20 @@ "trackAdoption": false, "children": [], "returnComment": [] + }, + { + "parentPluginId": "share", + "id": "def-public.ShowShareMenuOptions.objectTypeTitle", + "type": "string", + "tags": [], + "label": "objectTypeTitle", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "src/plugins/share/public/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false diff --git a/api_docs/share.mdx b/api_docs/share.mdx index 4f7eeb70251f1..789b2d6053949 100644 --- a/api_docs/share.mdx +++ b/api_docs/share.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/share title: "share" image: https://source.unsplash.com/400x175/?github description: API docs for the share plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'share'] --- import shareObj from './share.devdocs.json'; @@ -21,7 +21,7 @@ Contact [App Services](https://github.com/orgs/elastic/teams/kibana-app-services | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 115 | 0 | 56 | 10 | +| 118 | 0 | 59 | 10 | ## Client diff --git a/api_docs/snapshot_restore.mdx b/api_docs/snapshot_restore.mdx index ef4d7ee698391..9e0d060b3751c 100644 --- a/api_docs/snapshot_restore.mdx +++ b/api_docs/snapshot_restore.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/snapshotRestore title: "snapshotRestore" image: https://source.unsplash.com/400x175/?github description: API docs for the snapshotRestore plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'snapshotRestore'] --- import snapshotRestoreObj from './snapshot_restore.devdocs.json'; diff --git a/api_docs/spaces.mdx b/api_docs/spaces.mdx index 99a7069af01ff..3a2e632b21f52 100644 --- a/api_docs/spaces.mdx +++ b/api_docs/spaces.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/spaces title: "spaces" image: https://source.unsplash.com/400x175/?github description: API docs for the spaces plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'spaces'] --- import spacesObj from './spaces.devdocs.json'; diff --git a/api_docs/stack_alerts.mdx b/api_docs/stack_alerts.mdx index a47cce6193024..65ccf5447dc68 100644 --- a/api_docs/stack_alerts.mdx +++ b/api_docs/stack_alerts.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/stackAlerts title: "stackAlerts" image: https://source.unsplash.com/400x175/?github description: API docs for the stackAlerts plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'stackAlerts'] --- import stackAlertsObj from './stack_alerts.devdocs.json'; diff --git a/api_docs/stack_connectors.mdx b/api_docs/stack_connectors.mdx index d722c1a200cdc..1a4818419f402 100644 --- a/api_docs/stack_connectors.mdx +++ b/api_docs/stack_connectors.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/stackConnectors title: "stackConnectors" image: https://source.unsplash.com/400x175/?github description: API docs for the stackConnectors plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'stackConnectors'] --- import stackConnectorsObj from './stack_connectors.devdocs.json'; diff --git a/api_docs/task_manager.mdx b/api_docs/task_manager.mdx index 7006a5d92af14..bebc8d16ce634 100644 --- a/api_docs/task_manager.mdx +++ b/api_docs/task_manager.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/taskManager title: "taskManager" image: https://source.unsplash.com/400x175/?github description: API docs for the taskManager plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'taskManager'] --- import taskManagerObj from './task_manager.devdocs.json'; diff --git a/api_docs/telemetry.mdx b/api_docs/telemetry.mdx index e6b8896115c21..9819227f03716 100644 --- a/api_docs/telemetry.mdx +++ b/api_docs/telemetry.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/telemetry title: "telemetry" image: https://source.unsplash.com/400x175/?github description: API docs for the telemetry plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'telemetry'] --- import telemetryObj from './telemetry.devdocs.json'; diff --git a/api_docs/telemetry_collection_manager.mdx b/api_docs/telemetry_collection_manager.mdx index 5569fac17355e..7cdcf1aeb4e4f 100644 --- a/api_docs/telemetry_collection_manager.mdx +++ b/api_docs/telemetry_collection_manager.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/telemetryCollectionManager title: "telemetryCollectionManager" image: https://source.unsplash.com/400x175/?github description: API docs for the telemetryCollectionManager plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'telemetryCollectionManager'] --- import telemetryCollectionManagerObj from './telemetry_collection_manager.devdocs.json'; diff --git a/api_docs/telemetry_collection_xpack.mdx b/api_docs/telemetry_collection_xpack.mdx index 00a7efa0ec5b1..03f3319a24a21 100644 --- a/api_docs/telemetry_collection_xpack.mdx +++ b/api_docs/telemetry_collection_xpack.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/telemetryCollectionXpack title: "telemetryCollectionXpack" image: https://source.unsplash.com/400x175/?github description: API docs for the telemetryCollectionXpack plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'telemetryCollectionXpack'] --- import telemetryCollectionXpackObj from './telemetry_collection_xpack.devdocs.json'; diff --git a/api_docs/telemetry_management_section.mdx b/api_docs/telemetry_management_section.mdx index d6d8feba5926d..9177ef6b274d4 100644 --- a/api_docs/telemetry_management_section.mdx +++ b/api_docs/telemetry_management_section.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/telemetryManagementSection title: "telemetryManagementSection" image: https://source.unsplash.com/400x175/?github description: API docs for the telemetryManagementSection plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'telemetryManagementSection'] --- import telemetryManagementSectionObj from './telemetry_management_section.devdocs.json'; diff --git a/api_docs/threat_intelligence.devdocs.json b/api_docs/threat_intelligence.devdocs.json index bf7f44448dd5f..ccce9277fb240 100644 --- a/api_docs/threat_intelligence.devdocs.json +++ b/api_docs/threat_intelligence.devdocs.json @@ -502,6 +502,24 @@ } ], "returnComment": [] + }, + { + "parentPluginId": "threatIntelligence", + "id": "def-public.SecuritySolutionPluginContext.blockList", + "type": "Object", + "tags": [], + "label": "blockList", + "description": [], + "signature": [ + "{ exceptionListApiClient: unknown; useSetUrlParams: () => (params: Record, replace?: boolean | undefined) => void; getFlyoutComponent: () => React.NamedExoticComponent<", + "BlockListFlyoutProps", + ">; getFormComponent: () => React.NamedExoticComponent<", + "BlockListFormProps", + ">; }" + ], + "path": "x-pack/plugins/threat_intelligence/public/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false diff --git a/api_docs/threat_intelligence.mdx b/api_docs/threat_intelligence.mdx index e3627642912d5..a1aa998ce8897 100644 --- a/api_docs/threat_intelligence.mdx +++ b/api_docs/threat_intelligence.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/threatIntelligence title: "threatIntelligence" image: https://source.unsplash.com/400x175/?github description: API docs for the threatIntelligence plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'threatIntelligence'] --- import threatIntelligenceObj from './threat_intelligence.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Protections Experience Team](https://github.com/orgs/elastic/teams/prot | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 34 | 0 | 14 | 3 | +| 35 | 0 | 15 | 5 | ## Client diff --git a/api_docs/timelines.mdx b/api_docs/timelines.mdx index c5dcf94a08e0a..60e78dee3b9a2 100644 --- a/api_docs/timelines.mdx +++ b/api_docs/timelines.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/timelines title: "timelines" image: https://source.unsplash.com/400x175/?github description: API docs for the timelines plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'timelines'] --- import timelinesObj from './timelines.devdocs.json'; diff --git a/api_docs/transform.mdx b/api_docs/transform.mdx index e6eed985be513..851a2bcde33ea 100644 --- a/api_docs/transform.mdx +++ b/api_docs/transform.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/transform title: "transform" image: https://source.unsplash.com/400x175/?github description: API docs for the transform plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'transform'] --- import transformObj from './transform.devdocs.json'; diff --git a/api_docs/triggers_actions_ui.devdocs.json b/api_docs/triggers_actions_ui.devdocs.json index 2d586636a5af7..4987c06f62d11 100644 --- a/api_docs/triggers_actions_ui.devdocs.json +++ b/api_docs/triggers_actions_ui.devdocs.json @@ -3757,6 +3757,21 @@ } ], "returnComment": [] + }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertsTableProps.controls", + "type": "Object", + "tags": [], + "label": "controls", + "description": [], + "signature": [ + "EuiDataGridToolBarAdditionalControlsOptions", + " | undefined" + ], + "path": "x-pack/plugins/triggers_actions_ui/public/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -4053,6 +4068,81 @@ ], "initialIsOpen": false }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange", + "type": "Interface", + "tags": [], + "label": "AlertSummaryTimeRange", + "description": [], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange.utcFrom", + "type": "string", + "tags": [], + "label": "utcFrom", + "description": [], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange.utcTo", + "type": "string", + "tags": [], + "label": "utcTo", + "description": [], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange.fixedInterval", + "type": "string", + "tags": [], + "label": "fixedInterval", + "description": [], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange.title", + "type": "CompoundType", + "tags": [], + "label": "title", + "description": [], + "signature": [ + "string | JSX.Element | undefined" + ], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "triggersActionsUi", + "id": "def-public.AlertSummaryTimeRange.dateFormat", + "type": "string", + "tags": [], + "label": "dateFormat", + "description": [], + "signature": [ + "string | undefined" + ], + "path": "x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/types.ts", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, { "parentPluginId": "triggersActionsUi", "id": "def-public.BulkOperationResponse", diff --git a/api_docs/triggers_actions_ui.mdx b/api_docs/triggers_actions_ui.mdx index b256089e37b4e..5d981ba61183f 100644 --- a/api_docs/triggers_actions_ui.mdx +++ b/api_docs/triggers_actions_ui.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/triggersActionsUi title: "triggersActionsUi" image: https://source.unsplash.com/400x175/?github description: API docs for the triggersActionsUi plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'triggersActionsUi'] --- import triggersActionsUiObj from './triggers_actions_ui.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Response Ops](https://github.com/orgs/elastic/teams/response-ops) for q | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 579 | 11 | 550 | 53 | +| 586 | 11 | 557 | 53 | ## Client diff --git a/api_docs/ui_actions.devdocs.json b/api_docs/ui_actions.devdocs.json index e26733fbbb269..85c23674f7d5f 100644 --- a/api_docs/ui_actions.devdocs.json +++ b/api_docs/ui_actions.devdocs.json @@ -981,10 +981,10 @@ }, " extends Partial<", { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.Presentable", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.Presentable", "text": "Presentable" }, "<", @@ -1391,10 +1391,10 @@ }, " extends Partial<", { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.Presentable", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.Presentable", "text": "Presentable" }, "<", @@ -1805,15 +1805,15 @@ ], "signature": [ { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.Presentable", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.Presentable", "text": "Presentable" }, "" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -1826,7 +1826,7 @@ "description": [ "\nID that uniquely identifies this object." ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false }, @@ -1839,7 +1839,7 @@ "description": [ "\nDetermines the display order in relation to other items. Higher numbers are\ndisplayed first." ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false }, @@ -1855,7 +1855,7 @@ "signature": [ "React.FC<{ context: Context; }> | undefined" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false }, @@ -1871,7 +1871,7 @@ "signature": [ "(context: Context) => string | undefined" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -1885,7 +1885,7 @@ "signature": [ "Context" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -1905,7 +1905,7 @@ "signature": [ "(context: Context) => string" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -1919,7 +1919,7 @@ "signature": [ "Context" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -1939,7 +1939,7 @@ "signature": [ "((context: Context) => string) | undefined" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -1953,7 +1953,7 @@ "signature": [ "Context" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -1973,7 +1973,7 @@ "signature": [ "((context: Context) => Promise) | undefined" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -1987,7 +1987,7 @@ "signature": [ "Context" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -2007,7 +2007,7 @@ "signature": [ "(context: Context) => Promise" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "children": [ @@ -2021,7 +2021,7 @@ "signature": [ "Context" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "isRequired": true @@ -2040,15 +2040,15 @@ ], "signature": [ { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.PresentableGrouping", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGrouping", "text": "PresentableGrouping" }, " | undefined" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false } @@ -2464,10 +2464,16 @@ "label": "PresentableGrouping", "description": [], "signature": [ - "PresentableGroup", + { + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.PresentableGroup", + "text": "PresentableGroup" + }, "[]" ], - "path": "src/plugins/ui_actions/public/util/presentable.ts", + "path": "packages/kbn-ui-actions-browser/src/types/presentable.ts", "deprecated": false, "trackAdoption": false, "initialIsOpen": false diff --git a/api_docs/ui_actions.mdx b/api_docs/ui_actions.mdx index 952084f31f9a6..8c47375d5532d 100644 --- a/api_docs/ui_actions.mdx +++ b/api_docs/ui_actions.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/uiActions title: "uiActions" image: https://source.unsplash.com/400x175/?github description: API docs for the uiActions plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'uiActions'] --- import uiActionsObj from './ui_actions.devdocs.json'; @@ -21,7 +21,7 @@ Contact [App Services](https://github.com/orgs/elastic/teams/kibana-app-services | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 144 | 2 | 99 | 12 | +| 144 | 2 | 99 | 11 | ## Client diff --git a/api_docs/ui_actions_enhanced.devdocs.json b/api_docs/ui_actions_enhanced.devdocs.json index 5d5d97ac54ca1..cdc3e2f277d2e 100644 --- a/api_docs/ui_actions_enhanced.devdocs.json +++ b/api_docs/ui_actions_enhanced.devdocs.json @@ -265,10 +265,10 @@ }, " implements Omit<", { - "pluginId": "uiActions", - "scope": "public", - "docId": "kibUiActionsPluginApi", - "section": "def-public.Presentable", + "pluginId": "@kbn/ui-actions-browser", + "scope": "common", + "docId": "kibKbnUiActionsBrowserPluginApi", + "section": "def-common.Presentable", "text": "Presentable" }, ", \"getHref\">,", @@ -2350,10 +2350,10 @@ }, " extends Partial, \"getHref\">>,", diff --git a/api_docs/ui_actions_enhanced.mdx b/api_docs/ui_actions_enhanced.mdx index d3e8e5e14e5b9..cfedc3f66a919 100644 --- a/api_docs/ui_actions_enhanced.mdx +++ b/api_docs/ui_actions_enhanced.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/uiActionsEnhanced title: "uiActionsEnhanced" image: https://source.unsplash.com/400x175/?github description: API docs for the uiActionsEnhanced plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'uiActionsEnhanced'] --- import uiActionsEnhancedObj from './ui_actions_enhanced.devdocs.json'; diff --git a/api_docs/unified_field_list.mdx b/api_docs/unified_field_list.mdx index b9df25a5e1e83..7ee1f3878b567 100644 --- a/api_docs/unified_field_list.mdx +++ b/api_docs/unified_field_list.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/unifiedFieldList title: "unifiedFieldList" image: https://source.unsplash.com/400x175/?github description: API docs for the unifiedFieldList plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'unifiedFieldList'] --- import unifiedFieldListObj from './unified_field_list.devdocs.json'; diff --git a/api_docs/unified_histogram.devdocs.json b/api_docs/unified_histogram.devdocs.json index 7a881fb33eed3..aca1afdb564fa 100644 --- a/api_docs/unified_histogram.devdocs.json +++ b/api_docs/unified_histogram.devdocs.json @@ -163,19 +163,6 @@ "deprecated": false, "trackAdoption": false, "children": [ - { - "parentPluginId": "unifiedHistogram", - "id": "def-public.UnifiedHistogramChartLoadEvent.complete", - "type": "boolean", - "tags": [], - "label": "complete", - "description": [ - "\nTrue if loading is complete" - ], - "path": "src/plugins/unified_histogram/public/types.ts", - "deprecated": false, - "trackAdoption": false - }, { "parentPluginId": "unifiedHistogram", "id": "def-public.UnifiedHistogramChartLoadEvent.adapters", @@ -357,15 +344,76 @@ }, { "parentPluginId": "unifiedHistogram", - "id": "def-public.UnifiedHistogramLayoutProps.lastReloadRequestTime", - "type": "number", + "id": "def-public.UnifiedHistogramLayoutProps.query", + "type": "CompoundType", "tags": [], - "label": "lastReloadRequestTime", + "label": "query", "description": [ - "\nCan be updated to `Date.now()` to force a refresh" + "\nThe current query" ], "signature": [ - "number | undefined" + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Query", + "text": "Query" + }, + " | ", + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.AggregateQuery", + "text": "AggregateQuery" + }, + " | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.filters", + "type": "Array", + "tags": [], + "label": "filters", + "description": [ + "\nThe current filters" + ], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.Filter", + "text": "Filter" + }, + "[] | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.timeRange", + "type": "Object", + "tags": [], + "label": "timeRange", + "description": [ + "\nThe current time range" + ], + "signature": [ + { + "pluginId": "@kbn/es-query", + "scope": "common", + "docId": "kibKbnEsQueryPluginApi", + "section": "def-common.TimeRange", + "text": "TimeRange" + }, + " | undefined" ], "path": "src/plugins/unified_histogram/public/layout/layout.tsx", "deprecated": false, @@ -511,6 +559,71 @@ "deprecated": false, "trackAdoption": false }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.disableAutoFetching", + "type": "CompoundType", + "tags": [], + "label": "disableAutoFetching", + "description": [ + "\nDisable automatic refetching based on props changes, and instead wait for a `refetch` message" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.disableTriggers", + "type": "CompoundType", + "tags": [], + "label": "disableTriggers", + "description": [ + "\nDisable triggers for the Lens embeddable" + ], + "signature": [ + "boolean | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.disabledActions", + "type": "Array", + "tags": [], + "label": "disabledActions", + "description": [ + "\nDisabled action IDs for the Lens embeddable" + ], + "signature": [ + "string[] | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.input$", + "type": "Object", + "tags": [], + "label": "input$", + "description": [ + "\nInput observable" + ], + "signature": [ + "UnifiedHistogramInput", + "$ | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, { "parentPluginId": "unifiedHistogram", "id": "def-public.UnifiedHistogramLayoutProps.onTopPanelHeightChange", @@ -906,6 +1019,84 @@ } ], "returnComment": [] + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.onFilter", + "type": "Function", + "tags": [], + "label": "onFilter", + "description": [ + "\nCallback to pass to the Lens embeddable to handle filter changes" + ], + "signature": [ + "((data: { data: { table: Pick<", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + }, + ", \"rows\" | \"columns\">; column: number; row: number; value: any; }[]; timeFieldName?: string | undefined; negate?: boolean | undefined; }) => void) | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramLayoutProps.onBrushEnd", + "type": "Function", + "tags": [], + "label": "onBrushEnd", + "description": [ + "\nCallback to pass to the Lens embeddable to handle brush events" + ], + "signature": [ + "((data: { table: ", + { + "pluginId": "expressions", + "scope": "common", + "docId": "kibExpressionsPluginApi", + "section": "def-common.Datatable", + "text": "Datatable" + }, + "; column: number; range: number[]; timeFieldName?: string | undefined; }) => void) | undefined" + ], + "path": "src/plugins/unified_histogram/public/layout/layout.tsx", + "deprecated": false, + "trackAdoption": false + } + ], + "initialIsOpen": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramRefetchMessage", + "type": "Interface", + "tags": [], + "label": "UnifiedHistogramRefetchMessage", + "description": [ + "\nMessage to refetch the chart and total hits" + ], + "path": "src/plugins/unified_histogram/public/types.ts", + "deprecated": false, + "trackAdoption": false, + "children": [ + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramRefetchMessage.type", + "type": "string", + "tags": [], + "label": "type", + "description": [], + "signature": [ + "\"refetch\"" + ], + "path": "src/plugins/unified_histogram/public/types.ts", + "deprecated": false, + "trackAdoption": false } ], "initialIsOpen": false @@ -1165,6 +1356,55 @@ "deprecated": false, "trackAdoption": false, "initialIsOpen": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramInput$", + "type": "Type", + "tags": [], + "label": "UnifiedHistogramInput$", + "description": [ + "\nUnified histogram input observable" + ], + "signature": [ + "Subject", + "<", + { + "pluginId": "unifiedHistogram", + "scope": "public", + "docId": "kibUnifiedHistogramPluginApi", + "section": "def-public.UnifiedHistogramRefetchMessage", + "text": "UnifiedHistogramRefetchMessage" + }, + ">" + ], + "path": "src/plugins/unified_histogram/public/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false + }, + { + "parentPluginId": "unifiedHistogram", + "id": "def-public.UnifiedHistogramInputMessage", + "type": "Type", + "tags": [], + "label": "UnifiedHistogramInputMessage", + "description": [ + "\nUnified histogram input message" + ], + "signature": [ + { + "pluginId": "unifiedHistogram", + "scope": "public", + "docId": "kibUnifiedHistogramPluginApi", + "section": "def-public.UnifiedHistogramRefetchMessage", + "text": "UnifiedHistogramRefetchMessage" + } + ], + "path": "src/plugins/unified_histogram/public/types.ts", + "deprecated": false, + "trackAdoption": false, + "initialIsOpen": false } ], "objects": [] diff --git a/api_docs/unified_histogram.mdx b/api_docs/unified_histogram.mdx index 03561e0fdc7d7..c72e5eb087f3f 100644 --- a/api_docs/unified_histogram.mdx +++ b/api_docs/unified_histogram.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/unifiedHistogram title: "unifiedHistogram" image: https://source.unsplash.com/400x175/?github description: API docs for the unifiedHistogram plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'unifiedHistogram'] --- import unifiedHistogramObj from './unified_histogram.devdocs.json'; @@ -21,7 +21,7 @@ Contact [Data Discovery](https://github.com/orgs/elastic/teams/kibana-data-disco | Public API count | Any count | Items lacking comments | Missing exports | |-------------------|-----------|------------------------|-----------------| -| 52 | 0 | 15 | 0 | +| 63 | 0 | 16 | 1 | ## Client diff --git a/api_docs/unified_search.mdx b/api_docs/unified_search.mdx index 592368df78c68..fb4bd4dba1426 100644 --- a/api_docs/unified_search.mdx +++ b/api_docs/unified_search.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/unifiedSearch title: "unifiedSearch" image: https://source.unsplash.com/400x175/?github description: API docs for the unifiedSearch plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'unifiedSearch'] --- import unifiedSearchObj from './unified_search.devdocs.json'; diff --git a/api_docs/unified_search_autocomplete.mdx b/api_docs/unified_search_autocomplete.mdx index 58171baf3245a..5735e950dd9e4 100644 --- a/api_docs/unified_search_autocomplete.mdx +++ b/api_docs/unified_search_autocomplete.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/unifiedSearch-autocomplete title: "unifiedSearch.autocomplete" image: https://source.unsplash.com/400x175/?github description: API docs for the unifiedSearch.autocomplete plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'unifiedSearch.autocomplete'] --- import unifiedSearchAutocompleteObj from './unified_search_autocomplete.devdocs.json'; diff --git a/api_docs/url_forwarding.mdx b/api_docs/url_forwarding.mdx index 0c7f19b9648c8..82ed77a953e28 100644 --- a/api_docs/url_forwarding.mdx +++ b/api_docs/url_forwarding.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/urlForwarding title: "urlForwarding" image: https://source.unsplash.com/400x175/?github description: API docs for the urlForwarding plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'urlForwarding'] --- import urlForwardingObj from './url_forwarding.devdocs.json'; diff --git a/api_docs/usage_collection.mdx b/api_docs/usage_collection.mdx index 584f8992b8c94..7af3d592999e8 100644 --- a/api_docs/usage_collection.mdx +++ b/api_docs/usage_collection.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/usageCollection title: "usageCollection" image: https://source.unsplash.com/400x175/?github description: API docs for the usageCollection plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'usageCollection'] --- import usageCollectionObj from './usage_collection.devdocs.json'; diff --git a/api_docs/ux.mdx b/api_docs/ux.mdx index edac590dfd7b4..cbcd05f096a12 100644 --- a/api_docs/ux.mdx +++ b/api_docs/ux.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/ux title: "ux" image: https://source.unsplash.com/400x175/?github description: API docs for the ux plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'ux'] --- import uxObj from './ux.devdocs.json'; diff --git a/api_docs/vis_default_editor.mdx b/api_docs/vis_default_editor.mdx index 081b74cbb1b31..01b4a9f98e7b8 100644 --- a/api_docs/vis_default_editor.mdx +++ b/api_docs/vis_default_editor.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visDefaultEditor title: "visDefaultEditor" image: https://source.unsplash.com/400x175/?github description: API docs for the visDefaultEditor plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visDefaultEditor'] --- import visDefaultEditorObj from './vis_default_editor.devdocs.json'; diff --git a/api_docs/vis_type_gauge.mdx b/api_docs/vis_type_gauge.mdx index c5e1e304b7429..7bff9670c5818 100644 --- a/api_docs/vis_type_gauge.mdx +++ b/api_docs/vis_type_gauge.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeGauge title: "visTypeGauge" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeGauge plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeGauge'] --- import visTypeGaugeObj from './vis_type_gauge.devdocs.json'; diff --git a/api_docs/vis_type_heatmap.mdx b/api_docs/vis_type_heatmap.mdx index 87126c627ff91..492901d663c00 100644 --- a/api_docs/vis_type_heatmap.mdx +++ b/api_docs/vis_type_heatmap.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeHeatmap title: "visTypeHeatmap" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeHeatmap plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeHeatmap'] --- import visTypeHeatmapObj from './vis_type_heatmap.devdocs.json'; diff --git a/api_docs/vis_type_pie.mdx b/api_docs/vis_type_pie.mdx index 5264502819411..278d71b3f3500 100644 --- a/api_docs/vis_type_pie.mdx +++ b/api_docs/vis_type_pie.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypePie title: "visTypePie" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypePie plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypePie'] --- import visTypePieObj from './vis_type_pie.devdocs.json'; diff --git a/api_docs/vis_type_table.mdx b/api_docs/vis_type_table.mdx index 07ad87c971b23..22516a52290b1 100644 --- a/api_docs/vis_type_table.mdx +++ b/api_docs/vis_type_table.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeTable title: "visTypeTable" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeTable plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeTable'] --- import visTypeTableObj from './vis_type_table.devdocs.json'; diff --git a/api_docs/vis_type_timelion.mdx b/api_docs/vis_type_timelion.mdx index 61f8d06773288..388541ac59fce 100644 --- a/api_docs/vis_type_timelion.mdx +++ b/api_docs/vis_type_timelion.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeTimelion title: "visTypeTimelion" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeTimelion plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeTimelion'] --- import visTypeTimelionObj from './vis_type_timelion.devdocs.json'; diff --git a/api_docs/vis_type_timeseries.mdx b/api_docs/vis_type_timeseries.mdx index c9724bca5b14a..e36f7b12a10c0 100644 --- a/api_docs/vis_type_timeseries.mdx +++ b/api_docs/vis_type_timeseries.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeTimeseries title: "visTypeTimeseries" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeTimeseries plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeTimeseries'] --- import visTypeTimeseriesObj from './vis_type_timeseries.devdocs.json'; diff --git a/api_docs/vis_type_vega.mdx b/api_docs/vis_type_vega.mdx index 6cbfbcd4501c6..ed72bfafabc61 100644 --- a/api_docs/vis_type_vega.mdx +++ b/api_docs/vis_type_vega.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeVega title: "visTypeVega" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeVega plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeVega'] --- import visTypeVegaObj from './vis_type_vega.devdocs.json'; diff --git a/api_docs/vis_type_vislib.mdx b/api_docs/vis_type_vislib.mdx index 646694d739686..b6a172489358f 100644 --- a/api_docs/vis_type_vislib.mdx +++ b/api_docs/vis_type_vislib.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeVislib title: "visTypeVislib" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeVislib plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeVislib'] --- import visTypeVislibObj from './vis_type_vislib.devdocs.json'; diff --git a/api_docs/vis_type_xy.mdx b/api_docs/vis_type_xy.mdx index dbf5f36e47f5d..3e497b1426b59 100644 --- a/api_docs/vis_type_xy.mdx +++ b/api_docs/vis_type_xy.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visTypeXy title: "visTypeXy" image: https://source.unsplash.com/400x175/?github description: API docs for the visTypeXy plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visTypeXy'] --- import visTypeXyObj from './vis_type_xy.devdocs.json'; diff --git a/api_docs/visualizations.mdx b/api_docs/visualizations.mdx index bfc3b09e9800a..a09b11b2250f9 100644 --- a/api_docs/visualizations.mdx +++ b/api_docs/visualizations.mdx @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/visualizations title: "visualizations" image: https://source.unsplash.com/400x175/?github description: API docs for the visualizations plugin -date: 2023-01-16 +date: 2023-01-23 tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visualizations'] --- import visualizationsObj from './visualizations.devdocs.json'; diff --git a/dev_docs/tutorials/performance/adding_api_capacity_test.mdx b/dev_docs/tutorials/performance/adding_api_capacity_test.mdx new file mode 100644 index 0000000000000..869dab986b3bd --- /dev/null +++ b/dev_docs/tutorials/performance/adding_api_capacity_test.mdx @@ -0,0 +1,134 @@ +--- +id: kibDevTutorialAddingApiCapacityTestingJourney +slug: /kibana-dev-docs/tutorial/performance/adding_api_capacity_testing_journey +title: Adding Api Capacity Testing Journey +summary: Learn how to add api capacity test +date: 2023-01-13 +tags: ['kibana', 'onboarding', 'setup', 'performance', 'development', 'telemetry'] +--- + +## Overview +It is important to test individual API endpoint for the baseline performance, scalability, or breaking point. If an API doesn’t meet performance requirements, it is a bottleneck. +This capacity tests track how response time changes while we slowly increase number of concurrent requests per second. +While using similar load model, we are able to identify how many requests per second each endpoint can hold with response time staying below critical threshold. + +Capacity API test defines 3 response time thresholds (default ones: 3000, 6000, 12000) in ms. Test results report rps (requests per second) for each threshold. + +Test results are reported using EBT in the following format: +```json +{ + "_index": "backing-kibana-server-scalability-metrics-000003", + "_source": { + "eventType": "scalability_metric", + "journeyName": "GET /internal/security/me", + "ciBuildId": "0185aace-821d-42af-97c7-5b2b029f94df", + "responseTimeMetric": "85%", + "kibanaVersion": "8.7.0", + "threshold1ResponseTime": 3000, + "rpsAtThreshold1": 586, + "threshold2ResponseTime": 6000, + "rpsAtThreshold2": 601, + "threshold3ResponseTime": 12000, + "rpsAtThreshold3": 705, + "warmupAvgResponseTime": 34, + ... + } +} +``` + +### Adding a new test +Create a new json file in `x-pack/test/scalability/apis` with required properties: +- **journeyName** is a test name, e.g. `GET /internal/security/session` +- **scalabilitySetup** is used to set load model +- **testData** is used to populate Elasticsearch and Kibana wth test data +- **streams: `[ {requests: [] }]`** defines the API endpoint(s) to be called + +`scalabilitySetup` includes warmup and test phases. +Warmup phase simulates 10 concurrent requests during 30s period and is important to get consistent results in test phase. +Test phase simulates increasing concurrent requests from `minUsersCount` to `maxUsersCount` within `duration` time. +Both `maxUsersCount` and `duration` in test phase should be adjusted for individual endpoint: + - `maxUsersCount` should be reasonable and enough to reach endpoint limits + - `duration` should be long enough to ramp up requests with low pace (1-2 requests per second) + +Example: +```json +{ + "journeyName": "GET /internal/security/session", + "scalabilitySetup": { + "warmup": [ + { + "action": "constantUsersPerSec", + "userCount": 10, + "duration": "30s" + } + ], + "test": [ + { + "action": "rampUsersPerSec", + "minUsersCount": 10, + "maxUsersCount": 700, + "duration": "345s" + } + ], + "maxDuration": "8m" + }, + "testData": { + "esArchives": [], + "kbnArchives": [] + }, + "streams": [ + { + "requests": [ + { + "http": { + "method": "GET", + "path": "/internal/security/session", + "headers": { + "Cookie": "", + "Kbn-Version": "", + "Accept-Encoding": "gzip, deflate, br", + "Content-Type": "application/json" + }, + "statusCode": 200 + } + } + ] + } + ] +} +``` + +Override default response time thresholds by adding to `scalabilitySetup`: +```json + "responseTimeThreshold": { + "threshold1": 1000, + "threshold2": 2000, + "threshold3": 5000 + }, +``` + +### Running api capacity journey locally +Clone [kibana-load-testing](https://github.com/elastic/kibana-load-testing) repo. + +Use the Node script from kibana root directory: + `node scripts/run_scalability_cli.js --journey-path x-pack/test/scalability/apis/$YOUR_JOURNEY_NAME.ts` + +Use `--kibana-install-dir` flag to test build + +### Benchmarking performance on CI +In order to keep track on performance metrics stability, api capacity tests are run on main branch with a scheduled interval. +Bare metal machine is used to produce results as stable and reproducible as possible. + +#### Machine specifications + +All benchmarks are run on bare-metal machines with the [following specifications](https://www.hetzner.com/dedicated-rootserver/ex100): + +CPU: Intel® Core™ i9-12900K 16 cores +RAM: 128 GB +SSD: 1.92 TB Data center Gen4 NVMe + +#### Track performance results +APM metrics are reported to [kibana-stats](https://kibana-stats.elastic.dev/) cluster. +You can filter transactions using labels, e.g. `labels.journeyName : "GET /internal/security/session"` + +Custom metrics reported with EBT are available in [Telemetry Staging](https://telemetry-v2-staging.elastic.dev/) cluster, `kibana-performance` space. diff --git a/dev_docs/tutorials/adding_performance_metrics.mdx b/dev_docs/tutorials/performance/adding_custom_performance_metrics.mdx similarity index 78% rename from dev_docs/tutorials/adding_performance_metrics.mdx rename to dev_docs/tutorials/performance/adding_custom_performance_metrics.mdx index 0ef9064c67adc..042283bb77dba 100644 --- a/dev_docs/tutorials/adding_performance_metrics.mdx +++ b/dev_docs/tutorials/performance/adding_custom_performance_metrics.mdx @@ -1,34 +1,43 @@ --- -id: kibDevTutorialAddingPerformanceMetrics -slug: /kibana-dev-docs/tutorial/adding_performance_metrics +id: kibDevTutorialAddingCustomPerformanceMetrics +slug: /kibana-dev-docs/tutorial/performance/adding_custom_performance_metrics title: Adding Performance Metrics summary: Learn how to instrument your code and analyze performance -date: 2022-07-07 +date: 2023-01-13 tags: ['kibana', 'onboarding', 'setup', 'performance', 'development', 'telemetry'] --- -## Reporting performance events +# Build and track custom performance metrics +Having access to performance metrics allows us to better understand user experience across Kibana, identify issues and fix it. +Custom metrics allows to monitor critical flows like server start, saved objects fetching or dashboard loading times. -### Simple performance events +## Instrument your code to report metric event. +We use event-based telemetry (EBT) to report client-side metrics as events. +If you want to add a custom metric on server side, please notify the #kibana-core team in advance. Let's assume we intend to report the performance of a specific action called `APP_ACTION`. -In order to do so, we need to first measure the timing of that action. -Once we have the time measurement, we can use the `reportPerformanceMetricEvent` API to report it. +In order to do so, we need to first measure the timing of that action. The [`performance.now()`](https://developer.mozilla.org/en-US/docs/Web/API/Performance/now) API can help with that: -The most basic form of reporting would be: +```typescript +const actionStartTime = performance.now(); +// action is started and finished +const actionDuration = window.performance.now() - actionStartTime; // Duration in milliseconds +``` + +Once we have the time measurement, we can use the `reportPerformanceMetricEvent` API to report it. ```typescript reportPerformanceMetricEvent(analytics, { eventName: APP_ACTION, - duration, // Duration in milliseconds + duration: actionDuration, }); ``` -Once executed, the metric would be delivered to the `stack-telemetry` cluster, alongside with the event's context. +After the journey run is finished, the metric will be delivered to the [Telemetry Staging](https://telemetry-v2-staging.elastic.dev/) cluster, alongside with the event's context. The data is updated periodically, so you might have to wait up to 30 minutes to see your data in the index. Once indexed, this metric will appear in `ebt-kibana` index. It is also mapped into an additional index, dedicated to performance metrics. -We recommend using the `Kibana Peformance` space on the telemetry cluster, where you get an `index patten` to easily access this data. +We recommend using the `Kibana Performance` space on the telemetry cluster, where you get an `index patten` to easily access this data. Each document in the index has the following structure: ```typescript @@ -64,7 +73,7 @@ Lets assume we are interested in benchmarking the performance of a more complex - If data needs to be refreshed, it proceeds with a flow `load-data-from-api`. - `PROCESS_DATA` loads and processes the data depending on the flow chosen in the previous step. -We could utilise the additional options supported by the `reportPerformanceMetricEvent` API: +We could utilize the additional options supported by the `reportPerformanceMetricEvent` API: ```typescript import { reportPerformanceMetricEvent } from '@kbn/ebt-tools'; @@ -136,8 +145,7 @@ creating an event for cpuUsage does not bring any value because it doesn't bring events in different places of code will have so much variability during performance analysis of your code. However it can be nice attribute to follow if it's important for you to look inside of a specific event e.g. `page-load`. -- Understand your events - **Make sure that the event is clearly defined and consistent** (i.e. same code flow is executed each time). +- **Make sure that the event is clearly defined and consistent** (i.e. same code flow is executed each time). Consider the start point and endpoint of the measurement and what happens between those points. For example: a `app-data-load` event should not include the time it takes to render the data. - **Choose event names wisely**. @@ -159,54 +167,19 @@ to follow if it's important for you to look inside of a specific event e.g. `pag - **Keep performance in mind**. Reporting the performance of Kibana should never harm its own performance. Avoid sending events too frequently (`onMouseMove`) or adding serialized JSON objects (whole `SavedObjects`) into the meta object. -### Benchmarking performance on CI - -One of the use cases for event based telemetry is benchmarking the performance of features over time. -In order to keep track of their stability, the #kibana-performance team has developed a special set of -functional tests called `Journeys`. These journeys execute a UI workflow and allow the telemetry to be -reported to a cluster where it can then be analysed. - -Those journeys run on the key branches (main, release versions) on dedicated machines to produce results -as stable and reproducible as possible. - -#### Machine specifications - -All benchmarks are run on bare-metal machines with the [following specifications](https://www.hetzner.com/dedicated-rootserver/ex100): - -CPU: Intel® Core™ i9-12900K -RAM: 128 GB -SSD: 1.92 TB Datacenter Gen4 NVMe - -Since the tests are run on a local machine, there is also realistic throttling applied to the network to -simulate real life internet connection. This means that all requests have a [fixed latency and limited bandwidth](https://github.com/elastic/kibana/blob/main/x-pack/test/performance/services/performance.ts#L157). - -#### Journey implementation - -If you would like to keep track of the stability of your events, implement a journey by adding a functional -test to the `x-pack/test/performance/journeys` folder. - -The telemetry reported during the execution of those journeys will be reported to the `telemetry-v2-staging` cluster -alongside with execution context. Use the `context.labels.ciBuildName` label to filter down events to only those originating -from performance runs and visualize the duration of events (or their breakdowns). - -Run the test locally for troubleshooting purposes by running - -``` -node scripts/functional_tests --config x-pack/performance/journeys/$YOUR_JOURNEY_NAME.ts -``` - -#### Analyzing journey results - +### Analyzing journey results +The telemetry data will be reported to the Telemetry Staging cluster alongside with execution context. +Use the `context.labels.ciBuildName` label to filter down events to only those originating from performance runs and visualize the duration of events (or their breakdowns): - Be sure to narrow your analysis down to performance events by specifying a filter `context.labels.ciBuildName: kibana-single-user-performance`. Otherwise you might be looking at results originating from different hardware. - You can look at the results of a specific journey by filtering on `context.labels.journeyName`. -Please contact the #kibana-performance team if you need more help visualising and tracking the results. +Please contact the #kibana-performance team if you need more help visualizing and tracking the results. ### Production performance tracking All users who are opted in to report telemetry will start reporting event based telemetry as well. -The data is available to be analysed on the production telemetry cluster. +The data is available to be analyzed on the production telemetry cluster. # Analytics Client diff --git a/dev_docs/tutorials/performance/adding_performance_journey.mdx b/dev_docs/tutorials/performance/adding_performance_journey.mdx new file mode 100644 index 0000000000000..423619defd063 --- /dev/null +++ b/dev_docs/tutorials/performance/adding_performance_journey.mdx @@ -0,0 +1,85 @@ +--- +id: kibDevTutorialAddingPerformanceJourney +slug: /kibana-dev-docs/tutorial/performance/adding_performance_journey +title: Adding Single User Performance Journey +summary: Learn how to add journey and track Kibana performance +date: 2023-01-13 +tags: ['kibana', 'onboarding', 'setup', 'performance', 'development'] +--- + +## Overview +In order to achieve our goal of creating best user experience in Kibana, it is important to keep track on its features performance. +To make things easier, we introduced performance journeys, that mimics end-user experience with Kibana. + +Journey runs a flow of user interactions with Kibana in a browser and collects APM metrics for both server and client-side. +It is possible to instrument Kibana with [custom performance metrics](https://docs.elastic.dev/kibana-dev-docs/tutorials/performance/adding_custom_performance_metrics), +that will provide more detailed information about feature performance. + +Journeys core is [kbn-journeys](packages/kbn-journeys/README.mdx) package. It is a function test by design and is powered +by [Playwright](https://playwright.dev/) end-to-end testing tool. + +### Adding a new performance journey +Let's assume we instrumented dashboard with load time metrics and want to track sample data flights dashboard performance. +Journey supports loading test data with esArchiver or kbnArchiver. Similar to functional tests, it might require to implement custom wait +for UI rendering to be completed. + +Simply create a new file in `x-pack/performance/journeys` with the following code: + +``` +export const journey = new Journey({ + esArchives: ['x-pack/performance/es_archives/sample_data_flights'], + kbnArchives: ['x-pack/performance/kbn_archives/flights_no_map_dashboard'], +}) + + .step('Go to Dashboards Page', async ({ page, kbnUrl }) => { + await page.goto(kbnUrl.get(`/app/dashboards`)); + await page.waitForSelector('#dashboardListingHeading'); + }) + + .step('Go to Flights Dashboard', async ({ page, log }) => { + await page.click(subj('dashboardListingTitleLink-[Flights]-Global-Flight-Dashboard')); + await waitForVisualizations(page, log, 14); + }); +``` + +In oder to get correct and consistent metrics, it is important to design journey properly: +- use archives to generate test data +- decouple complex scenarios into multiple simple journeys +- use waiting for page loading / UI component rendering +- test locally and check if journey is stable. +- make sure performance metrics are collected on every run. + +### Running performance journey locally for troubleshooting purposes +Use the Node script: + `node scripts/run_performance.js --journey-path x-pack/performance/journeys/$YOUR_JOURNEY_NAME.ts` + +Scripts steps include: +- start Elasticsearch +- start Kibana and run journey first time (warmup) only APM metrics being reported +- start Kibana and run journey second time (test): both EBT and APM metrics being reported +- stop Elasticsearch + +You can skip warmup phase for debug purpose by using `--skip-warmup` flag + +Since the tests are run on a local machine, there is also realistic throttling applied to the network to +simulate real life internet connection. This means that all requests have a fixed latency and limited bandwidth. + +### Benchmarking performance on CI +In order to keep track on performance metrics stability, journeys are run on main branch with a scheduled interval. +Bare metal machine is used to produce results as stable and reproducible as possible. + +#### Machine specifications + +All benchmarks are run on bare-metal machines with the [following specifications](https://www.hetzner.com/dedicated-rootserver/ex100): + +CPU: Intel® Core™ i9-9900K 8 cores +RAM: 128 GB +SSD: 1.92 TB Data center Gen4 NVMe + +#### Track performance results +APM metrics are reported to [kibana-ops-e2e-perf](https://kibana-ops-e2e-perf.kb.us-central1.gcp.cloud.es.io/) cluster. +You can filter transactions using labels, e.g. `labels.journeyName : "flight_dashboard"` + +Custom metrics reported with EBT are available in [Telemetry Staging](https://telemetry-v2-staging.elastic.dev/) cluster, `kibana-performance` space. + + diff --git a/docs/api-generated/cases/case-apis-passthru.asciidoc b/docs/api-generated/cases/case-apis-passthru.asciidoc index 80e8c7eb9cac7..b95159d606ab1 100644 --- a/docs/api-generated/cases/case-apis-passthru.asciidoc +++ b/docs/api-generated/cases/case-apis-passthru.asciidoc @@ -160,6 +160,9 @@ Any modifications made to this file will be overwritten.

200

Indicates a successful call. case_response_properties +

401

+ Authorization information is missing or invalid. + 4xx_response





















@@ -1878,6 +1962,7 @@ Any modifications made to this file will be overwritten.

Table of Contents

    +
  1. 4xx_response - Unsuccessful cases API response
  2. Case_response_properties_for_comments_inner -
  3. Case_response_properties_for_connectors - Case response properties for connectors
  4. action_types -
  5. @@ -1964,6 +2049,15 @@ Any modifications made to this file will be overwritten.
  6. user_comment_response_properties - Case response properties for user comments
+
+

4xx_response - Unsuccessful cases API response Up

+
+
+
error (optional)
+
message (optional)
+
statusCode (optional)
+
+

Case_response_properties_for_comments_inner - Up

diff --git a/docs/api-generated/connectors/connector-apis-passthru.asciidoc b/docs/api-generated/connectors/connector-apis-passthru.asciidoc index 03a22d9addfde..ac2c18b4f2c29 100644 --- a/docs/api-generated/connectors/connector-apis-passthru.asciidoc +++ b/docs/api-generated/connectors/connector-apis-passthru.asciidoc @@ -18,13 +18,81 @@ Any modifications made to this file will be overwritten.

Connectors

Connectors

+
+
+ Up +
post /s/{spaceId}/api/actions/connector
+
Creates a connector. (createConnector)
+
You must have all privileges for the Actions and Connectors feature in the Management section of the Kibana feature privileges.
+ +

Path parameters

+
+
spaceId (required)
+ +
Path Parameter — An identifier for the space. If /s/ and the identifier are omitted from the path, the default space is used. default: null
+
+ +

Consumes

+ This API call consumes the following media types via the Content-Type request header: +
    +
  • application/json
  • +
+ +

Request body

+
+
Create_connector_request_body_properties Create_connector_request_body_properties (required)
+ +
Body Parameter
+ +
+ +

Request headers

+
+
kbn-xsrf (required)
+ +
Header Parameter — default: null
+ +
+ + + +

Return type

+ + + + +

Example data

+
Content-Type: application/json
+
null
+ +

Produces

+ This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
    +
  • application/json
  • +
+ +

Responses

+

200

+ Indicates a successful call. + connector_response_properties +

401

+ Authorization information is missing or invalid. + createConnector_401_response +
+
Up @@ -57,11 +125,23 @@ Any modifications made to this file will be overwritten. +

Produces

+ This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
    +
  • application/json
  • +

Responses

204

Indicates a successful call. +

401

+ Authorization information is missing or invalid. + createConnector_401_response +

404

+ Object is not found. + getConnector_404_response

@@ -87,7 +167,7 @@ Any modifications made to this file will be overwritten.

Return type

@@ -95,17 +175,7 @@ Any modifications made to this file will be overwritten.

Example data

Content-Type: application/json
-
{
-  "is_missing_secrets" : false,
-  "is_deprecated" : false,
-  "is_preconfigured" : false,
-  "name" : "my-connector",
-  "id" : "b0766e10-d190-11ec-b04c-776c77d14fca",
-  "config" : {
-    "key" : ""
-  },
-  "connector_type_id" : ".server-log"
-}
+
null

Produces

This API call produces the following media types according to the Accept request header; @@ -117,7 +187,13 @@ Any modifications made to this file will be overwritten.

Responses

200

Indicates a successful call. - getConnector_200_response + connector_response_properties +

401

+ Authorization information is missing or invalid. + createConnector_401_response +

404

+ Object is not found. + getConnector_404_response

@@ -147,7 +223,7 @@ Any modifications made to this file will be overwritten.

Return type

@@ -176,6 +252,9 @@ Any modifications made to this file will be overwritten.

200

Indicates a successful call. +

401

+ Authorization information is missing or invalid. + createConnector_401_response

@@ -199,7 +278,7 @@ Any modifications made to this file will be overwritten.

Return type

@@ -231,6 +310,83 @@ Any modifications made to this file will be overwritten.

200

Indicates a successful call. +

401

+ Authorization information is missing or invalid. + createConnector_401_response +
+
+
+
+ Up +
put /s/{spaceId}/api/actions/connector/{connectorId}
+
Updates the attributes for a connector. (updateConnector)
+
You must have all privileges for the Actions and Connectors feature in the Management section of the Kibana feature privileges.
+ +

Path parameters

+
+
connectorId (required)
+ +
Path Parameter — An identifier for the connector. default: null
spaceId (required)
+ +
Path Parameter — An identifier for the space. If /s/ and the identifier are omitted from the path, the default space is used. default: null
+
+ +

Consumes

+ This API call consumes the following media types via the Content-Type request header: +
    +
  • application/json
  • +
+ +

Request body

+
+
Update_connector_request_body_properties Update_connector_request_body_properties (required)
+ +
Body Parameter
+ +
+ +

Request headers

+
+
kbn-xsrf (required)
+ +
Header Parameter — default: null
+ +
+ + + +

Return type

+ + + + +

Example data

+
Content-Type: application/json
+
null
+ +

Produces

+ This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
    +
  • application/json
  • +
+ +

Responses

+

200

+ Indicates a successful call. + connector_response_properties +

400

+ Indicates a bad request. + updateConnector_400_response +

401

+ Authorization information is missing or invalid. + createConnector_401_response +

404

+ Object is not found. + getConnector_404_response

@@ -239,27 +395,160 @@ Any modifications made to this file will be overwritten.

Table of Contents

    -
  1. connector_types -
  2. +
  3. Alert_identifier_mapping - Alert identifier mapping
  4. +
  5. Case_comment_mapping - Case comment mapping
  6. +
  7. Case_description_mapping - Case description mapping
  8. +
  9. Case_identifier_mapping - Case identifier mapping
  10. +
  11. Case_name_mapping - Case name mapping
  12. +
  13. Connector_mappings_properties_for_a_Swimlane_connector - Connector mappings properties for a Swimlane connector
  14. +
  15. Create_connector_request_body_properties - Create connector request body properties
  16. +
  17. Get_connector_types_response_body_properties_inner -
  18. +
  19. Get_connectors_response_body_properties - Get connectors response body properties
  20. +
  21. Rule_name_mapping - Rule name mapping
  22. +
  23. Severity_mapping - Severity mapping
  24. +
  25. Update_connector_request_body_properties - Update connector request body properties
  26. +
  27. config_properties_cases_webhook - Connector request properties for Webhook - Case Management connector
  28. +
  29. config_properties_index - Connector request properties for an index connector
  30. +
  31. config_properties_jira - Connector request properties for a Jira connector
  32. +
  33. config_properties_opsgenie - Connector request properties for an Opsgenie connector
  34. +
  35. config_properties_resilient - Connector request properties for a IBM Resilient connector
  36. +
  37. config_properties_servicenow - Connector request properties for a ServiceNow ITSM connector
  38. +
  39. config_properties_servicenow_itom - Connector request properties for a ServiceNow ITSM connector
  40. +
  41. config_properties_swimlane - Connector request properties for a Swimlane connector
  42. +
  43. connector_response_properties - Connector response properties
  44. +
  45. connector_response_properties_cases_webhook - Connector request properties for a Webhook - Case Management connector
  46. +
  47. connector_response_properties_email - Connector response properties for an email connector
  48. +
  49. connector_response_properties_index - Connector response properties for an index connector
  50. +
  51. connector_response_properties_jira - Connector response properties for a Jira connector
  52. +
  53. connector_response_properties_opsgenie - Connector response properties for an Opsgenie connector
  54. +
  55. connector_response_properties_pagerduty - Connector response properties for a PagerDuty connector
  56. +
  57. connector_response_properties_resilient - Connector response properties for a IBM Resilient connector
  58. +
  59. connector_response_properties_serverlog - Connector response properties for a server log connector
  60. +
  61. connector_response_properties_servicenow - Connector response properties for a ServiceNow ITSM connector
  62. +
  63. connector_response_properties_servicenow_itom - Connector response properties for a ServiceNow ITOM connector
  64. +
  65. connector_response_properties_servicenow_sir - Connector response properties for a ServiceNow SecOps connector
  66. +
  67. connector_response_properties_slack - Connector response properties for a Slack connector
  68. +
  69. connector_response_properties_swimlane - Connector response properties for a Swimlane connector
  70. +
  71. connector_response_properties_teams - Connector response properties for a Microsoft Teams connector
  72. +
  73. connector_response_properties_tines - Connector response properties for a Tines connector
  74. +
  75. connector_response_properties_webhook - Connector response properties for a Webhook connector
  76. +
  77. connector_response_properties_xmatters - Connector response properties for an xMatters connector
  78. +
  79. connector_types - Connector types
  80. +
  81. createConnector_401_response -
  82. +
  83. create_connector_request_cases_webhook - Create Webhook - Case Managment connector request
  84. +
  85. create_connector_request_email - Create email connector request
  86. +
  87. create_connector_request_index - Create index connector request
  88. +
  89. create_connector_request_jira - Create Jira connector request
  90. +
  91. create_connector_request_opsgenie - Create Opsgenie connector request
  92. +
  93. create_connector_request_pagerduty - Create PagerDuty connector request
  94. +
  95. create_connector_request_resilient - Create IBM Resilient connector request
  96. +
  97. create_connector_request_serverlog - Create server log connector request
  98. +
  99. create_connector_request_servicenow - Create ServiceNow ITSM connector request
  100. +
  101. create_connector_request_servicenow_itom - Create ServiceNow ITOM connector request
  102. +
  103. create_connector_request_servicenow_sir - Create ServiceNow SecOps connector request
  104. +
  105. create_connector_request_slack - Create Slack connector request
  106. +
  107. create_connector_request_swimlane - Create Swimlane connector request
  108. +
  109. create_connector_request_teams - Create Microsoft Teams connector request
  110. +
  111. create_connector_request_tines - Create Tines connector request
  112. +
  113. create_connector_request_webhook - Create Webhook connector request
  114. +
  115. create_connector_request_xmatters - Create xMatters connector request
  116. features -
  117. -
  118. getConnectorTypes_200_response_inner -
  119. -
  120. getConnector_200_response -
  121. -
  122. getConnectors_200_response_inner -
  123. +
  124. getConnector_404_response -
  125. +
  126. secrets_properties_cases_webhook - Connector secrets properties for Webhook - Case Management connector
  127. +
  128. secrets_properties_jira - Connector secrets properties for a Jira connector
  129. +
  130. secrets_properties_opsgenie - Connector secrets properties for an Opsgenie connector
  131. +
  132. secrets_properties_resilient - Connector secrets properties for IBM Resilient connector
  133. +
  134. secrets_properties_servicenow - Connector secrets properties for ServiceNow ITOM, ServiceNow ITSM, and ServiceNow SecOps connectors
  135. +
  136. secrets_properties_swimlane - Connector secrets properties for a Swimlane connector
  137. +
  138. updateConnector_400_response -
  139. +
  140. update_connector_request_cases_webhook - Update Webhook - Case Managment connector request
  141. +
  142. update_connector_request_index - Update index connector request
  143. +
  144. update_connector_request_jira - Update Jira connector request
  145. +
  146. update_connector_request_opsgenie - Update Opsgenie connector request
  147. +
  148. update_connector_request_resilient - Update IBM Resilient connector request
  149. +
  150. update_connector_request_serverlog - Update server log connector request
  151. +
  152. update_connector_request_servicenow - Update ServiceNow ITSM connector or ServiceNow SecOps request
  153. +
  154. update_connector_request_servicenow_itom - Create ServiceNow ITOM connector request
  155. +
  156. update_connector_request_swimlane - Update Swimlane connector request
-

connector_types - Up

-
The type of connector. For example, .email, .index, .jira, .opsgenie, or .server-log.
+

Alert_identifier_mapping - Alert identifier mapping Up

+
Mapping for the alert ID.
-
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
-

features - Up

-
The feature that uses the connector. Valid values are alerting, cases, uptime, and siem.
+

Case_comment_mapping - Case comment mapping Up

+
Mapping for the case comments.
-
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
-

getConnectorTypes_200_response_inner - Up

+

Case_description_mapping - Case description mapping Up

+
Mapping for the case description.
+
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
+
+
+

Case_identifier_mapping - Case identifier mapping Up

+
Mapping for the case ID.
+
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
+
+
+

Case_name_mapping - Case name mapping Up

+
Mapping for the case name.
+
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
+
+
+

Connector_mappings_properties_for_a_Swimlane_connector - Connector mappings properties for a Swimlane connector Up

+
The field mapping.
+
+
alertIdConfig (optional)
+
caseIdConfig (optional)
+
caseNameConfig (optional)
+
commentsConfig (optional)
+
descriptionConfig (optional)
+
ruleNameConfig (optional)
+
severityConfig (optional)
+
+
+
+

Create_connector_request_body_properties - Create connector request body properties Up

+
The properties vary depending on the connector type.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .xmatters.
+
connector_type_id
String The type of connector.
+
Enum:
+
.xmatters
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .xmatters.
+
+
+
+

Get_connector_types_response_body_properties_inner - Up

enabled (optional)
Boolean Indicates whether the connector type is enabled in Kibana.
@@ -272,11 +561,165 @@ Any modifications made to this file will be overwritten.
-

getConnector_200_response - Up

+

Get_connectors_response_body_properties - Get connectors response body properties Up

+
The properties vary for each connector type.
+
+
connector_type_id
+
config (optional)
map[String, oas_any_type_not_mapped] The configuration for the connector. Configuration properties vary depending on the connector type.
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
referenced_by_count
Integer Indicates the number of saved objects that reference the connector. If is_preconfigured is true, this value is not calculated.
+
+
+
+

Rule_name_mapping - Rule name mapping Up

+
Mapping for the name of the alert's rule.
+
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
+
+
+

Severity_mapping - Severity mapping Up

+
Mapping for the severity.
+
+
fieldType
String The type of field in Swimlane.
+
id
String The identifier for the field in Swimlane.
+
key
String The key for the field in Swimlane.
+
name
String The name of the field in Swimlane.
+
+
+
+

Update_connector_request_body_properties - Update connector request body properties Up

+
The properties vary depending on the connector type.
+
+
config
+
name
String The display name for the connector.
+
secrets
+
+
+
+

config_properties_cases_webhook - Connector request properties for Webhook - Case Management connector Up

+
Defines properties for connectors when type is .cases-webhook.
+
+
createCommentJson (optional)
String A JSON payload sent to the create comment URL to create a case comment. You can use variables to add Kibana Cases data to the payload. The required variable is case.comment. Due to Mustache template variables (the text enclosed in triple braces, for example, {{{case.title}}}), the JSON is not validated when you create the connector. The JSON is validated once the Mustache variables have been placed when the REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass.
+
createCommentMethod (optional)
String The REST API HTTP request method to create a case comment in the third-party system. Valid values are patch, post, and put.
+
Enum:
+
patch
post
put
+
createCommentUrl (optional)
String The REST API URL to create a case comment by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the xpack.actions.allowedHosts setting, add the hostname to the allowed hosts.
+
createIncidentJson
String A JSON payload sent to the create case URL to create a case. You can use variables to add case data to the payload. Required variables are case.title and case.description. Due to Mustache template variables (which is the text enclosed in triple braces, for example, {{{case.title}}}), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review.
+
createIncidentMethod (optional)
String The REST API HTTP request method to create a case in the third-party system. Valid values are patch, post, and put.
+
Enum:
+
patch
post
put
+
createIncidentResponseKey
String The JSON key in the create case response that contains the external case ID.
+
createIncidentUrl
String The REST API URL to create a case in the third-party system. If you are using the xpack.actions.allowedHosts setting, add the hostname to the allowed hosts.
+
getIncidentResponseExternalTitleKey
String The JSON key in get case response that contains the external case title.
+
getIncidentUrl
String The REST API URL to get the case by ID from the third-party system. If you are using the xpack.actions.allowedHosts setting, add the hostname to the allowed hosts. You can use a variable to add the external system ID to the URL. Due to Mustache template variables (the text enclosed in triple braces, for example, {{{case.title}}}), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass.
+
hasAuth (optional)
Boolean If true, a username and password for login type authentication must be provided.
+
headers (optional)
String A set of key-value pairs sent as headers with the request URLs for the create case, update case, get case, and create comment methods.
+
updateIncidentJson
String The JSON payload sent to the update case URL to update the case. You can use variables to add Kibana Cases data to the payload. Required variables are case.title and case.description. Due to Mustache template variables (which is the text enclosed in triple braces, for example, {{{case.title}}}), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review.
+
updateIncidentMethod (optional)
String The REST API HTTP request method to update the case in the third-party system. Valid values are patch, post, and put.
+
Enum:
+
patch
post
put
+
updateIncidentUrl
String The REST API URL to update the case by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the xpack.actions.allowedHosts setting, add the hostname to the allowed hosts.
+
viewIncidentUrl
String The URL to view the case in the external system. You can use variables to add the external system ID or external system title to the URL.
+
+
+
+

config_properties_index - Connector request properties for an index connector Up

+
Defines properties for connectors when type is .index.
+
+
executionTimeField (optional)
String Specifies a field that will contain the time the alert condition was detected.
+
index
String The Elasticsearch index to be written to.
+
refresh (optional)
Boolean The refresh policy for the write request, which affects when changes are made visible to search. Refer to the refresh setting for Elasticsearch document APIs.
+
+
+
+

config_properties_jira - Connector request properties for a Jira connector Up

+
Defines properties for connectors when type is .jira.
+
+
apiUrl
String The Jira instance URL.
+
projectKey
String The Jira project key.
+
+
+
+

config_properties_opsgenie - Connector request properties for an Opsgenie connector Up

+
Defines properties for connectors when type is .opsgenie.
+
+
apiUrl
String The Opsgenie URL. For example, https://api.opsgenie.com or https://api.eu.opsgenie.com. If you are using the xpack.actions.allowedHosts setting, add the hostname to the allowed hosts.
+
+
+
+

config_properties_resilient - Connector request properties for a IBM Resilient connector Up

+
Defines properties for connectors when type is .resilient.
+
+
apiUrl
String The IBM Resilient instance URL.
+
orgId
String The IBM Resilient organization ID.
+
+
+
+

config_properties_servicenow - Connector request properties for a ServiceNow ITSM connector Up

+
Defines properties for connectors when type is .servicenow.
+
+
apiUrl
String The ServiceNow instance URL.
+
clientId (optional)
String The client ID assigned to your OAuth application. This property is required when isOAuth is true.
+
isOAuth (optional)
String The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth).
+
jwtKeyId (optional)
String The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when isOAuth is true.
+
userIdentifierValue (optional)
String The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is Email, the user identifier should be the user's email address. This property is required when isOAuth is true.
+
usesTableApi (optional)
Boolean Determines whether the connector uses the Table API or the Import Set API. This property is supported only for ServiceNow ITSM and ServiceNow SecOps connectors. NOTE: If this property is set to false, the Elastic application should be installed in ServiceNow.
+
+
+
+

config_properties_servicenow_itom - Connector request properties for a ServiceNow ITSM connector Up

+
Defines properties for connectors when type is .servicenow.
+
+
apiUrl
String The ServiceNow instance URL.
+
clientId (optional)
String The client ID assigned to your OAuth application. This property is required when isOAuth is true.
+
isOAuth (optional)
String The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth).
+
jwtKeyId (optional)
String The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when isOAuth is true.
+
userIdentifierValue (optional)
String The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is Email, the user identifier should be the user's email address. This property is required when isOAuth is true.
+
+
+
+

config_properties_swimlane - Connector request properties for a Swimlane connector Up

+
Defines properties for connectors when type is .swimlane.
+
+
apiUrl
String The Swimlane instance URL.
+
appId
String The Swimlane application ID.
+
connectorType
String The type of connector. Valid values are all, alerts, and cases.
+
Enum:
+
all
alerts
cases
+
mappings (optional)
+
+
+
+

connector_response_properties - Connector response properties Up

+
The properties vary depending on the connector type.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .xmatters.
+
connector_type_id
String The type of connector.
+
Enum:
+
.xmatters
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_cases_webhook - Connector request properties for a Webhook - Case Management connector Up

-
config (optional)
map[String, oas_any_type_not_mapped] The configuration for the connector. Configuration properties vary depending on the connector type.
-
connector_type_id
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.cases-webhook
id
String The identifier for the connector.
is_deprecated
Boolean Indicates whether the connector type is deprecated.
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
@@ -285,17 +728,606 @@ Any modifications made to this file will be overwritten.
-

getConnectors_200_response_inner - Up

+

connector_response_properties_email - Connector response properties for an email connector Up

-
connector_type_id
-
config (optional)
map[String, oas_any_type_not_mapped] The configuration for the connector. Configuration properties vary depending on the connector type.
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .email.
+
connector_type_id
String The type of connector.
+
Enum:
+
.email
id
String The identifier for the connector.
is_deprecated
Boolean Indicates whether the connector type is deprecated.
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
name
String The display name for the connector.
-
referenced_by_count
Integer Indicates the number of saved objects that reference the connector. If is_preconfigured is true, this value is not calculated.
+
+
+
+

connector_response_properties_index - Connector response properties for an index connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.index
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_jira - Connector response properties for a Jira connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.jira
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_opsgenie - Connector response properties for an Opsgenie connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.opsgenie
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_pagerduty - Connector response properties for a PagerDuty connector Up

+
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .pagerduty.
+
connector_type_id
String The type of connector.
+
Enum:
+
.pagerduty
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_resilient - Connector response properties for a IBM Resilient connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.resilient
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_serverlog - Connector response properties for a server log connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.server-log
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_servicenow - Connector response properties for a ServiceNow ITSM connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_servicenow_itom - Connector response properties for a ServiceNow ITOM connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow-itom
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_servicenow_sir - Connector response properties for a ServiceNow SecOps connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow-sir
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_slack - Connector response properties for a Slack connector Up

+
+
+
connector_type_id
String The type of connector.
+
Enum:
+
.slack
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_swimlane - Connector response properties for a Swimlane connector Up

+
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.swimlane
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_teams - Connector response properties for a Microsoft Teams connector Up

+
+
+
connector_type_id
String The type of connector.
+
Enum:
+
.teams
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_tines - Connector response properties for a Tines connector Up

+
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .tines.
+
connector_type_id
String The type of connector.
+
Enum:
+
.tines
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_webhook - Connector response properties for a Webhook connector Up

+
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .webhook.
+
connector_type_id
String The type of connector.
+
Enum:
+
.webhook
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_response_properties_xmatters - Connector response properties for an xMatters connector Up

+
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .xmatters.
+
connector_type_id
String The type of connector.
+
Enum:
+
.xmatters
+
id
String The identifier for the connector.
+
is_deprecated
Boolean Indicates whether the connector type is deprecated.
+
is_missing_secrets (optional)
Boolean Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.
+
is_preconfigured
Boolean Indicates whether it is a preconfigured connector. If true, the config and is_missing_secrets properties are omitted from the response.
+
name
String The display name for the connector.
+
+
+
+

connector_types - Connector types Up

+
The type of connector. For example, .email, .index, .jira, .opsgenie, or .server-log.
+
+
+
+
+

createConnector_401_response - Up

+
+
+
error (optional)
+
message (optional)
+
statusCode (optional)
+
+
+
+

create_connector_request_cases_webhook - Create Webhook - Case Managment connector request Up

+
The Webhook - Case Management connector uses axios to send POST, PUT, and GET requests to a case management RESTful API web service.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.cases-webhook
+
name
String The display name for the connector.
+
secrets (optional)
+
+
+
+

create_connector_request_email - Create email connector request Up

+
The email connector uses the SMTP protocol to send mail messages, using an integration of Nodemailer. An exception is Microsoft Exchange, which uses HTTP protocol for sending emails, Send mail. Email message text is sent as both plain text and html text.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .email.
+
connector_type_id
String The type of connector.
+
Enum:
+
.email
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .email.
+
+
+
+

create_connector_request_index - Create index connector request Up

+
The index connector indexes a document into Elasticsearch.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.index
+
name
String The display name for the connector.
+
+
+
+

create_connector_request_jira - Create Jira connector request Up

+
The Jira connector uses the REST API v2 to create Jira issues.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.jira
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_opsgenie - Create Opsgenie connector request Up

+
The Opsgenie connector uses the Opsgenie alert API.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.opsgenie
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_pagerduty - Create PagerDuty connector request Up

+
The PagerDuty connector uses the v2 Events API to trigger, acknowledge, and resolve PagerDuty alerts.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .pagerduty.
+
connector_type_id
String The type of connector.
+
Enum:
+
.pagerduty
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .pagerduty.
+
+
+
+

create_connector_request_resilient - Create IBM Resilient connector request Up

+
The IBM Resilient connector uses the RESILIENT REST v2 to create IBM Resilient incidents.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.resilient
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_serverlog - Create server log connector request Up

+
This connector writes an entry to the Kibana server log.
+
+
connector_type_id
String The type of connector.
+
Enum:
+
.server-log
+
name
String The display name for the connector.
+
+
+
+

create_connector_request_servicenow - Create ServiceNow ITSM connector request Up

+
The ServiceNow ITSM connector uses the import set API to create ServiceNow incidents. You can use the connector for rule actions and cases.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_servicenow_itom - Create ServiceNow ITOM connector request Up

+
The ServiceNow ITOM connector uses the event API to create ServiceNow events. You can use the connector for rule actions.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow-itom
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_servicenow_sir - Create ServiceNow SecOps connector request Up

+
The ServiceNow SecOps connector uses the import set API to create ServiceNow security incidents. You can use the connector for rule actions and cases.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.servicenow-sir
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_slack - Create Slack connector request Up

+
The Slack connector uses Slack Incoming Webhooks.
+
+
connector_type_id
String The type of connector.
+
Enum:
+
.slack
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .slack.
+
+
+
+

create_connector_request_swimlane - Create Swimlane connector request Up

+
The Swimlane connector uses the Swimlane REST API to create Swimlane records.
+
+
config
+
connector_type_id
String The type of connector.
+
Enum:
+
.swimlane
+
name
String The display name for the connector.
+
secrets
+
+
+
+

create_connector_request_teams - Create Microsoft Teams connector request Up

+
The Microsoft Teams connector uses Incoming Webhooks.
+
+
connector_type_id
String The type of connector.
+
Enum:
+
.teams
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .teams.
+
+
+
+

create_connector_request_tines - Create Tines connector request Up

+
The Tines connector uses Tines Webhook actions to send events via POST request.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .tines.
+
connector_type_id
String The type of connector.
+
Enum:
+
.tines
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .tines.
+
+
+
+

create_connector_request_webhook - Create Webhook connector request Up

+
The Webhook connector uses axios to send a POST or PUT request to a web service.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .webhook.
+
connector_type_id
String The type of connector.
+
Enum:
+
.webhook
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .webhook.
+
+
+
+

create_connector_request_xmatters - Create xMatters connector request Up

+
The xMatters connector uses the xMatters Workflow for Elastic to send actionable alerts to on-call xMatters resources.
+
+
config
map[String, oas_any_type_not_mapped] Defines properties for connectors when type is .xmatters.
+
connector_type_id
String The type of connector.
+
Enum:
+
.xmatters
+
name
String The display name for the connector.
+
secrets
map[String, oas_any_type_not_mapped] Defines secrets for connectors when type is .xmatters.
+
+
+
+

features - Up

+
The feature that uses the connector. Valid values are alerting, cases, uptime, and siem.
+
+
+
+
+

getConnector_404_response - Up

+
+
+
error (optional)
+
message (optional)
+
statusCode (optional)
+
+
+
+

secrets_properties_cases_webhook - Connector secrets properties for Webhook - Case Management connector Up

+
+
+
password (optional)
String The password for HTTP basic authentication. If hasAuth is set to true, this property is required.
+
user (optional)
String The username for HTTP basic authentication. If hasAuth is set to true, this property is required.
+
+
+
+

secrets_properties_jira - Connector secrets properties for a Jira connector Up

+
Defines secrets for connectors when type is .jira.
+
+
apiToken
String The Jira API authentication token for HTTP basic authentication.
+
email
String The account email for HTTP Basic authentication.
+
+
+
+

secrets_properties_opsgenie - Connector secrets properties for an Opsgenie connector Up

+
Defines secrets for connectors when type is .opsgenie.
+
+
apiKey
String The Opsgenie API authentication key for HTTP Basic authentication.
+
+
+
+

secrets_properties_resilient - Connector secrets properties for IBM Resilient connector Up

+
Defines secrets for connectors when type is .resilient.
+
+
apiKeyId
String The authentication key ID for HTTP Basic authentication.
+
apiKeySecret
String The authentication key secret for HTTP Basic authentication.
+
+
+
+

secrets_properties_servicenow - Connector secrets properties for ServiceNow ITOM, ServiceNow ITSM, and ServiceNow SecOps connectors Up

+
Defines secrets for connectors when type is .servicenow, .servicenow-sir, or .servicenow-itom.
+
+
clientSecret (optional)
String The client secret assigned to your OAuth application. This property is required when isOAuth is true.
+
password (optional)
String The password for HTTP basic authentication. This property is required when isOAuth is false.
+
privateKey (optional)
String The RSA private key that you created for use in ServiceNow. This property is required when isOAuth is true.
+
privateKeyPassword (optional)
String The password for the RSA private key. This property is required when isOAuth is true and you set a password on your private key.
+
username (optional)
String The username for HTTP basic authentication. This property is required when isOAuth is false.
+
+
+
+

secrets_properties_swimlane - Connector secrets properties for a Swimlane connector Up

+
Defines secrets for connectors when type is .swimlane.
+
+
apiToken (optional)
String Swimlane API authentication token.
+
+
+
+

updateConnector_400_response - Up

+
+
+
error (optional)
+
message (optional)
+
statusCode (optional)
+
+
+ +
+

update_connector_request_index - Update index connector request Up

+
+
+
config
+
name
String The display name for the connector.
+
+
+
+

update_connector_request_jira - Update Jira connector request Up

+
+
+
config
+
name
String The display name for the connector.
+
secrets
+
+
+ + +
+

update_connector_request_serverlog - Update server log connector request Up

+
+
+
name
String The display name for the connector.
+
+
+ + + diff --git a/docs/api-generated/rules/rule-apis-passthru.asciidoc b/docs/api-generated/rules/rule-apis-passthru.asciidoc index 0e9260905cbc8..8ef9fdfacf560 100644 --- a/docs/api-generated/rules/rule-apis-passthru.asciidoc +++ b/docs/api-generated/rules/rule-apis-passthru.asciidoc @@ -22,7 +22,9 @@ Any modifications made to this file will be overwritten.
  • post /s/{spaceId}/api/alerting/rule/{ruleId}/_disable
  • post /s/{spaceId}/api/alerting/rule/{ruleId}/_enable
  • get /s/{spaceId}/api/alerting/rules/_find
  • +
  • get /s/{spaceId}/api/alerting/_health
  • get /s/{spaceId}/api/alerting/rule/{ruleId}
  • +
  • get /s/{spaceId}/api/alerting/rule_types
  • post /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_mute
  • post /s/{spaceId}/api/alerting/rule/{ruleId}/_mute_all
  • post /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_unmute
  • @@ -63,18 +65,30 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response +

    404

    + Object is not found. + 404_response
    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/_disable
    -
    Disable a rule. (disableRule)
    +
    Disables a rule. (disableRule)
    You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features.

    Path parameters

    @@ -102,18 +116,30 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response +

    404

    + Object is not found. + 404_response

    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/_enable
    -
    Enable a rule. (enableRule)
    +
    Enables a rule. (enableRule)
    This API supports token-based authentication only. You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features.

    Path parameters

    @@ -141,11 +167,23 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response +

    404

    + Object is not found. + 401_response

    +
    +
    +
    + Up +
    get /s/{spaceId}/api/alerting/_health
    +
    Retrieves the health status of the alerting framework. (getAlertingHealth)
    +
    You must have read privileges for the Management > Stack Rules feature or for at least one of the Analytics > Discover, Analytics > Machine Learning, Observability, or Security features.
    + +

    Path parameters

    +
    +
    spaceId (required)
    + +
    Path Parameter — An identifier for the space. If /s/ and the identifier are omitted from the path, the default space is used. default: null
    +
    + + + + + + +

    Return type

    + + + + +

    Example data

    +
    Content-Type: application/json
    +
    {
    +  "alerting_framework_health" : {
    +    "execution_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    },
    +    "read_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    },
    +    "decryption_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    }
    +  },
    +  "alerting_framework_heath" : {
    +    "_deprecated" : "This state property has a typo, use \"alerting_framework_health\" instead.",
    +    "execution_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    },
    +    "read_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    },
    +    "decryption_health" : {
    +      "status" : "ok",
    +      "timestamp" : "2023-01-13T01:28:00.28Z"
    +    }
    +  },
    +  "has_permanent_encryption_key" : true,
    +  "is_sufficiently_secure" : true
    +}
    + +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +
    + +

    Responses

    +

    200

    + Indicates a successful call. + getAlertingHealth_200_response +

    401

    + Authorization information is missing or invalid. + 401_response

    Up
    get /s/{spaceId}/api/alerting/rule/{ruleId}
    -
    Retrieve a rule by its identifier. (getRule)
    +
    Retrieves a rule by its identifier. (getRule)
    You must have read privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rules you're seeking. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability features, or Security features. To get rules associated with the Stack Monitoring feature, use the monitoring_user built-in role.

    Path parameters

    @@ -424,13 +544,154 @@ Any modifications made to this file will be overwritten.

    200

    Indicates a successful call. rule_response_properties +

    401

    + Authorization information is missing or invalid. + 401_response +

    404

    + Object is not found. + 404_response +
    +
    +
    +
    + Up +
    get /s/{spaceId}/api/alerting/rule_types
    +
    Retrieves a list of rule types. (getRuleTypes)
    +
    If you have read privileges for one or more Kibana features, the API response contains information about the appropriate rule types. For example, there are rule types associated with the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability features, and Security features. To get rule types associated with the Stack Monitoring feature, use the monitoring_user built-in role.
    + +

    Path parameters

    +
    +
    spaceId (required)
    + +
    Path Parameter — An identifier for the space. If /s/ and the identifier are omitted from the path, the default space is used. default: null
    +
    + + + + + + +

    Return type

    + + + + +

    Example data

    +
    Content-Type: application/json
    +
    {
    +  "recovery_action_group" : {
    +    "name" : "name",
    +    "id" : "id"
    +  },
    +  "does_set_recovery_context" : true,
    +  "is_exportable" : true,
    +  "authorized_consumers" : {
    +    "alerts" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "discover" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "stackAlerts" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "infrastructure" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "siem" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "monitoring" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "logs" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "apm" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "ml" : {
    +      "all" : true,
    +      "read" : true
    +    },
    +    "uptime" : {
    +      "all" : true,
    +      "read" : true
    +    }
    +  },
    +  "action_groups" : [ {
    +    "name" : "name",
    +    "id" : "id"
    +  }, {
    +    "name" : "name",
    +    "id" : "id"
    +  } ],
    +  "minimum_license_required" : "basic",
    +  "action_variables" : {
    +    "context" : [ {
    +      "name" : "name",
    +      "description" : "description",
    +      "useWithTripleBracesInTemplates" : true
    +    }, {
    +      "name" : "name",
    +      "description" : "description",
    +      "useWithTripleBracesInTemplates" : true
    +    } ],
    +    "state" : [ {
    +      "name" : "name",
    +      "description" : "description"
    +    }, {
    +      "name" : "name",
    +      "description" : "description"
    +    } ],
    +    "params" : [ {
    +      "name" : "name",
    +      "description" : "description"
    +    }, {
    +      "name" : "name",
    +      "description" : "description"
    +    } ]
    +  },
    +  "rule_task_timeout" : "5m",
    +  "name" : "name",
    +  "enabled_in_license" : true,
    +  "producer" : "stackAlerts",
    +  "id" : "id",
    +  "default_action_group_id" : "default_action_group_id"
    +}
    + +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +
    + +

    Responses

    +

    200

    + Indicates a successful call. + +

    401

    + Authorization information is missing or invalid. + 401_response

    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_mute
    -
    Mute an alert. (muteAlert)
    +
    Mutes an alert. (muteAlert)
    You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features. If the rule has actions, you must also have read privileges for the Management > Actions and Connectors feature.

    Path parameters

    @@ -460,18 +721,27 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response

    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/_mute_all
    -
    Mute all alerts. (muteAllAlerts)
    +
    Mutes all alerts. (muteAllAlerts)
    This API snoozes the notifications for the rule indefinitely. The rule checks continue to occur but alerts will not trigger any actions. You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features. If the rule has actions, you must also have read privileges for the Management > Actions and Connectors feature.

    Path parameters

    @@ -499,18 +769,27 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response

    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_unmute
    -
    Unmute an alert. (unmuteAlert)
    +
    Unmutes an alert. (unmuteAlert)
    You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features. If the rule has actions, you must also have read privileges for the Management > Actions and Connectors feature.

    Path parameters

    @@ -540,18 +819,27 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response

    Up
    post /s/{spaceId}/api/alerting/rule/{ruleId}/_unmute_all
    -
    Unmute all alerts. (unmuteAllAlerts)
    +
    Unmutes all alerts. (unmuteAllAlerts)
    If the rule has its notifications snoozed indefinitely, this API cancels the snooze. You must have all privileges for the appropriate Kibana features, depending on the consumer and rule_type_id of the rule. For example, the Management > Stack Rules feature, Analytics > Discover and Machine Learning features, Observability, and Security features. If the rule has actions, you must also have read privileges for the Management > Actions and Connectors feature.

    Path parameters

    @@ -579,11 +867,20 @@ Any modifications made to this file will be overwritten. +

    Produces

    + This API call produces the following media types according to the Accept request header; + the media type will be conveyed by the Content-Type response header. +
      +
    • application/json
    • +

    Responses

    204

    Indicates a successful call. +

    401

    + Authorization information is missing or invalid. + 401_response


    @@ -710,10 +1013,27 @@ Any modifications made to this file will be overwritten.

    Table of Contents

      +
    1. 401_response - Unsuccessful rule API response
    2. +
    3. 404_response -
    4. actions_inner -
    5. findRules_200_response -
    6. findRules_has_reference_parameter -
    7. findRules_search_fields_parameter -
    8. +
    9. getAlertingHealth_200_response -
    10. +
    11. getAlertingHealth_200_response_alerting_framework_health -
    12. +
    13. getAlertingHealth_200_response_alerting_framework_health_decryption_health -
    14. +
    15. getAlertingHealth_200_response_alerting_framework_health_execution_health -
    16. +
    17. getAlertingHealth_200_response_alerting_framework_health_read_health -
    18. +
    19. getAlertingHealth_200_response_alerting_framework_heath -
    20. +
    21. getAlertingHealth_200_response_alerting_framework_heath_decryption_health -
    22. +
    23. getRuleTypes_200_response_inner -
    24. +
    25. getRuleTypes_200_response_inner_action_groups_inner -
    26. +
    27. getRuleTypes_200_response_inner_action_variables -
    28. +
    29. getRuleTypes_200_response_inner_action_variables_context_inner -
    30. +
    31. getRuleTypes_200_response_inner_action_variables_params_inner -
    32. +
    33. getRuleTypes_200_response_inner_authorized_consumers -
    34. +
    35. getRuleTypes_200_response_inner_authorized_consumers_alerts -
    36. +
    37. getRuleTypes_200_response_inner_recovery_action_group -
    38. notify_when -
    39. rule_response_properties - Rule response properties
    40. rule_response_properties_execution_status -
    41. @@ -723,6 +1043,32 @@ Any modifications made to this file will be overwritten.
    42. update_rule_request - Update rule request
    +
    +

    401_response - Unsuccessful rule API response Up

    +
    +
    +
    error (optional)
    +
    Enum:
    +
    Unauthorized
    +
    message (optional)
    +
    statusCode (optional)
    +
    Enum:
    +
    401
    +
    +
    +
    +

    404_response - Up

    +
    +
    +
    error (optional)
    +
    Enum:
    +
    Not Found
    +
    message (optional)
    +
    statusCode (optional)
    +
    Enum:
    +
    404
    +
    +

    actions_inner - Up

    @@ -756,6 +1102,158 @@ Any modifications made to this file will be overwritten.
    +
    +

    getAlertingHealth_200_response - Up

    +
    +
    +
    alerting_framework_heath (optional)
    +
    alerting_framework_health (optional)
    +
    has_permanent_encryption_key (optional)
    Boolean If false, the encrypted saved object plugin does not have a permanent encryption key.
    +
    is_sufficiently_secure (optional)
    Boolean If false, security is enabled but TLS is not.
    +
    +
    +
    +

    getAlertingHealth_200_response_alerting_framework_health - Up

    +
    Three substates identify the health of the alerting framework: decryption_health, execution_health, and read_health.
    + +
    +
    +

    getAlertingHealth_200_response_alerting_framework_health_decryption_health - Up

    +
    The timestamp and status of the rule decryption.
    +
    +
    status (optional)
    +
    Enum:
    +
    error
    ok
    warn
    +
    timestamp (optional)
    Date format: date-time
    +
    +
    +
    +

    getAlertingHealth_200_response_alerting_framework_health_execution_health - Up

    +
    The timestamp and status of the rule run.
    +
    +
    status (optional)
    +
    Enum:
    +
    error
    ok
    warn
    +
    timestamp (optional)
    Date format: date-time
    +
    +
    +
    +

    getAlertingHealth_200_response_alerting_framework_health_read_health - Up

    +
    The timestamp and status of the rule reading events.
    +
    +
    status (optional)
    +
    Enum:
    +
    error
    ok
    warn
    +
    timestamp (optional)
    Date format: date-time
    +
    +
    + +
    +

    getAlertingHealth_200_response_alerting_framework_heath_decryption_health - Up

    +
    +
    +
    status (optional)
    +
    timestamp (optional)
    Date format: date-time
    +
    +
    +
    +

    getRuleTypes_200_response_inner - Up

    +
    +
    +
    action_groups (optional)
    array[getRuleTypes_200_response_inner_action_groups_inner] An explicit list of groups for which the rule type can schedule actions, each with the action group's unique ID and human readable name. Rule actions validation uses this configuration to ensure that groups are valid.
    +
    action_variables (optional)
    +
    authorized_consumers (optional)
    +
    default_action_group_id (optional)
    String The default identifier for the rule type group.
    +
    does_set_recovery_context (optional)
    Boolean Indicates whether the rule passes context variables to its recovery action.
    +
    enabled_in_license (optional)
    Boolean Indicates whether the rule type is enabled or disabled based on the subscription.
    +
    id (optional)
    String The unique identifier for the rule type.
    +
    is_exportable (optional)
    Boolean Indicates whether the rule type is exportable in Stack Management > Saved Objects.
    +
    minimum_license_required (optional)
    String The subscriptions required to use the rule type.
    +
    name (optional)
    String The descriptive name of the rule type.
    +
    producer (optional)
    String An identifier for the application that produces this rule type.
    +
    recovery_action_group (optional)
    +
    rule_task_timeout (optional)
    +
    +
    + +
    +

    getRuleTypes_200_response_inner_action_variables - Up

    +
    A list of action variables that the rule type makes available via context and state in action parameter templates, and a short human readable description. When you create a rule in Kibana, it uses this information to prompt you for these variables in action parameter editors.
    + +
    +
    +

    getRuleTypes_200_response_inner_action_variables_context_inner - Up

    +
    +
    +
    name (optional)
    +
    description (optional)
    +
    useWithTripleBracesInTemplates (optional)
    +
    +
    +
    +

    getRuleTypes_200_response_inner_action_variables_params_inner - Up

    +
    +
    +
    description (optional)
    +
    name (optional)
    +
    +
    + + +
    +

    getRuleTypes_200_response_inner_recovery_action_group - Up

    +
    An action group to use when an alert goes from an active state to an inactive one.
    +
    +
    id (optional)
    +
    name (optional)
    +
    +

    notify_when - Up

    Indicates how often alerts generate actions. Valid values include: onActionGroupChange: Actions run when the alert status changes; onActiveAlert: Actions run when the alert becomes active and at each check interval while the rule conditions are met; onThrottleInterval: Actions run when the alert becomes active and at the interval specified in the throttle property while the rule conditions are met.
    diff --git a/docs/api/actions-and-connectors/create.asciidoc b/docs/api/actions-and-connectors/create.asciidoc index cdaab61e5581e..259c5dfee00af 100644 --- a/docs/api/actions-and-connectors/create.asciidoc +++ b/docs/api/actions-and-connectors/create.asciidoc @@ -6,6 +6,12 @@ Creates a connector. +[NOTE] +==== +For the most up-to-date API details, refer to the +{kib-repo}/tree/{branch}/x-pack/plugins/actions/docs/openapi[open API specification]. For a preview, check out <>. +==== + [[create-connector-api-request]] === {api-request-title} @@ -121,9 +127,9 @@ the selected user field is `Email`, the user identifier should be the user's email address. This property is required when `isOAuth` is `true`. `usesTableApi`:: -(Optional, string) Determines whether the connector uses the Table API or the +(Optional, boolean) Determines whether the connector uses the Table API or the Import Set API. This property is supported only for {sn-itsm} and {sn-sir} -connectors. +connectors. The default value is `true`. + NOTE: If this property is set to false, the Elastic application should be installed in {sn}. @@ -152,7 +158,7 @@ installed in {sn}. (Optional, object) Mapping for the alert ID. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -167,7 +173,7 @@ installed in {sn}. (Optional, object) Mapping for the case ID. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -182,7 +188,7 @@ installed in {sn}. (Optional, object) Mapping for the case name. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -197,7 +203,7 @@ installed in {sn}. (Optional, object) Mapping for the case comments. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -212,7 +218,7 @@ installed in {sn}. (Optional, object) Mapping for the case description. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -227,7 +233,7 @@ installed in {sn}. (Optional, object) Mapping for the name of the alert's rule. `fieldType`:::: -(Required, Object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. @@ -242,7 +248,7 @@ installed in {sn}. (Optional, object) Mapping for the severity. `fieldType`:::: -(Required, object) The type of the field in {swimlane}. +(Required, string) The type of the field in {swimlane}. `id`:::: (Required, string) The id of the field in {swimlane}. diff --git a/docs/api/actions-and-connectors/execute.asciidoc b/docs/api/actions-and-connectors/execute.asciidoc index a3e10efc5720b..7fbaae439094e 100644 --- a/docs/api/actions-and-connectors/execute.asciidoc +++ b/docs/api/actions-and-connectors/execute.asciidoc @@ -178,7 +178,7 @@ the `subAction` value. (Optional, array of strings) The custom actions available to the alert. `alias`:::: -(Optional, string) The unique identifier used for alert de-duplication in {opsgenie}. +(Optional, string) The unique identifier used for alert deduplication in {opsgenie}. `description`:::: (Optional, string) A description that provides detailed information about the alert. @@ -258,7 +258,7 @@ required. [%collapsible%open] ====== `alias`:::: -(Required, string) The unique identifier used for alert de-duplication in {opsgenie}. +(Required, string) The unique identifier used for alert deduplication in {opsgenie}. The alias must match the value used when creating the alert. `note`:::: diff --git a/docs/api/actions-and-connectors/update.asciidoc b/docs/api/actions-and-connectors/update.asciidoc index 16fb327e61931..b690d3fac995b 100644 --- a/docs/api/actions-and-connectors/update.asciidoc +++ b/docs/api/actions-and-connectors/update.asciidoc @@ -6,6 +6,12 @@ Updates the attributes for a connector. +[NOTE] +==== +For the most up-to-date API details, refer to the +{kib-repo}/tree/{branch}/x-pack/plugins/actions/docs/openapi[open API specification]. For a preview, check out <>. +==== + [[update-connector-api-request]] === {api-request-title} diff --git a/docs/api/alerting/health.asciidoc b/docs/api/alerting/health.asciidoc index 1f0c8936419b5..ce22ece799b76 100644 --- a/docs/api/alerting/health.asciidoc +++ b/docs/api/alerting/health.asciidoc @@ -6,6 +6,12 @@ Retrieve the health status of the alerting framework. +[NOTE] +==== +For the most up-to-date API details, refer to the +{kib-repo}/tree/{branch}/x-pack/plugins/alerting/docs/openapi[open API specification]. For a preview, check out <>. +==== + [[get-alerting-framework-health-api-request]] === {api-request-title} diff --git a/docs/api/alerting/list_rule_types.asciidoc b/docs/api/alerting/list_rule_types.asciidoc index 1d37ff9e4dbcc..32b4be086705a 100644 --- a/docs/api/alerting/list_rule_types.asciidoc +++ b/docs/api/alerting/list_rule_types.asciidoc @@ -6,6 +6,13 @@ Retrieve a list of rule types that the user is authorized to access. +[NOTE] +==== +For the most up-to-date API details, refer to the +{kib-repo}/tree/{branch}/x-pack/plugins/alerting/docs/openapi[open API specification]. For a preview, check out <>. +==== + + [[list-rule-types-api-request]] === {api-request-title} diff --git a/docs/developer/advanced/upgrading-nodejs.asciidoc b/docs/developer/advanced/upgrading-nodejs.asciidoc index 348a43c0595ff..16e8502450c17 100644 --- a/docs/developer/advanced/upgrading-nodejs.asciidoc +++ b/docs/developer/advanced/upgrading-nodejs.asciidoc @@ -13,11 +13,11 @@ These files must be updated when upgrading Node.js: If they are not, and the update is urgent, you can skip this file and update it later once Docker Hub has been updated. - {kib-repo}blob/{branch}/.node-version[`.node-version`] - {kib-repo}blob/{branch}/.nvmrc[`.nvmrc`] - - {kib-repo}blob/{branch}/package.json[`package.json`] - The version is specified in the `engines.node` field. + - {kib-repo}blob/{branch}/package.json[`package.json`] - The version is specified in the `engines.node` field (if possible, also upgrade `@types/node` to match the new version, both under `devDependencies` and `resolutions`). - {kib-repo}blob/{branch}/WORKSPACE.bazel[`WORKSPACE.bazel`] - The version is specified in the `node_version` property. Besides this property, the list of files under `node_repositories` must be updated along with their respective SHA256 hashes. These can be found on the https://nodejs.org[nodejs.org] website. - Example for Node.js v16.18.1: https://nodejs.org/dist/v16.18.1/SHASUMS256.txt.asc + Example for Node.js v18.13.0: https://nodejs.org/dist/v18.13.0/SHASUMS256.txt.asc See PR {kib-repo}pull/128123[#128123] for an example of how the Node.js version has been upgraded previously. diff --git a/docs/management/cases/add-connectors.asciidoc b/docs/management/cases/add-connectors.asciidoc index dac588b99950d..c193a42b8fb29 100644 --- a/docs/management/cases/add-connectors.asciidoc +++ b/docs/management/cases/add-connectors.asciidoc @@ -26,8 +26,11 @@ as described in <>. Alternatively, you can create them in . Click *Edit external connection*. + +-- [role="screenshot"] image::images/cases-connectors.png[] +// NOTE: This is an autogenerated screenshot. Do not edit it directly. +-- . From the *Incident management system* list, select *Add new connector*. diff --git a/docs/management/cases/cases.asciidoc b/docs/management/cases/cases.asciidoc index de2f2196ee63f..dc72b453f5e94 100644 --- a/docs/management/cases/cases.asciidoc +++ b/docs/management/cases/cases.asciidoc @@ -10,6 +10,7 @@ management systems by configuring connectors. [role="screenshot"] image::images/cases.png[Cases page] +// NOTE: This is an autogenerated screenshot. Do not edit it directly. NOTE: If you create cases in the {observability} or {security-app}, they are not visible in *{stack-manage-app}*. Likewise, the cases you create in diff --git a/docs/management/cases/images/cases-connectors.png b/docs/management/cases/images/cases-connectors.png index 95af429aef2de..deec94f09871a 100644 Binary files a/docs/management/cases/images/cases-connectors.png and b/docs/management/cases/images/cases-connectors.png differ diff --git a/docs/management/cases/manage-cases.asciidoc b/docs/management/cases/manage-cases.asciidoc index 71b1694e046a8..1a04a8a00e24b 100644 --- a/docs/management/cases/manage-cases.asciidoc +++ b/docs/management/cases/manage-cases.asciidoc @@ -32,6 +32,7 @@ example, you can portray event and alert data through charts and graphs. [role="screenshot"] image::images/cases-visualization.png[Cases page] +// NOTE: This is an autogenerated screenshot. Do not edit it directly. To add a visualization to a comment within your case: diff --git a/docs/management/connectors/action-types/opsgenie.asciidoc b/docs/management/connectors/action-types/opsgenie.asciidoc index 384595be2fae8..6f96933c59bf8 100644 --- a/docs/management/connectors/action-types/opsgenie.asciidoc +++ b/docs/management/connectors/action-types/opsgenie.asciidoc @@ -88,7 +88,7 @@ Message:: The message for the alert (required). Opsgenie tags:: The tags for the alert (optional). Priority:: The priority level for the alert. Description:: A description that provides detailed information about the alert (optional). -Alias:: The alert identifier, which is used for alert de-duplication in Opsgenie. For more information, refer to the https://support.atlassian.com/opsgenie/docs/what-is-alert-de-duplication/[Opsgenie documentation] (optional). +Alias:: The alert identifier, which is used for alert deduplication in Opsgenie. For more information, refer to the https://support.atlassian.com/opsgenie/docs/what-is-alert-de-duplication/[Opsgenie documentation] (optional). Entity:: The domain of the alert (optional). Source:: The source of the alert (optional). User:: The display name of the owner (optional). @@ -145,7 +145,7 @@ Example JSON editor contents The close alert action has the following configuration properties. -Alias:: The alert identifier, which is used for alert de-duplication in Opsgenie (required). The alias must match the value used when creating the alert. For more information, refer to the https://support.atlassian.com/opsgenie/docs/what-is-alert-de-duplication/[Opsgenie documentation]. +Alias:: The alert identifier, which is used for alert deduplication in Opsgenie (required). The alias must match the value used when creating the alert. For more information, refer to the https://support.atlassian.com/opsgenie/docs/what-is-alert-de-duplication/[Opsgenie documentation]. Note:: Additional information for the alert (optional). Source:: The display name of the source (optional). User:: The display name of the owner (optional). diff --git a/docs/maps/connect-to-ems.asciidoc b/docs/maps/connect-to-ems.asciidoc index f3e0709f7f506..6a2ed12d9c536 100644 --- a/docs/maps/connect-to-ems.asciidoc +++ b/docs/maps/connect-to-ems.asciidoc @@ -66,7 +66,7 @@ endif::[] [[elastic-maps-server-configuration]] ==== Configuration -{hosted-ems} reads properties from a configuration file in YAML format that is validated on startup. The location of this file is provided by the `EMS_PATH_CONF` environment variable and defaults to `/usr/src/app/server/config/elastic-maps-server.yml`. +{hosted-ems} reads properties from a configuration file in YAML format that is validated on startup. The location of this file is provided by the `EMS_PATH_CONF` container environment variable and defaults to `/usr/src/app/server/config/elastic-maps-server.yml`. This environment variable can be changed by making use of the `-e` docker flag of the start command. *General settings* diff --git a/docs/osquery/images/case-button-osquery.png b/docs/osquery/images/case-button-osquery.png new file mode 100644 index 0000000000000..9fc908984df68 Binary files /dev/null and b/docs/osquery/images/case-button-osquery.png differ diff --git a/docs/osquery/images/discover-button-osquery.png b/docs/osquery/images/discover-button-osquery.png new file mode 100644 index 0000000000000..599f3f3578e90 Binary files /dev/null and b/docs/osquery/images/discover-button-osquery.png differ diff --git a/docs/osquery/images/enter-query.png b/docs/osquery/images/enter-query.png index 6043eb3632982..189edc551c6b1 100644 Binary files a/docs/osquery/images/enter-query.png and b/docs/osquery/images/enter-query.png differ diff --git a/docs/osquery/images/lens-button-osquery.png b/docs/osquery/images/lens-button-osquery.png new file mode 100644 index 0000000000000..92c79f0f206ac Binary files /dev/null and b/docs/osquery/images/lens-button-osquery.png differ diff --git a/docs/osquery/images/live-query-check-results.png b/docs/osquery/images/live-query-check-results.png index f52a96a3d64f6..758b543367e82 100644 Binary files a/docs/osquery/images/live-query-check-results.png and b/docs/osquery/images/live-query-check-results.png differ diff --git a/docs/osquery/images/view-osquery-details.png b/docs/osquery/images/view-osquery-details.png new file mode 100644 index 0000000000000..3dc0daca5a50f Binary files /dev/null and b/docs/osquery/images/view-osquery-details.png differ diff --git a/docs/osquery/osquery.asciidoc b/docs/osquery/osquery.asciidoc index eccee409ec68f..2f6e0657b42af 100644 --- a/docs/osquery/osquery.asciidoc +++ b/docs/osquery/osquery.asciidoc @@ -54,7 +54,13 @@ image::images/enter-query.png[Select saved query dropdown name showing query nam + TIP: To save a single query for future use, click *Save for later* and define the ID, description, and other <>. -. Review the results. Next, navigate to *Discover* to dive deeper into the response or to *Lens* to create visualizations. +. Review the results and do any of the following: + +** Click *View in Discover* (image:images/discover-button-osquery.png[View in Discover icon,20,20]) to explore the results in *Discover*. +** Click *View in Lens* (image:images/lens-button-osquery.png[View in Lens icon,20,20]) to navigate to *Lens*, where you can use the drag-and-drop *Lens* editor to create visualizations. +** Click *Add to Case* (image:images/case-button-osquery.png[Add to Case icon,20,20]) to add the query results to a new or existing case. +** Click the view details icon (image:images/view-osquery-details.png[View details icon,20,20]) to examine the query ID and statement. + . To view more information about the request, such as failures, open the *Status* tab. [float] diff --git a/examples/controls_example/public/search_example.tsx b/examples/controls_example/public/search_example.tsx index 0fba77fa8ddfe..db2a291af1a0d 100644 --- a/examples/controls_example/public/search_example.tsx +++ b/examples/controls_example/public/search_example.tsx @@ -7,7 +7,7 @@ */ import React, { useEffect, useState } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { lastValueFrom } from 'rxjs'; import type { DataPublicPluginStart } from '@kbn/data-plugin/public'; import type { DataView } from '@kbn/data-views-plugin/public'; @@ -74,7 +74,7 @@ export const SearchExample = ({ data, dataView, navigation }: Props) => { const { rawResponse: resp } = await lastValueFrom( searchSource.fetch$({ abortSignal: abortController.signal, - sessionId: uuid(), + sessionId: uuidv4(), legacyHitsTotal: false, }) ); diff --git a/examples/guided_onboarding_example/kibana.json b/examples/guided_onboarding_example/kibana.json index 331f84525c668..57466230ca5e7 100755 --- a/examples/guided_onboarding_example/kibana.json +++ b/examples/guided_onboarding_example/kibana.json @@ -7,7 +7,7 @@ "githubTeam": "platform-onboarding" }, "description": "Example plugin to consume guidedOnboarding", - "server": false, + "server": true, "ui": true, "requiredPlugins": ["navigation", "guidedOnboarding"], "optionalPlugins": [] diff --git a/examples/guided_onboarding_example/server/index.ts b/examples/guided_onboarding_example/server/index.ts new file mode 100644 index 0000000000000..dbcdfe70c67ee --- /dev/null +++ b/examples/guided_onboarding_example/server/index.ts @@ -0,0 +1,12 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { PluginInitializerContext } from '@kbn/core/server'; +import { GuidedOnboardingExamplePlugin } from './plugin'; + +export const plugin = (ctx: PluginInitializerContext) => new GuidedOnboardingExamplePlugin(ctx); diff --git a/examples/guided_onboarding_example/server/plugin.ts b/examples/guided_onboarding_example/server/plugin.ts new file mode 100644 index 0000000000000..40b90f9aa77c1 --- /dev/null +++ b/examples/guided_onboarding_example/server/plugin.ts @@ -0,0 +1,36 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { GuidedOnboardingPluginSetup } from '@kbn/guided-onboarding-plugin/server'; +import { PluginInitializerContext, CoreSetup, Plugin, Logger } from '@kbn/core/server'; +import { testGuideId, testGuideConfig } from '@kbn/guided-onboarding'; + +interface PluginsSetup { + guidedOnboarding: GuidedOnboardingPluginSetup; +} + +export class GuidedOnboardingExamplePlugin implements Plugin { + private readonly logger: Logger; + + constructor(initializerContext: PluginInitializerContext) { + this.logger = initializerContext.logger.get(); + } + + public setup(coreSetup: CoreSetup, { guidedOnboarding }: PluginsSetup) { + this.logger.debug('guidedOnboardingExample: Setup'); + guidedOnboarding.registerGuideConfig(testGuideId, testGuideConfig); + return {}; + } + + public start() { + this.logger.debug('guidedOnboardingExample: Started'); + return {}; + } + + public stop() {} +} diff --git a/examples/guided_onboarding_example/server/types.ts b/examples/guided_onboarding_example/server/types.ts new file mode 100644 index 0000000000000..c488ac71479b0 --- /dev/null +++ b/examples/guided_onboarding_example/server/types.ts @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +// eslint-disable-next-line @typescript-eslint/no-empty-interface +export interface GuidedOnboardingExamplePluginSetup {} + +// eslint-disable-next-line @typescript-eslint/no-empty-interface +export interface GuidedOnboardingExamplePluginStart {} diff --git a/examples/search_examples/server/fibonacci_strategy.ts b/examples/search_examples/server/fibonacci_strategy.ts index 87419d8fe6be4..8317834dcbb3d 100644 --- a/examples/search_examples/server/fibonacci_strategy.ts +++ b/examples/search_examples/server/fibonacci_strategy.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ISearchStrategy } from '@kbn/data-plugin/server'; import { FibonacciRequest, FibonacciResponse } from '../common/types'; @@ -17,7 +17,7 @@ export const fibonacciStrategyProvider = (): ISearchStrategy< const responseMap = new Map(); return { search: (request: FibonacciRequest) => { - const id = request.id ?? uuid(); + const id = request.id ?? uuidv4(); const [sequence, total, started] = responseMap.get(id) ?? [ [], request.params?.n ?? 0, diff --git a/fleet_packages.json b/fleet_packages.json index 2b938cc2e56c5..a258e60fcc8bc 100644 --- a/fleet_packages.json +++ b/fleet_packages.json @@ -20,7 +20,7 @@ [ { "name": "apm", - "version": "8.7.0-preview-1673519880", + "version": "8.7.0-preview-1674061297", "forceAlignStackVersion": true }, { @@ -41,6 +41,6 @@ }, { "name": "security_detection_engine", - "version": "8.4.1" + "version": "8.4.2-beta.1" } ] \ No newline at end of file diff --git a/nav-kibana-dev.docnav.json b/nav-kibana-dev.docnav.json index 05a1b8e95d78c..683722674a631 100644 --- a/nav-kibana-dev.docnav.json +++ b/nav-kibana-dev.docnav.json @@ -117,7 +117,7 @@ "label": "Tutorials", "items": [ { - "id": "kibDevTutorialAddingPerformanceMetrics" + "id": "kibDevTutorialAddingCustomPerformanceMetrics" }, { "id": "kibDevTutorialSetupWindowsDevWSL" diff --git a/package.json b/package.json index f1b62441a17ae..397b1d16b093e 100644 --- a/package.json +++ b/package.json @@ -56,7 +56,7 @@ "makelogs": "node scripts/makelogs", "spec_to_console": "node scripts/spec_to_console", "start": "node scripts/kibana --dev", - "storybook": "node scripts/storybook", + "storybook": "node --openssl-legacy-provider scripts/storybook", "test:ftr": "node scripts/functional_tests", "test:ftr:runner": "node scripts/functional_test_runner", "test:ftr:server": "node scripts/functional_tests_server", @@ -68,11 +68,11 @@ "url": "https://github.com/elastic/kibana.git" }, "engines": { - "node": "16.18.1", + "node": "18.13.0", "yarn": "^1.22.19" }, "resolutions": { - "**/@types/node": "16.11.41", + "**/@types/node": "18.11.18", "**/chokidar": "^3.5.3", "**/deepmerge": "^4.2.2", "**/fast-deep-equal": "^3.1.1", @@ -107,7 +107,7 @@ "@elastic/datemath": "5.0.3", "@elastic/elasticsearch": "npm:@elastic/elasticsearch-canary@8.5.0-canary.1", "@elastic/ems-client": "8.3.3", - "@elastic/eui": "72.2.0", + "@elastic/eui": "73.0.0", "@elastic/filesaver": "1.1.2", "@elastic/node-crypto": "1.2.1", "@elastic/numeral": "^2.5.1", @@ -143,6 +143,7 @@ "@kbn/apm-config-loader": "link:packages/kbn-apm-config-loader", "@kbn/apm-utils": "link:packages/kbn-apm-utils", "@kbn/cases-components": "link:packages/kbn-cases-components", + "@kbn/cell-actions": "link:packages/kbn-cell-actions", "@kbn/chart-expressions-common": "link:src/plugins/chart_expressions/common", "@kbn/chart-icons": "link:packages/kbn-chart-icons", "@kbn/coloring": "link:packages/kbn-coloring", @@ -446,6 +447,7 @@ "@kbn/timelion-grammar": "link:packages/kbn-timelion-grammar", "@kbn/tinymath": "link:packages/kbn-tinymath", "@kbn/typed-react-router-config": "link:packages/kbn-typed-react-router-config", + "@kbn/ui-actions-browser": "link:packages/kbn-ui-actions-browser", "@kbn/ui-framework": "link:packages/kbn-ui-framework", "@kbn/ui-shared-deps-npm": "link:packages/kbn-ui-shared-deps-npm", "@kbn/ui-shared-deps-src": "link:packages/kbn-ui-shared-deps-src", @@ -622,7 +624,7 @@ "query-string": "^6.13.2", "rbush": "^3.0.1", "re-resizable": "^6.1.1", - "re2": "1.17.4", + "re2": "1.17.7", "react": "^17.0.2", "react-ace": "^7.0.5", "react-beautiful-dnd": "^13.1.0", @@ -683,7 +685,7 @@ "styled-components": "^5.1.0", "suricata-sid-db": "^1.0.2", "symbol-observable": "^1.2.0", - "tar": "^6.1.11", + "tar": "^6.1.13", "tinycolor2": "1.4.1", "tinygradient": "0.4.3", "ts-easing": "^0.2.0", @@ -695,7 +697,7 @@ "use-resize-observer": "^6.0.0", "usng.js": "^0.4.5", "utility-types": "^3.10.0", - "uuid": "3.3.2", + "uuid": "9.0.0", "vega": "^5.22.1", "vega-interpreter": "^1.0.4", "vega-lite": "^5.5.0", @@ -936,7 +938,7 @@ "@types/multistream": "^4.1.0", "@types/mustache": "^0.8.31", "@types/nock": "^10.0.3", - "@types/node": "16.11.41", + "@types/node": "18.11.18", "@types/node-fetch": "^2.6.0", "@types/node-forge": "^1.3.1", "@types/nodemailer": "^6.4.0", @@ -983,14 +985,14 @@ "@types/styled-components": "^5.1.0", "@types/supertest": "^2.0.5", "@types/tapable": "^1.0.6", - "@types/tar": "^4.0.5", + "@types/tar": "^6.1.3", "@types/tempy": "^0.2.0", "@types/testing-library__jest-dom": "^5.14.5", "@types/tinycolor2": "^1.4.1", "@types/tough-cookie": "^4.0.2", "@types/type-detect": "^4.0.1", "@types/use-resize-observer": "^6.0.0", - "@types/uuid": "^3.4.4", + "@types/uuid": "^9.0.0", "@types/vinyl": "^2.0.4", "@types/vinyl-fs": "^2.4.11", "@types/watchpack": "^1.1.5", @@ -1027,7 +1029,7 @@ "backport": "^8.9.7", "callsites": "^3.1.0", "chance": "1.0.18", - "chromedriver": "^108.0.0", + "chromedriver": "^109.0.0", "clean-webpack-plugin": "^3.0.0", "compression-webpack-plugin": "^4.0.0", "copy-webpack-plugin": "^6.0.2", @@ -1158,7 +1160,7 @@ "simple-git": "^3.15.1", "sinon": "^7.4.2", "sort-package-json": "^1.53.1", - "source-map": "^0.7.3", + "source-map": "^0.7.4", "string-replace-loader": "^2.2.0", "style-loader": "^1.1.3", "stylelint": "^14.9.1", diff --git a/packages/README.md b/packages/README.md index 2dbbc7220221e..dd6bce456d476 100644 --- a/packages/README.md +++ b/packages/README.md @@ -30,14 +30,16 @@ instead be: "@kbn/i18n": "link:../../kibana/packages/kbn-i18n" ``` +then run `yarn kbn bootstrap` from the plugin directory. + ## Creating a new package -Create a new sub-folder. The name of the folder should mirror the `name` in the -package's `package.json`. E.g. if the name is `@kbn/i18n` the folder name -should be `kbn-i18n`. +Run the following command from the root of the Kibana repo: + +``` +node scripts/generate package @kbn/ --web --owner @elastic/ +``` -All new packages should use the `@kbn` namespace, and should be marked with -`"private": true`. ## Unit tests for a package diff --git a/packages/content-management/content_editor/kibana.jsonc b/packages/content-management/content_editor/kibana.jsonc index ebb0d3e59f63d..b81ccf9573c96 100644 --- a/packages/content-management/content_editor/kibana.jsonc +++ b/packages/content-management/content_editor/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/content-management-content-editor", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/content-management/table_list/kibana.jsonc b/packages/content-management/table_list/kibana.jsonc index 1837c97e9d2a5..2e4dd9548f604 100644 --- a/packages/content-management/table_list/kibana.jsonc +++ b/packages/content-management/table_list/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/content-management-table-list", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/core/application/core-application-browser/src/app_leave.ts b/packages/core/application/core-application-browser/src/app_leave.ts index edc18c5ef8a48..bfc9d2480473c 100644 --- a/packages/core/application/core-application-browser/src/app_leave.ts +++ b/packages/core/application/core-application-browser/src/app_leave.ts @@ -17,9 +17,9 @@ import type { EuiButtonColor } from '@elastic/eui'; * * See {@link AppMountParameters} for detailed usage examples. * + * @remarks prefer {@link ScopedHistory.block} instead + * * @public - * @deprecated {@link AppMountParameters.onAppLeave} has been deprecated in favor of {@link ScopedHistory.block} - * @removeBy 8.8.0 */ export type AppLeaveHandler = ( factory: AppLeaveActionFactory, diff --git a/packages/core/application/core-application-browser/src/app_mount.ts b/packages/core/application/core-application-browser/src/app_mount.ts index 03cf63be5c6b3..6dbea9a8eaad5 100644 --- a/packages/core/application/core-application-browser/src/app_mount.ts +++ b/packages/core/application/core-application-browser/src/app_mount.ts @@ -142,6 +142,7 @@ export interface AppMountParameters { * This will be called either when the user goes to another application, or when * trying to close the tab or manually changing the url. * + * * @example * * ```ts @@ -165,8 +166,10 @@ export interface AppMountParameters { * } * ``` * - * @deprecated {@link ScopedHistory.block} should be used instead. - * @removeBy 8.8.0 + * @remarks prefer {@link ScopedHistory.block} instead + * Resources with names containing percent sign with other special characters or + * containing `%25` sequence can experience navigation issues. Refs https://github.com/elastic/kibana/issues/82440 and https://github.com/elastic/kibana/issues/132600 + */ onAppLeave: (handler: AppLeaveHandler) => void; diff --git a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header.tsx b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header.tsx index 3a15e5d58c841..66297bf9a9b86 100644 --- a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header.tsx +++ b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header.tsx @@ -11,9 +11,7 @@ import { EuiHeader, EuiHeaderSection, EuiHeaderSectionItem, - EuiHeaderSectionItemButton, EuiHideFor, - EuiIcon, EuiShowFor, htmlIdGenerator, } from '@elastic/eui'; @@ -47,6 +45,7 @@ import { HeaderNavControls } from './header_nav_controls'; import { HeaderActionMenu } from './header_action_menu'; import { HeaderExtension } from './header_extension'; import { HeaderTopBanner } from './header_top_banner'; +import { HeaderMenuButton } from './header_menu_button'; export interface HeaderProps { kibanaVersion: string; @@ -188,7 +187,7 @@ export function Header({ }} customNavLink$={observables.customNavLink$} button={ - - - + forwardRef={toggleCollapsibleNavRef} + /> } /> diff --git a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_help_menu.tsx b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_help_menu.tsx index f938608091ba6..1d4813763a201 100644 --- a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_help_menu.tsx +++ b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_help_menu.tsx @@ -200,10 +200,10 @@ export class HeaderHelpMenu extends Component { return globalHelpExtensionMenuLinks .sort((a, b) => b.priority - a.priority) .map((link, index) => { - const { linkType, content: text, href, ...rest } = link; + const { linkType, content: text, href, external, ...rest } = link; return createCustomLink(index, text, true, { href, - onClick: this.createOnClickHandler(href, navigateToUrl), + onClick: external ? undefined : this.createOnClickHandler(href, navigateToUrl), ...rest, }); }); @@ -264,7 +264,7 @@ export class HeaderHelpMenu extends Component { }); } case 'custom': { - const { linkType, content: text, href, ...rest } = link; + const { linkType, content: text, href, external, ...rest } = link; return createCustomLink(index, text, addSpacer, { href, onClick: this.createOnClickHandler(href, navigateToUrl), diff --git a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_menu_button.tsx b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_menu_button.tsx new file mode 100644 index 0000000000000..0e318594d60b8 --- /dev/null +++ b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/header_menu_button.tsx @@ -0,0 +1,39 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { forwardRef, Ref } from 'react'; +import { EuiHeaderSectionItemButton, EuiIcon } from '@elastic/eui'; +import { EuiHeaderSectionItemButtonRef } from '@elastic/eui/src/components/header/header_section/header_section_item_button'; + +interface HeaderMenuButtonProps { + 'aria-controls': string; + 'aria-label': string; + 'aria-expanded': boolean; + 'aria-pressed': boolean; + 'data-test-subj': string; + onClick: () => void; + forwardRef: Ref | undefined; +} + +export const HeaderMenuButton = forwardRef( + (props: HeaderMenuButtonProps, ref: Ref | undefined) => { + return ( + + + + ); + } +); diff --git a/packages/core/chrome/core-chrome-browser/src/help_extension.ts b/packages/core/chrome/core-chrome-browser/src/help_extension.ts index f682a166ca29c..fa9c9a1f29fd7 100644 --- a/packages/core/chrome/core-chrome-browser/src/help_extension.ts +++ b/packages/core/chrome/core-chrome-browser/src/help_extension.ts @@ -92,6 +92,10 @@ export interface ChromeHelpExtensionMenuCustomLink extends ChromeHelpExtensionLi * Content of the button (in lieu of `children`) */ content: React.ReactNode; + /** + * Opens link in new tab + */ + external?: boolean; } /** @public */ diff --git a/packages/core/custom-branding/core-custom-branding-browser-internal/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-browser-internal/kibana.jsonc index 288faf09c1873..134e7269013ab 100644 --- a/packages/core/custom-branding/core-custom-branding-browser-internal/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-browser-internal/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-browser-internal", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-browser-mocks/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-browser-mocks/kibana.jsonc index 04b4b07fdf4a6..3a39229822bc7 100644 --- a/packages/core/custom-branding/core-custom-branding-browser-mocks/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-browser-mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-browser-mocks", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-browser/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-browser/kibana.jsonc index 05f64583697a5..79234981b43b6 100644 --- a/packages/core/custom-branding/core-custom-branding-browser/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-browser/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-browser", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-common/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-common/kibana.jsonc index b0cd8d74970b5..7043dc5c81215 100644 --- a/packages/core/custom-branding/core-custom-branding-common/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-common/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-common", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-server-internal/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-server-internal/kibana.jsonc index c44c8a470ef93..328ac5aadff8b 100644 --- a/packages/core/custom-branding/core-custom-branding-server-internal/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-server-internal/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-server-internal", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-server-mocks/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-server-mocks/kibana.jsonc index ce6284cb4d912..9fb4201dc7e57 100644 --- a/packages/core/custom-branding/core-custom-branding-server-mocks/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-server-mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-server-mocks", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/custom-branding/core-custom-branding-server/kibana.jsonc b/packages/core/custom-branding/core-custom-branding-server/kibana.jsonc index 5b0d758c39a25..693715f46f30b 100644 --- a/packages/core/custom-branding/core-custom-branding-server/kibana.jsonc +++ b/packages/core/custom-branding/core-custom-branding-server/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/core-custom-branding-server", - "owner": "@elastic/kibana-global-experience", + "owner": "@elastic/appex-sharedux", } diff --git a/packages/core/environment/core-environment-server-internal/src/resolve_uuid.ts b/packages/core/environment/core-environment-server-internal/src/resolve_uuid.ts index 97131e185dd8f..3ba6285fe6836 100644 --- a/packages/core/environment/core-environment-server-internal/src/resolve_uuid.ts +++ b/packages/core/environment/core-environment-server-internal/src/resolve_uuid.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { join } from 'path'; import { PathConfigType } from '@kbn/utils'; import type { Logger } from '@kbn/logging'; @@ -52,7 +52,7 @@ export async function resolveInstanceUuid({ } } if (uuidFromFile === undefined) { - const newUuid = uuid.v4(); + const newUuid = uuidv4(); // no uuid either in config or file, we need to generate and write it. logger.debug(`Setting new Kibana instance UUID: ${newUuid}`); await writeUuidToFile(uuidFilePath, newUuid); diff --git a/packages/core/http/core-http-router-server-internal/src/request.ts b/packages/core/http/core-http-router-server-internal/src/request.ts index 66dedcc017e9b..7e8e927bd4671 100644 --- a/packages/core/http/core-http-router-server-internal/src/request.ts +++ b/packages/core/http/core-http-router-server-internal/src/request.ts @@ -7,7 +7,7 @@ */ import { URL } from 'url'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Request, RouteOptions } from '@hapi/hapi'; import { fromEvent, NEVER } from 'rxjs'; import { shareReplay, first, filter } from 'rxjs/operators'; @@ -131,8 +131,8 @@ export class CoreKibanaRequest< // KibanaRequest in conjunction with scoped Elasticsearch and SavedObjectsClient in order to pass credentials. // In these cases, the ids default to a newly generated UUID. const appState = request.app as KibanaRequestState | undefined; - this.id = appState?.requestId ?? uuid.v4(); - this.uuid = appState?.requestUuid ?? uuid.v4(); + this.id = appState?.requestId ?? uuidv4(); + this.uuid = appState?.requestUuid ?? uuidv4(); this.rewrittenUrl = appState?.rewrittenUrl; this.url = request.url ?? new URL('https://fake-request/url'); diff --git a/packages/core/http/core-http-server-internal/src/http_config.test.ts b/packages/core/http/core-http-server-internal/src/http_config.test.ts index ec9fc41ed02fd..9e9c7febed995 100644 --- a/packages/core/http/core-http-server-internal/src/http_config.test.ts +++ b/packages/core/http/core-http-server-internal/src/http_config.test.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { config, HttpConfig } from './http_config'; import { cspConfig } from './csp'; import { ExternalUrlConfig } from './external_url'; @@ -245,7 +245,7 @@ describe('publicBaseUrl', () => { test('accepts only valid uuids for server.uuid', () => { const httpSchema = config.schema; - expect(() => httpSchema.validate({ uuid: uuid.v4() })).not.toThrow(); + expect(() => httpSchema.validate({ uuid: uuidv4() })).not.toThrow(); expect(() => httpSchema.validate({ uuid: 'not an uuid' })).toThrowErrorMatchingInlineSnapshot( `"[uuid]: must be a valid uuid"` ); diff --git a/packages/core/http/core-http-server-internal/src/http_server.ts b/packages/core/http/core-http-server-internal/src/http_server.ts index 4e4bf17d7a17a..fb19795d77dce 100644 --- a/packages/core/http/core-http-server-internal/src/http_server.ts +++ b/packages/core/http/core-http-server-internal/src/http_server.ts @@ -9,7 +9,7 @@ import { Server, Request } from '@hapi/hapi'; import HapiStaticFiles from '@hapi/inert'; import url from 'url'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { createServer, getListenerOptions, @@ -365,7 +365,7 @@ export class HttpServer { request.app = { ...(request.app ?? {}), requestId, - requestUuid: uuid.v4(), + requestUuid: uuidv4(), // Kibana stores trace.id until https://github.com/elastic/apm-agent-nodejs/issues/2353 is resolved // The current implementation of the APM agent ends a request transaction before "response" log is emitted. traceId: apm.currentTraceIds['trace.id'], diff --git a/packages/core/i18n/core-i18n-browser-internal/src/__snapshots__/i18n_service.test.tsx.snap b/packages/core/i18n/core-i18n-browser-internal/src/__snapshots__/i18n_service.test.tsx.snap index 087b5db023ef5..95e15be0220bb 100644 --- a/packages/core/i18n/core-i18n-browser-internal/src/__snapshots__/i18n_service.test.tsx.snap +++ b/packages/core/i18n/core-i18n-browser-internal/src/__snapshots__/i18n_service.test.tsx.snap @@ -53,6 +53,7 @@ exports[`#start() returns \`Context\` component 1`] = ` "euiColumnSelector.button": "Columns", "euiColumnSelector.buttonActivePlural": [Function], "euiColumnSelector.buttonActiveSingular": [Function], + "euiColumnSelector.dragHandleAriaLabel": "Drag handle", "euiColumnSelector.hideAll": "Hide all", "euiColumnSelector.search": "Search", "euiColumnSelector.searchcolumns": "Search columns", diff --git a/packages/core/i18n/core-i18n-browser-internal/src/i18n_eui_mapping.tsx b/packages/core/i18n/core-i18n-browser-internal/src/i18n_eui_mapping.tsx index 143da92aae897..439e928f977e9 100644 --- a/packages/core/i18n/core-i18n-browser-internal/src/i18n_eui_mapping.tsx +++ b/packages/core/i18n/core-i18n-browser-internal/src/i18n_eui_mapping.tsx @@ -234,6 +234,12 @@ export const getEuiContextMapping = (): EuiTokensObject => { 'euiColumnActions.moveRight': i18n.translate('core.euiColumnActions.moveRight', { defaultMessage: 'Move right', }), + 'euiColumnSelector.dragHandleAriaLabel': i18n.translate( + 'core.euiColumnSelector.dragHandleAriaLabel', + { + defaultMessage: 'Drag handle', + } + ), 'euiColumnSelector.hideAll': i18n.translate('core.euiColumnSelector.hideAll', { defaultMessage: 'Hide all', }), diff --git a/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts b/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts index dc22dbf3c5d95..26a6e4a3c7464 100644 --- a/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts +++ b/packages/core/lifecycle/core-lifecycle-browser/src/core_start.ts @@ -46,7 +46,10 @@ export interface CoreStart { executionContext: ExecutionContextStart; /** {@link HttpStart} */ http: HttpStart; - /** {@link SavedObjectsStart} */ + /** + * {@link SavedObjectsStart} + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ savedObjects: SavedObjectsStart; /** {@link I18nStart} */ i18n: I18nStart; diff --git a/packages/core/metrics/core-metrics-server/src/metrics.ts b/packages/core/metrics/core-metrics-server/src/metrics.ts index c20b2eb78d5d3..63a80dde1c371 100644 --- a/packages/core/metrics/core-metrics-server/src/metrics.ts +++ b/packages/core/metrics/core-metrics-server/src/metrics.ts @@ -191,8 +191,7 @@ export interface OpsMetrics { elasticsearch_client: ElasticsearchClientsMetrics; /** * Process related metrics. - * @deprecated use the processes field instead. - * @removeBy 8.8.0 + * @remarks processes field preferred */ process: OpsProcessMetrics; /** Process related metrics. Reports an array of objects for each kibana pid.*/ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts index 74d5223def315..451e2551f08eb 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/base.ts @@ -12,6 +12,7 @@ import { SimpleSavedObject } from '../simple_saved_object'; * Batch response for simple saved objects * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBatchResponse { /** Array of simple saved objects */ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts index 6d5ce23205ef8..f685d982f8202 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_create.ts @@ -12,6 +12,7 @@ import type { SavedObjectsCreateOptions } from './create'; * Per-object parameters for bulk create operation * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkCreateObject extends SavedObjectsCreateOptions { /** Create a SavedObject of this type. */ @@ -24,7 +25,8 @@ export interface SavedObjectsBulkCreateObject extends SavedObjectsC * Options for bulk create operation * * @public - * */ + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ export interface SavedObjectsBulkCreateOptions { /** If a document with the given `id` already exists, overwrite its contents (default=false). */ overwrite?: boolean; diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts index 532e900338d8a..4744cc406e97b 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_delete.ts @@ -12,6 +12,7 @@ import { SavedObjectError } from '@kbn/core-saved-objects-common'; * Options for bulk delete operation * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkDeleteOptions { /** Force deletion of any objects that exist in multiple namespaces (default=false) */ @@ -22,6 +23,7 @@ export interface SavedObjectsBulkDeleteOptions { * Single item within the statuses array of the bulk delete response * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkDeleteResponseItem { /** saved object id */ @@ -38,6 +40,7 @@ export interface SavedObjectsBulkDeleteResponseItem { * Return type of the Saved Objects `bulkDelete()` method. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkDeleteResponse { /** array of statuses per object */ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts index c5ba482525298..8b24e32f5791c 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_resolve.ts @@ -12,6 +12,7 @@ import type { ResolvedSimpleSavedObject } from './resolve'; * Return type of the Saved Objects `bulkResolve()` method. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkResolveResponse { /** Array of {@link ResolvedSimpleSavedObject} that were resolved */ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts index c819fb1ac448d..56f516a37e9df 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/bulk_update.ts @@ -12,6 +12,7 @@ import type { SavedObjectReference } from '@kbn/core-saved-objects-common'; * Per-object parameters for bulk update operation * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsBulkUpdateObject { /** Type of the saved object to update */ @@ -30,6 +31,7 @@ export interface SavedObjectsBulkUpdateObject { * Options for bulk update operation * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 * */ export interface SavedObjectsBulkUpdateOptions { /** diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts index fb6a18219e5bf..65242b1bda546 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/create.ts @@ -15,6 +15,7 @@ import type { * Options for creating a saved object. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsCreateOptions { /** diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts index c43dbec6845b3..e25038acf27cc 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/delete.ts @@ -10,6 +10,7 @@ * Options for deleting a saved object. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsDeleteOptions { /** Force deletion of an object that exists in multiple namespaces (default=false) */ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts index 39d99a6ee6e86..9048b2b54308d 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/find.ts @@ -15,6 +15,7 @@ export type { SavedObjectsFindOptionsReference } from '@kbn/core-saved-objects-a * Browser options for finding saved objects * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export type SavedObjectsFindOptions = Omit< SavedObjectFindOptionsServer, @@ -25,6 +26,7 @@ export type SavedObjectsFindOptions = Omit< * Return type of the Saved Objects `find()` method. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsFindResponse extends SavedObjectsBatchResponse { diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts index d2868ae48ced1..53ffe7782c720 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/resolve.ts @@ -14,6 +14,7 @@ import type { SimpleSavedObject } from '../simple_saved_object'; * with the {@link SavedObjectsClientContract}. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface ResolvedSimpleSavedObject { /** diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts index f8095e35df1e5..e456c5b9c6ea6 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/apis/update.ts @@ -12,6 +12,7 @@ import type { SavedObjectReference } from '@kbn/core-saved-objects-common'; * Options for updating a saved object * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsUpdateOptions { /** version of the saved object */ diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts index 9ff01104c5ba0..fc4285406effe 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/saved_objects_client.ts @@ -30,6 +30,7 @@ import type { SimpleSavedObject } from './simple_saved_object'; * HTTP API for interacting with Saved Objects. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsClientContract { /** @@ -39,6 +40,7 @@ export interface SavedObjectsClientContract { * @param {string} attributes - the attributes of the object * @param {string} options {@link SavedObjectsCreateOptions} * @returns The result of the create operation - the created saved object + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ create( type: string, @@ -52,6 +54,7 @@ export interface SavedObjectsClientContract { * @param {string} objects - an array of objects containing type, attributes * @param {string} options {@link SavedObjectsBulkCreateOptions} * @returns The result of the create operation containing created saved objects. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ bulkCreate( objects: SavedObjectsBulkCreateObject[], @@ -65,6 +68,7 @@ export interface SavedObjectsClientContract { * @param {string} id - the id of the object to delete * @param {string} options {@link SavedObjectsDeleteOptions} * @param {string} options.force - required to delete objects shared to multiple spaces + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ delete(type: string, id: string, options?: SavedObjectsDeleteOptions): Promise<{}>; @@ -73,6 +77,7 @@ export interface SavedObjectsClientContract { * @param objects - an array of objects containing id, type * @param options - optional force argument to force deletion of objects in a namespace other than the scoped client * @returns The bulk delete result for the saved objects for the given types and ids. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ bulkDelete( objects: SavedObjectTypeIdTuple[], @@ -92,6 +97,7 @@ export interface SavedObjectsClientContract { * @property {array} options.fields * @property {object} [options.hasReference] - { type, id } * @returns A find result with objects matching the specified search. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ find( options: SavedObjectsFindOptions @@ -103,6 +109,7 @@ export interface SavedObjectsClientContract { * @param {string} type - the type of the object to get * @param {string} id - the ID of the object to get * @returns The saved object for the given type and id. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ get(type: string, id: string): Promise>; @@ -117,6 +124,7 @@ export interface SavedObjectsClientContract { * { id: 'one', type: 'config' }, * { id: 'foo', type: 'index-pattern' } * ]) + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ bulkGet(objects: SavedObjectTypeIdTuple[]): Promise>; @@ -131,6 +139,7 @@ export interface SavedObjectsClientContract { * outcome is that "exactMatch" is the default outcome, and the outcome only changes if an alias is found. This behavior for the `resolve` * API is unique to the public client, which batches individual calls with `bulkResolve` under the hood. We don't throw an error in that * case for legacy compatibility reasons. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ resolve(type: string, id: string): Promise>; @@ -149,6 +158,7 @@ export interface SavedObjectsClientContract { * @note Saved objects that Kibana fails to find are replaced with an error object and an "exactMatch" outcome. The rationale behind the * outcome is that "exactMatch" is the default outcome, and the outcome only changes if an alias is found. The `resolve` method in the * public client uses `bulkResolve` under the hood, so it behaves the same way. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ bulkResolve( objects: SavedObjectTypeIdTuple[] @@ -164,6 +174,7 @@ export interface SavedObjectsClientContract { * @prop {integer} options.version - ensures version matches that of persisted object * @prop {object} options.migrationVersion - The optional migrationVersion of this document * @returns the udpated simple saved object + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ update( type: string, @@ -177,6 +188,7 @@ export interface SavedObjectsClientContract { * * @param {array} objects - an array of objects containing type, id, attributes, and references * @returns the result of the bulk update operation containing both failed and updated saved objects. + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ bulkUpdate( objects: SavedObjectsBulkUpdateObject[] diff --git a/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts b/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts index 2932d4f5675a8..90bcd81c31638 100644 --- a/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts +++ b/packages/core/saved-objects/core-saved-objects-api-browser/src/simple_saved_object.ts @@ -16,6 +16,7 @@ import type { SavedObject as SavedObjectType } from '@kbn/core-saved-objects-com * but doesn't include any type-specific implementations. * * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SimpleSavedObject { /** attributes of the object, templated */ @@ -71,11 +72,13 @@ export interface SimpleSavedObject { /** * Saves this object + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ save(): Promise>; /** * Deletes this object + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ delete(): Promise<{}>; } diff --git a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/aggregations/aggs_types/bucket_aggs.ts b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/aggregations/aggs_types/bucket_aggs.ts index 7a6d94c31f291..20ebeb234b479 100644 --- a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/aggregations/aggs_types/bucket_aggs.ts +++ b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/aggregations/aggs_types/bucket_aggs.ts @@ -61,6 +61,36 @@ const existsSchema = s.object({ }) ), }); + +const rangeSchema = s.object({ + range: s.recordOf( + s.string(), + s.object({ + lt: s.maybe(s.string()), + lte: s.maybe(s.string()), + gt: s.maybe(s.string()), + gte: s.maybe(s.string()), + }) + ), +}); + +const termValueSchema = s.object({ + term: s.recordOf(s.string(), s.object({ value: s.string() })), +}); + +const nestedSchema = s.object({ + nested: s.object({ + path: s.string(), + query: s.object({ + bool: s.object({ + filter: s.arrayOf(termValueSchema), + }), + }), + }), +}); + +const arraySchema = s.arrayOf(s.oneOf([nestedSchema, rangeSchema])); + // TODO: it would be great if we could recursively build the schema since the aggregation have be nested // For more details see how the types are defined in the elasticsearch javascript client: // https://github.com/elastic/elasticsearch-js/blob/4ad5daeaf401ce8ebb28b940075e0a67e56ff9ce/src/api/typesWithBodyKey.ts#L5295 @@ -70,7 +100,7 @@ const boolSchema = s.object({ must_not: s.oneOf([termSchema, existsSchema]), }), s.object({ - filter: s.oneOf([termSchema, existsSchema]), + filter: s.oneOf([termSchema, existsSchema, arraySchema]), }), ]), }); diff --git a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts index 81498a2b9df2f..59162f991928a 100644 --- a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts +++ b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.spaces_extension.test.ts @@ -31,6 +31,7 @@ import { SavedObject } from '@kbn/core-saved-objects-common'; import { ISavedObjectsSpacesExtension, ISavedObjectsSecurityExtension, + ISavedObjectsEncryptionExtension, } from '@kbn/core-saved-objects-server'; import { SavedObjectsErrorHelpers } from '@kbn/core-saved-objects-utils-server'; import { kibanaMigratorMock } from '../mocks'; @@ -56,6 +57,7 @@ import { setupPerformAuthUnauthorized, generateIndexPatternSearchResults, bulkDeleteSuccess, + ENCRYPTED_TYPE, } from '../test_helpers/repository.test.common'; import { savedObjectsExtensionsMock } from '../mocks/saved_objects_extensions.mock'; @@ -72,6 +74,7 @@ describe('SavedObjectsRepository Spaces Extension', () => { let serializer: jest.Mocked; let mockSpacesExt: jest.Mocked; let mockSecurityExt: jest.Mocked; + let mockEncryptionExt: jest.Mocked; const registry = createRegistry(); const documentMigrator = createDocumentMigrator(registry); @@ -93,7 +96,11 @@ describe('SavedObjectsRepository Spaces Extension', () => { serializer, allowedTypes, logger, - extensions: { spacesExtension: mockSpacesExt, securityExtension: mockSecurityExt }, + extensions: { + spacesExtension: mockSpacesExt, + securityExtension: mockSecurityExt, + encryptionExtension: mockEncryptionExt, + }, }); }; @@ -922,4 +929,198 @@ describe('SavedObjectsRepository Spaces Extension', () => { }); }); }); + + describe(`with encryption extension`, () => { + const currentSpace = 'current_space'; + const encryptedSO = { + id: 'encrypted-id', + type: ENCRYPTED_TYPE, + namespaces: ['foo-namespace'], + attributes: { + attrNotSoSecret: '*not-so-secret*', + attrOne: 'one', + attrSecret: '*secret*', + attrThree: 'three', + title: 'Testing', + }, + references: [], + }; + const decryptedStrippedAttributes = { + attributes: { attrOne: 'one', attrNotSoSecret: 'not-so-secret', attrThree: 'three' }, + }; + + beforeEach(() => { + pointInTimeFinderMock.mockClear(); + client = elasticsearchClientMock.createElasticsearchClient(); + migrator = kibanaMigratorMock.create(); + documentMigrator.prepareMigrations(); + migrator.migrateDocument = jest.fn().mockImplementation(documentMigrator.migrate); + migrator.runMigrations = jest.fn().mockResolvedValue([{ status: 'skipped' }]); + logger = loggerMock.create(); + serializer = createSpySerializer(registry); + mockSpacesExt = savedObjectsExtensionsMock.createSpacesExtension(); + mockEncryptionExt = savedObjectsExtensionsMock.createEncryptionExtension(); + mockGetCurrentTime.mockReturnValue(mockTimestamp); + mockGetSearchDsl.mockClear(); + repository = instantiateRepository(); + mockSpacesExt.getCurrentNamespace.mockImplementation((namespace: string | undefined) => { + if (namespace) { + throw SavedObjectsErrorHelpers.createBadRequestError(ERROR_NAMESPACE_SPECIFIED); + } + return currentSpace; + }); + }); + + describe(`#create`, () => { + test(`calls encryptAttributes with the current namespace by default`, async () => { + mockEncryptionExt.isEncryptableType.mockReturnValue(true); + await repository.create(encryptedSO.type, encryptedSO.attributes); + expect(mockSpacesExt.getCurrentNamespace).toBeCalledTimes(1); + expect(mockSpacesExt.getCurrentNamespace).toHaveBeenCalledWith(undefined); + expect(client.create).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenCalledTimes(3); // (no upsert) optionallyEncryptAttributes, optionallyDecryptAndRedactSingleResult + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(1, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(2, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(3, encryptedSO.type); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledWith( + { + id: expect.objectContaining(/[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}/), + namespace: currentSpace, + type: ENCRYPTED_TYPE, + }, + encryptedSO.attributes + ); + }); + }); + + describe(`#bulkCreate`, () => { + const obj1 = { + type: 'config', + id: '6.0.0-alpha1', + attributes: { title: 'Test One' }, + references: [{ name: 'ref_0', type: 'test', id: '1' }], + }; + + test(`calls encryptAttributes with the current namespace by default`, async () => { + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(true); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(true); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(true); + await bulkCreateSuccess(client, repository, [ + obj1, + { ...encryptedSO, id: undefined }, // Predefined IDs are not allowed for saved objects with encrypted attributes unless the ID is a UUID + ]); + expect(mockSpacesExt.getCurrentNamespace).toBeCalledTimes(1); + expect(mockSpacesExt.getCurrentNamespace).toHaveBeenCalledWith(undefined); + expect(mockSpacesExt.getSearchableNamespaces).not.toHaveBeenCalled(); + expect(client.bulk).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenCalledTimes(6); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(1, obj1.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(2, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(3, obj1.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(4, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(5, obj1.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(6, encryptedSO.type); + + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledWith( + { + id: expect.objectContaining(/[0-9a-f]{8}-([0-9a-f]{4}-){3}[0-9a-f]{12}/), + namespace: currentSpace, + type: ENCRYPTED_TYPE, + }, + encryptedSO.attributes + ); + }); + }); + + describe(`#update`, () => { + it('calls encryptAttributes with the current namespace by default', async () => { + mockEncryptionExt.isEncryptableType.mockReturnValue(true); + mockEncryptionExt.decryptOrStripResponseAttributes.mockResolvedValue({ + ...encryptedSO, + ...decryptedStrippedAttributes, + }); + await updateSuccess( + client, + repository, + registry, + encryptedSO.type, + encryptedSO.id, + encryptedSO.attributes, + { + // no namespace provided + references: encryptedSO.references, + } + ); + expect(mockSpacesExt.getCurrentNamespace).toBeCalledTimes(1); + expect(mockSpacesExt.getCurrentNamespace).toHaveBeenCalledWith(undefined); + expect(client.update).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenCalledTimes(2); // (no upsert) optionallyEncryptAttributes, optionallyDecryptAndRedactSingleResult + expect(mockEncryptionExt.isEncryptableType).toHaveBeenCalledWith(encryptedSO.type); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledWith( + { + id: encryptedSO.id, + namespace: currentSpace, + type: ENCRYPTED_TYPE, + }, + encryptedSO.attributes + ); + }); + }); + + describe(`#bulkUpdate`, () => { + const obj1: SavedObjectsBulkUpdateObject = { + type: 'config', + id: '6.0.0-alpha1', + attributes: { title: 'Test One' }, + }; + const obj2: SavedObjectsBulkUpdateObject = { + type: 'index-pattern', + id: 'logstash-*', + attributes: { title: 'Test Two' }, + }; + + it(`calls encryptAttributes with the current namespace by default`, async () => { + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(true); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(true); + mockEncryptionExt.isEncryptableType.mockReturnValueOnce(false); + await bulkUpdateSuccess( + client, + repository, + registry, + [obj1, encryptedSO, obj2], + undefined, // No options/namespace specified + undefined, + undefined + ); + expect(mockSpacesExt.getCurrentNamespace).toBeCalledTimes(1); + expect(mockSpacesExt.getCurrentNamespace).toHaveBeenCalledWith(undefined); + expect(mockSpacesExt.getSearchableNamespaces).not.toHaveBeenCalled(); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenCalledTimes(6); // (no upsert) optionallyEncryptAttributes, optionallyDecryptAndRedactSingleResult + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(1, obj1.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(2, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(3, obj2.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(4, obj1.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(5, encryptedSO.type); + expect(mockEncryptionExt.isEncryptableType).toHaveBeenNthCalledWith(6, obj2.type); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledTimes(1); + expect(mockEncryptionExt.encryptAttributes).toHaveBeenCalledWith( + { + id: encryptedSO.id, + namespace: currentSpace, + type: ENCRYPTED_TYPE, + }, + encryptedSO.attributes + ); + }); + }); + }); }); diff --git a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts index 8260a7cdddec9..cb23c5f89fbcf 100644 --- a/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts +++ b/packages/core/saved-objects/core-saved-objects-api-server-internal/src/lib/repository.ts @@ -1957,7 +1957,7 @@ export class SavedObjectsRepository implements ISavedObjectsRepository { ...(savedObjectNamespace && { namespace: savedObjectNamespace }), ...(savedObjectNamespaces && { namespaces: savedObjectNamespaces }), attributes: { - ...(await this.optionallyEncryptAttributes(type, id, options.namespace, upsert)), + ...(await this.optionallyEncryptAttributes(type, id, namespace, upsert)), }, updated_at: time, }); @@ -1965,7 +1965,7 @@ export class SavedObjectsRepository implements ISavedObjectsRepository { } const doc = { - [type]: await this.optionallyEncryptAttributes(type, id, options.namespace, attributes), + [type]: await this.optionallyEncryptAttributes(type, id, namespace, attributes), updated_at: time, ...(Array.isArray(references) && { references }), }; diff --git a/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts b/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts index 1fd111186f551..d7f9b8a8b4d0b 100644 --- a/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts +++ b/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_client.ts @@ -104,6 +104,7 @@ const getObjectsToResolve = (queue: BatchResolveQueueEntry[]) => { * HTTP API for interacting with Saved Objects. * * @internal + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export class SavedObjectsClient implements SavedObjectsClientContract { private http: HttpSetup; diff --git a/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts b/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts index 111d98bfcc126..7cef8a1c39057 100644 --- a/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts +++ b/packages/core/saved-objects/core-saved-objects-browser-internal/src/saved_objects_service.ts @@ -11,6 +11,9 @@ import type { HttpStart } from '@kbn/core-http-browser'; import type { SavedObjectsStart } from '@kbn/core-saved-objects-browser'; import { SavedObjectsClient } from './saved_objects_client'; +/** + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ export class SavedObjectsService implements CoreService { public async setup() {} diff --git a/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts b/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts index 414ed5bbf1846..8c5fc18129761 100644 --- a/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts +++ b/packages/core/saved-objects/core-saved-objects-browser-internal/src/simple_saved_object.ts @@ -18,6 +18,7 @@ import type { * Core internal implementation of {@link SimpleSavedObject} * * @internal Should use the {@link SimpleSavedObject} interface instead + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export class SimpleSavedObjectImpl implements SimpleSavedObject { public attributes: T; diff --git a/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts b/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts index 2239b94d7e2eb..3b537311d72d9 100644 --- a/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts +++ b/packages/core/saved-objects/core-saved-objects-browser-mocks/src/saved_objects_service.mock.ts @@ -41,6 +41,9 @@ const createMock = () => { return mocked; }; +/** + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ export const savedObjectsServiceMock = { create: createMock, createStartContract: createStartContractMock, diff --git a/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts b/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts index 2e3c30ac17d9c..8264b5fd6ba87 100644 --- a/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts +++ b/packages/core/saved-objects/core-saved-objects-browser-mocks/src/simple_saved_object.mock.ts @@ -63,6 +63,9 @@ const createSimpleSavedObjectMock = ( return mock; }; +/** + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ export const simpleSavedObjectMock = { create: (client: SavedObjectsClientContract, savedObject: SavedObject) => createSimpleSavedObjectMock(savedObject), diff --git a/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts b/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts index c372f3169ed80..082893e6efc74 100644 --- a/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts +++ b/packages/core/saved-objects/core-saved-objects-browser/src/contracts.ts @@ -9,6 +9,7 @@ import type { SavedObjectsClientContract } from '@kbn/core-saved-objects-api-bro /** * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 */ export interface SavedObjectsStart { /** {@link SavedObjectsClientContract} */ diff --git a/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts b/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts index b9ea336d349bd..12e554cf185c8 100644 --- a/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts +++ b/packages/core/saved-objects/core-saved-objects-common/src/saved_objects.ts @@ -6,47 +6,7 @@ * Side Public License, v 1. */ -/** - * Don't use this type, it's simply a helper type for {@link SavedObjectAttribute} - * - * @public - */ -export type SavedObjectAttributeSingle = - | string - | number - | boolean - | null - | undefined - | SavedObjectAttributes; - -/** - * Type definition for a Saved Object attribute value - * - * @public - */ -export type SavedObjectAttribute = SavedObjectAttributeSingle | SavedObjectAttributeSingle[]; - -/** - * The data for a Saved Object is stored as an object in the `attributes` - * property. - * - * @public - * @deprecated This type reduces the type safety of your code. Create an interface for your specific saved object type or use `unknown` instead. - */ -export interface SavedObjectAttributes { - [key: string]: SavedObjectAttribute; -} - -/** - * A reference to another saved object. - * - * @public - */ -export interface SavedObjectReference { - name: string; - type: string; - id: string; -} +import * as serverTypes from './server_types'; /** * Information about the migrations that have been applied to this SavedObject. @@ -68,41 +28,6 @@ export interface SavedObjectsMigrationVersion { [pluginName: string]: string; } -export interface SavedObject { - /** The ID of this Saved Object, guaranteed to be unique for all objects of the same `type` */ - id: string; - /** The type of Saved Object. Each plugin can define it's own custom Saved Object types. */ - type: string; - /** An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control. */ - version?: string; - /** Timestamp of the time this document had been created. */ - created_at?: string; - /** Timestamp of the last time this document had been updated. */ - updated_at?: string; - /** Error associated with this object, populated if an operation failed for this object. */ - error?: SavedObjectError; - /** The data for a Saved Object is stored as an object in the `attributes` property. **/ - attributes: T; - /** {@inheritdoc SavedObjectReference} */ - references: SavedObjectReference[]; - /** {@inheritdoc SavedObjectsMigrationVersion} */ - migrationVersion?: SavedObjectsMigrationVersion; - /** A semver value that is used when upgrading objects between Kibana versions. */ - coreMigrationVersion?: string; - /** - * Space(s) that this saved object exists in. This attribute is not used for "global" saved object types which are registered with - * `namespaceType: 'agnostic'`. - */ - namespaces?: string[]; - /** - * The ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration - * from a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import - * to ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given - * space. - */ - originId?: string; -} - /** * The namespace type dictates how a saved object can be interacted in relation to namespaces. Each type is mutually exclusive: * * single (default): This type of saved object is namespace-isolated, e.g., it exists in only one namespace. @@ -123,3 +48,33 @@ export interface SavedObjectError { statusCode: number; metadata?: Record; } + +/** + * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ +export type SavedObjectAttributeSingle = serverTypes.SavedObjectAttributeSingle; + +/** + * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ +export type SavedObjectAttribute = serverTypes.SavedObjectAttribute; + +/** + * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ +export type SavedObjectAttributes = serverTypes.SavedObjectAttributes; + +/** + * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ +export type SavedObjectReference = serverTypes.SavedObjectReference; + +/** + * @public + * @deprecated See https://github.com/elastic/kibana/issues/149098 + */ +export type SavedObject = serverTypes.SavedObject; diff --git a/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts b/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts new file mode 100644 index 0000000000000..8b0ae5c819952 --- /dev/null +++ b/packages/core/saved-objects/core-saved-objects-common/src/server_types.ts @@ -0,0 +1,94 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +/** + * Note: this file contains types that are intended for use by server-side code + * only. Once the Saved Objects client is removed from browser code we will + * remove these types as well. + * + * See https://github.com/elastic/kibana/issues/149098. + */ + +import type { SavedObjectsMigrationVersion, SavedObjectError } from './saved_objects'; + +/** + * Don't use this type, it's simply a helper type for {@link SavedObjectAttribute} + * + * @public + */ +export type SavedObjectAttributeSingle = + | string + | number + | boolean + | null + | undefined + | SavedObjectAttributes; + +/** + * Type definition for a Saved Object attribute value + * + * @public + */ +export type SavedObjectAttribute = SavedObjectAttributeSingle | SavedObjectAttributeSingle[]; + +/** + * The data for a Saved Object is stored as an object in the `attributes` + * property. + * + * @public + * @deprecated This type reduces the type safety of your code. Create an interface for your specific saved object type or use `unknown` instead. + */ +export interface SavedObjectAttributes { + [key: string]: SavedObjectAttribute; +} + +/** + * A reference to another saved object. + * + * @public + */ +export interface SavedObjectReference { + name: string; + type: string; + id: string; +} + +export interface SavedObject { + /** The ID of this Saved Object, guaranteed to be unique for all objects of the same `type` */ + id: string; + /** The type of Saved Object. Each plugin can define it's own custom Saved Object types. */ + type: string; + /** An opaque version number which changes on each successful write operation. Can be used for implementing optimistic concurrency control. */ + version?: string; + /** Timestamp of the time this document had been created. */ + created_at?: string; + /** Timestamp of the last time this document had been updated. */ + updated_at?: string; + /** Error associated with this object, populated if an operation failed for this object. */ + error?: SavedObjectError; + /** The data for a Saved Object is stored as an object in the `attributes` property. **/ + attributes: T; + /** {@inheritdoc SavedObjectReference} */ + references: SavedObjectReference[]; + /** {@inheritdoc SavedObjectsMigrationVersion} */ + migrationVersion?: SavedObjectsMigrationVersion; + /** A semver value that is used when upgrading objects between Kibana versions. */ + coreMigrationVersion?: string; + /** + * Space(s) that this saved object exists in. This attribute is not used for "global" saved object types which are registered with + * `namespaceType: 'agnostic'`. + */ + namespaces?: string[]; + /** + * The ID of the saved object this originated from. This is set if this object's `id` was regenerated; that can happen during migration + * from a legacy single-namespace type, or during import. It is only set during migration or create operations. This is used during import + * to ensure that ID regeneration is deterministic, so saved objects will be overwritten if they are imported multiple times into a given + * space. + */ + originId?: string; +} diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts index f8d2948510531..dd64014f815bd 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.test.ts @@ -738,7 +738,7 @@ describe('DocumentMigrator', () => { migrations: { '1.2.3': (doc, { log }) => { log.info(logTestMsg); - log.warning(logTestMsg); + log.warn(logTestMsg); return doc; }, }, diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts index c737489dd2231..ae50d7fac643a 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/document_migrator.ts @@ -42,7 +42,7 @@ */ import Boom from '@hapi/boom'; -import uuidv5 from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import { set } from '@kbn/safer-lodash-set'; import _ from 'lodash'; import Semver from 'semver'; diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts index c2ae13b70cbdd..e4851e9b3be00 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/core/migration_logger.ts @@ -25,7 +25,6 @@ export class MigrationLogger implements SavedObjectsMigrationLogger { public info = (msg: string) => this.logger.info(msg); public debug = (msg: string) => this.logger.debug(msg); - public warning = (msg: string) => this.logger.warn(msg); public warn = (msg: string) => this.logger.warn(msg); public error = (msg: string, meta: LogMeta) => this.logger.error(msg, meta); } diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.test.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.test.ts index 8072675b96b7e..3c47ea01ecd72 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.test.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.test.ts @@ -652,6 +652,11 @@ describe('migrations v2 model', () => { expect(newState.controlState).toBe('WAIT_FOR_YELLOW_SOURCE'); expect(newState.sourceIndex.value).toBe('.kibana_7.invalid.0_001'); + expect(newState.aliases).toEqual({ + '.kibana': '.kibana_7.invalid.0_001', + '.kibana_7.11.0': '.kibana_7.11.0_001', + '.kibana_7.12.0': '.kibana_7.invalid.0_001', + }); }); test('INIT -> WAIT_FOR_YELLOW_SOURCE when migrating from a v2 migrations index (>= 7.11.0)', () => { @@ -683,6 +688,10 @@ describe('migrations v2 model', () => { expect(newState.sourceIndex.value).toBe('.kibana_7.11.0_001'); expect(newState.retryCount).toEqual(0); expect(newState.retryDelay).toEqual(0); + expect(newState.aliases).toEqual({ + '.kibana': '.kibana_7.11.0_001', + '.kibana_7.11.0': '.kibana_7.11.0_001', + }); }); test('INIT -> WAIT_FOR_YELLOW_SOURCE when migrating from a v1 migrations index (>= 6.5 < 7.11.0)', () => { @@ -701,6 +710,9 @@ describe('migrations v2 model', () => { expect(newState.sourceIndex.value).toBe('.kibana_3'); expect(newState.retryCount).toEqual(0); expect(newState.retryDelay).toEqual(0); + expect(newState.aliases).toEqual({ + '.kibana': '.kibana_3', + }); }); test('INIT -> LEGACY_SET_WRITE_BLOCK when migrating from a legacy index (>= 6.0.0 < 6.5)', () => { const res: ResponseType<'INIT'> = Either.right({ @@ -807,67 +819,6 @@ describe('migrations v2 model', () => { expect(newState.retryCount).toEqual(0); expect(newState.retryDelay).toEqual(0); }); - - describe('when upgrading to a new stack version', () => { - const unchangedMappingsState: State = { - ...baseState, - controlState: 'INIT', - kibanaVersion: '7.12.0', // new version! - currentAlias: '.kibana', - versionAlias: '.kibana_7.12.0', - versionIndex: '.kibana_7.11.0_001', - }; - it('INIT -> PREPARE_COMPATIBLE_MIGRATION when the mappings have not changed', () => { - const res: ResponseType<'INIT'> = Either.right({ - '.kibana_7.11.0_001': { - aliases: { - '.kibana': {}, - '.kibana_7.11.0': {}, - }, - mappings: indexMapping, - settings: {}, - }, - }); - const newState = model(unchangedMappingsState, res) as PrepareCompatibleMigration; - - expect(newState.controlState).toEqual('PREPARE_COMPATIBLE_MIGRATION'); - expect(newState.targetIndexRawMappings).toEqual({ - _meta: { - migrationMappingPropertyHashes: { - new_saved_object_type: '4a11183eee21e6fbad864f7a30b39ad0', - }, - }, - properties: { - new_saved_object_type: { - properties: { - value: { - type: 'text', - }, - }, - }, - }, - }); - expect(newState.versionAlias).toEqual('.kibana_7.12.0'); - expect(newState.currentAlias).toEqual('.kibana'); - // will point to - expect(newState.targetIndex).toEqual('.kibana_7.11.0_001'); - expect(newState.preTransformDocsActions).toEqual([ - { - add: { - alias: '.kibana_7.12.0', - index: '.kibana_7.11.0_001', - }, - }, - { - remove: { - alias: '.kibana_7.11.0', - index: '.kibana_7.11.0_001', - must_exist: true, - }, - }, - ]); - }); - }); }); }); @@ -1259,25 +1210,129 @@ describe('migrations v2 model', () => { }); describe('WAIT_FOR_YELLOW_SOURCE', () => { - const someMappings = { - properties: {}, - } as const; - const waitForYellowSourceState: WaitForYellowSourceState = { ...baseState, controlState: 'WAIT_FOR_YELLOW_SOURCE', - sourceIndex: Option.some('.kibana_3') as Option.Some, - sourceIndexMappings: someMappings, + sourceIndex: Option.some('.kibana_7.11.0_001') as Option.Some, + sourceIndexMappings: baseState.targetIndexMappings, + aliases: { + '.kibana': '.kibana_7.11.0_001', + '.kibana_7.11.0': '.kibana_7.11.0_001', + }, }; - test('WAIT_FOR_YELLOW_SOURCE -> CHECK_UNKNOWN_DOCUMENTS if action succeeds', () => { - const res: ResponseType<'WAIT_FOR_YELLOW_SOURCE'> = Either.right({}); - const newState = model(waitForYellowSourceState, res); - expect(newState.controlState).toEqual('CHECK_UNKNOWN_DOCUMENTS'); + describe('if action succeeds', () => { + test('it resets retry count and delay', () => { + const res: ResponseType<'WAIT_FOR_YELLOW_SOURCE'> = Either.right({}); + const testState = { + ...waitForYellowSourceState, + retryCount: 1, + retryDelay: 2000, + }; + const newState = model(testState, res); + expect(newState.retryCount).toEqual(0); + expect(newState.retryDelay).toEqual(0); + }); - expect(newState).toMatchObject({ - controlState: 'CHECK_UNKNOWN_DOCUMENTS', - sourceIndex: Option.some('.kibana_3'), + describe('and mappings match (diffMappings == false)', () => { + const unchangedMappingsState: State = { + ...waitForYellowSourceState, + controlState: 'WAIT_FOR_YELLOW_SOURCE', + kibanaVersion: '7.12.0', // new version! + currentAlias: '.kibana', + versionAlias: '.kibana_7.12.0', + versionIndex: '.kibana_7.11.0_001', + }; + + test('WAIT_FOR_YELLOW_SOURCE -> PREPARE_COMPATIBLE_MIGRATION', () => { + const res: ResponseType<'WAIT_FOR_YELLOW_SOURCE'> = Either.right({ + '.kibana_7.11.0_001': { + aliases: { + '.kibana': {}, + '.kibana_7.11.0': {}, + }, + mappings: indexMapping, + settings: {}, + }, + }); + const newState = model(unchangedMappingsState, res) as PrepareCompatibleMigration; + + expect(newState.controlState).toEqual('PREPARE_COMPATIBLE_MIGRATION'); + expect(newState.targetIndexRawMappings).toEqual({ + _meta: { + migrationMappingPropertyHashes: { + new_saved_object_type: '4a11183eee21e6fbad864f7a30b39ad0', + }, + }, + properties: { + new_saved_object_type: { + properties: { + value: { + type: 'text', + }, + }, + }, + }, + }); + expect(newState.versionAlias).toEqual('.kibana_7.12.0'); + expect(newState.currentAlias).toEqual('.kibana'); + // will point to + expect(newState.targetIndex).toEqual('.kibana_7.11.0_001'); + expect(newState.preTransformDocsActions).toEqual([ + { + add: { + alias: '.kibana_7.12.0', + index: '.kibana_7.11.0_001', + }, + }, + { + remove: { + alias: '.kibana_7.11.0', + index: '.kibana_7.11.0_001', + must_exist: true, + }, + }, + ]); + }); + }); + + describe('and mappings DO NOT match (diffMappings == true)', () => { + const actualMappings: IndexMapping = { + properties: { + new_saved_object_type: { + properties: { + value: { type: 'integer' }, + }, + }, + }, + _meta: { + migrationMappingPropertyHashes: { + new_saved_object_type: '5b11183eee21e6fbad864f7a30b39be1', + }, + }, + }; + + const changedMappingsState: State = { + ...waitForYellowSourceState, + controlState: 'WAIT_FOR_YELLOW_SOURCE', + kibanaVersion: '7.12.0', // new version! + currentAlias: '.kibana', + versionAlias: '.kibana_7.12.0', + versionIndex: '.kibana_7.11.0_001', + sourceIndexMappings: actualMappings, + }; + + test('WAIT_FOR_YELLOW_SOURCE -> CHECK_UNKNOWN_DOCUMENTS', () => { + const res: ResponseType<'WAIT_FOR_YELLOW_SOURCE'> = Either.right({}); + const newState = model(changedMappingsState, res); + expect(newState.controlState).toEqual('CHECK_UNKNOWN_DOCUMENTS'); + + expect(newState).toMatchObject({ + controlState: 'CHECK_UNKNOWN_DOCUMENTS', + sourceIndex: Option.some('.kibana_7.11.0_001'), + sourceIndexMappings: actualMappings, + }); + }); }); }); @@ -1297,22 +1352,6 @@ describe('migrations v2 model', () => { } `); }); - - test('WAIT_FOR_YELLOW_SOURCE -> CHECK_UNKNOWN_DOCUMENTS resets retry count and delay if action succeeds', () => { - const res: ResponseType<'WAIT_FOR_YELLOW_SOURCE'> = Either.right({}); - const testState = { - ...waitForYellowSourceState, - retryCount: 1, - retryDelay: 2000, - }; - const newState = model(testState, res); - expect(newState.controlState).toEqual('CHECK_UNKNOWN_DOCUMENTS'); - - expect(newState).toMatchObject({ - controlState: 'CHECK_UNKNOWN_DOCUMENTS', - sourceIndex: Option.some('.kibana_3'), - }); - }); }); describe('CHECK_UNKNOWN_DOCUMENTS', () => { diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.ts index 44de571c13f5d..167a5d3771b78 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/model/model.ts @@ -158,48 +158,14 @@ export const model = (currentState: State, resW: ResponseType): }, ], }; - } else if ( - // source exists - Boolean(indices[source!]?.mappings?._meta?.migrationMappingPropertyHashes) && - // ...and mappings are unchanged - !diffMappings( - /* actual */ - indices[source!].mappings, - /* expected */ - stateP.targetIndexMappings - ) - ) { - const targetIndex = source!; - const sourceMappings = indices[source!].mappings; - - return { - ...stateP, - controlState: 'PREPARE_COMPATIBLE_MIGRATION', - sourceIndex: Option.none, - targetIndex, - targetIndexRawMappings: sourceMappings, - targetIndexMappings: mergeMigrationMappingPropertyHashes( - stateP.targetIndexMappings, - sourceMappings - ), - preTransformDocsActions: [ - // Point the version alias to the source index. This let's other Kibana - // instances know that a migration for the current version is "done" - // even though we may be waiting for document transformations to finish. - { add: { index: source!, alias: stateP.versionAlias } }, - ...buildRemoveAliasActions(source!, Object.keys(aliases), [ - stateP.currentAlias, - stateP.versionAlias, - ]), - ], - versionIndexReadyActions: Option.none, - }; } else if ( // If the `.kibana` alias exists source != null ) { + // CHECKPOINT here we decide to go for yellow source return { ...stateP, + aliases, controlState: 'WAIT_FOR_YELLOW_SOURCE', sourceIndex: Option.some(source!) as Option.Some, sourceIndexMappings: indices[source!].mappings, @@ -481,10 +447,50 @@ export const model = (currentState: State, resW: ResponseType): } else if (stateP.controlState === 'WAIT_FOR_YELLOW_SOURCE') { const res = resW as ExcludeRetryableEsError>; if (Either.isRight(res)) { - return { - ...stateP, - controlState: 'CHECK_UNKNOWN_DOCUMENTS', - }; + // check the existing mappings to see if we can avoid reindexing + if ( + // source exists + Boolean(stateP.sourceIndexMappings._meta?.migrationMappingPropertyHashes) && + // ...and mappings are unchanged + !diffMappings( + /* actual */ + stateP.sourceIndexMappings, + /* expected */ + stateP.targetIndexMappings + ) + ) { + // The source index .kibana is pointing to. E.g: ".xx8.7.0_001" + const source = stateP.sourceIndex.value; + + return { + ...stateP, + controlState: 'PREPARE_COMPATIBLE_MIGRATION', + sourceIndex: Option.none, + targetIndex: source!, + targetIndexRawMappings: stateP.sourceIndexMappings, + targetIndexMappings: mergeMigrationMappingPropertyHashes( + stateP.targetIndexMappings, + stateP.sourceIndexMappings + ), + preTransformDocsActions: [ + // Point the version alias to the source index. This let's other Kibana + // instances know that a migration for the current version is "done" + // even though we may be waiting for document transformations to finish. + { add: { index: source!, alias: stateP.versionAlias } }, + ...buildRemoveAliasActions(source!, Object.keys(stateP.aliases), [ + stateP.currentAlias, + stateP.versionAlias, + ]), + ], + versionIndexReadyActions: Option.none, + }; + } else { + // the mappings have changed, but changes might still be compatible + return { + ...stateP, + controlState: 'CHECK_UNKNOWN_DOCUMENTS', + }; + } } else if (Either.isLeft(res)) { const left = res.left; if (isTypeof(left, 'index_not_yellow_timeout')) { diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/state.ts b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/state.ts index e3873122329fd..f3a59fadf2dd4 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/state.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-internal/src/state.ts @@ -215,6 +215,7 @@ export interface WaitForYellowSourceState extends BaseState { readonly controlState: 'WAIT_FOR_YELLOW_SOURCE'; readonly sourceIndex: Option.Some; readonly sourceIndexMappings: IndexMapping; + readonly aliases: Record; } export interface CheckUnknownDocumentsState extends BaseState { diff --git a/packages/core/saved-objects/core-saved-objects-migration-server-mocks/src/migration.mocks.ts b/packages/core/saved-objects/core-saved-objects-migration-server-mocks/src/migration.mocks.ts index 6cb3cc3d1fd86..a32e683b579ab 100644 --- a/packages/core/saved-objects/core-saved-objects-migration-server-mocks/src/migration.mocks.ts +++ b/packages/core/saved-objects/core-saved-objects-migration-server-mocks/src/migration.mocks.ts @@ -16,7 +16,6 @@ export const createSavedObjectsMigrationLoggerMock = const mock = { debug: jest.fn(), info: jest.fn(), - warning: jest.fn(), warn: jest.fn(), error: jest.fn(), }; diff --git a/packages/core/saved-objects/core-saved-objects-server/index.ts b/packages/core/saved-objects/core-saved-objects-server/index.ts index f8791a1efbe5a..33b9dfd64f6f8 100644 --- a/packages/core/saved-objects/core-saved-objects-server/index.ts +++ b/packages/core/saved-objects/core-saved-objects-server/index.ts @@ -89,3 +89,11 @@ export { SECURITY_EXTENSION_ID, SPACES_EXTENSION_ID, } from './src/extensions/extensions'; + +export type { + SavedObject, + SavedObjectAttribute, + SavedObjectAttributes, + SavedObjectAttributeSingle, + SavedObjectReference, +} from '@kbn/core-saved-objects-common/src/server_types'; diff --git a/packages/core/saved-objects/core-saved-objects-server/src/migration.ts b/packages/core/saved-objects/core-saved-objects-server/src/migration.ts index 9ac9444a8dbee..9273009241e04 100644 --- a/packages/core/saved-objects/core-saved-objects-server/src/migration.ts +++ b/packages/core/saved-objects/core-saved-objects-server/src/migration.ts @@ -51,11 +51,6 @@ export type SavedObjectMigrationFn void; info: (msg: string) => void; - /** - * @deprecated Use `warn` instead. - * @removeBy 8.8.0 - */ - warning: (msg: string) => void; warn: (msg: string) => void; error: (msg: string, meta: Meta) => void; } diff --git a/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.test.mock.ts b/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.test.mock.ts index 9e2b5c66bc91a..34b6d5e7d7070 100644 --- a/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.test.mock.ts +++ b/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.test.mock.ts @@ -7,10 +7,12 @@ */ const mockUuidv1 = jest.fn().mockReturnValue('uuidv1'); -jest.mock('uuid/v1', () => mockUuidv1); - const mockUuidv5 = jest.fn().mockReturnValue('uuidv5'); Object.defineProperty(mockUuidv5, 'DNS', { value: 'DNSUUID', writable: false }); -jest.mock('uuid/v5', () => mockUuidv5); + +jest.mock('uuid', () => ({ + v1: mockUuidv1, + v5: mockUuidv5, +})); export { mockUuidv1, mockUuidv5 }; diff --git a/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.ts b/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.ts index 240abb53db289..f88ea5472fcb4 100644 --- a/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.ts +++ b/packages/core/saved-objects/core-saved-objects-utils-server/src/saved_objects_utils.ts @@ -6,8 +6,7 @@ * Side Public License, v 1. */ -import uuidv1 from 'uuid/v1'; -import uuidv5 from 'uuid/v5'; +import { v1 as uuidv1, v5 as uuidv5 } from 'uuid'; import type { SavedObjectsFindOptions, SavedObjectsFindResponse, diff --git a/packages/home/sample_data_card/kibana.jsonc b/packages/home/sample_data_card/kibana.jsonc index 03869fcdb70bf..330df0f2b7cb8 100644 --- a/packages/home/sample_data_card/kibana.jsonc +++ b/packages/home/sample_data_card/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/home-sample-data-card", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/home/sample_data_tab/kibana.jsonc b/packages/home/sample_data_tab/kibana.jsonc index ecf1eae5d146a..a44c2f7446c7e 100644 --- a/packages/home/sample_data_tab/kibana.jsonc +++ b/packages/home/sample_data_tab/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/home-sample-data-tab", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/home/sample_data_types/kibana.jsonc b/packages/home/sample_data_types/kibana.jsonc index f82d226f836e0..0297a131db3b8 100644 --- a/packages/home/sample_data_types/kibana.jsonc +++ b/packages/home/sample_data_types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/home-sample-data-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/kbn-apm-config-loader/src/config.test.ts b/packages/kbn-apm-config-loader/src/config.test.ts index 5bc723a27590b..697e601d92fdd 100644 --- a/packages/kbn-apm-config-loader/src/config.test.ts +++ b/packages/kbn-apm-config-loader/src/config.test.ts @@ -156,27 +156,52 @@ describe('ApmConfiguration', () => { delete process.env.NODE_ENV; }); - it('correctly sets environment by reading env vars', () => { - let config = new ApmConfiguration(mockedRootDir, {}, false); - expect(config.getConfig('serviceName')).toEqual( - expect.objectContaining({ - environment: 'development', - }) - ); + describe('correctly sets environment by reading env vars', () => { + it('no env var', () => { + const config = new ApmConfiguration(mockedRootDir, {}, false); + expect(config.getConfig('serviceName')).toEqual( + expect.objectContaining({ + environment: 'development', + }) + ); + }); + + it('NODE_ENV', () => { + process.env.NODE_ENV = 'production'; + const config = new ApmConfiguration(mockedRootDir, {}, false); + expect(config.getConfig('serviceName')).toEqual( + expect.objectContaining({ + environment: 'production', + }) + ); + }); + + it('ELASTIC_APM_ENVIRONMENT', () => { + process.env.ELASTIC_APM_ENVIRONMENT = 'ci'; + const config = new ApmConfiguration(mockedRootDir, {}, false); + expect(config.getConfig('serviceName')).toEqual( + expect.objectContaining({ + environment: 'ci', + }) + ); + }); + }); + + it('does not override the environment from NODE_ENV if already set in the config file', () => { + const kibanaConfig = { + elastic: { + apm: { + environment: 'local', + }, + }, + }; process.env.NODE_ENV = 'production'; - config = new ApmConfiguration(mockedRootDir, {}, false); - expect(config.getConfig('serviceName')).toEqual( - expect.objectContaining({ - environment: 'production', - }) - ); - process.env.ELASTIC_APM_ENVIRONMENT = 'ci'; - config = new ApmConfiguration(mockedRootDir, {}, false); + const config = new ApmConfiguration(mockedRootDir, kibanaConfig, false); expect(config.getConfig('serviceName')).toEqual( expect.objectContaining({ - environment: 'ci', + environment: 'local', }) ); }); diff --git a/packages/kbn-apm-config-loader/src/config.ts b/packages/kbn-apm-config-loader/src/config.ts index a993a5c38b3df..0552329acd205 100644 --- a/packages/kbn-apm-config-loader/src/config.ts +++ b/packages/kbn-apm-config-loader/src/config.ts @@ -111,7 +111,7 @@ export class ApmConfiguration { /** * Override some config values when specific environment variables are used */ - private getConfigFromEnv(): AgentConfigOptions { + private getConfigFromEnv(configFromKibanaConfig: AgentConfigOptions): AgentConfigOptions { const config: AgentConfigOptions = {}; if (process.env.ELASTIC_APM_ACTIVE === 'true') { @@ -124,8 +124,15 @@ export class ApmConfiguration { config.contextPropagationOnly = false; } - if (process.env.ELASTIC_APM_ENVIRONMENT || process.env.NODE_ENV) { - config.environment = process.env.ELASTIC_APM_ENVIRONMENT || process.env.NODE_ENV; + if (process.env.ELASTIC_APM_ENVIRONMENT) { + config.environment = process.env.ELASTIC_APM_ENVIRONMENT; + } else { + // We check NODE_ENV in a different way so that, unlike + // ELASTIC_APM_ENVIRONMENT, it does not override any explicit value set + // in the config file. + if (!configFromKibanaConfig.environment && process.env.NODE_ENV) { + config.environment = process.env.NODE_ENV; + } } if (process.env.ELASTIC_APM_TRANSACTION_SAMPLE_RATE) { @@ -256,7 +263,9 @@ export class ApmConfiguration { * Reads APM configuration from different sources and merges them together. */ private getConfigFromAllSources(): AgentConfigOptions { - const config = merge({}, this.getConfigFromKibanaConfig(), this.getConfigFromEnv()); + const configFromKibanaConfig = this.getConfigFromKibanaConfig(); + const configFromEnv = this.getConfigFromEnv(configFromKibanaConfig); + const config = merge({}, configFromKibanaConfig, configFromEnv); if (config.active === false && config.contextPropagationOnly !== false) { throw new Error( diff --git a/packages/kbn-apm-synthtrace/README.md b/packages/kbn-apm-synthtrace/README.md index 27ace45288298..6a6d0b726a5e4 100644 --- a/packages/kbn-apm-synthtrace/README.md +++ b/packages/kbn-apm-synthtrace/README.md @@ -139,6 +139,7 @@ Note: - The default `--to` is `15m`. - You can combine `--from` and `--to` with `--live` to back-fill some data. +- To specify `--scenarioOpts` you need to use [yargs Objects syntax](https://github.com/yargs/yargs/blob/HEAD/docs/tricks.md#objects). (e.g. --scenarioOpts.myOption=myValue) ### Setup options diff --git a/packages/kbn-cases-components/.storybook/main.js b/packages/kbn-cases-components/.storybook/main.js new file mode 100644 index 0000000000000..8dc3c5d1518f4 --- /dev/null +++ b/packages/kbn-cases-components/.storybook/main.js @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +module.exports = require('@kbn/storybook').defaultConfig; diff --git a/packages/kbn-cases-components/README.md b/packages/kbn-cases-components/README.md index bc60e2fba7fe5..cea88ceb6b37b 100644 --- a/packages/kbn-cases-components/README.md +++ b/packages/kbn-cases-components/README.md @@ -13,3 +13,34 @@ import { Status, CaseStatuses } from '@kbn/cases-components'; ``` + +### Tooltip + +The component renders the tooltip with case details on hover of an Element. Usage: + +``` +import { Tooltip, CaseStatuses } from '@kbn/cases-components'; +import type { CaseTooltipContentProps, CaseTooltipProps } from '@kbn/cases-components'; + +const tooltipContent: CaseTooltipContentProps = { + title: 'Case title', + description: 'Case description', + createdAt: '2020-02-19T23:06:33.798Z', + createdBy: { + fullName: 'Elastic User', + username: 'elastic', + }, + totalComments: 1, + status: CaseStatuses.open, +} + +const tooltipProps: CaseTooltipProps = { + loading: false, + content: tooltipContent, + className: 'customClass', +}; + + + This is a demo span + +``` diff --git a/packages/kbn-cases-components/index.ts b/packages/kbn-cases-components/index.ts index 47a7a298f0e1d..9605b0267a25f 100644 --- a/packages/kbn-cases-components/index.ts +++ b/packages/kbn-cases-components/index.ts @@ -9,3 +9,5 @@ export { Status } from './src/status/status'; export { CaseStatuses } from './src/status/types'; export { getStatusConfiguration } from './src/status/config'; +export { Tooltip } from './src/tooltip/tooltip'; +export type { CaseTooltipProps, CaseTooltipContentProps } from './src/tooltip/types'; diff --git a/packages/kbn-cases-components/src/__stories__/tooltip.stories.tsx b/packages/kbn-cases-components/src/__stories__/tooltip.stories.tsx new file mode 100644 index 0000000000000..673e17db75bee --- /dev/null +++ b/packages/kbn-cases-components/src/__stories__/tooltip.stories.tsx @@ -0,0 +1,103 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { I18nProvider } from '@kbn/i18n-react'; +import { ComponentStory, ComponentMeta } from '@storybook/react'; + +import { CaseStatuses } from '../status/types'; +import { Tooltip } from '../tooltip/tooltip'; +import type { CaseTooltipProps, CaseTooltipContentProps } from '../tooltip/types'; + +const sampleText = 'This is a test span element!!'; +const TestSpan = () => ( + + {sampleText} + +); + +const tooltipContent: CaseTooltipContentProps = { + title: 'Unusual process identified', + description: 'There was an unusual process while adding alerts to existing case.', + createdAt: '2020-02-19T23:06:33.798Z', + createdBy: { + fullName: 'Elastic User', + username: 'elastic', + }, + totalComments: 10, + status: CaseStatuses.open, +}; + +const tooltipProps: CaseTooltipProps = { + children: TestSpan, + loading: false, + content: tooltipContent, +}; + +const longTitle = `Lorem Ipsum is simply dummy text of the printing and typesetting industry. + Lorem Ipsum has been the industry standard dummy text ever since the 1500s!! Lorem!!!`; + +const longDescription = `Lorem Ipsum is simply dummy text of the printing and typesetting industry. + Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer + took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, + but also the leap into electronic typesetting, remaining essentially unchanged.`; + +const Template = (args: CaseTooltipProps) => ( + + + + + +); + +export default { + title: 'CaseTooltip', + component: Template, +} as ComponentMeta; + +export const Default: ComponentStory = Template.bind({}); +Default.args = { ...tooltipProps }; + +export const LoadingState: ComponentStory = Template.bind({}); +LoadingState.args = { ...tooltipProps, loading: true }; + +export const LongTitle: ComponentStory = Template.bind({}); +LongTitle.args = { ...tooltipProps, content: { ...tooltipContent, title: longTitle } }; + +export const LongDescription: ComponentStory = Template.bind({}); +LongDescription.args = { + ...tooltipProps, + content: { ...tooltipContent, description: longDescription }, +}; + +export const InProgressStatus: ComponentStory = Template.bind({}); +InProgressStatus.args = { + ...tooltipProps, + content: { ...tooltipContent, status: CaseStatuses['in-progress'] }, +}; + +export const ClosedStatus: ComponentStory = Template.bind({}); +ClosedStatus.args = { + ...tooltipProps, + content: { ...tooltipContent, status: CaseStatuses.closed }, +}; + +export const NoUserInfo: ComponentStory = Template.bind({}); +NoUserInfo.args = { ...tooltipProps, content: { ...tooltipContent, createdBy: {} } }; + +export const FullName: ComponentStory = Template.bind({}); +FullName.args = { + ...tooltipProps, + content: { ...tooltipContent, createdBy: { fullName: 'Elastic User' } }, +}; + +export const LongUserName: ComponentStory = Template.bind({}); +LongUserName.args = { + ...tooltipProps, + content: { ...tooltipContent, createdBy: { fullName: 'LoremIpsumElasticUser WithALongSurname' } }, +}; diff --git a/packages/kbn-cases-components/src/tooltip/icon_with_count.test.tsx b/packages/kbn-cases-components/src/tooltip/icon_with_count.test.tsx new file mode 100644 index 0000000000000..99a777fd91bb9 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/icon_with_count.test.tsx @@ -0,0 +1,26 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { render } from '@testing-library/react'; + +import { IconWithCount } from './icon_with_count'; + +describe('IconWithCount', () => { + it('renders component correctly', () => { + const res = render(); + + expect(res.getByTestId('comment-count-icon')).toBeInTheDocument(); + }); + + it('renders count correctly', () => { + const res = render(); + + expect(res.getByText(100)).toBeInTheDocument(); + }); +}); diff --git a/packages/kbn-cases-components/src/tooltip/icon_with_count.tsx b/packages/kbn-cases-components/src/tooltip/icon_with_count.tsx new file mode 100644 index 0000000000000..80e8c8c9a7520 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/icon_with_count.tsx @@ -0,0 +1,31 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { EuiFlexGroup, EuiFlexItem, EuiIcon, EuiText } from '@elastic/eui'; +import React from 'react'; + +export const IconWithCount = React.memo<{ + count: number; + icon: string; +}>(({ count, icon }) => ( + + + + + + {count} + + +)); + +IconWithCount.displayName = 'IconWithCount'; diff --git a/packages/kbn-cases-components/src/tooltip/skeleton.tsx b/packages/kbn-cases-components/src/tooltip/skeleton.tsx new file mode 100644 index 0000000000000..f0c78e2a2e215 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/skeleton.tsx @@ -0,0 +1,25 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { EuiFlexItem, EuiLoadingContent, EuiHorizontalRule, EuiSpacer } from '@elastic/eui'; + +const SkeletonComponent: React.FC = () => { + return ( + + + + + + + ); +}; + +SkeletonComponent.displayName = 'Skeleton'; + +export const Skeleton = SkeletonComponent; diff --git a/packages/kbn-cases-components/src/tooltip/tooltip.test.tsx b/packages/kbn-cases-components/src/tooltip/tooltip.test.tsx new file mode 100644 index 0000000000000..a4573db2f8ccd --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/tooltip.test.tsx @@ -0,0 +1,175 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { render, fireEvent } from '@testing-library/react'; +import { I18nProvider } from '@kbn/i18n-react'; + +import { Tooltip } from './tooltip'; +import { CaseStatuses } from '../status/types'; +import type { CaseTooltipContentProps, CaseTooltipProps } from './types'; + +const elasticUser = { + fullName: 'Elastic User', + username: 'elastic', +}; + +const sampleText = 'This is a test span element!!'; +const TestSpan = () => {sampleText}; + +const tooltipContent: CaseTooltipContentProps = { + title: 'Another horrible breach!!', + description: 'Demo case banana Issue', + createdAt: '2020-02-19T23:06:33.798Z', + createdBy: elasticUser, + totalComments: 1, + status: CaseStatuses.open, +}; + +const tooltipProps: CaseTooltipProps = { + children: TestSpan, + loading: false, + content: tooltipContent, +}; + +describe('Tooltip', () => { + it('renders correctly', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByTestId('cases-components-tooltip')).toBeInTheDocument(); + }); + + it('renders custom test subject correctly', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByTestId('custom-data-test')).toBeInTheDocument(); + }); + + it('renders loading state correctly', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByTestId('tooltip-loading-content')).toBeInTheDocument(); + }); + + it('renders title correctly', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByText(tooltipContent.title)).toBeInTheDocument(); + }); + + it('renders description correctly', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByText(tooltipContent.description)).toBeInTheDocument(); + }); + + it('renders icon', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByTestId('comment-count-icon')).toBeInTheDocument(); + }); + + it('renders comment count', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByText(tooltipContent.totalComments)).toBeInTheDocument(); + }); + + it('renders correct status', async () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByText('Closed')).toBeInTheDocument(); + }); + + it('renders full name when no username available', async () => { + const newUser = { + fullName: 'New User', + }; + + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(await res.findByTestId('tooltip-username')).toBeInTheDocument(); + expect(await res.findByText(newUser.fullName)).toBeInTheDocument(); + }); + + it('does not render username when no username or full name available', () => { + const res = render( + + + + + + ); + + fireEvent.mouseOver(res.getByTestId('sample-span')); + expect(res.queryByTestId('tooltip-username')).not.toBeInTheDocument(); + }); +}); diff --git a/packages/kbn-cases-components/src/tooltip/tooltip.tsx b/packages/kbn-cases-components/src/tooltip/tooltip.tsx new file mode 100644 index 0000000000000..7ac199ff58f24 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/tooltip.tsx @@ -0,0 +1,32 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { memo } from 'react'; +import { EuiToolTip } from '@elastic/eui'; + +import { TooltipContent } from './tooltip_content'; +import type { CaseTooltipProps } from './types'; +import { Skeleton } from './skeleton'; + +const CaseTooltipComponent = React.memo((props) => { + const { dataTestSubj, children, loading = false, className = '', content } = props; + + return ( + : } + > + <>{children} + + ); +}); + +CaseTooltipComponent.displayName = 'Tooltip'; + +export const Tooltip = memo(CaseTooltipComponent); diff --git a/packages/kbn-cases-components/src/tooltip/tooltip_content.tsx b/packages/kbn-cases-components/src/tooltip/tooltip_content.tsx new file mode 100644 index 0000000000000..262365fba3ae4 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/tooltip_content.tsx @@ -0,0 +1,69 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { memo } from 'react'; +import { FormattedRelative } from '@kbn/i18n-react'; +import { EuiFlexGroup, EuiFlexItem, EuiText, EuiHorizontalRule } from '@elastic/eui'; + +import { Status } from '../status/status'; +import { CaseStatuses } from '../status/types'; +import { IconWithCount } from './icon_with_count'; +import { getTruncatedText } from './utils'; +import * as i18n from './translations'; +import type { CaseTooltipContentProps } from './types'; + +const TITLE_TRUNCATE_LENGTH = 35; +const DESCRIPTION_TRUNCATE_LENGTH = 80; +const USER_TRUNCATE_LENGTH = 15; + +const CaseTooltipContentComponent = React.memo( + ({ title, description, status, totalComments, createdAt, createdBy }) => ( + <> + + + + + + + + + + + {getTruncatedText(title, TITLE_TRUNCATE_LENGTH)} + + + + + {getTruncatedText(description, DESCRIPTION_TRUNCATE_LENGTH)} + + + + + + + {status === CaseStatuses.closed ? i18n.CLOSED : i18n.OPENED}{' '} + {' '} + {createdBy.username || createdBy.fullName ? ( + <> + {i18n.BY}{' '} + + {getTruncatedText( + createdBy.username ?? createdBy.fullName ?? '', + USER_TRUNCATE_LENGTH + )} + + + ) : null} + + + ) +); + +CaseTooltipContentComponent.displayName = 'TooltipContent'; + +export const TooltipContent = memo(CaseTooltipContentComponent); diff --git a/packages/kbn-cases-components/src/tooltip/translations.ts b/packages/kbn-cases-components/src/tooltip/translations.ts new file mode 100644 index 0000000000000..b9223ba032206 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/translations.ts @@ -0,0 +1,21 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { i18n } from '@kbn/i18n'; + +export const OPENED = i18n.translate('cases.components.tooltip.opened', { + defaultMessage: 'Opened', +}); + +export const CLOSED = i18n.translate('cases.components.tooltip.closed', { + defaultMessage: 'Closed', +}); + +export const BY = i18n.translate('cases.components.tooltip.by', { + defaultMessage: 'by', +}); diff --git a/packages/kbn-cases-components/src/tooltip/types.ts b/packages/kbn-cases-components/src/tooltip/types.ts new file mode 100644 index 0000000000000..dea545ab8f40b --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/types.ts @@ -0,0 +1,25 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { CaseStatuses } from '../status/types'; +export interface CaseTooltipContentProps { + title: string; + description: string; + status: CaseStatuses; + totalComments: number; + createdAt: string; + createdBy: { username?: string; fullName?: string }; +} + +export interface CaseTooltipProps { + children: React.ReactNode; + content: CaseTooltipContentProps; + dataTestSubj?: string; + className?: string; + loading?: boolean; +} diff --git a/packages/kbn-cases-components/src/tooltip/utils.test.ts b/packages/kbn-cases-components/src/tooltip/utils.test.ts new file mode 100644 index 0000000000000..b9d5657ab0e3e --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/utils.test.ts @@ -0,0 +1,51 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { getTruncatedText } from './utils'; + +describe('getTruncatedText', () => { + it('should return truncated text correctly', () => { + const sampleText = 'This is a sample text!!'; + const res = getTruncatedText(sampleText, 4); + + expect(res).toEqual('This...'); + }); + + it('should return original text if text is empty', () => { + const res = getTruncatedText('', 4); + + expect(res).toEqual(''); + }); + + it('should return empty text if text is empty', () => { + const res = getTruncatedText('', 10); + + expect(res).toEqual(''); + }); + + it('should return original text if truncate length is negative', () => { + const sampleText = 'This is a sample text!!'; + const res = getTruncatedText(sampleText, -4); + + expect(res).toEqual(sampleText); + }); + + it('should return original text if truncate length is zero', () => { + const sampleText = 'This is a sample text!!'; + const res = getTruncatedText(sampleText, 0); + + expect(res).toEqual(sampleText); + }); + + it('should return original text if text is smaller than truncate length number', () => { + const sampleText = 'This is a sample text!!'; + const res = getTruncatedText(sampleText, 50); + + expect(res).toEqual(sampleText); + }); +}); diff --git a/packages/kbn-cases-components/src/tooltip/utils.ts b/packages/kbn-cases-components/src/tooltip/utils.ts new file mode 100644 index 0000000000000..95b43e62c36e8 --- /dev/null +++ b/packages/kbn-cases-components/src/tooltip/utils.ts @@ -0,0 +1,15 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export const getTruncatedText = (text: string, truncateLength: number): string => { + if (truncateLength <= 0 || text.length <= truncateLength) { + return text; + } + + return text.slice(0, truncateLength).trim().concat('...'); +}; diff --git a/packages/kbn-cases-components/tsconfig.json b/packages/kbn-cases-components/tsconfig.json index 3d7519541dc8d..09abcbdb81a3e 100644 --- a/packages/kbn-cases-components/tsconfig.json +++ b/packages/kbn-cases-components/tsconfig.json @@ -14,6 +14,7 @@ ], "kbn_references": [ "@kbn/i18n", + "@kbn/i18n-react", ], "exclude": [ "target/**/*", diff --git a/packages/kbn-cell-actions/.storybook/main.js b/packages/kbn-cell-actions/.storybook/main.js new file mode 100644 index 0000000000000..8dc3c5d1518f4 --- /dev/null +++ b/packages/kbn-cell-actions/.storybook/main.js @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +module.exports = require('@kbn/storybook').defaultConfig; diff --git a/packages/kbn-cell-actions/README.md b/packages/kbn-cell-actions/README.md new file mode 100644 index 0000000000000..7cacff6becda6 --- /dev/null +++ b/packages/kbn-cell-actions/README.md @@ -0,0 +1,15 @@ +This package provides a uniform interface for displaying UI actions for a cell. +For the `CellActions` component to work, it must be wrapped by `CellActionsProvider`. Ideally, the wrapper should stay on the top of the rendering tree. + +Example: + +```JSX + + [...] + + Hover me + + +``` + +`CellActions` component will display all compatible actions registered for the trigger id. diff --git a/src/plugins/unified_histogram/public/chart/consts.ts b/packages/kbn-cell-actions/index.ts similarity index 89% rename from src/plugins/unified_histogram/public/chart/consts.ts rename to packages/kbn-cell-actions/index.ts index d2af2ed4ee33a..de0577ee3ed83 100644 --- a/src/plugins/unified_histogram/public/chart/consts.ts +++ b/packages/kbn-cell-actions/index.ts @@ -6,4 +6,4 @@ * Side Public License, v 1. */ -export const REQUEST_DEBOUNCE_MS = 100; +export * from './src'; diff --git a/packages/kbn-cell-actions/jest.config.js b/packages/kbn-cell-actions/jest.config.js new file mode 100644 index 0000000000000..b9301a9500864 --- /dev/null +++ b/packages/kbn-cell-actions/jest.config.js @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +module.exports = { + preset: '@kbn/test', + rootDir: '../..', + roots: ['/packages/kbn-cell-actions'], +}; diff --git a/packages/kbn-cell-actions/kibana.jsonc b/packages/kbn-cell-actions/kibana.jsonc new file mode 100644 index 0000000000000..e1ce1385436b3 --- /dev/null +++ b/packages/kbn-cell-actions/kibana.jsonc @@ -0,0 +1,5 @@ +{ + "type": "shared-common", + "id": "@kbn/cell-actions", + "owner": "@elastic/security-threat-hunting-explore" +} diff --git a/packages/kbn-cell-actions/package.json b/packages/kbn-cell-actions/package.json new file mode 100644 index 0000000000000..f216094e0a710 --- /dev/null +++ b/packages/kbn-cell-actions/package.json @@ -0,0 +1,7 @@ +{ + "name": "@kbn/cell-actions", + "version": "1.0.0", + "description": "Uniform components for displaying UI actions in data cells", + "license": "SSPL-1.0 OR Elastic License 2.0", + "private": true +} diff --git a/packages/kbn-cell-actions/src/__stories__/cell_actions.stories.tsx b/packages/kbn-cell-actions/src/__stories__/cell_actions.stories.tsx new file mode 100644 index 0000000000000..4c0f362d3ddf1 --- /dev/null +++ b/packages/kbn-cell-actions/src/__stories__/cell_actions.stories.tsx @@ -0,0 +1,78 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { ComponentStory } from '@storybook/react'; +import { CellActionsProvider } from '../context/cell_actions_context'; +import { makeAction } from '../mocks/helpers'; +import { CellActions } from '../components/cell_actions'; +import { CellActionsMode, type CellActionsProps } from '../types'; + +const TRIGGER_ID = 'testTriggerId'; + +const FIELD = { name: 'name', value: '123', type: 'text' }; + +const getCompatibleActions = () => + Promise.resolve([ + makeAction('Filter in', 'plusInCircle', 2), + makeAction('Filter out', 'minusInCircle', 3), + makeAction('Minimize', 'minimize', 1), + makeAction('Send email', 'email', 4), + makeAction('Pin field', 'pin', 5), + ]); + +export default { + title: 'CellAction', + decorators: [ + (storyFn: Function) => ( + +
    + {storyFn()} + + ), + ], +}; + +const CellActionsTemplate: ComponentStory> = (args) => ( + Field value +); + +export const DefaultWithControls = CellActionsTemplate.bind({}); + +DefaultWithControls.argTypes = { + mode: { + options: [CellActionsMode.HOVER, CellActionsMode.INLINE], + defaultValue: CellActionsMode.HOVER, + control: { + type: 'radio', + }, + }, +}; + +DefaultWithControls.args = { + showActionTooltips: true, + mode: CellActionsMode.INLINE, + triggerId: TRIGGER_ID, + field: FIELD, + visibleCellActions: 3, +}; + +export const CellActionInline = ({}: {}) => ( + + Field value + +); + +export const CellActionHoverPopup = ({}: {}) => ( + + Hover me + +); diff --git a/packages/kbn-cell-actions/src/components/cell_action_item.test.tsx b/packages/kbn-cell-actions/src/components/cell_action_item.test.tsx new file mode 100644 index 0000000000000..ab56f083f7365 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/cell_action_item.test.tsx @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { render } from '@testing-library/react'; +import React from 'react'; +import { makeAction } from '../mocks/helpers'; +import { CellActionExecutionContext } from '../types'; +import { ActionItem } from './cell_action_item'; + +describe('ActionItem', () => { + it('renders', () => { + const action = makeAction('test-action'); + const actionContext = {} as CellActionExecutionContext; + const { queryByTestId } = render( + + ); + expect(queryByTestId('actionItem-test-action')).toBeInTheDocument(); + }); + + it('renders tooltip when showTooltip=true is received', () => { + const action = makeAction('test-action'); + const actionContext = {} as CellActionExecutionContext; + const { container } = render( + + ); + + expect(container.querySelector('.euiToolTipAnchor')).not.toBeNull(); + }); +}); diff --git a/packages/kbn-cell-actions/src/components/cell_action_item.tsx b/packages/kbn-cell-actions/src/components/cell_action_item.tsx new file mode 100644 index 0000000000000..b002afb35d83f --- /dev/null +++ b/packages/kbn-cell-actions/src/components/cell_action_item.tsx @@ -0,0 +1,44 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { useMemo } from 'react'; + +import { EuiButtonIcon, EuiToolTip, IconType } from '@elastic/eui'; +import type { CellAction, CellActionExecutionContext } from '../types'; + +export const ActionItem = ({ + action, + actionContext, + showTooltip, +}: { + action: CellAction; + actionContext: CellActionExecutionContext; + showTooltip: boolean; +}) => { + const actionProps = useMemo( + () => ({ + iconType: action.getIconType(actionContext) as IconType, + onClick: () => action.execute(actionContext), + 'data-test-subj': `actionItem-${action.id}`, + 'aria-label': action.getDisplayName(actionContext), + }), + [action, actionContext] + ); + + if (!actionProps.iconType) return null; + + return showTooltip ? ( + + + + ) : ( + + ); +}; diff --git a/packages/kbn-cell-actions/src/components/cell_actions.test.tsx b/packages/kbn-cell-actions/src/components/cell_actions.test.tsx new file mode 100644 index 0000000000000..d23d7f731b156 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/cell_actions.test.tsx @@ -0,0 +1,75 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { act, render } from '@testing-library/react'; +import React from 'react'; +import { CellActions } from './cell_actions'; +import { CellActionsMode } from '../types'; +import { CellActionsProvider } from '../context/cell_actions_context'; + +const TRIGGER_ID = 'test-trigger-id'; +const FIELD = { name: 'name', value: '123', type: 'text' }; + +describe('CellActions', () => { + it('renders', async () => { + const getActionsPromise = Promise.resolve([]); + const getActions = () => getActionsPromise; + + const { queryByTestId } = render( + + + Field value + + + ); + + await act(async () => { + await getActionsPromise; + }); + + expect(queryByTestId('cellActions')).toBeInTheDocument(); + }); + + it('renders InlineActions when mode is INLINE', async () => { + const getActionsPromise = Promise.resolve([]); + const getActions = () => getActionsPromise; + + const { queryByTestId } = render( + + + Field value + + + ); + + await act(async () => { + await getActionsPromise; + }); + + expect(queryByTestId('inlineActions')).toBeInTheDocument(); + }); + + it('renders HoverActionsPopover when mode is HOVER', async () => { + const getActionsPromise = Promise.resolve([]); + const getActions = () => getActionsPromise; + + const { queryByTestId } = render( + + + Field value + + + ); + + await act(async () => { + await getActionsPromise; + }); + + expect(queryByTestId('hoverActionsPopover')).toBeInTheDocument(); + }); +}); diff --git a/packages/kbn-cell-actions/src/components/cell_actions.tsx b/packages/kbn-cell-actions/src/components/cell_actions.tsx new file mode 100644 index 0000000000000..682233eaa76b7 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/cell_actions.tsx @@ -0,0 +1,64 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { useMemo, useRef } from 'react'; +import { InlineActions } from './inline_actions'; +import { HoverActionsPopover } from './hover_actions_popover'; +import { CellActionsMode, type CellActionsProps, type CellActionExecutionContext } from '../types'; + +export const CellActions: React.FC = ({ + field, + triggerId, + children, + mode, + showActionTooltips = true, + visibleCellActions = 3, + metadata, +}) => { + const extraContentNodeRef = useRef(null); + const nodeRef = useRef(null); + + const actionContext: CellActionExecutionContext = useMemo( + () => ({ + field, + trigger: { id: triggerId }, + extraContentNodeRef, + nodeRef, + metadata, + }), + [field, triggerId, metadata] + ); + + if (mode === CellActionsMode.HOVER) { + return ( +
    + + {children} + + +
    +
    + ); + } + + return ( +
    + {children} + +
    +
    + ); +}; diff --git a/packages/kbn-cell-actions/src/components/extra_actions_button.test.tsx b/packages/kbn-cell-actions/src/components/extra_actions_button.test.tsx new file mode 100644 index 0000000000000..0fcc81a9cc1c9 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/extra_actions_button.test.tsx @@ -0,0 +1,32 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { fireEvent, render } from '@testing-library/react'; +import React from 'react'; +import { ExtraActionsButton } from './extra_actions_button'; + +describe('ExtraActionsButton', () => { + it('renders', () => { + const { queryByTestId } = render( {}} showTooltip={false} />); + + expect(queryByTestId('showExtraActionsButton')).toBeInTheDocument(); + }); + + it('renders tooltip when showTooltip=true is received', () => { + const { container } = render( {}} showTooltip />); + expect(container.querySelector('.euiToolTipAnchor')).not.toBeNull(); + }); + + it('calls onClick when button is clicked', () => { + const onClick = jest.fn(); + const { getByTestId } = render(); + + fireEvent.click(getByTestId('showExtraActionsButton')); + expect(onClick).toHaveBeenCalled(); + }); +}); diff --git a/packages/kbn-cell-actions/src/components/extra_actions_button.tsx b/packages/kbn-cell-actions/src/components/extra_actions_button.tsx new file mode 100644 index 0000000000000..e70a28e5db4e3 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/extra_actions_button.tsx @@ -0,0 +1,35 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { EuiButtonIcon, EuiToolTip } from '@elastic/eui'; +import React from 'react'; +import { SHOW_MORE_ACTIONS } from './translations'; + +interface ExtraActionsButtonProps { + onClick: () => void; + showTooltip: boolean; +} + +export const ExtraActionsButton: React.FC = ({ onClick, showTooltip }) => + showTooltip ? ( + + + + ) : ( + + ); diff --git a/packages/kbn-cell-actions/src/components/extra_actions_popover.test.tsx b/packages/kbn-cell-actions/src/components/extra_actions_popover.test.tsx new file mode 100644 index 0000000000000..b463077bceed6 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/extra_actions_popover.test.tsx @@ -0,0 +1,90 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { act, fireEvent, render } from '@testing-library/react'; +import React from 'react'; +import { makeAction, makeActionContext } from '../mocks/helpers'; +import { ExtraActionsPopOver, ExtraActionsPopOverWithAnchor } from './extra_actions_popover'; + +const actionContext = makeActionContext(); +describe('ExtraActionsPopOver', () => { + it('renders', () => { + const { queryByTestId } = render( + {}} + actions={[]} + button={} + /> + ); + + expect(queryByTestId('extraActionsPopOver')).toBeInTheDocument(); + }); + + it('executes action and close popover when menu item is clicked', async () => { + const executeAction = jest.fn(); + const closePopOver = jest.fn(); + const action = { ...makeAction('test-action'), execute: executeAction }; + const { getByLabelText } = render( + } + /> + ); + + await act(async () => { + await fireEvent.click(getByLabelText('test-action')); + }); + + expect(executeAction).toHaveBeenCalled(); + expect(closePopOver).toHaveBeenCalled(); + }); +}); + +describe('ExtraActionsPopOverWithAnchor', () => { + const anchorElement = document.createElement('span'); + document.body.appendChild(anchorElement); + + it('renders', () => { + const { queryByTestId } = render( + {}} + actions={[]} + anchorRef={{ current: anchorElement }} + /> + ); + + expect(queryByTestId('extraActionsPopOverWithAnchor')).toBeInTheDocument(); + }); + + it('executes action and close popover when menu item is clicked', () => { + const executeAction = jest.fn(); + const closePopOver = jest.fn(); + const action = { ...makeAction('test-action'), execute: executeAction }; + const { getByLabelText } = render( + + ); + + fireEvent.click(getByLabelText('test-action')); + + expect(executeAction).toHaveBeenCalled(); + expect(closePopOver).toHaveBeenCalled(); + }); +}); diff --git a/packages/kbn-cell-actions/src/components/extra_actions_popover.tsx b/packages/kbn-cell-actions/src/components/extra_actions_popover.tsx new file mode 100644 index 0000000000000..4ed1c0d629dcd --- /dev/null +++ b/packages/kbn-cell-actions/src/components/extra_actions_popover.tsx @@ -0,0 +1,132 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { + EuiContextMenuItem, + EuiContextMenuPanel, + EuiPopover, + EuiScreenReaderOnly, + EuiWrappingPopover, +} from '@elastic/eui'; +import React, { useMemo } from 'react'; +import { euiThemeVars } from '@kbn/ui-theme'; +import { css } from '@emotion/react'; +import { EXTRA_ACTIONS_ARIA_LABEL, YOU_ARE_IN_A_DIALOG_CONTAINING_OPTIONS } from './translations'; +import type { CellAction, CellActionExecutionContext } from '../types'; + +const euiContextMenuItemCSS = css` + color: ${euiThemeVars.euiColorPrimaryText}; +`; + +interface ActionsPopOverProps { + actionContext: CellActionExecutionContext; + isOpen: boolean; + closePopOver: () => void; + actions: CellAction[]; + button: JSX.Element; +} + +export const ExtraActionsPopOver: React.FC = ({ + actions, + actionContext, + isOpen, + closePopOver, + button, +}) => ( + + + +); + +interface ExtraActionsPopOverWithAnchorProps + extends Pick { + anchorRef: React.RefObject; +} + +export const ExtraActionsPopOverWithAnchor = ({ + anchorRef, + actionContext, + isOpen, + closePopOver, + actions, +}: ExtraActionsPopOverWithAnchorProps) => { + return anchorRef.current ? ( + + + + ) : null; +}; + +type ExtraActionsPopOverContentProps = Pick< + ActionsPopOverProps, + 'actionContext' | 'closePopOver' | 'actions' +>; + +const ExtraActionsPopOverContent: React.FC = ({ + actionContext, + actions, + closePopOver, +}) => { + const items = useMemo( + () => + actions.map((action) => ( + { + closePopOver(); + action.execute(actionContext); + }} + > + {action.getDisplayName(actionContext)} + + )), + [actionContext, actions, closePopOver] + ); + return ( + <> + +

    {YOU_ARE_IN_A_DIALOG_CONTAINING_OPTIONS(actionContext.field.name)}

    +
    + + + ); +}; diff --git a/packages/kbn-cell-actions/src/components/hover_actions_popover.test.tsx b/packages/kbn-cell-actions/src/components/hover_actions_popover.test.tsx new file mode 100644 index 0000000000000..8326b4a70f366 --- /dev/null +++ b/packages/kbn-cell-actions/src/components/hover_actions_popover.test.tsx @@ -0,0 +1,191 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { act, fireEvent, render } from '@testing-library/react'; +import React from 'react'; +import { makeAction, makeActionContext } from '../mocks/helpers'; +import { HoverActionsPopover } from './hover_actions_popover'; +import { CellActionsProvider } from '../context/cell_actions_context'; + +describe('HoverActionsPopover', () => { + const actionContext = makeActionContext(); + const TestComponent = () => ; + jest.useFakeTimers(); + + it('renders', () => { + const getActions = () => Promise.resolve([]); + const { queryByTestId } = render( + + + + ); + expect(queryByTestId('hoverActionsPopover')).toBeInTheDocument(); + }); + + it('renders actions when hovered', async () => { + const action = makeAction('test-action'); + const getActionsPromise = Promise.resolve([action]); + const getActions = () => getActionsPromise; + + const { queryByLabelText, getByTestId } = render( + + + + + + ); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + expect(queryByLabelText('test-action')).toBeInTheDocument(); + }); + + it('hide actions when mouse stops hovering', async () => { + const action = makeAction('test-action'); + const getActionsPromise = Promise.resolve([action]); + const getActions = () => getActionsPromise; + + const { queryByLabelText, getByTestId } = render( + + + + + + ); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + // Mouse leaves hover state + await act(async () => { + fireEvent.mouseLeave(getByTestId('test-component')); + }); + + expect(queryByLabelText('test-action')).not.toBeInTheDocument(); + }); + + it('renders extra actions button', async () => { + const actions = [makeAction('test-action-1'), makeAction('test-action-2')]; + const getActionsPromise = Promise.resolve(actions); + const getActions = () => getActionsPromise; + + const { getByTestId } = render( + + + + + + ); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + expect(getByTestId('showExtraActionsButton')).toBeInTheDocument(); + }); + + it('shows extra actions when extra actions button is clicked', async () => { + const actions = [makeAction('test-action-1'), makeAction('test-action-2')]; + const getActionsPromise = Promise.resolve(actions); + const getActions = () => getActionsPromise; + + const { getByTestId, getByLabelText } = render( + + + + + + ); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + act(() => { + fireEvent.click(getByTestId('showExtraActionsButton')); + }); + + expect(getByLabelText('test-action-2')).toBeInTheDocument(); + }); + + it('does not render visible actions if extra actions are already rendered', async () => { + const actions = [ + makeAction('test-action-1'), + // extra actions + makeAction('test-action-2'), + makeAction('test-action-3'), + ]; + const getActionsPromise = Promise.resolve(actions); + const getActions = () => getActionsPromise; + + const { getByTestId, queryByLabelText } = render( + + + + + + ); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + act(() => { + fireEvent.click(getByTestId('showExtraActionsButton')); + }); + + await hoverElement(getByTestId('test-component'), async () => { + await getActionsPromise; + jest.runAllTimers(); + }); + + expect(queryByLabelText('test-action-1')).not.toBeInTheDocument(); + expect(queryByLabelText('test-action-2')).toBeInTheDocument(); + expect(queryByLabelText('test-action-3')).toBeInTheDocument(); + }); +}); + +const hoverElement = async (element: Element, waitForChange: () => Promise) => { + await act(async () => { + fireEvent.mouseEnter(element); + await waitForChange(); + }); +}; diff --git a/packages/kbn-cell-actions/src/components/hover_actions_popover.tsx b/packages/kbn-cell-actions/src/components/hover_actions_popover.tsx new file mode 100644 index 0000000000000..a6201159d0a0e --- /dev/null +++ b/packages/kbn-cell-actions/src/components/hover_actions_popover.tsx @@ -0,0 +1,168 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { EuiPopover, EuiScreenReaderOnly } from '@elastic/eui'; + +import React, { useCallback, useEffect, useMemo, useRef, useState } from 'react'; +import { euiThemeVars } from '@kbn/ui-theme'; +import { css } from '@emotion/react'; +import { debounce } from 'lodash'; +import { ActionItem } from './cell_action_item'; +import { ExtraActionsButton } from './extra_actions_button'; +import { ACTIONS_AREA_LABEL, YOU_ARE_IN_A_DIALOG_CONTAINING_OPTIONS } from './translations'; +import { partitionActions } from '../hooks/actions'; +import { ExtraActionsPopOverWithAnchor } from './extra_actions_popover'; +import { CellActionExecutionContext } from '../types'; +import { useLoadActionsFn } from '../hooks/use_load_actions'; + +/** This class is added to the document body while dragging */ +export const IS_DRAGGING_CLASS_NAME = 'is-dragging'; + +// Overwrite Popover default minWidth to avoid displaying empty space +const PANEL_STYLE = { minWidth: `24px` }; + +const hoverContentWrapperCSS = css` + padding: 0 ${euiThemeVars.euiSizeS}; +`; + +/** + * To avoid expensive changes to the DOM, delay showing the popover menu + */ +const HOVER_INTENT_DELAY = 100; // ms + +interface Props { + children: React.ReactNode; + visibleCellActions: number; + actionContext: CellActionExecutionContext; + showActionTooltips: boolean; +} + +export const HoverActionsPopover = React.memo( + ({ children, visibleCellActions, actionContext, showActionTooltips }) => { + const contentRef = useRef(null); + const [isExtraActionsPopoverOpen, setIsExtraActionsPopoverOpen] = useState(false); + const [showHoverContent, setShowHoverContent] = useState(false); + const popoverRef = useRef(null); + + const [{ value: actions }, loadActions] = useLoadActionsFn(); + + const { visibleActions, extraActions } = useMemo( + () => partitionActions(actions ?? [], visibleCellActions), + [actions, visibleCellActions] + ); + + const closePopover = useCallback(() => { + setShowHoverContent(false); + }, []); + + const closeExtraActions = useCallback( + () => setIsExtraActionsPopoverOpen(false), + [setIsExtraActionsPopoverOpen] + ); + + const onShowExtraActionsClick = useCallback(() => { + setIsExtraActionsPopoverOpen(true); + closePopover(); + }, [closePopover, setIsExtraActionsPopoverOpen]); + + const openPopOverDebounced = useMemo( + () => + debounce(() => { + if (!document.body.classList.contains(IS_DRAGGING_CLASS_NAME)) { + setShowHoverContent(true); + } + }, HOVER_INTENT_DELAY), + [] + ); + + // prevent setState on an unMounted component + useEffect(() => { + return () => { + openPopOverDebounced.cancel(); + }; + }, [openPopOverDebounced]); + + const onMouseEnter = useCallback(async () => { + // Do not open actions with extra action popover is open + if (isExtraActionsPopoverOpen) return; + + // memoize actions after the first call + if (actions === undefined) { + loadActions(actionContext); + } + + openPopOverDebounced(); + }, [isExtraActionsPopoverOpen, actions, openPopOverDebounced, loadActions, actionContext]); + + const onMouseLeave = useCallback(() => { + closePopover(); + }, [closePopover]); + + const content = useMemo(() => { + return ( + // Hack - Forces extra actions popover to close when hover content is clicked. + // This hack is required because we anchor the popover to the hover content instead + // of anchoring it to the button that triggers the popover. + // eslint-disable-next-line jsx-a11y/click-events-have-key-events +
    + {children} +
    + ); + }, [onMouseEnter, closeExtraActions, children]); + + return ( + <> +
    + + {showHoverContent ? ( +
    + +

    {YOU_ARE_IN_A_DIALOG_CONTAINING_OPTIONS(actionContext.field.name)}

    +
    + {visibleActions.map((action) => ( + + ))} + {extraActions.length > 0 ? ( + + ) : null} +
    + ) : null} +
    +
    + + + ); + } +); diff --git a/packages/kbn-cell-actions/src/components/index.tsx b/packages/kbn-cell-actions/src/components/index.tsx new file mode 100644 index 0000000000000..2f7fd950a6f4c --- /dev/null +++ b/packages/kbn-cell-actions/src/components/index.tsx @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export { CellActions } from './cell_actions'; diff --git a/packages/kbn-cell-actions/src/components/inline_actions.test.tsx b/packages/kbn-cell-actions/src/components/inline_actions.test.tsx new file mode 100644 index 0000000000000..91733929e8b6a --- /dev/null +++ b/packages/kbn-cell-actions/src/components/inline_actions.test.tsx @@ -0,0 +1,63 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { act, render } from '@testing-library/react'; +import React from 'react'; +import { makeAction, makeActionContext } from '../mocks/helpers'; +import { InlineActions } from './inline_actions'; +import { CellActionsProvider } from '../context/cell_actions_context'; + +describe('InlineActions', () => { + const actionContext = makeActionContext(); + + it('renders', async () => { + const getActionsPromise = Promise.resolve([]); + const getActions = () => getActionsPromise; + const { queryByTestId } = render( + + + + ); + + await act(async () => { + await getActionsPromise; + }); + + expect(queryByTestId('inlineActions')).toBeInTheDocument(); + }); + + it('renders all actions', async () => { + const getActionsPromise = Promise.resolve([ + makeAction('action-1'), + makeAction('action-2'), + makeAction('action-3'), + makeAction('action-4'), + makeAction('action-5'), + ]); + const getActions = () => getActionsPromise; + const { queryAllByRole } = render( + + + + ); + + await act(async () => { + await getActionsPromise; + }); + + expect(queryAllByRole('button').length).toBe(5); + }); +}); diff --git a/packages/kbn-cell-actions/src/components/inline_actions.tsx b/packages/kbn-cell-actions/src/components/inline_actions.tsx new file mode 100644 index 0000000000000..bcf8222ce83ca --- /dev/null +++ b/packages/kbn-cell-actions/src/components/inline_actions.tsx @@ -0,0 +1,62 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { useCallback, useMemo, useState } from 'react'; +import { ActionItem } from './cell_action_item'; +import { usePartitionActions } from '../hooks/actions'; +import { ExtraActionsPopOver } from './extra_actions_popover'; +import { ExtraActionsButton } from './extra_actions_button'; +import type { CellActionExecutionContext } from '../types'; +import { useLoadActions } from '../hooks/use_load_actions'; + +interface InlineActionsProps { + actionContext: CellActionExecutionContext; + showActionTooltips: boolean; + visibleCellActions: number; +} + +export const InlineActions: React.FC = ({ + actionContext, + showActionTooltips, + visibleCellActions, +}) => { + const { value: allActions } = useLoadActions(actionContext); + const { extraActions, visibleActions } = usePartitionActions( + allActions ?? [], + visibleCellActions + ); + const [isPopoverOpen, setIsPopoverOpen] = useState(false); + const togglePopOver = useCallback(() => setIsPopoverOpen((isOpen) => !isOpen), []); + const closePopOver = useCallback(() => setIsPopoverOpen(false), []); + const button = useMemo( + () => , + [togglePopOver, showActionTooltips] + ); + + return ( + + {visibleActions.map((action, index) => ( + + ))} + {extraActions.length > 0 ? ( + + ) : null} + + ); +}; diff --git a/packages/kbn-cell-actions/src/components/translations.ts b/packages/kbn-cell-actions/src/components/translations.ts new file mode 100644 index 0000000000000..1209881f1732c --- /dev/null +++ b/packages/kbn-cell-actions/src/components/translations.ts @@ -0,0 +1,26 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ +import { i18n } from '@kbn/i18n'; + +export const YOU_ARE_IN_A_DIALOG_CONTAINING_OPTIONS = (fieldName: string) => + i18n.translate('cellActions.youAreInADialogContainingOptionsScreenReaderOnly', { + values: { fieldName }, + defaultMessage: `You are in a dialog, containing options for field {fieldName}. Press tab to navigate options. Press escape to exit.`, + }); + +export const EXTRA_ACTIONS_ARIA_LABEL = i18n.translate('cellActions.extraActionsAriaLabel', { + defaultMessage: 'Extra actions', +}); + +export const SHOW_MORE_ACTIONS = i18n.translate('cellActions.showMoreActionsLabel', { + defaultMessage: 'More actions', +}); + +export const ACTIONS_AREA_LABEL = i18n.translate('cellActions.actionsAriaLabel', { + defaultMessage: 'Actions', +}); diff --git a/packages/kbn-cell-actions/src/context/cell_actions_context.test.tsx b/packages/kbn-cell-actions/src/context/cell_actions_context.test.tsx new file mode 100644 index 0000000000000..5c9084d0e81dd --- /dev/null +++ b/packages/kbn-cell-actions/src/context/cell_actions_context.test.tsx @@ -0,0 +1,84 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { renderHook } from '@testing-library/react-hooks'; +import React from 'react'; +import { makeAction, makeActionContext } from '../mocks/helpers'; +import { CellActionsProvider, useCellActionsContext } from './cell_actions_context'; + +const action = makeAction('action-1', 'icon', 1); +const mockGetTriggerCompatibleActions = jest.fn(async () => [action]); +const ContextWrapper: React.FC = ({ children }) => ( + + {children} + +); + +describe('CellActionContext', () => { + const triggerId = 'triggerId'; + const actionContext = makeActionContext(); + + beforeEach(() => { + jest.clearAllMocks(); + }); + + it('should throw error when context not found', () => { + const { result } = renderHook(useCellActionsContext); + expect(result.error).toEqual( + new Error('No CellActionsContext found. Please wrap the application with CellActionsProvider') + ); + }); + + it('should call getTriggerCompatibleActions and return actions', async () => { + const { result } = renderHook(useCellActionsContext, { wrapper: ContextWrapper }); + const actions = await result.current.getActions(actionContext); + + expect(mockGetTriggerCompatibleActions).toHaveBeenCalledWith(triggerId, actionContext); + expect(actions).toEqual([action]); + }); + + it('should sort actions by order', async () => { + const firstAction = makeAction('action-1', 'icon', 1); + const secondAction = makeAction('action-2', 'icon', 2); + mockGetTriggerCompatibleActions.mockResolvedValueOnce([secondAction, firstAction]); + + const { result } = renderHook(useCellActionsContext, { wrapper: ContextWrapper }); + const actions = await result.current.getActions(actionContext); + + expect(actions).toEqual([firstAction, secondAction]); + }); + + it('should sort actions by id when order is undefined', async () => { + const firstAction = makeAction('action-1'); + const secondAction = makeAction('action-2'); + + mockGetTriggerCompatibleActions.mockResolvedValueOnce([secondAction, firstAction]); + + const { result } = renderHook(useCellActionsContext, { wrapper: ContextWrapper }); + const actions = await result.current.getActions(actionContext); + + expect(actions).toEqual([firstAction, secondAction]); + }); + + it('should sort actions by id and order', async () => { + const actionWithoutOrder = makeAction('action-1-no-order'); + const secondAction = makeAction('action-2', 'icon', 2); + const thirdAction = makeAction('action-3', 'icon', 3); + + mockGetTriggerCompatibleActions.mockResolvedValueOnce([ + thirdAction, + secondAction, + actionWithoutOrder, + ]); + + const { result } = renderHook(useCellActionsContext, { wrapper: ContextWrapper }); + const actions = await result.current.getActions(actionContext); + + expect(actions).toEqual([secondAction, thirdAction, actionWithoutOrder]); + }); +}); diff --git a/packages/kbn-cell-actions/src/context/cell_actions_context.tsx b/packages/kbn-cell-actions/src/context/cell_actions_context.tsx new file mode 100644 index 0000000000000..af47a2fbe0ff7 --- /dev/null +++ b/packages/kbn-cell-actions/src/context/cell_actions_context.tsx @@ -0,0 +1,40 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { orderBy } from 'lodash/fp'; +import React, { createContext, FC, useCallback, useContext } from 'react'; +import type { CellAction, CellActionsProviderProps, GetActions } from '../types'; + +const CellActionsContext = createContext<{ getActions: GetActions } | null>(null); + +export const CellActionsProvider: FC = ({ + children, + getTriggerCompatibleActions, +}) => { + const getActions = useCallback( + (context) => + getTriggerCompatibleActions(context.trigger.id, context).then((actions) => + orderBy(['order', 'id'], ['asc', 'asc'], actions) + ) as Promise, + [getTriggerCompatibleActions] + ); + + return ( + {children} + ); +}; + +export const useCellActionsContext = () => { + const context = useContext(CellActionsContext); + if (!context) { + throw new Error( + 'No CellActionsContext found. Please wrap the application with CellActionsProvider' + ); + } + return context; +}; diff --git a/packages/kbn-cell-actions/src/context/index.ts b/packages/kbn-cell-actions/src/context/index.ts new file mode 100644 index 0000000000000..e5fff63ef7659 --- /dev/null +++ b/packages/kbn-cell-actions/src/context/index.ts @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export { CellActionsProvider } from './cell_actions_context'; diff --git a/packages/kbn-cell-actions/src/hooks/actions.test.ts b/packages/kbn-cell-actions/src/hooks/actions.test.ts new file mode 100644 index 0000000000000..a7ca564570e2c --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/actions.test.ts @@ -0,0 +1,85 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { makeAction } from '../mocks/helpers'; +import { partitionActions } from './actions'; + +describe('InlineActions', () => { + it('returns an empty array when actions is an empty array', async () => { + const { extraActions, visibleActions } = partitionActions([], 5); + + expect(visibleActions).toEqual([]); + expect(extraActions).toEqual([]); + }); + + it('returns only visible actions when visibleCellActions > actions.length', async () => { + const actions = [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')]; + const { extraActions, visibleActions } = partitionActions(actions, 4); + + expect(visibleActions.length).toEqual(actions.length); + expect(extraActions).toEqual([]); + }); + + it('returns only extra actions when visibleCellActions is 1', async () => { + const actions = [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')]; + const { extraActions, visibleActions } = partitionActions(actions, 1); + + expect(visibleActions).toEqual([]); + expect(extraActions.length).toEqual(actions.length); + }); + + it('returns only extra actions when visibleCellActions is 0', async () => { + const actions = [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')]; + const { extraActions, visibleActions } = partitionActions(actions, 0); + + expect(visibleActions).toEqual([]); + expect(extraActions.length).toEqual(actions.length); + }); + + it('returns only extra actions when visibleCellActions is negative', async () => { + const actions = [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')]; + const { extraActions, visibleActions } = partitionActions(actions, -6); + + expect(visibleActions).toEqual([]); + expect(extraActions.length).toEqual(actions.length); + }); + + it('returns only one visible action when visibleCellActionss 2 and action.length is 3', async () => { + const { extraActions, visibleActions } = partitionActions( + [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')], + 2 + ); + + expect(visibleActions.length).toEqual(1); + expect(extraActions.length).toEqual(2); + }); + + it('returns two visible actions when visibleCellActions is 3 and action.length is 5', async () => { + const { extraActions, visibleActions } = partitionActions( + [ + makeAction('action-1'), + makeAction('action-2'), + makeAction('action-3'), + makeAction('action-4'), + makeAction('action-5'), + ], + 3 + ); + expect(visibleActions.length).toEqual(2); + expect(extraActions.length).toEqual(3); + }); + + it('returns three visible actions when visibleCellActions is 3 and action.length is 3', async () => { + const { extraActions, visibleActions } = partitionActions( + [makeAction('action-1'), makeAction('action-2'), makeAction('action-3')], + 3 + ); + expect(visibleActions.length).toEqual(3); + expect(extraActions.length).toEqual(0); + }); +}); diff --git a/packages/kbn-cell-actions/src/hooks/actions.ts b/packages/kbn-cell-actions/src/hooks/actions.ts new file mode 100644 index 0000000000000..1eccdb737e483 --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/actions.ts @@ -0,0 +1,29 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { useMemo } from 'react'; +import type { PartitionedActions, CellAction } from '../types'; + +export const partitionActions = (actions: CellAction[], visibleCellActions: number) => { + if (visibleCellActions <= 1) return { extraActions: actions, visibleActions: [] }; + if (actions.length <= visibleCellActions) return { extraActions: [], visibleActions: actions }; + + return { + visibleActions: actions.slice(0, visibleCellActions - 1), + extraActions: actions.slice(visibleCellActions - 1, actions.length), + }; +}; + +export const usePartitionActions = ( + allActions: CellAction[], + visibleCellActions: number +): PartitionedActions => { + return useMemo(() => { + return partitionActions(allActions ?? [], visibleCellActions); + }, [allActions, visibleCellActions]); +}; diff --git a/packages/kbn-cell-actions/src/hooks/index.ts b/packages/kbn-cell-actions/src/hooks/index.ts new file mode 100644 index 0000000000000..94086c432065e --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/index.ts @@ -0,0 +1,12 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export { + useDataGridColumnsCellActions, + type UseDataGridColumnsCellActionsProps, +} from './use_data_grid_column_cell_actions'; diff --git a/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx new file mode 100644 index 0000000000000..db6a02b918ca1 --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx @@ -0,0 +1,166 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { JSXElementConstructor } from 'react'; +import { + EuiButtonEmpty, + EuiDataGridColumnCellActionProps, + type EuiDataGridColumnCellAction, +} from '@elastic/eui'; +import { render } from '@testing-library/react'; +import { act, renderHook } from '@testing-library/react-hooks'; +import { makeAction } from '../mocks/helpers'; +import { + useDataGridColumnsCellActions, + UseDataGridColumnsCellActionsProps, +} from './use_data_grid_column_cell_actions'; + +const action1 = makeAction('action-1', 'icon1', 1); +action1.execute = jest.fn(); +const action2 = makeAction('action-2', 'icon2', 2); +action2.execute = jest.fn(); +const actions = [action1, action2]; +const mockGetActions = jest.fn(async () => actions); + +jest.mock('../context/cell_actions_context', () => ({ + useCellActionsContext: () => ({ getActions: mockGetActions }), +})); + +const field1 = { name: 'column1', values: ['0.0', '0.1', '0.2', '0.3'], type: 'text' }; +const field2 = { name: 'column2', values: ['1.0', '1.1', '1.2', '1.3'], type: 'keyword' }; +const columns = [{ id: field1.name }, { id: field2.name }]; + +const useDataGridColumnsCellActionsProps: UseDataGridColumnsCellActionsProps = { + fields: [field1, field2], + triggerId: 'testTriggerId', + metadata: { some: 'value' }, +}; + +const renderCellAction = ( + columnCellAction: EuiDataGridColumnCellAction, + props: Partial = {} +) => { + const CellAction = columnCellAction as JSXElementConstructor; + return render( + + ); +}; + +describe('useDataGridColumnsCellActions', () => { + beforeEach(() => { + jest.clearAllMocks(); + }); + + it('should return array with actions for each columns', async () => { + const { result, waitForNextUpdate } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + expect(result.current).toHaveLength(columns.length); + expect(result.current[0]).toHaveLength(1); // loader + + await waitForNextUpdate(); + + expect(result.current).toHaveLength(columns.length); + expect(result.current[0]).toHaveLength(actions.length); + }); + + it('should render cell actions loading state', async () => { + const { result } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + + await act(async () => { + const cellAction = renderCellAction(result.current[0][0]); + expect(cellAction.getByTestId('dataGridColumnCellAction-loading')).toBeInTheDocument(); + }); + }); + + it('should render the cell actions', async () => { + const { result, waitForNextUpdate } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + + await waitForNextUpdate(); + + const cellAction1 = renderCellAction(result.current[0][0]); + + expect(cellAction1.getByTestId(`dataGridColumnCellAction-${action1.id}`)).toBeInTheDocument(); + expect(cellAction1.getByText(action1.getDisplayName())).toBeInTheDocument(); + + const cellAction2 = renderCellAction(result.current[0][1]); + + expect(cellAction2.getByTestId(`dataGridColumnCellAction-${action2.id}`)).toBeInTheDocument(); + expect(cellAction2.getByText(action2.getDisplayName())).toBeInTheDocument(); + }); + + it('should execute the action on click', async () => { + const { result, waitForNextUpdate } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + await waitForNextUpdate(); + + const cellAction = renderCellAction(result.current[0][0]); + + cellAction.getByTestId(`dataGridColumnCellAction-${action1.id}`).click(); + + expect(action1.execute).toHaveBeenCalled(); + }); + + it('should execute the action with correct context', async () => { + const { result, waitForNextUpdate } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + await waitForNextUpdate(); + + const cellAction1 = renderCellAction(result.current[0][0], { rowIndex: 1 }); + + cellAction1.getByTestId(`dataGridColumnCellAction-${action1.id}`).click(); + + expect(action1.execute).toHaveBeenCalledWith( + expect.objectContaining({ + field: { name: field1.name, type: field1.type, value: field1.values[1] }, + trigger: { id: useDataGridColumnsCellActionsProps.triggerId }, + }) + ); + + const cellAction2 = renderCellAction(result.current[1][1], { rowIndex: 2 }); + + cellAction2.getByTestId(`dataGridColumnCellAction-${action2.id}`).click(); + + expect(action2.execute).toHaveBeenCalledWith( + expect.objectContaining({ + field: { name: field2.name, type: field2.type, value: field2.values[2] }, + trigger: { id: useDataGridColumnsCellActionsProps.triggerId }, + }) + ); + }); + + it('should execute the action with correct page value', async () => { + const { result, waitForNextUpdate } = renderHook(useDataGridColumnsCellActions, { + initialProps: useDataGridColumnsCellActionsProps, + }); + await waitForNextUpdate(); + + const cellAction = renderCellAction(result.current[0][0], { rowIndex: 25 }); + + cellAction.getByTestId(`dataGridColumnCellAction-${action1.id}`).click(); + + expect(action1.execute).toHaveBeenCalledWith( + expect.objectContaining({ + field: { name: field1.name, type: field1.type, value: field1.values[1] }, + }) + ); + }); +}); diff --git a/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx new file mode 100644 index 0000000000000..6212ad2c30776 --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.tsx @@ -0,0 +1,107 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { useMemo, useRef } from 'react'; +import { EuiLoadingSpinner, type EuiDataGridColumnCellAction } from '@elastic/eui'; +import type { + CellAction, + CellActionExecutionContext, + CellActionField, + CellActionsProps, +} from '../types'; +import { useBulkLoadActions } from './use_load_actions'; + +interface BulkField extends Pick { + /** + * Array containing all the values of the field in the visible page, indexed by rowIndex + */ + values: Array; +} + +export interface UseDataGridColumnsCellActionsProps + extends Pick { + fields: BulkField[]; +} +export const useDataGridColumnsCellActions = ({ + fields, + triggerId, + metadata, +}: UseDataGridColumnsCellActionsProps): EuiDataGridColumnCellAction[][] => { + const bulkContexts: CellActionExecutionContext[] = useMemo( + () => + fields.map(({ values, ...field }) => ({ + field, // we are getting the actions for the whole column field, so the compatibility check will be done without the value + trigger: { id: triggerId }, + metadata, + })), + [fields, triggerId, metadata] + ); + + const { loading, value: columnsActions } = useBulkLoadActions(bulkContexts); + + const columnsCellActions = useMemo(() => { + if (loading) { + return fields.map(() => [ + () => , + ]); + } + if (!columnsActions) { + return []; + } + return columnsActions.map((actions, columnIndex) => + actions.map((action) => + createColumnCellAction({ action, metadata, triggerId, field: fields[columnIndex] }) + ) + ); + }, [columnsActions, fields, loading, metadata, triggerId]); + + return columnsCellActions; +}; + +interface CreateColumnCellActionParams extends Pick { + field: BulkField; + action: CellAction; +} +const createColumnCellAction = ({ + field, + action, + metadata, + triggerId, +}: CreateColumnCellActionParams): EuiDataGridColumnCellAction => + function ColumnCellAction({ Component, rowIndex }) { + const nodeRef = useRef(null); + const extraContentNodeRef = useRef(null); + + const { name, type, values } = field; + // rowIndex refers to all pages, we need to use the row index relative to the page to get the value + const value = values[rowIndex % values.length]; + + const actionContext: CellActionExecutionContext = { + field: { name, type, value }, + trigger: { id: triggerId }, + extraContentNodeRef, + nodeRef, + metadata, + }; + + return ( + nodeRef} + aria-label={action.getDisplayName(actionContext)} + title={action.getDisplayName(actionContext)} + data-test-subj={`dataGridColumnCellAction-${action.id}`} + iconType={action.getIconType(actionContext)!} + onClick={() => { + action.execute(actionContext); + }} + > + {action.getDisplayName(actionContext)} +
    extraContentNodeRef} /> + + ); + }; diff --git a/packages/kbn-cell-actions/src/hooks/use_load_actions.test.ts b/packages/kbn-cell-actions/src/hooks/use_load_actions.test.ts new file mode 100644 index 0000000000000..74cb5091a5efb --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/use_load_actions.test.ts @@ -0,0 +1,85 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { act, renderHook } from '@testing-library/react-hooks'; +import { makeAction, makeActionContext } from '../mocks/helpers'; +import { useBulkLoadActions, useLoadActions, useLoadActionsFn } from './use_load_actions'; + +const action = makeAction('action-1', 'icon', 1); +const mockGetActions = jest.fn(async () => [action]); +jest.mock('../context/cell_actions_context', () => ({ + useCellActionsContext: () => ({ getActions: mockGetActions }), +})); + +describe('useLoadActions', () => { + const actionContext = makeActionContext(); + + beforeEach(() => { + jest.clearAllMocks(); + }); + + it('loads actions when useLoadActions called', async () => { + const { result, waitForNextUpdate } = renderHook(useLoadActions, { + initialProps: actionContext, + }); + + expect(result.current.value).toBeUndefined(); + expect(result.current.loading).toEqual(true); + expect(mockGetActions).toHaveBeenCalledTimes(1); + expect(mockGetActions).toHaveBeenCalledWith(actionContext); + + await waitForNextUpdate(); + + expect(result.current.value).toEqual([action]); + expect(result.current.loading).toEqual(false); + }); + + it('loads actions when useLoadActionsFn function is called', async () => { + const { result, waitForNextUpdate } = renderHook(useLoadActionsFn); + const [{ value: valueBeforeCall, loading: loadingBeforeCall }, loadActions] = result.current; + + expect(valueBeforeCall).toBeUndefined(); + expect(loadingBeforeCall).toEqual(false); + expect(mockGetActions).not.toHaveBeenCalled(); + + act(() => { + loadActions(actionContext); + }); + + const [{ value: valueAfterCall, loading: loadingAfterCall }] = result.current; + expect(valueAfterCall).toBeUndefined(); + expect(loadingAfterCall).toEqual(true); + expect(mockGetActions).toHaveBeenCalledTimes(1); + expect(mockGetActions).toHaveBeenCalledWith(actionContext); + + await waitForNextUpdate(); + + const [{ value: valueAfterUpdate, loading: loadingAfterUpdate }] = result.current; + expect(valueAfterUpdate).toEqual([action]); + expect(loadingAfterUpdate).toEqual(false); + }); + + it('loads bulk actions array when useBulkLoadActions is called', async () => { + const actionContext2 = makeActionContext({ trigger: { id: 'triggerId2' } }); + const actionContexts = [actionContext, actionContext2]; + const { result, waitForNextUpdate } = renderHook(useBulkLoadActions, { + initialProps: actionContexts, + }); + + expect(result.current.value).toBeUndefined(); + expect(result.current.loading).toEqual(true); + expect(mockGetActions).toHaveBeenCalledTimes(2); + expect(mockGetActions).toHaveBeenCalledWith(actionContext); + expect(mockGetActions).toHaveBeenCalledWith(actionContext2); + + await waitForNextUpdate(); + + expect(result.current.value).toEqual([[action], [action]]); + expect(result.current.loading).toEqual(false); + }); +}); diff --git a/packages/kbn-cell-actions/src/hooks/use_load_actions.ts b/packages/kbn-cell-actions/src/hooks/use_load_actions.ts new file mode 100644 index 0000000000000..85d8f64042f93 --- /dev/null +++ b/packages/kbn-cell-actions/src/hooks/use_load_actions.ts @@ -0,0 +1,36 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import useAsync from 'react-use/lib/useAsync'; +import useAsyncFn from 'react-use/lib/useAsyncFn'; +import { useCellActionsContext } from '../context/cell_actions_context'; +import { CellActionExecutionContext } from '../types'; + +/** + * Performs the getActions async call and returns its value + */ +export const useLoadActions = (context: CellActionExecutionContext) => { + const { getActions } = useCellActionsContext(); + return useAsync(() => getActions(context), []); +}; + +/** + * Returns a function to perform the getActions async call + */ +export const useLoadActionsFn = () => { + const { getActions } = useCellActionsContext(); + return useAsyncFn(getActions, []); +}; + +/** + * Groups getActions calls for an array of contexts in one async bulk operation + */ +export const useBulkLoadActions = (contexts: CellActionExecutionContext[]) => { + const { getActions } = useCellActionsContext(); + return useAsync(() => Promise.all(contexts.map((context) => getActions(context))), []); +}; diff --git a/packages/kbn-cell-actions/src/index.ts b/packages/kbn-cell-actions/src/index.ts new file mode 100644 index 0000000000000..69c4b0fbc6e13 --- /dev/null +++ b/packages/kbn-cell-actions/src/index.ts @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export { CellActions } from './components'; +export { CellActionsProvider } from './context'; +export { useDataGridColumnsCellActions, type UseDataGridColumnsCellActionsProps } from './hooks'; +export { CellActionsMode } from './types'; +export type { CellAction, CellActionExecutionContext } from './types'; diff --git a/packages/kbn-cell-actions/src/mocks/helpers.ts b/packages/kbn-cell-actions/src/mocks/helpers.ts new file mode 100644 index 0000000000000..21f1047f384ad --- /dev/null +++ b/packages/kbn-cell-actions/src/mocks/helpers.ts @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { CellActionExecutionContext } from '../types'; + +export const makeAction = (actionsName: string, icon: string = 'icon', order?: number) => ({ + id: actionsName, + type: actionsName, + order, + getIconType: () => icon, + getDisplayName: () => actionsName, + getDisplayNameTooltip: () => actionsName, + isCompatible: () => Promise.resolve(true), + execute: () => { + alert(actionsName); + return Promise.resolve(); + }, +}); + +export const makeActionContext = ( + override: Partial = {} +): CellActionExecutionContext => ({ + trigger: { id: 'triggerId' }, + field: { + name: 'fieldName', + type: 'keyword', + }, + ...override, +}); diff --git a/packages/kbn-cell-actions/src/types.ts b/packages/kbn-cell-actions/src/types.ts new file mode 100644 index 0000000000000..592a412e7fb68 --- /dev/null +++ b/packages/kbn-cell-actions/src/types.ts @@ -0,0 +1,105 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import type { + Action, + ActionExecutionContext, + UiActionsService, +} from '@kbn/ui-actions-plugin/public'; + +export type CellAction = Action; + +export interface CellActionsProviderProps { + /** + * Please assign `uiActions.getTriggerCompatibleActions` function. + * This function should return a list of actions for a triggerId that are compatible with the provided context. + */ + getTriggerCompatibleActions: UiActionsService['getTriggerCompatibleActions']; +} + +export type GetActions = (context: CellActionExecutionContext) => Promise; + +export interface CellActionField { + /** + * Field name. + * Example: 'host.name' + */ + name: string; + /** + * Field type. + * Example: 'keyword' + */ + type: string; + /** + * Field value. + * Example: 'My-Laptop' + */ + value?: string | string[] | null; +} + +export interface PartitionedActions { + extraActions: CellAction[]; + visibleActions: CellAction[]; +} + +export interface CellActionExecutionContext extends ActionExecutionContext { + field: CellActionField; + /** + * Ref to a DOM node where the action can add custom HTML. + */ + extraContentNodeRef?: React.MutableRefObject; + + /** + * Ref to the node where the cell action are rendered. + */ + nodeRef?: React.MutableRefObject; + + /** + * Extra configurations for actions. + */ + metadata?: Record; +} + +export enum CellActionsMode { + HOVER = 'hover', + INLINE = 'inline', +} + +export interface CellActionsProps { + /** + * Common set of properties used by most actions. + */ + field: CellActionField; + /** + * The trigger in which the actions are registered. + */ + triggerId: string; + /** + * UI configuration. Possible options are `HOVER` and `INLINE`. + * + * `HOVER` shows the actions when the children component is hovered. + * + * `INLINE` always shows the actions. + */ + mode: CellActionsMode; + + /** + * It displays a tooltip for every action button when `true`. + */ + showActionTooltips?: boolean; + /** + * It shows 'more actions' button when the number of actions is bigger than this parameter. + */ + visibleCellActions?: number; + /** + * Custom set of properties used by some actions. + * An action might require a specific set of metadata properties to render. + * This data is sent directly to actions. + */ + metadata?: Record; +} diff --git a/packages/kbn-cell-actions/tsconfig.json b/packages/kbn-cell-actions/tsconfig.json new file mode 100644 index 0000000000000..63c76dfbfaa45 --- /dev/null +++ b/packages/kbn-cell-actions/tsconfig.json @@ -0,0 +1,21 @@ +{ + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "outDir": "target/types", + "types": [ + "jest", + "node", + "react", + "@emotion/react/types/css-prop", + "@testing-library/jest-dom", + "@testing-library/react" + ] + }, + "include": ["**/*.ts", "**/*.tsx"], + "kbn_references": [ + "@kbn/ui-theme", + "@kbn/i18n", + "@kbn/ui-actions-plugin", + ], + "exclude": ["target/**/*"] +} diff --git a/packages/kbn-cli-dev-mode/src/watcher.ts b/packages/kbn-cli-dev-mode/src/watcher.ts index 17ab0af5a7db1..bf5063ac364a4 100644 --- a/packages/kbn-cli-dev-mode/src/watcher.ts +++ b/packages/kbn-cli-dev-mode/src/watcher.ts @@ -24,8 +24,8 @@ const nonPackageMatcher = makeMatcher([ 'src/**', '!src/{dev,fixtures}/**', 'x-pack/plugins/**', - '!x-pack/plugins/screenshotting/chromium', - '!x-pack/plugins/canvas/canvas_plugin_src', + '!x-pack/plugins/screenshotting/chromium/**', + '!x-pack/plugins/canvas/shareable_runtime/**', ]); export interface Options { diff --git a/packages/kbn-datemath/kibana.jsonc b/packages/kbn-datemath/kibana.jsonc index ab8ac6257044c..43bbf53a816e3 100644 --- a/packages/kbn-datemath/kibana.jsonc +++ b/packages/kbn-datemath/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/datemath", - "owner": "@elastic/kibana-app-services" + "owner": "@elastic/kibana-data-discovery" } diff --git a/packages/kbn-doc-links/src/get_doc_links.ts b/packages/kbn-doc-links/src/get_doc_links.ts index 24462ed7274e4..6406e0c635a28 100644 --- a/packages/kbn-doc-links/src/get_doc_links.ts +++ b/packages/kbn-doc-links/src/get_doc_links.ts @@ -124,6 +124,7 @@ export const getDocLinks = ({ kibanaBranch }: GetDocLinkOptions): DocLinks => { }, enterpriseSearch: { apiKeys: `${KIBANA_DOCS}api-keys.html`, + behavioralAnalyticsEvents: `${ENTERPRISE_SEARCH_DOCS}analytics-events.html`, bulkApi: `${ELASTICSEARCH_DOCS}docs-bulk.html`, configuration: `${ENTERPRISE_SEARCH_DOCS}configuration.html`, connectors: `${ENTERPRISE_SEARCH_DOCS}connectors.html`, diff --git a/packages/kbn-doc-links/src/types.ts b/packages/kbn-doc-links/src/types.ts index beebf4739028f..1d771c8c89647 100644 --- a/packages/kbn-doc-links/src/types.ts +++ b/packages/kbn-doc-links/src/types.ts @@ -109,6 +109,7 @@ export interface DocLinks { }; readonly enterpriseSearch: { readonly apiKeys: string; + readonly behavioralAnalyticsEvents: string; readonly bulkApi: string; readonly configuration: string; readonly connectors: string; diff --git a/packages/kbn-es-query/kibana.jsonc b/packages/kbn-es-query/kibana.jsonc index 727aad02554f6..896ea93fe1f65 100644 --- a/packages/kbn-es-query/kibana.jsonc +++ b/packages/kbn-es-query/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/es-query", - "owner": "@elastic/kibana-app-services" + "owner": "@elastic/kibana-data-discovery" } diff --git a/packages/kbn-es-query/src/es_query/build_es_query.ts b/packages/kbn-es-query/src/es_query/build_es_query.ts index 497d38a0530cf..9d1b0b1c6b139 100644 --- a/packages/kbn-es-query/src/es_query/build_es_query.ts +++ b/packages/kbn-es-query/src/es_query/build_es_query.ts @@ -67,6 +67,7 @@ export function buildEsQuery( dateFormatTZ: config.dateFormatTZ, filtersInMustClause: config.filtersInMustClause, nestedIgnoreUnmapped: config.nestedIgnoreUnmapped, + caseInsensitive: config.caseInsensitive, } ); const luceneQuery = buildQueryFromLucene( diff --git a/packages/kbn-es-query/src/es_query/from_kuery.ts b/packages/kbn-es-query/src/es_query/from_kuery.ts index 6a1254a6e5037..be29e2952241a 100644 --- a/packages/kbn-es-query/src/es_query/from_kuery.ts +++ b/packages/kbn-es-query/src/es_query/from_kuery.ts @@ -23,7 +23,12 @@ export function buildQueryFromKuery( { allowLeadingWildcards = false }: { allowLeadingWildcards?: boolean } = { allowLeadingWildcards: false, }, - { filtersInMustClause = false, dateFormatTZ, nestedIgnoreUnmapped }: KueryQueryOptions = { + { + filtersInMustClause = false, + dateFormatTZ, + nestedIgnoreUnmapped, + caseInsensitive, + }: KueryQueryOptions = { filtersInMustClause: false, } ): BoolQuery { @@ -35,6 +40,7 @@ export function buildQueryFromKuery( filtersInMustClause, dateFormatTZ, nestedIgnoreUnmapped, + caseInsensitive, }); } diff --git a/packages/kbn-es-query/src/filters/helpers/update_filter.test.ts b/packages/kbn-es-query/src/filters/helpers/update_filter.test.ts index b57855bf472e8..7c33cf36e07c0 100644 --- a/packages/kbn-es-query/src/filters/helpers/update_filter.test.ts +++ b/packages/kbn-es-query/src/filters/helpers/update_filter.test.ts @@ -127,7 +127,7 @@ describe('updateFilter', () => { meta: { alias: '', index: 'index1', - params: { query: 0 }, + params: { query: undefined }, key: 'test-field', negate: true, type: 'phrase', diff --git a/packages/kbn-es-query/src/filters/helpers/update_filter.ts b/packages/kbn-es-query/src/filters/helpers/update_filter.ts index 1ebe43cbdbfd0..ea61545d557be 100644 --- a/packages/kbn-es-query/src/filters/helpers/update_filter.ts +++ b/packages/kbn-es-query/src/filters/helpers/update_filter.ts @@ -79,7 +79,7 @@ function updateWithIsOperator( ...filter.meta, negate: operator?.negate, type: operator?.type, - params: { ...filter.meta.params, query: safeParams }, + params: { ...filter.meta.params, query: params }, value: undefined, }, query: { match_phrase: { [filter.meta.key!]: safeParams ?? '' } }, diff --git a/packages/kbn-es-query/src/kuery/functions/is.test.ts b/packages/kbn-es-query/src/kuery/functions/is.test.ts index bde7e956f0c43..75974e019efd0 100644 --- a/packages/kbn-es-query/src/kuery/functions/is.test.ts +++ b/packages/kbn-es-query/src/kuery/functions/is.test.ts @@ -212,7 +212,7 @@ describe('kuery functions', () => { should: [ { wildcard: { - 'machine.os.keyword': 'win*', + 'machine.os.keyword': { value: 'win*' }, }, }, ], @@ -225,6 +225,25 @@ describe('kuery functions', () => { expect(result).toEqual(expected); }); + test('should create a case-insensitive wildcard query for keyword fields', () => { + const expected = { + bool: { + should: [ + { + wildcard: { + 'machine.os.keyword': { value: 'win*', case_insensitive: true }, + }, + }, + ], + minimum_should_match: 1, + }, + }; + const node = nodeTypes.function.buildNode('is', 'machine.os.keyword', 'win*'); + const result = is.toElasticsearchQuery(node, indexPattern, { caseInsensitive: true }); + + expect(result).toEqual(expected); + }); + test('should support scripted fields', () => { const node = nodeTypes.function.buildNode('is', 'script string', 'foo'); const result = is.toElasticsearchQuery(node, indexPattern); @@ -370,7 +389,24 @@ describe('kuery functions', () => { should: [ { term: { - 'machine.os.keyword': 'Win 7', + 'machine.os.keyword': { value: 'Win 7' }, + }, + }, + ], + minimum_should_match: 1, + }, + }); + }); + + test('should use a case-insensitive term query for keyword fields', () => { + const node = nodeTypes.function.buildNode('is', 'machine.os.keyword', 'Win 7'); + const result = is.toElasticsearchQuery(node, indexPattern, { caseInsensitive: true }); + expect(result).toEqual({ + bool: { + should: [ + { + term: { + 'machine.os.keyword': { value: 'Win 7', case_insensitive: true }, }, }, ], diff --git a/packages/kbn-es-query/src/kuery/functions/is.ts b/packages/kbn-es-query/src/kuery/functions/is.ts index 5493a3a6072e6..95563e6c429f6 100644 --- a/packages/kbn-es-query/src/kuery/functions/is.ts +++ b/packages/kbn-es-query/src/kuery/functions/is.ts @@ -146,7 +146,12 @@ export function toElasticsearchQuery( const query = isKeywordField ? { wildcard: { - [field.name]: value, + [field.name]: { + value, + ...(typeof config.caseInsensitive === 'boolean' && { + case_insensitive: config.caseInsensitive, + }), + }, }, } : { @@ -177,8 +182,22 @@ export function toElasticsearchQuery( }, }), ]; + } else if (isKeywordField) { + return [ + ...accumulator, + wrapWithNestedQuery({ + term: { + [field.name]: { + value, + ...(typeof config.caseInsensitive === 'boolean' && { + case_insensitive: config.caseInsensitive, + }), + }, + }, + }), + ]; } else { - const queryType = isKeywordField ? 'term' : type === 'phrase' ? 'match_phrase' : 'match'; + const queryType = type === 'phrase' ? 'match_phrase' : 'match'; return [ ...accumulator, wrapWithNestedQuery({ diff --git a/packages/kbn-es-query/src/kuery/types.ts b/packages/kbn-es-query/src/kuery/types.ts index f6175e41832d8..57cc2a52beeee 100644 --- a/packages/kbn-es-query/src/kuery/types.ts +++ b/packages/kbn-es-query/src/kuery/types.ts @@ -47,6 +47,12 @@ export interface KueryQueryOptions { * The `nestedIgnoreUnmapped` param allows creating queries with "ignore_unmapped": true */ nestedIgnoreUnmapped?: boolean; + /** + * Whether term-level queries should be treated as case-insensitive or not. For example, `agent.keyword: foobar` won't + * match a value of "FooBar" unless this parameter is `true`. + * (See https://www.elastic.co/guide/en/elasticsearch/reference/8.6/query-dsl-term-query.html#term-field-params) + */ + caseInsensitive?: boolean; } /** @public */ diff --git a/packages/kbn-field-types/kibana.jsonc b/packages/kbn-field-types/kibana.jsonc index fadb82dabf4a4..e19eebb3a3a9f 100644 --- a/packages/kbn-field-types/kibana.jsonc +++ b/packages/kbn-field-types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/field-types", - "owner": "@elastic/kibana-app-services" + "owner": "@elastic/kibana-data-discovery" } diff --git a/packages/kbn-guided-onboarding/index.ts b/packages/kbn-guided-onboarding/index.ts index d6adc813ee629..00f2447a1f0ab 100644 --- a/packages/kbn-guided-onboarding/index.ts +++ b/packages/kbn-guided-onboarding/index.ts @@ -13,6 +13,10 @@ export type { StepStatus, GuideStep, GuideStatus, + GuideConfig, + StepConfig, + StepDescriptionWithLink, } from './src/types'; export { GuideCard, InfrastructureLinkCard } from './src/components/landing_page'; export type { GuideCardUseCase } from './src/components/landing_page'; +export { testGuideId, testGuideConfig } from './src/common/test_guide_config'; diff --git a/src/plugins/guided_onboarding/common/test_guide_config.ts b/packages/kbn-guided-onboarding/src/common/test_guide_config.ts similarity index 96% rename from src/plugins/guided_onboarding/common/test_guide_config.ts rename to packages/kbn-guided-onboarding/src/common/test_guide_config.ts index 7934e3474f97a..a7944ef1d8bb8 100644 --- a/src/plugins/guided_onboarding/common/test_guide_config.ts +++ b/packages/kbn-guided-onboarding/src/common/test_guide_config.ts @@ -6,8 +6,7 @@ * Side Public License, v 1. */ -import type { GuideId } from '@kbn/guided-onboarding'; -import type { GuideConfig } from './types'; +import type { GuideId, GuideConfig } from '../types'; export const testGuideId: GuideId = 'testGuide'; export const testGuideConfig: GuideConfig = { diff --git a/packages/kbn-guided-onboarding/src/types.ts b/packages/kbn-guided-onboarding/src/types.ts index fa405684e71df..0bfe947c05c37 100644 --- a/packages/kbn-guided-onboarding/src/types.ts +++ b/packages/kbn-guided-onboarding/src/types.ts @@ -45,3 +45,56 @@ export interface GuideStep { id: GuideStepIds; status: StepStatus; } + +export interface GuideConfig { + title: string; + description: string; + guideName: string; + telemetryId: string; + docs?: { + text: string; + url: string; + }; + completedGuideRedirectLocation?: { + appID: string; + path: string; + }; + steps: StepConfig[]; +} + +/* To append a link to the description, specify its text and url in the properties. + * An example: + * { + * description: 'This is a description with a link'. + * linkText: 'My link', + * linkUrl: 'example.com', + * isLinkExternal: true, + * } + * + */ +export interface StepDescriptionWithLink { + descriptionText: string; + linkText: string; + linkUrl: string; + isLinkExternal?: boolean; +} + +export interface StepConfig { + id: GuideStepIds; + title: string; + // description is displayed as a single paragraph, can be combined with description list + description?: string | StepDescriptionWithLink; + // description list is displayed as an unordered list, can be combined with description + descriptionList?: Array; + location?: { + appID: string; + path: string; + }; + status?: StepStatus; + integration?: string; + manualCompletion?: { + title: string; + description: string; + readyToCompleteOnNavigation?: boolean; + }; +} diff --git a/packages/kbn-i18n/src/core/i18n.test.ts b/packages/kbn-i18n/src/core/i18n.test.ts index dfea790f129b5..f9a6535d881ee 100644 --- a/packages/kbn-i18n/src/core/i18n.test.ts +++ b/packages/kbn-i18n/src/core/i18n.test.ts @@ -662,13 +662,13 @@ describe('I18n engine', () => { i18n.translate('a.short', { values: { expires: new Date(2018, 5, 20, 18, 40, 30, 50) }, } as any) - ).toBe('Coupon expires at 6:40 PM'); + ).toBe('Coupon expires at 6:40 PM'); expect( i18n.translate('a.medium', { values: { expires: new Date(2018, 5, 20, 18, 40, 30, 50) }, } as any) - ).toBe('Coupon expires at 6:40:30 PM'); + ).toBe('Coupon expires at 6:40:30 PM'); }); test('should format default messages with time formatter', () => { @@ -679,14 +679,14 @@ describe('I18n engine', () => { defaultMessage: 'Coupon expires at {expires, time, short}', values: { expires: new Date(2018, 5, 20, 18, 40, 30, 50) }, }) - ).toBe('Coupon expires at 6:40 PM'); + ).toBe('Coupon expires at 6:40 PM'); expect( i18n.translate('foo', { defaultMessage: 'Coupon expires at {expires, time, medium}', values: { expires: new Date(2018, 5, 20, 18, 40, 30, 50) }, }) - ).toBe('Coupon expires at 6:40:30 PM'); + ).toBe('Coupon expires at 6:40:30 PM'); }); test('should format message with a custom format', () => { diff --git a/packages/kbn-monaco/BUILD.bazel b/packages/kbn-monaco/BUILD.bazel index 8d13702e74588..2ca10b073fd18 100644 --- a/packages/kbn-monaco/BUILD.bazel +++ b/packages/kbn-monaco/BUILD.bazel @@ -56,9 +56,11 @@ webpack_cli( env = select({ "//:dist": { "NODE_ENV": "production", + "NODE_OPTIONS": "--openssl-legacy-provider", }, "//conditions:default": { "NODE_ENV": "development", + "NODE_OPTIONS": "--openssl-legacy-provider", }, }), visibility = ["//visibility:public"], diff --git a/packages/kbn-monaco/kibana.jsonc b/packages/kbn-monaco/kibana.jsonc index c258ae7584a55..32e962e27ca3b 100644 --- a/packages/kbn-monaco/kibana.jsonc +++ b/packages/kbn-monaco/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/monaco", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/kbn-optimizer/limits.yml b/packages/kbn-optimizer/limits.yml index c1371edbd4068..e5da6d72de548 100644 --- a/packages/kbn-optimizer/limits.yml +++ b/packages/kbn-optimizer/limits.yml @@ -147,6 +147,6 @@ pageLoadAssetSize: visTypeTimeseries: 55203 visTypeVega: 153573 visTypeVislib: 242838 - visTypeXy: 31800 + visTypeXy: 46868 visualizations: 90000 watcher: 43598 diff --git a/packages/kbn-optimizer/src/optimizer/observe_worker.ts b/packages/kbn-optimizer/src/optimizer/observe_worker.ts index cf250a7deef6e..49c150fbf2dcb 100644 --- a/packages/kbn-optimizer/src/optimizer/observe_worker.ts +++ b/packages/kbn-optimizer/src/optimizer/observe_worker.ts @@ -60,6 +60,7 @@ function usingWorkerProc(config: OptimizerConfig, fn: (proc: ChildProcess) => (): ProcResource => { const proc = fork(require.resolve('../worker/run_worker'), [], { execArgv: [ + '--openssl-legacy-provider', `--require=@kbn/babel-register/install`, ...(inspectFlag && config.inspectWorkers ? [`${inspectFlag}=${inspectPortCounter++}`] diff --git a/packages/kbn-react-field/kibana.jsonc b/packages/kbn-react-field/kibana.jsonc index 4b85e53ad6af2..5b65d59d4dbbd 100644 --- a/packages/kbn-react-field/kibana.jsonc +++ b/packages/kbn-react-field/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/react-field", - "owner": "@elastic/kibana-app-services" + "owner": "@elastic/kibana-data-discovery" } diff --git a/packages/kbn-repo-source-classifier/src/repo_source_classifier.ts b/packages/kbn-repo-source-classifier/src/repo_source_classifier.ts index c10a2d3680c30..9957d3474e549 100644 --- a/packages/kbn-repo-source-classifier/src/repo_source_classifier.ts +++ b/packages/kbn-repo-source-classifier/src/repo_source_classifier.ts @@ -124,6 +124,17 @@ export class RepoSourceClassifier { } } + /** + * Apply screenshotting specific rules + * @param root the root dir within the screenshotting plugin + * @returns a type, or undefined if the file should be classified as a standard file + */ + private classifyScreenshotting(root: string): ModuleType | undefined { + if (root === 'chromium') { + return 'non-package'; + } + } + /** * Determine the "type" of a file */ @@ -195,6 +206,13 @@ export class RepoSourceClassifier { } } + if (pkgId === '@kbn/screenshotting-plugin') { + const type = this.classifyScreenshotting(root); + if (type) { + return type; + } + } + if (root === 'public' || root === 'static') { return 'browser package'; } diff --git a/packages/kbn-securitysolution-io-ts-alerting-types/src/default_uuid/index.ts b/packages/kbn-securitysolution-io-ts-alerting-types/src/default_uuid/index.ts index 73bf807e92c43..07ed82cddec65 100644 --- a/packages/kbn-securitysolution-io-ts-alerting-types/src/default_uuid/index.ts +++ b/packages/kbn-securitysolution-io-ts-alerting-types/src/default_uuid/index.ts @@ -8,18 +8,18 @@ import * as t from 'io-ts'; import { Either } from 'fp-ts/lib/Either'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { NonEmptyString } from '@kbn/securitysolution-io-ts-types'; /** * Types the DefaultUuid as: - * - If null or undefined, then a default string uuid.v4() will be + * - If null or undefined, then a default string uuidv4() will be * created otherwise it will be checked just against an empty string */ export const DefaultUuid = new t.Type( 'DefaultUuid', t.string.is, (input, context): Either => - input == null ? t.success(uuid.v4()) : NonEmptyString.validate(input, context), + input == null ? t.success(uuidv4()) : NonEmptyString.validate(input, context), t.identity ); diff --git a/packages/kbn-securitysolution-io-ts-types/src/default_uuid/index.ts b/packages/kbn-securitysolution-io-ts-types/src/default_uuid/index.ts index 01bd58d11e96d..5b7dce73b8057 100644 --- a/packages/kbn-securitysolution-io-ts-types/src/default_uuid/index.ts +++ b/packages/kbn-securitysolution-io-ts-types/src/default_uuid/index.ts @@ -8,18 +8,18 @@ import * as t from 'io-ts'; import { Either } from 'fp-ts/lib/Either'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { NonEmptyString } from '../non_empty_string'; /** * Types the DefaultUuid as: - * - If null or undefined, then a default string uuid.v4() will be + * - If null or undefined, then a default string uuidv4() will be * created otherwise it will be checked just against an empty string */ export const DefaultUuid = new t.Type( 'DefaultUuid', t.string.is, (input, context): Either => - input == null ? t.success(uuid.v4()) : NonEmptyString.validate(input, context), + input == null ? t.success(uuidv4()) : NonEmptyString.validate(input, context), t.identity ); diff --git a/packages/kbn-securitysolution-list-utils/src/helpers/index.ts b/packages/kbn-securitysolution-list-utils/src/helpers/index.ts index 945afbbc8604e..638dead59e366 100644 --- a/packages/kbn-securitysolution-list-utils/src/helpers/index.ts +++ b/packages/kbn-securitysolution-list-utils/src/helpers/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { addIdToItem, removeIdFromItem } from '@kbn/securitysolution-utils'; import { validate } from '@kbn/securitysolution-io-ts-utils'; import { @@ -159,7 +159,7 @@ export const getNewExceptionItem = ({ item_id: undefined, list_id: listId, meta: { - temporaryUuid: uuid.v4(), + temporaryUuid: uuidv4(), }, name, namespace_type: namespaceType, @@ -897,7 +897,7 @@ export const getFormattedBuilderEntries = ( export const getDefaultEmptyEntry = (): EmptyEntry => ({ field: '', - id: uuid.v4(), + id: uuidv4(), operator: OperatorEnum.INCLUDED, type: OperatorTypeEnum.MATCH, value: '', @@ -906,7 +906,7 @@ export const getDefaultEmptyEntry = (): EmptyEntry => ({ export const getDefaultNestedEmptyEntry = (): EmptyNestedEntry => ({ entries: [], field: '', - id: uuid.v4(), + id: uuidv4(), type: OperatorTypeEnum.NESTED, }); diff --git a/packages/kbn-securitysolution-utils/src/add_remove_id_to_item/index.ts b/packages/kbn-securitysolution-utils/src/add_remove_id_to_item/index.ts index 682e38ae2b8bf..37a58438e62f2 100644 --- a/packages/kbn-securitysolution-utils/src/add_remove_id_to_item/index.ts +++ b/packages/kbn-securitysolution-utils/src/add_remove_id_to_item/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; /** * This is useful for when you have arrays without an ID and need to add one for @@ -23,7 +23,7 @@ export const addIdToItem = (item: NotArray): T => { if (maybeId.id != null) { return item; } else { - return { ...item, id: uuid.v4() }; + return { ...item, id: uuidv4() }; } }; diff --git a/packages/kbn-server-http-tools/src/get_request_id.ts b/packages/kbn-server-http-tools/src/get_request_id.ts index 3af70ecc3a7a3..7f010e5d65e75 100644 --- a/packages/kbn-server-http-tools/src/get_request_id.ts +++ b/packages/kbn-server-http-tools/src/get_request_id.ts @@ -7,7 +7,7 @@ */ import { Request } from '@hapi/hapi'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export function getRequestId( request: Request, @@ -17,6 +17,6 @@ export function getRequestId( return allowFromAnyIp || // socket may be undefined in integration tests that connect via the http listener directly (remoteAddress && ipAllowlist.includes(remoteAddress)) - ? request.headers['x-opaque-id'] ?? uuid.v4() - : uuid.v4(); + ? request.headers['x-opaque-id'] ?? uuidv4() + : uuidv4(); } diff --git a/packages/kbn-shared-ux-utility/kibana.jsonc b/packages/kbn-shared-ux-utility/kibana.jsonc index db36089572290..23205fc09e20c 100644 --- a/packages/kbn-shared-ux-utility/kibana.jsonc +++ b/packages/kbn-shared-ux-utility/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-utility", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/kbn-slo-schema/src/rest_specs/slo.ts b/packages/kbn-slo-schema/src/rest_specs/slo.ts index 246e50ba1383e..6fb6c69f9293c 100644 --- a/packages/kbn-slo-schema/src/rest_specs/slo.ts +++ b/packages/kbn-slo-schema/src/rest_specs/slo.ts @@ -11,6 +11,7 @@ import * as t from 'io-ts'; import { budgetingMethodSchema, dateType, + historicalSummarySchema, indicatorSchema, indicatorTypesArraySchema, objectiveSchema, @@ -109,6 +110,9 @@ const findSLOResponseSchema = t.type({ results: t.array(sloWithSummaryResponseSchema), }); +const fetchHistoricalSummaryParamsSchema = t.type({ body: t.type({ sloIds: t.array(t.string) }) }); +const fetchHistoricalSummaryResponseSchema = t.record(t.string, t.array(historicalSummarySchema)); + type SLOResponse = t.OutputOf; type SLOWithSummaryResponse = t.OutputOf; @@ -125,6 +129,9 @@ type UpdateSLOResponse = t.OutputOf; type FindSLOParams = t.TypeOf; type FindSLOResponse = t.OutputOf; +type FetchHistoricalSummaryParams = t.TypeOf; +type FetchHistoricalSummaryResponse = t.OutputOf; + type BudgetingMethod = t.TypeOf; export { @@ -134,6 +141,8 @@ export { findSLOResponseSchema, getSLOParamsSchema, getSLOResponseSchema, + fetchHistoricalSummaryParamsSchema, + fetchHistoricalSummaryResponseSchema, sloResponseSchema, sloWithSummaryResponseSchema, updateSLOParamsSchema, @@ -147,6 +156,8 @@ export type { FindSLOParams, FindSLOResponse, GetSLOResponse, + FetchHistoricalSummaryParams, + FetchHistoricalSummaryResponse, SLOResponse, SLOWithSummaryResponse, UpdateSLOInput, diff --git a/packages/kbn-slo-schema/src/schema/indicators.ts b/packages/kbn-slo-schema/src/schema/indicators.ts index 73933fb785794..a8936c38f7663 100644 --- a/packages/kbn-slo-schema/src/schema/indicators.ts +++ b/packages/kbn-slo-schema/src/schema/indicators.ts @@ -7,7 +7,13 @@ */ import * as t from 'io-ts'; -import { allOrAnyString, dateRangeSchema } from './common'; +import { + allOrAnyString, + dateRangeSchema, + dateType, + errorBudgetSchema, + statusSchema, +} from './common'; const apmTransactionDurationIndicatorTypeSchema = t.literal('sli.apm.transactionDuration'); const apmTransactionDurationIndicatorSchema = t.type({ @@ -62,6 +68,13 @@ const indicatorDataSchema = t.type({ total: t.number, }); +const historicalSummarySchema = t.type({ + date: dateType, + errorBudget: errorBudgetSchema, + sliValue: t.number, + status: statusSchema, +}); + const indicatorTypesSchema = t.union([ apmTransactionDurationIndicatorTypeSchema, apmTransactionErrorRateIndicatorTypeSchema, @@ -104,4 +117,5 @@ export { indicatorTypesArraySchema, indicatorTypesSchema, indicatorDataSchema, + historicalSummarySchema, }; diff --git a/packages/kbn-test/src/es/test_es_cluster.ts b/packages/kbn-test/src/es/test_es_cluster.ts index 6f7310e4bd2e2..af7ccc69052e9 100644 --- a/packages/kbn-test/src/es/test_es_cluster.ts +++ b/packages/kbn-test/src/es/test_es_cluster.ts @@ -9,7 +9,7 @@ import Path from 'path'; import { format } from 'url'; import del from 'del'; -import Uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import globby from 'globby'; import createArchiver from 'archiver'; import Fs from 'fs'; @@ -307,7 +307,7 @@ export function createTestEsCluster< return; } - const uuid = Uuid.v4(); + const uuid = uuidv4(); const debugPath = Path.resolve(REPO_ROOT, `data/es_debug_${uuid}.tar.gz`); log.error(`[es] debug files found, archiving install to ${debugPath}`); const archiver = createArchiver('tar', { gzip: true }); diff --git a/packages/kbn-test/src/functional_tests/lib/run_kibana_server.ts b/packages/kbn-test/src/functional_tests/lib/run_kibana_server.ts index 2f82d23d72874..745f8d015ec47 100644 --- a/packages/kbn-test/src/functional_tests/lib/run_kibana_server.ts +++ b/packages/kbn-test/src/functional_tests/lib/run_kibana_server.ts @@ -9,7 +9,7 @@ import Path from 'path'; import Os from 'os'; -import Uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ProcRunner } from '@kbn/dev-proc-runner'; import { REPO_ROOT } from '@kbn/repo-info'; @@ -98,7 +98,7 @@ export async function runKibanaServer(options: { ? [] : [ '--node.roles=["ui"]', - `--path.data=${Path.resolve(Os.tmpdir(), `ftr-ui-${Uuid.v4()}`)}`, + `--path.data=${Path.resolve(Os.tmpdir(), `ftr-ui-${uuidv4()}`)}`, ]), ]), ], @@ -121,7 +121,7 @@ export async function runKibanaServer(options: { ...kbnFlags, `--server.port=${DedicatedTaskRunner.getPort(config.get('servers.kibana.port'))}`, '--node.roles=["background_tasks"]', - `--path.data=${Path.resolve(Os.tmpdir(), `ftr-task-runner-${Uuid.v4()}`)}`, + `--path.data=${Path.resolve(Os.tmpdir(), `ftr-task-runner-${uuidv4()}`)}`, ...(typeof mainUuid === 'string' && mainUuid ? [`--server.uuid=${DedicatedTaskRunner.getUuid(mainUuid)}`] : []), diff --git a/packages/kbn-ui-actions-browser/README.md b/packages/kbn-ui-actions-browser/README.md new file mode 100644 index 0000000000000..928a945593408 --- /dev/null +++ b/packages/kbn-ui-actions-browser/README.md @@ -0,0 +1,3 @@ +# @kbn/ui-actions-browser + +Empty package generated by @kbn/generate diff --git a/packages/kbn-ui-actions-browser/index.ts b/packages/kbn-ui-actions-browser/index.ts new file mode 100644 index 0000000000000..de0577ee3ed83 --- /dev/null +++ b/packages/kbn-ui-actions-browser/index.ts @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export * from './src'; diff --git a/packages/kbn-ui-actions-browser/jest.config.js b/packages/kbn-ui-actions-browser/jest.config.js new file mode 100644 index 0000000000000..a4badadfa0bbd --- /dev/null +++ b/packages/kbn-ui-actions-browser/jest.config.js @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +module.exports = { + preset: '@kbn/test', + rootDir: '../..', + roots: ['/packages/kbn-ui-actions-browser'], +}; diff --git a/packages/kbn-ui-actions-browser/kibana.jsonc b/packages/kbn-ui-actions-browser/kibana.jsonc new file mode 100644 index 0000000000000..3fbdc46e64b16 --- /dev/null +++ b/packages/kbn-ui-actions-browser/kibana.jsonc @@ -0,0 +1,5 @@ +{ + "type": "shared-common", + "id": "@kbn/ui-actions-browser", + "owner": "@elastic/appex-sharedux" +} diff --git a/packages/kbn-ui-actions-browser/package.json b/packages/kbn-ui-actions-browser/package.json new file mode 100644 index 0000000000000..dee7bc9f05f0c --- /dev/null +++ b/packages/kbn-ui-actions-browser/package.json @@ -0,0 +1,6 @@ +{ + "name": "@kbn/ui-actions-browser", + "private": true, + "version": "1.0.0", + "license": "SSPL-1.0 OR Elastic License 2.0" +} \ No newline at end of file diff --git a/packages/kbn-ui-actions-browser/src/index.ts b/packages/kbn-ui-actions-browser/src/index.ts new file mode 100644 index 0000000000000..12594660136d8 --- /dev/null +++ b/packages/kbn-ui-actions-browser/src/index.ts @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export * from './types'; diff --git a/src/plugins/ui_actions/public/util/index.ts b/packages/kbn-ui-actions-browser/src/types/index.ts similarity index 100% rename from src/plugins/ui_actions/public/util/index.ts rename to packages/kbn-ui-actions-browser/src/types/index.ts diff --git a/src/plugins/ui_actions/public/util/presentable.ts b/packages/kbn-ui-actions-browser/src/types/presentable.ts similarity index 100% rename from src/plugins/ui_actions/public/util/presentable.ts rename to packages/kbn-ui-actions-browser/src/types/presentable.ts diff --git a/packages/kbn-ui-actions-browser/tsconfig.json b/packages/kbn-ui-actions-browser/tsconfig.json new file mode 100644 index 0000000000000..87f865132f4b4 --- /dev/null +++ b/packages/kbn-ui-actions-browser/tsconfig.json @@ -0,0 +1,19 @@ +{ + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "outDir": "target/types", + "types": [ + "jest", + "node", + "react" + ] + }, + "include": [ + "**/*.ts", + "**/*.tsx", + ], + "exclude": [ + "target/**/*" + ], + "kbn_references": [] +} diff --git a/packages/kbn-ui-shared-deps-npm/BUILD.bazel b/packages/kbn-ui-shared-deps-npm/BUILD.bazel index 2b49f1e5a92f1..7bcc1b3c4b380 100644 --- a/packages/kbn-ui-shared-deps-npm/BUILD.bazel +++ b/packages/kbn-ui-shared-deps-npm/BUILD.bazel @@ -57,6 +57,7 @@ RUNTIME_DEPS = [ "@npm//rxjs", "@npm//styled-components", "@npm//tslib", + "@npm//uuid", ] webpack_cli( @@ -83,9 +84,11 @@ webpack_cli( env = select({ "//:dist": { "NODE_ENV": "production", + "NODE_OPTIONS": "--openssl-legacy-provider", }, "//conditions:default": { "NODE_ENV": "development", + "NODE_OPTIONS": "--openssl-legacy-provider", }, }) ) diff --git a/packages/kbn-ui-shared-deps-npm/webpack.config.js b/packages/kbn-ui-shared-deps-npm/webpack.config.js index 680751927ad6f..70186333b3857 100644 --- a/packages/kbn-ui-shared-deps-npm/webpack.config.js +++ b/packages/kbn-ui-shared-deps-npm/webpack.config.js @@ -105,6 +105,7 @@ module.exports = (_, argv) => { 'rxjs/operators', 'styled-components', 'tslib', + 'uuid', ], 'kbn-ui-shared-deps-npm.v8.dark': ['@elastic/eui/dist/eui_theme_dark.css'], 'kbn-ui-shared-deps-npm.v8.light': ['@elastic/eui/dist/eui_theme_light.css'], diff --git a/packages/kbn-ui-shared-deps-src/BUILD.bazel b/packages/kbn-ui-shared-deps-src/BUILD.bazel index 0b350c51331ff..49c2cc62dcfe5 100644 --- a/packages/kbn-ui-shared-deps-src/BUILD.bazel +++ b/packages/kbn-ui-shared-deps-src/BUILD.bazel @@ -45,9 +45,11 @@ webpack_cli( env = select({ "//:dist": { "NODE_ENV": "production", + "NODE_OPTIONS": "--openssl-legacy-provider", }, "//conditions:default": { "NODE_ENV": "development", + "NODE_OPTIONS": "--openssl-legacy-provider", }, }), visibility = ["//visibility:public"], diff --git a/packages/kbn-ui-shared-deps-src/src/definitions.js b/packages/kbn-ui-shared-deps-src/src/definitions.js index 83a24b7c88d28..1448410c4049e 100644 --- a/packages/kbn-ui-shared-deps-src/src/definitions.js +++ b/packages/kbn-ui-shared-deps-src/src/definitions.js @@ -79,6 +79,7 @@ const externals = { * runtime deps which don't need to be copied across all bundles */ tslib: '__kbnSharedDeps__.TsLib', + uuid: '__kbnSharedDeps__.Uuid', '@kbn/analytics': '__kbnSharedDeps__.KbnAnalytics', '@kbn/es-query': '__kbnSharedDeps__.KbnEsQuery', '@kbn/std': '__kbnSharedDeps__.KbnStd', diff --git a/packages/kbn-ui-shared-deps-src/src/entry.js b/packages/kbn-ui-shared-deps-src/src/entry.js index 146efce495eaf..9e6adf6e5f4bc 100644 --- a/packages/kbn-ui-shared-deps-src/src/entry.js +++ b/packages/kbn-ui-shared-deps-src/src/entry.js @@ -53,6 +53,7 @@ export const Fflate = { unzlibSync, strFromU8 }; // runtime deps which don't need to be copied across all bundles export const TsLib = require('tslib'); +export const Uuid = require('uuid'); export const KbnAnalytics = require('@kbn/analytics'); export const KbnEsQuery = require('@kbn/es-query'); export const KbnStd = require('@kbn/std'); diff --git a/packages/shared-ux/avatar/solution/kibana.jsonc b/packages/shared-ux/avatar/solution/kibana.jsonc index 6bb90e43260f7..bec67862823b3 100644 --- a/packages/shared-ux/avatar/solution/kibana.jsonc +++ b/packages/shared-ux/avatar/solution/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-avatar-solution", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/avatar/user_profile/impl/kibana.jsonc b/packages/shared-ux/avatar/user_profile/impl/kibana.jsonc index 0cebb8c02e969..f5105c929224b 100644 --- a/packages/shared-ux/avatar/user_profile/impl/kibana.jsonc +++ b/packages/shared-ux/avatar/user_profile/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-avatar-user-profile-components", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/button/exit_full_screen/impl/kibana.jsonc b/packages/shared-ux/button/exit_full_screen/impl/kibana.jsonc index c74b644894aeb..8cd27723b051f 100644 --- a/packages/shared-ux/button/exit_full_screen/impl/kibana.jsonc +++ b/packages/shared-ux/button/exit_full_screen/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-button-exit-full-screen", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/button/exit_full_screen/mocks/kibana.jsonc b/packages/shared-ux/button/exit_full_screen/mocks/kibana.jsonc index 27c601e53c53f..1c21ffbc91c7c 100644 --- a/packages/shared-ux/button/exit_full_screen/mocks/kibana.jsonc +++ b/packages/shared-ux/button/exit_full_screen/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-button-exit-full-screen-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/button/exit_full_screen/types/kibana.jsonc b/packages/shared-ux/button/exit_full_screen/types/kibana.jsonc index 932f0031e9b5d..9c8448d02a2b1 100644 --- a/packages/shared-ux/button/exit_full_screen/types/kibana.jsonc +++ b/packages/shared-ux/button/exit_full_screen/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-button-exit-full-screen-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/button_toolbar/kibana.jsonc b/packages/shared-ux/button_toolbar/kibana.jsonc index 2d2b0c9ce82c3..8e5d78dff0e53 100644 --- a/packages/shared-ux/button_toolbar/kibana.jsonc +++ b/packages/shared-ux/button_toolbar/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-button-toolbar", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/card/no_data/impl/kibana.jsonc b/packages/shared-ux/card/no_data/impl/kibana.jsonc index 172a06aec0650..26ee0d2734598 100644 --- a/packages/shared-ux/card/no_data/impl/kibana.jsonc +++ b/packages/shared-ux/card/no_data/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-card-no-data", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/card/no_data/mocks/kibana.jsonc b/packages/shared-ux/card/no_data/mocks/kibana.jsonc index 74acf79369075..4efb668db6e5a 100644 --- a/packages/shared-ux/card/no_data/mocks/kibana.jsonc +++ b/packages/shared-ux/card/no_data/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-card-no-data-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/card/no_data/types/kibana.jsonc b/packages/shared-ux/card/no_data/types/kibana.jsonc index 6b7c283766469..8362ac58ccb44 100644 --- a/packages/shared-ux/card/no_data/types/kibana.jsonc +++ b/packages/shared-ux/card/no_data/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-card-no-data-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/context/kibana.jsonc b/packages/shared-ux/file/context/kibana.jsonc index 8d511e381a8df..c4b2a631f0c9f 100644 --- a/packages/shared-ux/file/context/kibana.jsonc +++ b/packages/shared-ux/file/context/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-context", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/file_picker/impl/kibana.jsonc b/packages/shared-ux/file/file_picker/impl/kibana.jsonc index ab54fb4f21612..733d78bcd3037 100644 --- a/packages/shared-ux/file/file_picker/impl/kibana.jsonc +++ b/packages/shared-ux/file/file_picker/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-picker", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/file_upload/impl/kibana.jsonc b/packages/shared-ux/file/file_upload/impl/kibana.jsonc index a091e6e1ec046..0ebcd24bf98ea 100644 --- a/packages/shared-ux/file/file_upload/impl/kibana.jsonc +++ b/packages/shared-ux/file/file_upload/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-upload", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/image/impl/kibana.jsonc b/packages/shared-ux/file/image/impl/kibana.jsonc index 1f10c9524e6c3..e7bc1629fe4f1 100644 --- a/packages/shared-ux/file/image/impl/kibana.jsonc +++ b/packages/shared-ux/file/image/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-image", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/image/mocks/kibana.jsonc b/packages/shared-ux/file/image/mocks/kibana.jsonc index 79ddeb6e8d7ad..abf9037fe0497 100644 --- a/packages/shared-ux/file/image/mocks/kibana.jsonc +++ b/packages/shared-ux/file/image/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-image-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/mocks/kibana.jsonc b/packages/shared-ux/file/mocks/kibana.jsonc index 587fc49d1a21d..ea930e806051a 100644 --- a/packages/shared-ux/file/mocks/kibana.jsonc +++ b/packages/shared-ux/file/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/types/kibana.jsonc b/packages/shared-ux/file/types/kibana.jsonc index becf0ea53cc4c..5d97907473384 100644 --- a/packages/shared-ux/file/types/kibana.jsonc +++ b/packages/shared-ux/file/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/file/util/kibana.jsonc b/packages/shared-ux/file/util/kibana.jsonc index 5e63db9a0f1fb..80c644db509e3 100644 --- a/packages/shared-ux/file/util/kibana.jsonc +++ b/packages/shared-ux/file/util/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-file-util", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/link/redirect_app/impl/kibana.jsonc b/packages/shared-ux/link/redirect_app/impl/kibana.jsonc index 4ba057259182f..5b6d19ecb0cbc 100644 --- a/packages/shared-ux/link/redirect_app/impl/kibana.jsonc +++ b/packages/shared-ux/link/redirect_app/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-link-redirect-app", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/link/redirect_app/mocks/kibana.jsonc b/packages/shared-ux/link/redirect_app/mocks/kibana.jsonc index 3282ed29cba75..1c070c1998633 100644 --- a/packages/shared-ux/link/redirect_app/mocks/kibana.jsonc +++ b/packages/shared-ux/link/redirect_app/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-link-redirect-app-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/link/redirect_app/types/kibana.jsonc b/packages/shared-ux/link/redirect_app/types/kibana.jsonc index 7c3f5a0d6d8fc..ca657f445f43d 100644 --- a/packages/shared-ux/link/redirect_app/types/kibana.jsonc +++ b/packages/shared-ux/link/redirect_app/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-link-redirect-app-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/markdown/impl/kibana.jsonc b/packages/shared-ux/markdown/impl/kibana.jsonc index 6286957024922..a6a615abb33ea 100644 --- a/packages/shared-ux/markdown/impl/kibana.jsonc +++ b/packages/shared-ux/markdown/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-markdown", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/markdown/mocks/kibana.jsonc b/packages/shared-ux/markdown/mocks/kibana.jsonc index 7f362da42b0d0..c1183a70ceda7 100644 --- a/packages/shared-ux/markdown/mocks/kibana.jsonc +++ b/packages/shared-ux/markdown/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-markdown-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/markdown/types/kibana.jsonc b/packages/shared-ux/markdown/types/kibana.jsonc index 7c4c3348bc082..18412b08bd7af 100644 --- a/packages/shared-ux/markdown/types/kibana.jsonc +++ b/packages/shared-ux/markdown/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-markdown-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/analytics_no_data/impl/kibana.jsonc b/packages/shared-ux/page/analytics_no_data/impl/kibana.jsonc index a971be9527c92..9e583fb0f3935 100644 --- a/packages/shared-ux/page/analytics_no_data/impl/kibana.jsonc +++ b/packages/shared-ux/page/analytics_no_data/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-analytics-no-data", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/analytics_no_data/mocks/kibana.jsonc b/packages/shared-ux/page/analytics_no_data/mocks/kibana.jsonc index ced2ab2b9a374..cde1666e15f14 100644 --- a/packages/shared-ux/page/analytics_no_data/mocks/kibana.jsonc +++ b/packages/shared-ux/page/analytics_no_data/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-analytics-no-data-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/analytics_no_data/types/kibana.jsonc b/packages/shared-ux/page/analytics_no_data/types/kibana.jsonc index cc8fc3c873022..c0c64b07c5683 100644 --- a/packages/shared-ux/page/analytics_no_data/types/kibana.jsonc +++ b/packages/shared-ux/page/analytics_no_data/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-analytics-no-data-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_no_data/impl/kibana.jsonc b/packages/shared-ux/page/kibana_no_data/impl/kibana.jsonc index 07de27d7e9aa3..32f0f5bd58123 100644 --- a/packages/shared-ux/page/kibana_no_data/impl/kibana.jsonc +++ b/packages/shared-ux/page/kibana_no_data/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-no-data", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_no_data/mocks/kibana.jsonc b/packages/shared-ux/page/kibana_no_data/mocks/kibana.jsonc index 4d9403bec3999..6d757ebb856b4 100644 --- a/packages/shared-ux/page/kibana_no_data/mocks/kibana.jsonc +++ b/packages/shared-ux/page/kibana_no_data/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-no-data-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_no_data/types/kibana.jsonc b/packages/shared-ux/page/kibana_no_data/types/kibana.jsonc index 6bfd4e44a05d9..9ca77555690b4 100644 --- a/packages/shared-ux/page/kibana_no_data/types/kibana.jsonc +++ b/packages/shared-ux/page/kibana_no_data/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-no-data-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_template/impl/kibana.jsonc b/packages/shared-ux/page/kibana_template/impl/kibana.jsonc index 5b670f59b7d18..e46ee9f3b499a 100644 --- a/packages/shared-ux/page/kibana_template/impl/kibana.jsonc +++ b/packages/shared-ux/page/kibana_template/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-template", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_template/mocks/kibana.jsonc b/packages/shared-ux/page/kibana_template/mocks/kibana.jsonc index 29b752ee4a424..5a40da10af0f4 100644 --- a/packages/shared-ux/page/kibana_template/mocks/kibana.jsonc +++ b/packages/shared-ux/page/kibana_template/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-template-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/kibana_template/types/kibana.jsonc b/packages/shared-ux/page/kibana_template/types/kibana.jsonc index eda1aee86b12b..cb1b977b116c2 100644 --- a/packages/shared-ux/page/kibana_template/types/kibana.jsonc +++ b/packages/shared-ux/page/kibana_template/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-kibana-template-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data/impl/kibana.jsonc b/packages/shared-ux/page/no_data/impl/kibana.jsonc index 26e30ef8c15f2..f24a483a8dfbf 100644 --- a/packages/shared-ux/page/no_data/impl/kibana.jsonc +++ b/packages/shared-ux/page/no_data/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data/mocks/kibana.jsonc b/packages/shared-ux/page/no_data/mocks/kibana.jsonc index cbcf8d5376a61..78d4d58d477e3 100644 --- a/packages/shared-ux/page/no_data/mocks/kibana.jsonc +++ b/packages/shared-ux/page/no_data/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data/types/kibana.jsonc b/packages/shared-ux/page/no_data/types/kibana.jsonc index 2e79352fbd5fd..01a284fc5663c 100644 --- a/packages/shared-ux/page/no_data/types/kibana.jsonc +++ b/packages/shared-ux/page/no_data/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data_config/impl/kibana.jsonc b/packages/shared-ux/page/no_data_config/impl/kibana.jsonc index eac1472b64938..5be804aba54b1 100644 --- a/packages/shared-ux/page/no_data_config/impl/kibana.jsonc +++ b/packages/shared-ux/page/no_data_config/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data-config", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data_config/mocks/kibana.jsonc b/packages/shared-ux/page/no_data_config/mocks/kibana.jsonc index 0faf3792e6104..19341c81182a0 100644 --- a/packages/shared-ux/page/no_data_config/mocks/kibana.jsonc +++ b/packages/shared-ux/page/no_data_config/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data-config-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/no_data_config/types/kibana.jsonc b/packages/shared-ux/page/no_data_config/types/kibana.jsonc index 2a3266cdadbbd..f2e1ed111e2c4 100644 --- a/packages/shared-ux/page/no_data_config/types/kibana.jsonc +++ b/packages/shared-ux/page/no_data_config/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-no-data-config-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/page/solution_nav/kibana.jsonc b/packages/shared-ux/page/solution_nav/kibana.jsonc index 8a565ba934727..e8aa313b0f600 100644 --- a/packages/shared-ux/page/solution_nav/kibana.jsonc +++ b/packages/shared-ux/page/solution_nav/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-page-solution-nav", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/prompt/no_data_views/impl/kibana.jsonc b/packages/shared-ux/prompt/no_data_views/impl/kibana.jsonc index c5fb048c68098..1519adaa35592 100644 --- a/packages/shared-ux/prompt/no_data_views/impl/kibana.jsonc +++ b/packages/shared-ux/prompt/no_data_views/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-prompt-no-data-views", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/prompt/no_data_views/mocks/kibana.jsonc b/packages/shared-ux/prompt/no_data_views/mocks/kibana.jsonc index 29c18ad857afc..fba498c5d51de 100644 --- a/packages/shared-ux/prompt/no_data_views/mocks/kibana.jsonc +++ b/packages/shared-ux/prompt/no_data_views/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-prompt-no-data-views-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/prompt/no_data_views/types/kibana.jsonc b/packages/shared-ux/prompt/no_data_views/types/kibana.jsonc index 6aa07c20b34e9..6b34ae6cbbb88 100644 --- a/packages/shared-ux/prompt/no_data_views/types/kibana.jsonc +++ b/packages/shared-ux/prompt/no_data_views/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-prompt-no-data-views-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/prompt/not_found/kibana.jsonc b/packages/shared-ux/prompt/not_found/kibana.jsonc index 70ecc1dbf1eb9..fe3ad23f35c85 100644 --- a/packages/shared-ux/prompt/not_found/kibana.jsonc +++ b/packages/shared-ux/prompt/not_found/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-prompt-not-found", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/router/impl/kibana.jsonc b/packages/shared-ux/router/impl/kibana.jsonc index 5ecf4e1e558df..57433ea556f5c 100644 --- a/packages/shared-ux/router/impl/kibana.jsonc +++ b/packages/shared-ux/router/impl/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-router", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/router/mocks/kibana.jsonc b/packages/shared-ux/router/mocks/kibana.jsonc index 73750134ebdf2..26dc0fde75a25 100644 --- a/packages/shared-ux/router/mocks/kibana.jsonc +++ b/packages/shared-ux/router/mocks/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-router-mocks", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/router/types/kibana.jsonc b/packages/shared-ux/router/types/kibana.jsonc index 11df98571de3c..7508f5fa2f4b2 100644 --- a/packages/shared-ux/router/types/kibana.jsonc +++ b/packages/shared-ux/router/types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-router-types", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/storybook/config/kibana.jsonc b/packages/shared-ux/storybook/config/kibana.jsonc index 46f41bb01eb8e..fdf4553e204c2 100644 --- a/packages/shared-ux/storybook/config/kibana.jsonc +++ b/packages/shared-ux/storybook/config/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-storybook-config", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/packages/shared-ux/storybook/mock/kibana.jsonc b/packages/shared-ux/storybook/mock/kibana.jsonc index 143be36c8f400..ac21cf1df4b22 100644 --- a/packages/shared-ux/storybook/mock/kibana.jsonc +++ b/packages/shared-ux/storybook/mock/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-ux-storybook-mock", - "owner": "@elastic/kibana-global-experience" + "owner": "@elastic/appex-sharedux" } diff --git a/src/core/server/index.ts b/src/core/server/index.ts index 237a71821a9af..37306d63acf6b 100644 --- a/src/core/server/index.ts +++ b/src/core/server/index.ts @@ -239,11 +239,6 @@ export type { PluginName, DiscoveredPlugin } from '@kbn/core-base-common'; export type { SavedObjectsStart } from '@kbn/core-saved-objects-browser'; export type { - SavedObject, - SavedObjectAttribute, - SavedObjectAttributes, - SavedObjectAttributeSingle, - SavedObjectReference, SavedObjectsMigrationVersion, SavedObjectsImportConflictError, SavedObjectsImportAmbiguousConflictError, @@ -312,6 +307,11 @@ export type { SavedObjectsBulkDeleteStatus, } from '@kbn/core-saved-objects-api-server'; export type { + SavedObject, + SavedObjectAttribute, + SavedObjectAttributes, + SavedObjectAttributeSingle, + SavedObjectReference, SavedObjectsServiceSetup, SavedObjectsServiceStart, SavedObjectsClientProviderOptions, diff --git a/src/core/server/integration_tests/saved_objects/migrations/check_registered_types.test.ts b/src/core/server/integration_tests/saved_objects/migrations/check_registered_types.test.ts index ccaf01a70f5d1..569e8b81afd2d 100644 --- a/src/core/server/integration_tests/saved_objects/migrations/check_registered_types.test.ts +++ b/src/core/server/integration_tests/saved_objects/migrations/check_registered_types.test.ts @@ -74,7 +74,7 @@ describe('checking migration metadata changes on all registered SO types', () => "cases-configure": "1afc414f5563a36e4612fa269193d3ed7277c7bd", "cases-connector-mappings": "4b16d440af966e5d6e0fa33368bfa15d987a4b69", "cases-telemetry": "16e261e7378a72acd0806f18df92525dd1da4f37", - "cases-user-actions": "3973dfcaacbe6ae147d7331699cfc25d2a27ca30", + "cases-user-actions": "f1b0dcfeb58a65e68b35c5e99ddee70e746a06c7", "config": "e3f0408976dbdd453641f5699927b28b188f6b8c", "config-global": "b8f559884931609a349e129c717af73d23e7bc76", "connector_token": "fa5301aa5a2914795d3b1b82d0a49939444009da", @@ -124,6 +124,7 @@ describe('checking migration metadata changes on all registered SO types', () => "osquery-pack-asset": "de8783298eb33a577bf1fa0caacd42121dcfae91", "osquery-saved-query": "7b213b4b7a3e59350e99c50e8df9948662ed493a", "query": "4640ef356321500a678869f24117b7091a911cb6", + "rules-settings": "1af4c9abd4b40a154e233c2af4867df7aab7ac24", "sample-data-telemetry": "8b10336d9efae6f3d5593c4cc89fb4abcdf84e04", "search": "c48f5ab5d94545780ea98de1bff9e39f17f3606b", "search-session": "ba383309da68a15be3765977f7a44c84f0ec7964", diff --git a/src/core/server/integration_tests/saved_objects/migrations/skip_reindex.test.ts b/src/core/server/integration_tests/saved_objects/migrations/skip_reindex.test.ts index df64ccb853753..1699dbae46613 100644 --- a/src/core/server/integration_tests/saved_objects/migrations/skip_reindex.test.ts +++ b/src/core/server/integration_tests/saved_objects/migrations/skip_reindex.test.ts @@ -63,7 +63,8 @@ describe('skip reindexing', () => { logs = await fs.readFile(logFilePath, 'utf-8'); - expect(logs).toMatch('INIT -> PREPARE_COMPATIBLE_MIGRATION'); + expect(logs).toMatch('INIT -> WAIT_FOR_YELLOW_SOURCE'); + expect(logs).toMatch('WAIT_FOR_YELLOW_SOURCE -> PREPARE_COMPATIBLE_MIGRATION'); expect(logs).toMatch('PREPARE_COMPATIBLE_MIGRATION -> OUTDATED_DOCUMENTS_SEARCH_OPEN_PIT'); expect(logs).toMatch('CHECK_TARGET_MAPPINGS -> CHECK_VERSION_INDEX_READY_ACTIONS'); expect(logs).toMatch('CHECK_VERSION_INDEX_READY_ACTIONS -> DONE'); diff --git a/src/core/server/integration_tests/saved_objects/migrations/type_registrations.test.ts b/src/core/server/integration_tests/saved_objects/migrations/type_registrations.test.ts index 2cb85526f9340..2c8dbabf878a1 100644 --- a/src/core/server/integration_tests/saved_objects/migrations/type_registrations.test.ts +++ b/src/core/server/integration_tests/saved_objects/migrations/type_registrations.test.ts @@ -92,6 +92,7 @@ const previouslyRegisteredTypes = [ 'osquery-usage-metric', 'osquery-manager-usage-metric', 'query', + 'rules-settings', 'sample-data-telemetry', 'search', 'search-session', diff --git a/src/core/server/integration_tests/saved_objects/routes/import.test.ts b/src/core/server/integration_tests/saved_objects/routes/import.test.ts index f6098df7dd75b..6a98122141b00 100644 --- a/src/core/server/integration_tests/saved_objects/routes/import.test.ts +++ b/src/core/server/integration_tests/saved_objects/routes/import.test.ts @@ -491,8 +491,8 @@ describe(`POST ${URL}`, () => { const mockUuid = jest.requireMock('uuid'); mockUuid.v4 = jest .fn() - .mockReturnValueOnce('foo') // a uuid.v4() is generated for the request.id - .mockReturnValueOnce('foo') // another uuid.v4() is used for the request.uuid + .mockReturnValueOnce('foo') // a uuidv4() is generated for the request.id + .mockReturnValueOnce('foo') // another uuidv4() is used for the request.uuid .mockReturnValueOnce('new-id-1') .mockReturnValueOnce('new-id-2'); savedObjectsClient.bulkGet.mockResolvedValueOnce({ saved_objects: [mockIndexPattern] }); diff --git a/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker b/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker index f820a141afdad..9c5f2511f1617 100755 --- a/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker +++ b/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker @@ -381,6 +381,7 @@ kibana_vars=( xpack.security.sameSiteCookies xpack.security.secureCookies xpack.security.session.cleanupInterval + xpack.security.session.concurrentSessions.maxSessions xpack.security.session.idleTimeout xpack.security.session.lifespan xpack.security.sessionTimeout @@ -393,6 +394,7 @@ kibana_vars=( xpack.securitySolution.maxTimelineImportExportSize xpack.securitySolution.maxTimelineImportPayloadBytes xpack.securitySolution.packagerTaskInterval + xpack.securitySolution.prebuiltRulesPackageVersion xpack.spaces.maxSpaces xpack.task_manager.max_attempts xpack.task_manager.max_poll_inactivity_cycles diff --git a/src/dev/build/tasks/patch_native_modules_task.ts b/src/dev/build/tasks/patch_native_modules_task.ts index 1c1bebfa86c0e..596b94933385e 100644 --- a/src/dev/build/tasks/patch_native_modules_task.ts +++ b/src/dev/build/tasks/patch_native_modules_task.ts @@ -41,50 +41,50 @@ interface Package { const packages: Package[] = [ { name: 're2', - version: '1.17.4', + version: '1.17.7', destinationPath: 'node_modules/re2/build/Release/re2.node', extractMethod: 'gunzip', archives: { 'darwin-x64': { - url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.4/darwin-x64-93.gz', - sha256: '9558c5cb39622e9b3653203e772b129d6c634e7dbd7af1b244352fc1d704601f', + url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.7/darwin-x64-108.gz', + sha256: '4ed378c5a7fe6134b717afe7642254aff1ed7a881cbcaa53a012ac3efab49f99', }, 'linux-x64': { - url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.4/linux-x64-93.gz', - sha256: '4d06747b266c75b6f7ced93977692c0586ce6a52924cabb569bd966378941aa1', + url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.7/linux-x64-108.gz', + sha256: '197a617ca2965f220848561afed71ff6df653f6d79910cf38e866c84ab38a236', }, // ARM builds are currently done manually as Github Actions used in upstream project // do not natively support an ARM target. - // From a AWS Graviton instance running Ubuntu: - // * install build-essential package + // From an AWS Graviton instance running Ubuntu or a GCE T2A instance running Debian: + // * install build-essential package: `sudo apt-get update` + `sudo apt install build-essential` // * install nvm and the node version used by the Kibana repository - // * `npm install re2@1.17.4` + // * `npm install re2@1.17.7` // * re2 will build itself on install - // * `cp node_modules/re2/build/Release/re2.node > linux-arm64-$(node -e "console.log(process.versions.modules)") + // * `cp node_modules/re2/build/Release/re2.node linux-arm64-$(node -e "console.log(process.versions.modules)")` // * `gzip linux-arm64-*` // * capture the sha256 with: `shasum -a 256 linux-arm64-*` - // * upload the `linux-arm64-*.gz` artifact to the `yarn-prebuilt-assets` bucket in GCS using the correct version number + // * upload the `linux-arm64-*.gz` artifact to the `yarn-prebuilt-artifacts` bucket in GCS using the correct version number 'linux-arm64': { - url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.4/linux-arm64-93.gz', - sha256: '25409584f76f3d6ed85463d84adf094eb6e256ed1cb0b754b95bcbda6691fc26', + url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.7/linux-arm64-108.gz', + sha256: 'a690087a1a1fd9887aac1abdab68d1992600e218be10783da6d3381cca950c1a', }, // A similar process is necessary for building on ARM macs: // * bootstrap and re2 will build itself on install - // * `cp node_modules/re2/build/Release/re2.node > darwin-arm64-$(node -e "console.log(process.versions.modules)") + // * `cp node_modules/re2/build/Release/re2.node darwin-arm64-$(node -e "console.log(process.versions.modules)")` // * `gzip darwin-arm64-*` // * capture the sha256 with: `shasum -a 256 darwin-arm64-*` - // * upload the `darwin-arm64-*.gz` artifact to the `yarn-prebuilt-assets` bucket in GCS using the correct version number + // * upload the `darwin-arm64-*.gz` artifact to the `yarn-prebuilt-artifacts` bucket in GCS using the correct version number 'darwin-arm64': { - url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.4/darwin-arm64-93.gz', - sha256: 'd4b708749ddef1c87019f6b80e051ed0c29ccd1de34f233c47d8dcaddf803872', + url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.7/darwin-arm64-108.gz', + sha256: '42afc32137ff5c5bebae5d68347a9786906748c2f28e06194d8950707f2ae90e', }, 'win32-x64': { - url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.4/win32-x64-93.gz', - sha256: '0320d0c0385432944c6fb3c8c8fcd78d440ce5626f7618f9ec71d88e44820674', + url: 'https://us-central1-elastic-kibana-184716.cloudfunctions.net/kibana-ci-proxy-cache/node-re2/uhop/node-re2/releases/download/1.17.7/win32-x64-108.gz', + sha256: 'ff72fe02de652262659c8e17e44a932f3c873362233756b40d1a97538d05de92', }, }, }, diff --git a/src/dev/license_checker/config.ts b/src/dev/license_checker/config.ts index e1f0a5dcab5fa..7fba321d968b9 100644 --- a/src/dev/license_checker/config.ts +++ b/src/dev/license_checker/config.ts @@ -84,6 +84,6 @@ export const LICENSE_OVERRIDES = { 'jsts@1.6.2': ['Eclipse Distribution License - v 1.0'], // cf. https://github.com/bjornharrtell/jsts '@mapbox/jsonlint-lines-primitives@2.0.2': ['MIT'], // license in readme https://github.com/tmcw/jsonlint '@elastic/ems-client@8.3.3': ['Elastic License 2.0'], - '@elastic/eui@72.2.0': ['SSPL-1.0 OR Elastic License 2.0'], + '@elastic/eui@73.0.0': ['SSPL-1.0 OR Elastic License 2.0'], 'language-subtag-registry@0.3.21': ['CC-BY-4.0'], // retired ODC‑By license https://github.com/mattcg/language-subtag-registry }; diff --git a/src/dev/storybook/aliases.ts b/src/dev/storybook/aliases.ts index 05ae1c3048d17..9e2ba93dc4229 100644 --- a/src/dev/storybook/aliases.ts +++ b/src/dev/storybook/aliases.ts @@ -10,6 +10,8 @@ export const storybookAliases = { apm: 'x-pack/plugins/apm/.storybook', canvas: 'x-pack/plugins/canvas/storybook', + cases: 'packages/kbn-cases-components/.storybook', + cell_actions: 'packages/kbn-cell-actions/.storybook', ci_composite: '.ci/.storybook', cloud_chat: 'x-pack/plugins/cloud_integrations/cloud_chat/.storybook', coloring: 'packages/kbn-coloring/.storybook', diff --git a/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.test.ts b/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.test.ts index 07646450a43a0..200e91a52f363 100644 --- a/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.test.ts +++ b/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.test.ts @@ -6,14 +6,16 @@ * Side Public License, v 1. */ import { Datatable, DatatableColumn } from '@kbn/expressions-plugin/public'; -import { getFilterClickData, getFilterEventData } from './filter_helpers'; -import { createMockBucketColumns, createMockVisData } from '../mocks'; +import { fieldFormatsMock } from '@kbn/field-formats-plugin/common/mocks'; +import { getFilterClickData, getFilterEventData, getFilterPopoverTitle } from './filter_helpers'; +import { createMockBucketColumns, createMockVisData, createMockPieParams } from '../mocks'; import { consolidateMetricColumns } from '../../common/utils'; import { LayerValue } from '@elastic/charts'; import faker from 'faker'; const bucketColumns = createMockBucketColumns(); const visData = createMockVisData(); +const visParams = createMockPieParams(); describe('getFilterClickData', () => { it('returns the correct filter data for the specific layer', () => { @@ -264,3 +266,31 @@ describe('getFilterEventData', () => { expect(data[0].column).toEqual(0); }); }); + +describe('getFilterPopoverTitle', () => { + it('returns the series key if no buckets', () => { + const series = { + key: 'Kibana Airlines', + specId: 'pie', + }; + const newVisParams = { + ...visParams, + buckets: [], + }; + const defaultFormatter = jest.fn((...args) => fieldFormatsMock.deserialize(...args)); + + const title = getFilterPopoverTitle(newVisParams, visData, 0, defaultFormatter, series.key); + expect(title).toBe('Kibana Airlines'); + }); + + it('calls the formatter if buckets given', () => { + const series = { + key: '0', + specId: 'pie', + }; + const defaultFormatter = jest.fn((...args) => fieldFormatsMock.deserialize(...args)); + + getFilterPopoverTitle(visParams, visData, 1, defaultFormatter, series.key); + expect(defaultFormatter).toHaveBeenCalled(); + }); +}); diff --git a/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.ts b/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.ts index 4be6f2564e00d..9e317e6d48505 100644 --- a/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.ts +++ b/src/plugins/chart_expressions/expression_partition_vis/public/utils/filter_helpers.ts @@ -10,8 +10,9 @@ import { LayerValue, SeriesIdentifier } from '@elastic/charts'; import { Datatable, DatatableColumn } from '@kbn/expressions-plugin/public'; import { DataPublicPluginStart } from '@kbn/data-plugin/public'; import { ValueClickContext } from '@kbn/embeddable-plugin/public'; -import type { FieldFormat } from '@kbn/field-formats-plugin/common'; -import { BucketColumns } from '../../common/types'; +import { getFormatByAccessor } from '@kbn/visualizations-plugin/common/utils'; +import type { FieldFormat, FormatFactory } from '@kbn/field-formats-plugin/common'; +import { BucketColumns, PartitionVisParams } from '../../common/types'; import { FilterEvent } from '../types'; export const canFilter = async ( @@ -129,3 +130,20 @@ export const getFilterEventData = ( export const getSeriesValueColumnIndex = (value: string, visData: Datatable): number => { return visData.columns.findIndex(({ id }) => !!visData.rows.find((r) => r[id] === value)); }; + +export const getFilterPopoverTitle = ( + visParams: PartitionVisParams, + visData: Datatable, + columnIndex: number, + formatter: FormatFactory, + seriesKey: string +) => { + let formattedTitle = ''; + if (visParams.dimensions.buckets) { + const accessor = visParams.dimensions.buckets[columnIndex]; + formattedTitle = accessor + ? formatter(getFormatByAccessor(accessor, visData.columns)).convert(seriesKey) + : ''; + } + return formattedTitle || seriesKey; +}; diff --git a/src/plugins/chart_expressions/expression_partition_vis/public/utils/get_legend_actions.tsx b/src/plugins/chart_expressions/expression_partition_vis/public/utils/get_legend_actions.tsx index 9762b446bd7af..9ef6fbb13d50d 100644 --- a/src/plugins/chart_expressions/expression_partition_vis/public/utils/get_legend_actions.tsx +++ b/src/plugins/chart_expressions/expression_partition_vis/public/utils/get_legend_actions.tsx @@ -13,11 +13,10 @@ import { EuiContextMenuPanelDescriptor, EuiIcon, EuiPopover, EuiContextMenu } fr import { LegendAction, SeriesIdentifier, useLegendAction } from '@elastic/charts'; import { DataPublicPluginStart } from '@kbn/data-plugin/public'; import { Datatable } from '@kbn/expressions-plugin/public'; -import { getFormatByAccessor, getAccessor } from '@kbn/visualizations-plugin/common/utils'; import { FieldFormatsStart } from '@kbn/field-formats-plugin/public'; import { PartitionVisParams } from '../../common/types'; import { ColumnCellValueActions, FilterEvent } from '../types'; -import { getSeriesValueColumnIndex } from './filter_helpers'; +import { getSeriesValueColumnIndex, getFilterPopoverTitle } from './filter_helpers'; export const getLegendActions = ( canFilter: ( @@ -50,17 +49,13 @@ export const getLegendActions = ( return null; } - let formattedTitle = ''; - if (visParams.dimensions.buckets) { - const accessor = visParams.dimensions.buckets.find( - (bucket) => getAccessor(bucket) === columnIndex - ); - formattedTitle = - formatter - .deserialize(accessor ? getFormatByAccessor(accessor, visData.columns) : undefined) - .convert(pieSeries.key) ?? ''; - } - const title = formattedTitle || pieSeries.key; + const title = getFilterPopoverTitle( + visParams, + visData, + columnIndex, + formatter.deserialize, + pieSeries.key + ); const panelItems: EuiContextMenuPanelDescriptor['items'] = []; diff --git a/src/plugins/console/common/constants/variables.ts b/src/plugins/console/common/constants/variables.ts index 1554f118c264b..e3b2757121208 100644 --- a/src/plugins/console/common/constants/variables.ts +++ b/src/plugins/console/common/constants/variables.ts @@ -6,9 +6,9 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export const DEFAULT_VARIABLES = [ - { id: uuid.v4(), name: 'exampleVariable1', value: '_search' }, - { id: uuid.v4(), name: 'exampleVariable2', value: 'match_all' }, + { id: uuidv4(), name: 'exampleVariable1', value: '_search' }, + { id: uuidv4(), name: 'exampleVariable2', value: 'match_all' }, ]; diff --git a/src/plugins/console/public/application/components/variables/utils.ts b/src/plugins/console/public/application/components/variables/utils.ts index 9507e69644dd3..852498b92da98 100644 --- a/src/plugins/console/public/application/components/variables/utils.ts +++ b/src/plugins/console/public/application/components/variables/utils.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { DevToolsVariable } from './variables_flyout'; export const editVariable = ( @@ -33,7 +33,7 @@ export const deleteVariable = (variables: DevToolsVariable[], id: string) => { }; export const generateEmptyVariableField = (): DevToolsVariable => ({ - id: uuid.v4(), + id: uuidv4(), name: '', value: '', }); diff --git a/src/plugins/console/public/lib/local_storage_object_client/local_storage_object_client.ts b/src/plugins/console/public/lib/local_storage_object_client/local_storage_object_client.ts index 8ea5f9ed731d1..9cf8f39560b9a 100644 --- a/src/plugins/console/public/lib/local_storage_object_client/local_storage_object_client.ts +++ b/src/plugins/console/public/lib/local_storage_object_client/local_storage_object_client.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ObjectStorage, IdObject } from '../../../common/types'; import { Storage } from '../../services'; @@ -18,7 +18,7 @@ export class LocalObjectStorage implements ObjectStorage } async create(obj: Omit): Promise { - const id = uuid.v4(); + const id = uuidv4(); const newObj = { id, ...obj } as O; this.client.set(`${this.prefix}_${id}`, newObj); return newObj; diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.delete_transform.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.delete_transform.json index 48df0c5df1548..df821d3c2fcca 100644 --- a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.delete_transform.json +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.delete_transform.json @@ -1,7 +1,8 @@ { "transform.delete_transform": { "url_params": { - "force": "__flag__" + "force": "__flag__", + "timeout": "" }, "methods": [ "DELETE" diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.get_transform_stats.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.get_transform_stats.json index 445de6ffc5101..75f6f7286d2c2 100644 --- a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.get_transform_stats.json +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.get_transform_stats.json @@ -3,6 +3,7 @@ "url_params": { "from": "", "size": "", + "timeout": "", "allow_no_match": "__flag__" }, "methods": [ diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.preview_transform.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.preview_transform.json index 2e7b48f8528f6..a5c95a88392b4 100644 --- a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.preview_transform.json +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.preview_transform.json @@ -1,9 +1,14 @@ { "transform.preview_transform": { + "url_params": { + "timeout": "" + }, "methods": [ + "GET", "POST" ], "patterns": [ + "_transform/{transform_id}/_preview", "_transform/_preview" ], "documentation": "https://www.elastic.co/guide/en/elasticsearch/reference/current/preview-transform.html" diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.put_transform.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.put_transform.json index 00658134594e7..7833ce27d6788 100644 --- a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.put_transform.json +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.put_transform.json @@ -1,7 +1,8 @@ { "transform.put_transform": { "url_params": { - "defer_validation": "__flag__" + "defer_validation": "__flag__", + "timeout": "" }, "methods": [ "PUT" diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.reset_transform.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.reset_transform.json new file mode 100644 index 0000000000000..6770d47b22007 --- /dev/null +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.reset_transform.json @@ -0,0 +1,15 @@ +{ + "transform.reset_transform": { + "url_params": { + "force": "__flag__", + "timeout": "" + }, + "methods": [ + "POST" + ], + "patterns": [ + "_transform/{transform_id}/_reset" + ], + "documentation": "https://www.elastic.co/guide/en/elasticsearch/reference/current/reset-transform.html" + } +} diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.update_transform.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.update_transform.json index 307f31b1d706b..46bc351aa1956 100644 --- a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.update_transform.json +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.update_transform.json @@ -1,7 +1,8 @@ { "transform.update_transform": { "url_params": { - "defer_validation": "__flag__" + "defer_validation": "__flag__", + "timeout": "" }, "methods": [ "POST" diff --git a/src/plugins/console/server/lib/spec_definitions/json/generated/transform.upgrade_transforms.json b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.upgrade_transforms.json new file mode 100644 index 0000000000000..01381b30d35ea --- /dev/null +++ b/src/plugins/console/server/lib/spec_definitions/json/generated/transform.upgrade_transforms.json @@ -0,0 +1,15 @@ +{ + "transform.upgrade_transforms": { + "url_params": { + "dry_run": "__flag__", + "timeout": "" + }, + "methods": [ + "POST" + ], + "patterns": [ + "_transform/_upgrade" + ], + "documentation": "https://www.elastic.co/guide/en/elasticsearch/reference/current/upgrade-transforms.html" + } +} diff --git a/src/plugins/controls/common/options_list/types.ts b/src/plugins/controls/common/options_list/types.ts index eb1f7b886d427..8835c7f5767f6 100644 --- a/src/plugins/controls/common/options_list/types.ts +++ b/src/plugins/controls/common/options_list/types.ts @@ -40,6 +40,7 @@ export interface OptionsListSuggestions { * The Options list response is returned from the serverside Options List route. */ export interface OptionsListResponse { + rejected: boolean; suggestions: OptionsListSuggestions; totalCardinality: number; invalidSelections?: string[]; diff --git a/src/plugins/controls/public/__stories__/controls.stories.tsx b/src/plugins/controls/public/__stories__/controls.stories.tsx index 02a13125ba49c..6b1f97e39ed7e 100644 --- a/src/plugins/controls/public/__stories__/controls.stories.tsx +++ b/src/plugins/controls/public/__stories__/controls.stories.tsx @@ -9,7 +9,7 @@ import { EuiFlexGroup, EuiFlexItem, EuiSwitch, EuiTextAlign } from '@elastic/eui'; import React, { useEffect, useMemo, useState, useCallback, FC } from 'react'; import useEffectOnce from 'react-use/lib/useEffectOnce'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getFlightOptionsAsync, @@ -61,6 +61,7 @@ const storybookStubOptionsListRequest = async ( {} ), totalCardinality: 100, + rejected: false, }), 120 ) @@ -97,7 +98,7 @@ export const ControlGroupStoryComponent: FC<{ controlStyle: 'oneLine', chainingSystem: 'NONE', // a chaining system doesn't make sense in storybook since the controls aren't backed by elasticsearch panels: panels ?? {}, - id: uuid.v4(), + id: uuidv4(), viewMode, }); diff --git a/src/plugins/controls/public/control_group/control_group_input_builder.ts b/src/plugins/controls/public/control_group/control_group_input_builder.ts index a128025d52548..e340294cb2b15 100644 --- a/src/plugins/controls/public/control_group/control_group_input_builder.ts +++ b/src/plugins/controls/public/control_group/control_group_input_builder.ts @@ -7,7 +7,7 @@ */ import { i18n } from '@kbn/i18n'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ControlPanelState, OptionsListEmbeddableInput } from '../../common'; import { DEFAULT_CONTROL_GROW, @@ -89,7 +89,7 @@ export async function getDataControlPanelState( type: await getCompatibleControlType({ dataViewId, fieldName }), ...getPanelState(input, controlProps), explicitInput: { - id: controlId ? controlId : uuid.v4(), + id: controlId ? controlId : uuidv4(), dataViewId, fieldName, title: title ?? fieldName, @@ -106,7 +106,7 @@ export function getOptionsListPanelState( type: OPTIONS_LIST_CONTROL, ...getPanelState(input, controlProps), explicitInput: { - id: controlId ? controlId : uuid.v4(), + id: controlId ? controlId : uuidv4(), dataViewId, fieldName, title: title ?? fieldName, @@ -124,7 +124,7 @@ export function getRangeSliderPanelState( type: RANGE_SLIDER_CONTROL, ...getPanelState(input, controlProps), explicitInput: { - id: controlId ? controlId : uuid.v4(), + id: controlId ? controlId : uuidv4(), dataViewId, fieldName, title: title ?? fieldName, @@ -140,7 +140,7 @@ export function getTimeSliderPanelState(input: Partial) { grow: true, width: 'large', explicitInput: { - id: uuid.v4(), + id: uuidv4(), title: i18n.translate('controls.controlGroup.timeSlider.title', { defaultMessage: 'Time slider', }), diff --git a/src/plugins/controls/public/control_group/control_group_renderer.tsx b/src/plugins/controls/public/control_group/control_group_renderer.tsx index 9611c5a3c6c47..471e2db1e2dac 100644 --- a/src/plugins/controls/public/control_group/control_group_renderer.tsx +++ b/src/plugins/controls/public/control_group/control_group_renderer.tsx @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isEqual } from 'lodash'; import useLifecycles from 'react-use/lib/useLifecycles'; import React, { useEffect, useMemo, useRef, useState } from 'react'; @@ -48,7 +48,7 @@ export const ControlGroupRenderer = ({ }: ControlGroupRendererProps) => { const controlGroupRef = useRef(null); const [controlGroup, setControlGroup] = useState(); - const id = useMemo(() => uuid.v4(), []); + const id = useMemo(() => uuidv4(), []); /** * Use Lifecycles to load initial control group container */ diff --git a/src/plugins/controls/public/options_list/components/options_list.scss b/src/plugins/controls/public/options_list/components/options_list.scss index c737dd6dc0215..e88208ee4c623 100644 --- a/src/plugins/controls/public/options_list/components/options_list.scss +++ b/src/plugins/controls/public/options_list/components/options_list.scss @@ -7,15 +7,6 @@ height: 100%; } -.optionsList__items { - @include euiScrollBar; - - overflow-y: auto; - max-height: $euiSize * 30; - width: $euiSize * 25; - max-width: 100%; -} - .optionsList__actions { padding: $euiSizeS; border-bottom: $euiBorderThin; diff --git a/src/plugins/controls/public/options_list/components/options_list_control.tsx b/src/plugins/controls/public/options_list/components/options_list_control.tsx index 43742a817e3ec..3035eada20caf 100644 --- a/src/plugins/controls/public/options_list/components/options_list_control.tsx +++ b/src/plugins/controls/public/options_list/components/options_list_control.tsx @@ -43,18 +43,22 @@ export const OptionsListControl = ({ typeaheadSubject }: { typeaheadSubject: Sub const existsSelected = select((state) => state.explicitInput.existsSelected); const controlStyle = select((state) => state.explicitInput.controlStyle); const singleSelect = select((state) => state.explicitInput.singleSelect); + const fieldName = select((state) => state.explicitInput.fieldName); const exclude = select((state) => state.explicitInput.exclude); const id = select((state) => state.explicitInput.id); const loading = select((state) => state.output.loading); // debounce loading state so loading doesn't flash when user types - const [buttonLoading, setButtonLoading] = useState(true); - const debounceSetButtonLoading = useMemo( - () => debounce((latestLoading: boolean) => setButtonLoading(latestLoading), 100), + const [debouncedLoading, setDebouncedLoading] = useState(true); + const debounceSetLoading = useMemo( + () => + debounce((latestLoading: boolean) => { + setDebouncedLoading(latestLoading); + }, 100), [] ); - useEffect(() => debounceSetButtonLoading(loading ?? false), [loading, debounceSetButtonLoading]); + useEffect(() => debounceSetLoading(loading ?? false), [loading, debounceSetLoading]); // remove all other selections if this control is single select useEffect(() => { @@ -111,7 +115,7 @@ export const OptionsListControl = ({ typeaheadSubject }: { typeaheadSubject: Sub
    setIsPopoverOpen(false)} anchorClassName="optionsList__anchorOverride" - aria-labelledby={`control-popover-${id}`} + aria-label={OptionsListStrings.popover.getAriaLabel(fieldName)} > - + ); diff --git a/src/plugins/controls/public/options_list/components/options_list_popover.test.tsx b/src/plugins/controls/public/options_list/components/options_list_popover.test.tsx index b1315be51ae1e..acb5d24d80659 100644 --- a/src/plugins/controls/public/options_list/components/options_list_popover.test.tsx +++ b/src/plugins/controls/public/options_list/components/options_list_popover.test.tsx @@ -21,6 +21,7 @@ import { ControlOutput, OptionsListEmbeddableInput } from '../..'; describe('Options list popover', () => { const defaultProps = { width: 500, + isLoading: false, updateSearchString: jest.fn(), }; @@ -56,13 +57,13 @@ describe('Options list popover', () => { test('available options list width responds to container size', async () => { let popover = await mountComponent({ popoverProps: { width: 301 } }); - let availableOptionsDiv = findTestSubject(popover, 'optionsList-control-available-options'); - expect(availableOptionsDiv.getDOMNode().getAttribute('style')).toBe('width: 301px;'); + let popoverDiv = findTestSubject(popover, 'optionsList-control-popover'); + expect(popoverDiv.getDOMNode().getAttribute('style')).toBe('width: 301px;'); // the div cannot be smaller than 301 pixels wide popover = await mountComponent({ popoverProps: { width: 300 } }); - availableOptionsDiv = findTestSubject(popover, 'optionsList-control-available-options'); - expect(availableOptionsDiv.getDOMNode().getAttribute('style')).toBe(null); + popoverDiv = findTestSubject(popover, 'optionsList-control-available-options'); + expect(popoverDiv.getDOMNode().getAttribute('style')).toBe(null); }); test('no available options', async () => { @@ -92,13 +93,12 @@ describe('Options list popover', () => { explicitInput: { selectedOptions: selections }, }); clickShowOnlySelections(popover); - const availableOptionsDiv = findTestSubject(popover, 'optionsList-control-available-options'); - availableOptionsDiv - .childAt(0) - .children() - .forEach((child, i) => { - expect(child.text()).toBe(selections[i]); - }); + const availableOptions = popover.find( + '[data-test-subj="optionsList-control-available-options"] ul' + ); + availableOptions.children().forEach((child, i) => { + expect(child.text()).toBe(`${selections[i]} - Checked option.`); + }); }); test('disable search and sort when show only selected toggle is true', async () => { @@ -132,11 +132,18 @@ describe('Options list popover', () => { }, }); const validSelection = findTestSubject(popover, 'optionsList-control-selection-bark'); - expect(validSelection.text()).toEqual('bark75'); + expect(validSelection.find('.euiSelectableListItem__text').text()).toEqual( + 'bark - Checked option.' + ); + expect( + validSelection.find('div[data-test-subj="optionsList-document-count-badge"]').text().trim() + ).toEqual('75'); const title = findTestSubject(popover, 'optionList__ignoredSelectionLabel').text(); expect(title).toEqual('Ignored selection'); const invalidSelection = findTestSubject(popover, 'optionsList-control-ignored-selection-woof'); - expect(invalidSelection.text()).toEqual('woof'); + expect(invalidSelection.find('.euiSelectableListItem__text').text()).toEqual( + 'woof - Checked option.' + ); expect(invalidSelection.hasClass('optionsList__selectionInvalid')).toBe(true); }); @@ -221,8 +228,10 @@ describe('Options list popover', () => { explicitInput: { existsSelected: true }, }); clickShowOnlySelections(popover); - const availableOptionsDiv = findTestSubject(popover, 'optionsList-control-available-options'); - expect(availableOptionsDiv.children().at(0).text()).toBe('Exists'); + const availableOptions = popover.find( + '[data-test-subj="optionsList-control-available-options"] ul' + ); + expect(availableOptions.text()).toBe('Exists - Checked option.'); }); test('when sorting suggestions, show both sorting types for keyword field', async () => { diff --git a/src/plugins/controls/public/options_list/components/options_list_popover.tsx b/src/plugins/controls/public/options_list/components/options_list_popover.tsx index 6ad39e0b3dbd9..70353524068cd 100644 --- a/src/plugins/controls/public/options_list/components/options_list_popover.tsx +++ b/src/plugins/controls/public/options_list/components/options_list_popover.tsx @@ -22,10 +22,15 @@ import { OptionsListPopoverInvalidSelections } from './options_list_popover_inva export interface OptionsListPopoverProps { width: number; + isLoading: boolean; updateSearchString: (newSearchString: string) => void; } -export const OptionsListPopover = ({ width, updateSearchString }: OptionsListPopoverProps) => { +export const OptionsListPopover = ({ + width, + isLoading, + updateSearchString, +}: OptionsListPopoverProps) => { // Redux embeddable container Context const { useEmbeddableSelector: select } = useReduxEmbeddableContext< OptionsListReduxState, @@ -45,9 +50,10 @@ export const OptionsListPopover = ({ width, updateSearchString }: OptionsListPop const [showOnlySelected, setShowOnlySelected] = useState(false); return ( - 300 ? width : undefined }} + data-test-subj={`optionsList-control-popover`} aria-label={OptionsListStrings.popover.getAriaLabel(fieldName)} > {title} @@ -59,17 +65,15 @@ export const OptionsListPopover = ({ width, updateSearchString }: OptionsListPop /> )}
    300 ? width : undefined }} data-test-subj={`optionsList-control-available-options`} - data-option-count={Object.keys(availableOptions ?? {}).length} + data-option-count={isLoading ? 0 : Object.keys(availableOptions ?? {}).length} > - + {!showOnlySelected && invalidSelections && !isEmpty(invalidSelections) && ( )}
    {!hideExclude && } -
    +
    ); }; diff --git a/src/plugins/controls/public/options_list/components/options_list_popover_empty_message.tsx b/src/plugins/controls/public/options_list/components/options_list_popover_empty_message.tsx new file mode 100644 index 0000000000000..69c819a3caca2 --- /dev/null +++ b/src/plugins/controls/public/options_list/components/options_list_popover_empty_message.tsx @@ -0,0 +1,35 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { EuiIcon, EuiSpacer } from '@elastic/eui'; + +import { OptionsListStrings } from './options_list_strings'; + +export const OptionsListPopoverEmptyMessage = ({ + showOnlySelected, +}: { + showOnlySelected: boolean; +}) => { + return ( + + + + + {showOnlySelected + ? OptionsListStrings.popover.getSelectionsEmptyMessage() + : OptionsListStrings.popover.getEmptyMessage()} + + + ); +}; diff --git a/src/plugins/controls/public/options_list/components/options_list_popover_invalid_selections.tsx b/src/plugins/controls/public/options_list/components/options_list_popover_invalid_selections.tsx index 01c9f14363a4c..424ae37da4bcb 100644 --- a/src/plugins/controls/public/options_list/components/options_list_popover_invalid_selections.tsx +++ b/src/plugins/controls/public/options_list/components/options_list_popover_invalid_selections.tsx @@ -6,9 +6,15 @@ * Side Public License, v 1. */ -import React from 'react'; +import React, { useEffect, useState } from 'react'; -import { EuiFilterSelectItem, EuiSpacer, EuiTitle } from '@elastic/eui'; +import { + EuiSelectableOption, + EuiSelectable, + EuiSpacer, + EuiTitle, + EuiScreenReaderOnly, +} from '@elastic/eui'; import { useReduxEmbeddableContext } from '@kbn/presentation-util-plugin/public'; import { OptionsListReduxState } from '../types'; @@ -26,6 +32,31 @@ export const OptionsListPopoverInvalidSelections = () => { // Select current state from Redux using multiple selectors to avoid rerenders. const invalidSelections = select((state) => state.componentState.invalidSelections); + const fieldName = select((state) => state.explicitInput.fieldName); + + const [selectableOptions, setSelectableOptions] = useState([]); // will be set in following useEffect + useEffect(() => { + /* This useEffect makes selectableOptions responsive to unchecking options */ + const options: EuiSelectableOption[] = (invalidSelections ?? []).map((key) => { + return { + key, + label: key, + checked: 'on', + className: 'optionsList__selectionInvalid', + 'data-test-subj': `optionsList-control-ignored-selection-${key}`, + prepend: ( + +
    + {OptionsListStrings.popover.getInvalidSelectionScreenReaderText()} + {'" "'} {/* Adds a pause for the screen reader */} +
    +
    + ), + }; + }); + setSelectableOptions(options); + }, [invalidSelections]); + return ( <> @@ -40,18 +71,20 @@ export const OptionsListPopoverInvalidSelections = () => { )} - {invalidSelections?.map((ignoredSelection, index) => ( - dispatch(deselectOption(ignoredSelection))} - aria-label={OptionsListStrings.popover.getInvalidSelectionAriaLabel(ignoredSelection)} - > - {`${ignoredSelection}`} - - ))} + { + setSelectableOptions(newSuggestions); + dispatch(deselectOption(changedOption.label)); + }} + > + {(list) => list} + ); }; diff --git a/src/plugins/controls/public/options_list/components/options_list_popover_suggestion_badge.tsx b/src/plugins/controls/public/options_list/components/options_list_popover_suggestion_badge.tsx new file mode 100644 index 0000000000000..6c50d92ba81b5 --- /dev/null +++ b/src/plugins/controls/public/options_list/components/options_list_popover_suggestion_badge.tsx @@ -0,0 +1,46 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; + +import { css } from '@emotion/react'; +import { EuiScreenReaderOnly, EuiText, EuiToolTip, useEuiTheme } from '@elastic/eui'; + +import { OptionsListStrings } from './options_list_strings'; + +export const OptionsListPopoverSuggestionBadge = ({ documentCount }: { documentCount: number }) => { + const { euiTheme } = useEuiTheme(); + + return ( + <> + + + {`${documentCount.toLocaleString()}`} + + + +
    + {'" "'} {/* Adds a pause for the screen reader */} + {OptionsListStrings.popover.getDocumentCountScreenReaderText(documentCount)} +
    +
    + + ); +}; diff --git a/src/plugins/controls/public/options_list/components/options_list_popover_suggestions.tsx b/src/plugins/controls/public/options_list/components/options_list_popover_suggestions.tsx index 7983043ae1d8a..8bd8e361e7081 100644 --- a/src/plugins/controls/public/options_list/components/options_list_popover_suggestions.tsx +++ b/src/plugins/controls/public/options_list/components/options_list_popover_suggestions.tsx @@ -6,30 +6,25 @@ * Side Public License, v 1. */ -import React, { useMemo } from 'react'; +import React, { useEffect, useMemo, useState } from 'react'; -import { - EuiFilterSelectItem, - EuiFlexGroup, - EuiFlexItem, - EuiToolTip, - EuiSpacer, - EuiIcon, - useEuiTheme, - EuiText, -} from '@elastic/eui'; -import { css } from '@emotion/react'; +import { EuiLoadingSpinner, EuiSelectable, EuiSpacer } from '@elastic/eui'; import { useReduxEmbeddableContext } from '@kbn/presentation-util-plugin/public'; +import { EuiSelectableOption } from '@elastic/eui/src/components/selectable/selectable_option'; import { OptionsListReduxState } from '../types'; import { OptionsListStrings } from './options_list_strings'; import { optionsListReducers } from '../options_list_reducers'; +import { OptionsListPopoverEmptyMessage } from './options_list_popover_empty_message'; +import { OptionsListPopoverSuggestionBadge } from './options_list_popover_suggestion_badge'; interface OptionsListPopoverSuggestionsProps { + isLoading: boolean; showOnlySelected: boolean; } export const OptionsListPopoverSuggestions = ({ + isLoading, showOnlySelected, }: OptionsListPopoverSuggestionsProps) => { // Redux embeddable container Context @@ -39,7 +34,6 @@ export const OptionsListPopoverSuggestions = ({ actions: { replaceSelection, deselectOption, selectOption, selectExists }, } = useReduxEmbeddableContext(); const dispatch = useEmbeddableDispatch(); - const { euiTheme } = useEuiTheme(); // Select current state from Redux using multiple selectors to avoid rerenders. const invalidSelections = select((state) => state.componentState.invalidSelections); @@ -49,130 +43,97 @@ export const OptionsListPopoverSuggestions = ({ const existsSelected = select((state) => state.explicitInput.existsSelected); const singleSelect = select((state) => state.explicitInput.singleSelect); const hideExists = select((state) => state.explicitInput.hideExists); + const fieldName = select((state) => state.explicitInput.fieldName); - const loading = select((state) => state.output.loading); // track selectedOptions and invalidSelections in sets for more efficient lookup const selectedOptionsSet = useMemo(() => new Set(selectedOptions), [selectedOptions]); const invalidSelectionsSet = useMemo( () => new Set(invalidSelections), [invalidSelections] ); - const suggestions = showOnlySelected ? selectedOptions : Object.keys(availableOptions ?? {}); - if ( - !loading && - (!suggestions || suggestions.length === 0) && - !(showOnlySelected && existsSelected) - ) { - return ( -
    -
    - - -

    - {showOnlySelected - ? OptionsListStrings.popover.getSelectionsEmptyMessage() - : OptionsListStrings.popover.getEmptyMessage()} -

    -
    -
    - ); - } + const suggestions = useMemo(() => { + return showOnlySelected ? selectedOptions : Object.keys(availableOptions ?? {}); + }, [availableOptions, selectedOptions, showOnlySelected]); + + const existsSelectableOption = useMemo(() => { + if (hideExists || (!existsSelected && (showOnlySelected || suggestions?.length === 0))) return; + + return { + key: 'exists-option', + checked: existsSelected ? 'on' : undefined, + label: OptionsListStrings.controlAndPopover.getExists(), + className: 'optionsList__existsFilter', + 'data-test-subj': 'optionsList-control-selection-exists', + }; + }, [suggestions, existsSelected, showOnlySelected, hideExists]); + + const [selectableOptions, setSelectableOptions] = useState([]); // will be set in following useEffect + useEffect(() => { + /* This useEffect makes selectableOptions responsive to search, show only selected, and clear selections */ + const options: EuiSelectableOption[] = (suggestions ?? []).map((key) => { + return { + key, + label: key, + checked: selectedOptionsSet?.has(key) ? 'on' : undefined, + 'data-test-subj': `optionsList-control-selection-${key}`, + className: + showOnlySelected && invalidSelectionsSet.has(key) + ? 'optionsList__selectionInvalid' + : 'optionsList__validSuggestion', + append: + !showOnlySelected && availableOptions?.[key] ? ( + + ) : undefined, + }; + }); + const suggestionsSelectableOptions = existsSelectableOption + ? [existsSelectableOption, ...options] + : options; + setSelectableOptions(suggestionsSelectableOptions); + }, [ + suggestions, + availableOptions, + showOnlySelected, + selectedOptionsSet, + invalidSelectionsSet, + existsSelectableOption, + ]); return ( - <> - {!hideExists && !(showOnlySelected && !existsSelected) && ( - { - dispatch(selectExists(!Boolean(existsSelected))); - }} - className="optionsList__existsFilter" - > - {OptionsListStrings.controlAndPopover.getExists()} - + + + + {OptionsListStrings.popover.getLoadingMessage()} + + } + options={selectableOptions} + listProps={{ onFocusBadge: false }} + aria-label={OptionsListStrings.popover.getSuggestionsAriaLabel( + fieldName, + selectableOptions.length )} - {suggestions?.map((key: string) => ( - { - if (showOnlySelected) { - dispatch(deselectOption(key)); - return; - } - if (singleSelect) { - dispatch(replaceSelection(key)); - return; - } - if (selectedOptionsSet.has(key)) { - dispatch(deselectOption(key)); - return; - } - dispatch(selectOption(key)); - }} - className={ - showOnlySelected && invalidSelectionsSet.has(key) - ? 'optionsList__selectionInvalid' - : 'optionsList__validSuggestion' - } - aria-label={ - availableOptions?.[key] - ? OptionsListStrings.popover.getSuggestionAriaLabel( - key, - availableOptions[key].doc_count ?? 0 - ) - : key - } - > - - - {`${key}`} - - {!showOnlySelected && ( - - {availableOptions && availableOptions[key] && ( - - - {`${availableOptions[key].doc_count.toLocaleString()}`} - - - )} - - )} - - - ))} - + emptyMessage={} + onChange={(newSuggestions, _, changedOption) => { + setSelectableOptions(newSuggestions); + + const key = changedOption.key ?? changedOption.label; + // the order of these checks matters, so be careful if rearranging them + if (key === 'exists-option') { + dispatch(selectExists(!Boolean(existsSelected))); + } else if (showOnlySelected || selectedOptionsSet.has(key)) { + dispatch(deselectOption(key)); + } else if (singleSelect) { + dispatch(replaceSelection(key)); + } else { + dispatch(selectOption(key)); + } + }} + > + {(list) => list} + ); }; diff --git a/src/plugins/controls/public/options_list/components/options_list_strings.ts b/src/plugins/controls/public/options_list/components/options_list_strings.ts index a75eb7913064c..bef8a2cbc26ff 100644 --- a/src/plugins/controls/public/options_list/components/options_list_strings.ts +++ b/src/plugins/controls/public/options_list/components/options_list_strings.ts @@ -48,11 +48,15 @@ export const OptionsListStrings = { defaultMessage: 'Popover for {fieldName} control', values: { fieldName }, }), - getSuggestionAriaLabel: (key: string, documentCount: number) => + getSuggestionsAriaLabel: (fieldName: string, optionCount: number) => i18n.translate('controls.optionsList.popover.suggestionsAriaLabel', { defaultMessage: - '{key}, which appears in {documentCount} {documentCount, plural, one {document} other {documents}}.', - values: { key, documentCount }, + 'Available {optionCount, plural, one {option} other {options}} for {fieldName}', + values: { fieldName, optionCount }, + }), + getLoadingMessage: () => + i18n.translate('controls.optionsList.popover.loading', { + defaultMessage: 'Loading options', }), getEmptyMessage: () => i18n.translate('controls.optionsList.popover.empty', { @@ -80,6 +84,12 @@ export const OptionsListStrings = { 'Search {totalOptions} available {totalOptions, plural, one {option} other {options}}', values: { totalOptions }, }), + getInvalidSelectionsSectionAriaLabel: (fieldName: string, invalidSelectionCount: number) => + i18n.translate('controls.optionsList.popover.invalidSelectionsAriaLabel', { + defaultMessage: + 'Ignored {invalidSelectionCount, plural, one {selection} other {selections}} for {fieldName}', + values: { fieldName, invalidSelectionCount }, + }), getInvalidSelectionsSectionTitle: (invalidSelectionCount: number) => i18n.translate('controls.optionsList.popover.invalidSelectionsSectionTitle', { defaultMessage: @@ -92,10 +102,9 @@ export const OptionsListStrings = { '{selectedOptions} selected {selectedOptions, plural, one {option} other {options}} {selectedOptions, plural, one {is} other {are}} ignored because {selectedOptions, plural, one {it is} other {they are}} no longer in the data.', values: { selectedOptions }, }), - getInvalidSelectionAriaLabel: (option: string) => - i18n.translate('controls.optionsList.popover.invalidSelectionAriaLabel', { - defaultMessage: 'Ignored selection: {option}', - values: { option }, + getInvalidSelectionScreenReaderText: () => + i18n.translate('controls.optionsList.popover.invalidSelectionScreenReaderText', { + defaultMessage: 'Invalid selection.', }), getIncludeLabel: () => i18n.translate('controls.optionsList.popover.includeLabel', { @@ -127,6 +136,12 @@ export const OptionsListStrings = { 'This value appears in {documentCount, number} {documentCount, plural, one {document} other {documents}}', values: { documentCount }, }), + getDocumentCountScreenReaderText: (documentCount: number) => + i18n.translate('controls.optionsList.popover.documentCountScreenReaderText', { + defaultMessage: + 'Appears in {documentCount, number} {documentCount, plural, one {document} other {documents}}', + values: { documentCount }, + }), }, controlAndPopover: { getExists: (negate: number = +false) => diff --git a/src/plugins/controls/public/options_list/embeddable/options_list_embeddable.tsx b/src/plugins/controls/public/options_list/embeddable/options_list_embeddable.tsx index 1153150143f89..2f710a56c4f87 100644 --- a/src/plugins/controls/public/options_list/embeddable/options_list_embeddable.tsx +++ b/src/plugins/controls/public/options_list/embeddable/options_list_embeddable.tsx @@ -307,7 +307,7 @@ export class OptionsListEmbeddable extends Embeddable ) => { state.explicitInput.selectedOptions = [action.payload]; + if (state.explicitInput.existsSelected) state.explicitInput.existsSelected = false; }, clearSelections: (state: WritableDraft) => { if (state.explicitInput.existsSelected) state.explicitInput.existsSelected = false; diff --git a/src/plugins/controls/public/services/options_list/options_list.story.ts b/src/plugins/controls/public/services/options_list/options_list.story.ts index a44f698c93395..62686feee7495 100644 --- a/src/plugins/controls/public/services/options_list/options_list.story.ts +++ b/src/plugins/controls/public/services/options_list/options_list.story.ts @@ -20,6 +20,7 @@ let optionsListRequestMethod = async (request: OptionsListRequest, abortSignal: r({ suggestions: {}, totalCardinality: 100, + rejected: false, }), 120 ) diff --git a/src/plugins/controls/public/services/options_list/options_list_service.ts b/src/plugins/controls/public/services/options_list/options_list_service.ts index bc2934e9295a6..ab8e67666140b 100644 --- a/src/plugins/controls/public/services/options_list/options_list_service.ts +++ b/src/plugins/controls/public/services/options_list/options_list_service.ts @@ -101,7 +101,7 @@ class OptionsListService implements ControlsOptionsListService { } catch (error) { // Remove rejected results from memoize cache this.cachedOptionsListRequest.cache.delete(this.optionsListCacheResolver(request)); - return {} as OptionsListResponse; + return { rejected: true } as OptionsListResponse; } }; } diff --git a/src/plugins/controls/server/options_list/options_list_suggestions_route.ts b/src/plugins/controls/server/options_list/options_list_suggestions_route.ts index 6e2f8f769815d..0893d24ebacf0 100644 --- a/src/plugins/controls/server/options_list/options_list_suggestions_route.ts +++ b/src/plugins/controls/server/options_list/options_list_suggestions_route.ts @@ -144,6 +144,7 @@ export const setupOptionsListSuggestionsRoute = ( suggestions, totalCardinality, invalidSelections, + rejected: false, }; }; }; diff --git a/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx b/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx index 4e265187ea3ae..482553e2f002f 100644 --- a/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx +++ b/src/plugins/dashboard/public/dashboard_actions/clone_panel_action.tsx @@ -7,7 +7,7 @@ */ import _ from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObjectsStart } from '@kbn/core/public'; import { @@ -178,7 +178,7 @@ export class ClonePanelAction implements Action { type: embeddable.type, explicitInput: { ...(await embeddable.getInputAsValueType()), - id: uuid.v4(), + id: uuidv4(), title: newTitle, hidePanelTitles: panelToClone.explicitInput.hidePanelTitles, }, @@ -188,7 +188,7 @@ export class ClonePanelAction implements Action { type: embeddable.type, explicitInput: { ...panelToClone.explicitInput, - id: uuid.v4(), + id: uuidv4(), }, }; if (panelToClone.explicitInput.savedObjectId) { diff --git a/src/plugins/dashboard/public/dashboard_actions/filters_notification_action.tsx b/src/plugins/dashboard/public/dashboard_actions/filters_notification_action.tsx index 247200de71e8f..0847066e166ce 100644 --- a/src/plugins/dashboard/public/dashboard_actions/filters_notification_action.tsx +++ b/src/plugins/dashboard/public/dashboard_actions/filters_notification_action.tsx @@ -10,12 +10,10 @@ import React from 'react'; import { EditPanelAction, isFilterableEmbeddable, ViewMode } from '@kbn/embeddable-plugin/public'; import { type IEmbeddable, isErrorEmbeddable } from '@kbn/embeddable-plugin/public'; -import { KibanaThemeProvider } from '@kbn/kibana-react-plugin/public'; import { Action, IncompatibleActionError } from '@kbn/ui-actions-plugin/public'; import { createKibanaReactContext } from '@kbn/kibana-react-plugin/public'; import type { ApplicationStart } from '@kbn/core/public'; import { type AggregateQuery } from '@kbn/es-query'; -import { I18nProvider } from '@kbn/i18n-react'; import { FiltersNotificationPopover } from './filters_notification_popover'; import { dashboardFilterNotificationActionStrings } from './_dashboard_actions_strings'; @@ -60,19 +58,15 @@ export class FiltersNotificationAction implements Action - - - - - - + + + ); }; diff --git a/src/plugins/dashboard/public/dashboard_actions/library_notification_action.tsx b/src/plugins/dashboard/public/dashboard_actions/library_notification_action.tsx index 0d46aa66595ea..8f677450dca15 100644 --- a/src/plugins/dashboard/public/dashboard_actions/library_notification_action.tsx +++ b/src/plugins/dashboard/public/dashboard_actions/library_notification_action.tsx @@ -15,9 +15,7 @@ import { isReferenceOrValueEmbeddable, } from '@kbn/embeddable-plugin/public'; import { Action, IncompatibleActionError } from '@kbn/ui-actions-plugin/public'; -import { KibanaThemeProvider } from '@kbn/kibana-react-plugin/public'; -import { pluginServices } from '../services/plugin_services'; import { UnlinkFromLibraryAction } from './unlink_from_library_action'; import { LibraryNotificationPopover } from './library_notification_popover'; import { dashboardLibraryNotificationStrings } from './_dashboard_actions_strings'; @@ -33,15 +31,7 @@ export class LibraryNotificationAction implements Action { const { embeddable } = context; return ( - - - + ); }; diff --git a/src/plugins/dashboard/public/dashboard_constants.ts b/src/plugins/dashboard/public/dashboard_constants.ts index 9f8c45ad82d69..a53023c10ed84 100644 --- a/src/plugins/dashboard/public/dashboard_constants.ts +++ b/src/plugins/dashboard/public/dashboard_constants.ts @@ -44,6 +44,7 @@ export function createDashboardListingFilterUrl(filter: string | undefined) { export const DASHBOARD_LOADED_EVENT = 'dashboard_loaded'; export const SAVED_OBJECT_LOADED_TIME = 'saved_object_loaded_time'; export const SAVED_OBJECT_DELETE_TIME = 'saved_object_delete_time'; +export const SAVED_OBJECT_POST_TIME = 'saved_object_post_time'; export const DASHBOARD_UI_METRIC_ID = 'dashboard'; // ------------------------------------------------------------------ diff --git a/src/plugins/dashboard/public/dashboard_container/dashboard_container_renderer.tsx b/src/plugins/dashboard/public/dashboard_container/dashboard_container_renderer.tsx index 1d0cf7cad6a75..574e93b80871e 100644 --- a/src/plugins/dashboard/public/dashboard_container/dashboard_container_renderer.tsx +++ b/src/plugins/dashboard/public/dashboard_container/dashboard_container_renderer.tsx @@ -8,7 +8,7 @@ import './_dashboard_container.scss'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import classNames from 'classnames'; import { EuiLoadingElastic } from '@elastic/eui'; import React, { useEffect, useMemo, useRef, useState } from 'react'; @@ -57,7 +57,7 @@ export const DashboardContainerRenderer = ({ // eslint-disable-next-line react-hooks/exhaustive-deps }, [savedObjectId]); - const id = useMemo(() => uuid.v4(), []); + const id = useMemo(() => uuidv4(), []); useEffect(() => { let canceled = false; diff --git a/src/plugins/dashboard/public/dashboard_container/embeddable/api/panel_management.ts b/src/plugins/dashboard/public/dashboard_container/embeddable/api/panel_management.ts index 70e0f9df6e741..9f9357f8fbbff 100644 --- a/src/plugins/dashboard/public/dashboard_container/embeddable/api/panel_management.ts +++ b/src/plugins/dashboard/public/dashboard_container/embeddable/api/panel_management.ts @@ -12,7 +12,7 @@ import { IEmbeddable, PanelState, } from '@kbn/embeddable-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { IPanelPlacementArgs, @@ -52,7 +52,7 @@ export async function replacePanel( // replace panel can be called with generateNewId in order to totally destroy and recreate the embeddable panels = { ...this.input.panels }; delete panels[previousPanelState.explicitInput.id]; - const newId = uuid.v4(); + const newId = uuidv4(); panels[newId] = { ...previousPanelState, ...newPanelState, @@ -98,7 +98,7 @@ export function showPlaceholderUntil ); this.clearOverlays(); - showSaveModal(dashboardSaveModal, i18nContext); + showSaveModal(dashboardSaveModal); }); } diff --git a/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts b/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts index 16af08f728d67..15304119e31e9 100644 --- a/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts +++ b/src/plugins/dashboard/public/services/dashboard_saved_object/lib/load_dashboard_state_from_saved_object.ts @@ -5,7 +5,7 @@ * in compliance with, at your election, the Elastic License 2.0 or the Server * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { has } from 'lodash'; import { @@ -63,7 +63,7 @@ export const loadDashboardStateFromSavedObject = async ({ } = data; const savedObjectId = id; - const embeddableId = uuid.v4(); + const embeddableId = uuidv4(); const newDashboardState = { ...DEFAULT_DASHBOARD_INPUT, id: embeddableId }; diff --git a/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrate_to_730_panels.ts b/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrate_to_730_panels.ts index 531a0715038d5..0052604e19f66 100644 --- a/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrate_to_730_panels.ts +++ b/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrate_to_730_panels.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import semverSatisfies from 'semver/functions/satisfies'; import { i18n } from '@kbn/i18n'; @@ -114,7 +114,7 @@ function migratePre61PanelToLatest( const { columns, sort, row, col, size_x: sizeX, size_y: sizeY, ...rest } = panel; - const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuid.v4(); + const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuidv4(); return { ...rest, version, @@ -167,7 +167,7 @@ function migrate610PanelToLatest( : PANEL_HEIGHT_SCALE_FACTOR; const { columns, sort, ...rest } = panel; - const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuid.v4(); + const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuidv4(); return { ...rest, version, @@ -205,7 +205,7 @@ function migrate620PanelToLatest( : PANEL_HEIGHT_SCALE_FACTOR; const { columns, sort, ...rest } = panel; - const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuid.v4(); + const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuidv4(); return { ...rest, version, @@ -236,7 +236,7 @@ function migrate630PanelToLatest( } const { columns, sort, ...rest } = panel; - const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuid.v4(); + const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuidv4(); return { ...rest, version, @@ -251,7 +251,7 @@ function migrate640To720PanelsToLatest( panel: RawSavedDashboardPanel630, version: string ): RawSavedDashboardPanel730ToLatest { - const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuid.v4(); + const panelIndex = panel.panelIndex ? panel.panelIndex.toString() : uuidv4(); return { ...panel, version, diff --git a/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts b/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts index dcd1c2f2cb878..c92609858e32f 100644 --- a/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts +++ b/src/plugins/dashboard/server/dashboard_saved_object/migrations/migrate_to_730/migrations_730.ts @@ -53,7 +53,7 @@ export const migrations730 = (doc: DashboardDoc700To720, { log }: SavedObjectMig moveFiltersToQuery(searchSource) ); } catch (e) { - log.warning( + log.warn( `Exception @ migrations730 while trying to migrate dashboard query filters!\n` + `${e.stack}\n` + `dashboard: ${inspect(doc, false, null)}` @@ -80,7 +80,7 @@ export const migrations730 = (doc: DashboardDoc700To720, { log }: SavedObjectMig delete doc.attributes.uiStateJSON; } catch (e) { - log.warning( + log.warn( `Exception @ migrations730 while trying to migrate dashboard panels!\n` + `Error: ${e.stack}\n` + `dashboard: ${inspect(doc, false, null)}` diff --git a/src/plugins/data/common/query/filters/persistable_state.ts b/src/plugins/data/common/query/filters/persistable_state.ts index a2696723fbab7..01affb1be2641 100644 --- a/src/plugins/data/common/query/filters/persistable_state.ts +++ b/src/plugins/data/common/query/filters/persistable_state.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Filter } from '@kbn/es-query'; import { SavedObjectReference } from '@kbn/core/types'; import { MigrateFunctionsObject, VersionedState } from '@kbn/kibana-utils-plugin/common'; @@ -16,7 +16,7 @@ export const extract = (filters: Filter[]) => { const references: SavedObjectReference[] = []; const updatedFilters = filters.map((filter) => { if (filter.meta?.index) { - const id = uuid(); + const id = uuidv4(); references.push({ type: DATA_VIEW_SAVED_OBJECT_TYPE, name: id, diff --git a/src/plugins/data/public/query/filter_manager/lib/get_display_value.test.ts b/src/plugins/data/public/query/filter_manager/lib/get_display_value.test.ts index d32323d4d0b23..455e01663acae 100644 --- a/src/plugins/data/public/query/filter_manager/lib/get_display_value.test.ts +++ b/src/plugins/data/public/query/filter_manager/lib/get_display_value.test.ts @@ -36,6 +36,33 @@ describe('getDisplayValueFromFilter', () => { expect(displayValue).toBe(''); }); + it('returns 0 if value undefined and numeric field', () => { + const filter = { + meta: { + negate: false, + index: 'logstash-*', + type: 'phrase', + key: 'bytes', + value: undefined, + disabled: false, + alias: null, + params: { + query: undefined, + }, + }, + $state: { + store: FilterStateStore.APP_STATE, + }, + query: { + match_phrase: { + bytes: '0', + }, + }, + }; + const displayValue = getDisplayValueFromFilter(filter, [stubIndexPattern]); + expect(displayValue).toBe('0'); + }); + it('phrase filters without formatter', () => { jest.spyOn(stubIndexPattern, 'getFormatterForField').mockImplementation(() => undefined!); const displayValue = getDisplayValueFromFilter(phraseFilter, [stubIndexPattern]); diff --git a/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts b/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts index 6a8f5d895728a..bb1d6a464cb04 100644 --- a/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts +++ b/src/plugins/data/public/query/filter_manager/lib/get_display_value.ts @@ -61,10 +61,12 @@ export function getFieldDisplayValueFromFilter( export function getDisplayValueFromFilter(filter: Filter, indexPatterns: DataViewBase[]): string { const indexPattern = getIndexPatternFromFilter(filter, indexPatterns); const fieldName = getFilterField(filter); + const field = indexPattern?.fields.find((f) => f.name === fieldName); + const fieldType = field?.type; const valueFormatter = getValueFormatter(indexPattern, fieldName); if (isPhraseFilter(filter) || isScriptedPhraseFilter(filter)) { - return getPhraseDisplayValue(filter, valueFormatter); + return getPhraseDisplayValue(filter, valueFormatter, fieldType); } else if (isPhrasesFilter(filter)) { return getPhrasesDisplayValue(filter, valueFormatter); } else if (isRangeFilter(filter) || isScriptedRangeFilter(filter)) { diff --git a/src/plugins/data/public/query/filter_manager/lib/mappers/map_phrase.ts b/src/plugins/data/public/query/filter_manager/lib/mappers/map_phrase.ts index 3bbe9b886cf6a..6058a125c9a54 100644 --- a/src/plugins/data/public/query/filter_manager/lib/mappers/map_phrase.ts +++ b/src/plugins/data/public/query/filter_manager/lib/mappers/map_phrase.ts @@ -22,13 +22,15 @@ const getScriptedPhraseValue = (filter: PhraseFilter) => export function getPhraseDisplayValue( filter: PhraseFilter | ScriptedPhraseFilter, - formatter?: FieldFormat + formatter?: FieldFormat, + fieldType?: string ): string { const value = filter.meta.value ?? filter.meta.params.query; + const updatedValue = fieldType === 'number' && !value ? 0 : value; if (formatter?.convert) { - return formatter.convert(value); + return formatter.convert(updatedValue); } - return value === undefined ? '' : `${value}`; + return updatedValue === undefined ? '' : `${updatedValue}`; } const getParams = (filter: PhraseFilter) => { diff --git a/src/plugins/data/public/search/session/search_session_state.ts b/src/plugins/data/public/search/session/search_session_state.ts index 9b4c5d3098cc0..dc38ecef07f21 100644 --- a/src/plugins/data/public/search/session/search_session_state.ts +++ b/src/plugins/data/public/search/session/search_session_state.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import deepEqual from 'fast-deep-equal'; import { Observable } from 'rxjs'; import { distinctUntilChanged, map, shareReplay } from 'rxjs/operators'; @@ -188,7 +188,7 @@ export const sessionPureTransitions: SessionPureTransitions = { (state) => ({ appName }) => ({ ...createSessionDefaultState(), - sessionId: uuid.v4(), + sessionId: uuidv4(), startTime: new Date(), appName, }), diff --git a/src/plugins/data_view_field_editor/__jest__/client_integration/helpers/setup_environment.tsx b/src/plugins/data_view_field_editor/__jest__/client_integration/helpers/setup_environment.tsx index 25e3b4e8c05f1..e356c76ddb989 100644 --- a/src/plugins/data_view_field_editor/__jest__/client_integration/helpers/setup_environment.tsx +++ b/src/plugins/data_view_field_editor/__jest__/client_integration/helpers/setup_environment.tsx @@ -18,6 +18,7 @@ import { dataPluginMock } from '@kbn/data-plugin/public/mocks'; import { fieldFormatsMock as fieldFormats } from '@kbn/field-formats-plugin/common/mocks'; import { FieldFormat } from '@kbn/field-formats-plugin/common'; import { createStubDataView } from '@kbn/data-views-plugin/common/data_views/data_view.stub'; +import { PreviewController } from '../../../public/components/preview/preview_controller'; import { FieldEditorProvider, Context } from '../../../public/components/field_editor_context'; import { FieldPreviewProvider } from '../../../public/components/preview'; import { initApi, ApiService } from '../../../public/lib'; @@ -148,10 +149,11 @@ export const WithFieldEditorDependencies = }; const mergedDependencies = merge({}, dependencies, overridingDependencies); + const previewController = new PreviewController({ dataView, search }); return ( - + diff --git a/src/plugins/data_view_field_editor/public/components/field_editor/form_fields/script_field.tsx b/src/plugins/data_view_field_editor/public/components/field_editor/form_fields/script_field.tsx index dd66369a37d3f..6a53ae14186de 100644 --- a/src/plugins/data_view_field_editor/public/components/field_editor/form_fields/script_field.tsx +++ b/src/plugins/data_view_field_editor/public/components/field_editor/form_fields/script_field.tsx @@ -27,6 +27,8 @@ import { painlessErrorToMonacoMarker } from '../../../lib'; import { useFieldPreviewContext, Context } from '../../preview'; import { schema } from '../form_schema'; import type { FieldFormInternal } from '../field_editor'; +import { useStateSelector } from '../../../state_utils'; +import { PreviewState } from '../../preview/types'; interface Props { links: { runtimePainless: string }; @@ -53,18 +55,17 @@ const mapReturnTypeToPainlessContext = (runtimeType: RuntimeType): PainlessConte } }; +const currentDocumentSelector = (state: PreviewState) => state.documents[state.currentIdx]; +const currentDocumentIsLoadingSelector = (state: PreviewState) => state.isLoadingDocuments; + const ScriptFieldComponent = ({ existingConcreteFields, links, placeholder }: Props) => { const monacoEditor = useRef(null); const editorValidationSubscription = useRef(); const fieldCurrentValue = useRef(''); - const { - error, - isLoadingPreview, - isPreviewAvailable, - currentDocument: { isLoading: isFetchingDoc, value: currentDocument }, - validation: { setScriptEditorValidation }, - } = useFieldPreviewContext(); + const { error, isLoadingPreview, isPreviewAvailable, controller } = useFieldPreviewContext(); + const currentDocument = useStateSelector(controller.state$, currentDocumentSelector); + const isFetchingDoc = useStateSelector(controller.state$, currentDocumentIsLoadingSelector); const [validationData$, nextValidationData$] = useBehaviorSubject< | { isFetchingDoc: boolean; @@ -142,7 +143,7 @@ const ScriptFieldComponent = ({ existingConcreteFields, links, placeholder }: Pr editorValidationSubscription.current = PainlessLang.validation$().subscribe( ({ isValid, isValidating, errors }) => { - setScriptEditorValidation({ + controller.setScriptEditorValidation({ isValid, isValidating, message: errors[0]?.message ?? null, @@ -150,7 +151,7 @@ const ScriptFieldComponent = ({ existingConcreteFields, links, placeholder }: Pr } ); }, - [setScriptEditorValidation] + [controller] ); const updateMonacoMarkers = useCallback((markers: monaco.editor.IMarkerData[]) => { diff --git a/src/plugins/data_view_field_editor/public/components/field_editor_flyout_content_container.tsx b/src/plugins/data_view_field_editor/public/components/field_editor_flyout_content_container.tsx index 8366bcc71cb7f..60903fae03ea1 100644 --- a/src/plugins/data_view_field_editor/public/components/field_editor_flyout_content_container.tsx +++ b/src/plugins/data_view_field_editor/public/components/field_editor_flyout_content_container.tsx @@ -30,6 +30,7 @@ import { } from './field_editor_flyout_content'; import { FieldEditorProvider } from './field_editor_context'; import { FieldPreviewProvider } from './preview'; +import { PreviewController } from './preview/preview_controller'; export interface Props { /** Handler for the "save" footer button */ @@ -84,6 +85,7 @@ export const FieldEditorFlyoutContentContainer = ({ fieldFormats, uiSettings, }: Props) => { + const [controller] = useState(() => new PreviewController({ dataView, search })); const [isSaving, setIsSaving] = useState(false); const { fields } = dataView; @@ -258,7 +260,7 @@ export const FieldEditorFlyoutContentContainer = ({ fieldName$={new BehaviorSubject(fieldToEdit?.name || '')} subfields$={new BehaviorSubject(fieldToEdit?.fields)} > - + { + const doc = state.documents[state.currentIdx]; + return { + documentId: doc ? (doc._id as string) : undefined, + customId: state.customId, + }; +}; + export const DocumentsNavPreview = () => { const { - currentDocument: { id: documentId, isCustomId }, documents: { loadSingle, loadFromCluster, fetchDocError }, - navigation: { prev, next }, + controller, } = useFieldPreviewContext(); + const { goToPreviousDocument: prev, goToNextDocument: next } = controller; + const { documentId, customId } = useStateSelector(controller.state$, docIdSelector); const isInvalid = fetchDocError?.code === 'DOC_NOT_FOUND'; // We don't display the nav button when the user has entered a custom // document ID as at that point there is no more reference to what's "next" - const showNavButtons = isCustomId === false; + const showNavButtons = !customId; const onDocumentIdChange = useCallback( (e: React.SyntheticEvent) => { @@ -52,13 +63,13 @@ export const DocumentsNavPreview = () => { > - {isCustomId && ( + {customId && ( s.pinnedFields; +const currentDocumentSelector = (s: PreviewState) => s.documents[s.currentIdx]; + export const PreviewFieldList: React.FC = ({ height, clearSearch, searchValue = '' }) => { const { dataView } = useFieldEditorContext(); - const { - currentDocument: { value: currentDocument }, - pinnedFields: { value: pinnedFields, set: setPinnedFields }, - } = useFieldPreviewContext(); + const { controller } = useFieldPreviewContext(); + const pinnedFields = useStateSelector(controller.state$, pinnedFieldsSelector, isEqual); + const currentDocument = useStateSelector(controller.state$, currentDocumentSelector); const [showAllFields, setShowAllFields] = useState(false); @@ -126,19 +129,6 @@ export const PreviewFieldList: React.FC = ({ height, clearSearch, searchV setShowAllFields((prev) => !prev); }, []); - const toggleIsPinnedField = useCallback( - (name) => { - setPinnedFields((prev) => { - const isPinned = !prev[name]; - return { - ...prev, - [name]: isPinned, - }; - }); - }, - [setPinnedFields] - ); - const renderEmptyResult = () => { return ( <> @@ -213,7 +203,7 @@ export const PreviewFieldList: React.FC = ({ height, clearSearch, searchV
    ); diff --git a/src/plugins/data_view_field_editor/public/components/preview/field_preview_context.tsx b/src/plugins/data_view_field_editor/public/components/preview/field_preview_context.tsx index 90ac74d0ace7b..3addd448f1e7e 100644 --- a/src/plugins/data_view_field_editor/public/components/preview/field_preview_context.tsx +++ b/src/plugins/data_view_field_editor/public/components/preview/field_preview_context.tsx @@ -23,6 +23,7 @@ import { get } from 'lodash'; import { castEsToKbnFieldTypeName } from '@kbn/field-types'; import { BehaviorSubject } from 'rxjs'; import { RuntimePrimitiveTypes } from '../../shared_imports'; +import { useStateSelector } from '../../state_utils'; import { parseEsError } from '../../lib/runtime_field_validation'; import { useFieldEditorContext } from '../field_editor_context'; @@ -30,13 +31,13 @@ import type { PainlessExecuteContext, Context, Params, - ClusterData, - From, EsDocument, ScriptErrorCodes, FetchDocError, FieldPreview, + PreviewState, } from './types'; +import type { PreviewController } from './preview_controller'; const fieldPreviewContext = createContext(undefined); @@ -63,7 +64,23 @@ export const valueTypeToSelectedType = (value: unknown): RuntimePrimitiveTypes = return 'keyword'; }; -export const FieldPreviewProvider: FunctionComponent = ({ children }) => { +const documentsSelector = (state: PreviewState) => { + const currentDocument = state.documents[state.currentIdx]; + return { + currentDocument, + totalDocs: state.documents.length, + currentDocIndex: currentDocument?._index, + currentDocId: currentDocument?._id, + currentIdx: state.currentIdx, + }; +}; + +const scriptEditorValidationSelector = (state: PreviewState) => state.scriptEditorValidation; + +export const FieldPreviewProvider: FunctionComponent<{ controller: PreviewController }> = ({ + controller, + children, +}) => { const previewCount = useRef(0); // We keep in cache the latest params sent to the _execute API so we don't make unecessary requests @@ -103,43 +120,31 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { const [fetchDocError, setFetchDocError] = useState(null); /** The parameters required for the Painless _execute API */ const [params, setParams] = useState(defaultParams); - /** The sample documents fetched from the cluster */ - const [clusterData, setClusterData] = useState({ - documents: [], - currentIdx: 0, - }); + /** Flag to show/hide the preview panel */ const [isPanelVisible, setIsPanelVisible] = useState(true); /** Flag to indicate if we are loading document from cluster */ const [isFetchingDocument, setIsFetchingDocument] = useState(false); /** Flag to indicate if we are calling the _execute API */ const [isLoadingPreview, setIsLoadingPreview] = useState(false); + /** Flag to indicate if we are loading a single document by providing its ID */ const [customDocIdToLoad, setCustomDocIdToLoad] = useState(null); - /** Define if we provide the document to preview from the cluster or from a custom JSON */ - const [from, setFrom] = useState('cluster'); - /** Map of fields pinned to the top of the list */ - const [pinnedFields, setPinnedFields] = useState<{ [key: string]: boolean }>({}); - /** Keep track if the script painless syntax is being validated and if it is valid */ - const [scriptEditorValidation, setScriptEditorValidation] = useState<{ - isValidating: boolean; - isValid: boolean; - message: string | null; - }>({ isValidating: false, isValid: true, message: null }); - - const { documents, currentIdx } = clusterData; - const currentDocument: EsDocument | undefined = documents[currentIdx]; - const currentDocIndex: string | undefined = currentDocument?._index; - const currentDocId: string | undefined = currentDocument?._id; - const totalDocs = documents.length; - const isCustomDocId = customDocIdToLoad !== null; + + const { currentDocument, currentDocIndex, currentDocId, totalDocs, currentIdx } = + useStateSelector(controller.state$, documentsSelector); + const scriptEditorValidation = useStateSelector( + controller.state$, + scriptEditorValidationSelector + ); + let isPreviewAvailable = true; // If no documents could be fetched from the cluster (and we are not trying to load // a custom doc ID) then we disable preview as the script field validation expect the result // of the preview to before resolving. If there are no documents we can't have a preview // (the _execute API expects one) and thus the validation should not expect a value. - if (!isFetchingDocument && !isCustomDocId && documents.length === 0) { + if (!isFetchingDocument && !customDocIdToLoad && totalDocs === 0) { isPreviewAvailable = false; } @@ -249,13 +254,10 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { setFetchDocError(error); if (error === null) { - setClusterData({ - documents: response ? response.rawResponse.hits.hits : [], - currentIdx: 0, - }); + controller.setDocuments(response ? response.rawResponse.hits.hits : []); } }, - [dataView, search] + [dataView, search, controller] ); const loadDocument = useCallback( @@ -320,17 +322,14 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { setFetchDocError(error); if (error === null) { - setClusterData({ - documents: loadedDocuments, - currentIdx: 0, - }); + controller.setDocuments(loadedDocuments); } else { // Make sure we disable the "Updating..." indicator as we have an error // and we won't fetch the preview setIsLoadingPreview(false); } }, - [dataView, search] + [dataView, search, controller] ); const updateSingleFieldPreview = useCallback( @@ -477,39 +476,20 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { currentDocIndex, ]); - const goToNextDoc = useCallback(() => { - if (currentIdx >= totalDocs - 1) { - setClusterData((prev) => ({ ...prev, currentIdx: 0 })); - } else { - setClusterData((prev) => ({ ...prev, currentIdx: prev.currentIdx + 1 })); - } - }, [currentIdx, totalDocs]); - - const goToPrevDoc = useCallback(() => { - if (currentIdx === 0) { - setClusterData((prev) => ({ ...prev, currentIdx: totalDocs - 1 })); - } else { - setClusterData((prev) => ({ ...prev, currentIdx: prev.currentIdx - 1 })); - } - }, [currentIdx, totalDocs]); - const reset = useCallback(() => { // By resetting the previewCount we will discard previous inflight // API call response coming in after calling reset() was called previewCount.current = 0; - setClusterData({ - documents: [], - currentIdx: 0, - }); + controller.setDocuments([]); setPreviewResponse({ fields: [], error: null }); - setFrom('cluster'); setIsLoadingPreview(false); setIsFetchingDocument(false); - }, []); + }, [controller]); const ctx = useMemo( () => ({ + controller, fields: previewResponse.fields, error: previewResponse.error, fieldPreview$: fieldPreview$.current, @@ -520,12 +500,6 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { value: params, update: updateParams, }, - currentDocument: { - value: currentDocument, - id: isCustomDocId ? customDocIdToLoad! : currentDocId, - isLoading: isFetchingDocument, - isCustomId: isCustomDocId, - }, documents: { loadSingle: setCustomDocIdToLoad, loadFromCluster: fetchSampleDocuments, @@ -534,27 +508,16 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { navigation: { isFirstDoc: currentIdx === 0, isLastDoc: currentIdx >= totalDocs - 1, - next: goToNextDoc, - prev: goToPrevDoc, }, panel: { isVisible: isPanelVisible, setIsVisible: setIsPanelVisible, }, - from: { - value: from, - set: setFrom, - }, reset, - pinnedFields: { - value: pinnedFields, - set: setPinnedFields, - }, - validation: { - setScriptEditorValidation, - }, }), [ + controller, + currentIdx, previewResponse, fieldPreview$, fetchDocError, @@ -562,20 +525,10 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { isPreviewAvailable, isLoadingPreview, updateParams, - currentDocument, - currentDocId, - isCustomDocId, fetchSampleDocuments, - isFetchingDocument, - customDocIdToLoad, - currentIdx, totalDocs, - goToNextDoc, - goToPrevDoc, isPanelVisible, - from, reset, - pinnedFields, initialPreviewComplete, ] ); @@ -597,10 +550,11 @@ export const FieldPreviewProvider: FunctionComponent = ({ children }) => { * "customDocIdToLoad" changes */ useEffect(() => { + controller.setCustomId(customDocIdToLoad || undefined); if (customDocIdToLoad !== null && Boolean(customDocIdToLoad.trim())) { setIsFetchingDocument(true); } - }, [customDocIdToLoad]); + }, [customDocIdToLoad, controller]); /** * Whenever we show the preview panel we will update the documents from the cluster diff --git a/src/plugins/data_view_field_editor/public/components/preview/field_preview_header.tsx b/src/plugins/data_view_field_editor/public/components/preview/field_preview_header.tsx index 62d61dbdd4c79..c9435ff3bd75b 100644 --- a/src/plugins/data_view_field_editor/public/components/preview/field_preview_header.tsx +++ b/src/plugins/data_view_field_editor/public/components/preview/field_preview_header.tsx @@ -9,6 +9,8 @@ import React from 'react'; import { EuiTitle, EuiText, EuiTextColor, EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; +import { useStateSelector } from '../../state_utils'; +import { PreviewState } from './types'; import { useFieldEditorContext } from '../field_editor_context'; import { useFieldPreviewContext } from './field_preview_context'; @@ -23,12 +25,14 @@ const i18nTexts = { }), }; +const isLoadingSelector = (state: PreviewState) => state.isLoadingDocuments; +const documentSourceSelector = (state: PreviewState) => state.documentSource; + export const FieldPreviewHeader = () => { const { dataView } = useFieldEditorContext(); - const { - from, - currentDocument: { isLoading: isFetchingDocument }, - } = useFieldPreviewContext(); + const { controller } = useFieldPreviewContext(); + const isFetchingDocument = useStateSelector(controller.state$, isLoadingSelector); + const documentSource = useStateSelector(controller.state$, documentSourceSelector); return (
    @@ -47,9 +51,10 @@ export const FieldPreviewHeader = () => { {i18n.translate('indexPatternFieldEditor.fieldPreview.subTitle', { - defaultMessage: 'From: {from}', + defaultMessage: 'From: {documentSource}', values: { - from: from.value === 'cluster' ? dataView.getIndexPattern() : i18nTexts.customData, + documentSource: + documentSource === 'cluster' ? dataView.getIndexPattern() : i18nTexts.customData, }, })} diff --git a/src/plugins/data_view_field_editor/public/components/preview/preview_controller.ts b/src/plugins/data_view_field_editor/public/components/preview/preview_controller.ts new file mode 100644 index 0000000000000..b94051bb0107d --- /dev/null +++ b/src/plugins/data_view_field_editor/public/components/preview/preview_controller.ts @@ -0,0 +1,109 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import type { DataView } from '@kbn/data-views-plugin/public'; +import type { ISearchStart } from '@kbn/data-plugin/public'; +import { BehaviorSubject } from 'rxjs'; +import { PreviewState } from './types'; +import { BehaviorObservable } from '../../state_utils'; +import { EsDocument } from './types'; + +interface PreviewControllerDependencies { + dataView: DataView; + search: ISearchStart; +} + +const previewStateDefault: PreviewState = { + /** Map of fields pinned to the top of the list */ + pinnedFields: {}, + isLoadingDocuments: true, + /** Flag to indicate if we are loading a single document by providing its ID */ + customId: undefined, + /** sample documents fetched from cluster */ + documents: [], + currentIdx: 0, + documentSource: 'cluster', + /** Keep track if the script painless syntax is being validated and if it is valid */ + scriptEditorValidation: { isValidating: false, isValid: true, message: null }, +}; + +export class PreviewController { + constructor({ dataView, search }: PreviewControllerDependencies) { + this.dataView = dataView; + this.search = search; + + this.internalState$ = new BehaviorSubject({ + ...previewStateDefault, + }); + + this.state$ = this.internalState$ as BehaviorObservable; + } + + // @ts-ignore + private dataView: DataView; + // @ts-ignore + private search: ISearchStart; + private state: PreviewState = previewStateDefault; + private internalState$: BehaviorSubject; + state$: BehaviorObservable; + + private updateState = (newState: Partial) => { + this.state = { ...this.state, ...newState }; + this.publishState(); + }; + + private publishState = () => { + // todo try removing object copy + this.internalState$.next({ ...this.state }); + }; + + togglePinnedField = (fieldName: string) => { + const pinnedFields = { + ...this.state.pinnedFields, + [fieldName]: !this.state.pinnedFields[fieldName], + }; + + this.updateState({ pinnedFields }); + }; + + setDocuments = (documents: EsDocument[]) => { + this.updateState({ + documents, + currentIdx: 0, + isLoadingDocuments: false, + }); + }; + + setCurrentIdx = (currentIdx: number) => { + this.updateState({ currentIdx }); + }; + + goToNextDocument = () => { + if (this.state.currentIdx >= this.state.documents.length - 1) { + this.updateState({ currentIdx: 0 }); + } else { + this.updateState({ currentIdx: this.state.currentIdx + 1 }); + } + }; + + goToPreviousDocument = () => { + if (this.state.currentIdx === 0) { + this.updateState({ currentIdx: this.state.documents.length - 1 }); + } else { + this.updateState({ currentIdx: this.state.currentIdx - 1 }); + } + }; + + setScriptEditorValidation = (scriptEditorValidation: PreviewState['scriptEditorValidation']) => { + this.updateState({ scriptEditorValidation }); + }; + + setCustomId = (customId?: string) => { + this.updateState({ customId }); + }; +} diff --git a/src/plugins/data_view_field_editor/public/components/preview/types.ts b/src/plugins/data_view_field_editor/public/components/preview/types.ts index a2916a275cf52..377aed627ba54 100644 --- a/src/plugins/data_view_field_editor/public/components/preview/types.ts +++ b/src/plugins/data_view_field_editor/public/components/preview/types.ts @@ -6,7 +6,6 @@ * Side Public License, v 1. */ -import React from 'react'; import { BehaviorSubject } from 'rxjs'; import type { RuntimeType, @@ -15,8 +14,9 @@ import type { RuntimePrimitiveTypes, } from '../../shared_imports'; import type { RuntimeFieldPainlessError } from '../../types'; +import type { PreviewController } from './preview_controller'; -export type From = 'cluster' | 'custom'; +export type DocumentSource = 'cluster' | 'custom'; export interface EsDocument { _id: string; @@ -43,6 +43,20 @@ interface PreviewError { }; } +export interface PreviewState { + pinnedFields: Record; + isLoadingDocuments: boolean; + customId: string | undefined; + documents: EsDocument[]; + currentIdx: number; + documentSource: DocumentSource; + scriptEditorValidation: { + isValidating: boolean; + isValid: boolean; + message: string | null; + }; +} + export interface FetchDocError { code: FetchDocErrorCodes; error: { @@ -93,6 +107,7 @@ export interface Change { export type ChangeSet = Record; export interface Context { + controller: PreviewController; fields: FieldPreview[]; fieldPreview$: BehaviorSubject; error: PreviewError | null; @@ -104,12 +119,6 @@ export interface Context { }; isPreviewAvailable: boolean; isLoadingPreview: boolean; - currentDocument: { - value?: EsDocument; - id?: string; - isLoading: boolean; - isCustomId: boolean; - }; documents: { loadSingle: (id: string) => void; loadFromCluster: () => Promise; @@ -119,26 +128,11 @@ export interface Context { isVisible: boolean; setIsVisible: (isVisible: boolean) => void; }; - from: { - value: From; - set: (value: From) => void; - }; navigation: { isFirstDoc: boolean; isLastDoc: boolean; - next: () => void; - prev: () => void; }; reset: () => void; - pinnedFields: { - value: { [key: string]: boolean }; - set: React.Dispatch>; - }; - validation: { - setScriptEditorValidation: React.Dispatch< - React.SetStateAction<{ isValid: boolean; isValidating: boolean; message: string | null }> - >; - }; } export type PainlessExecuteContext = diff --git a/src/plugins/data_view_field_editor/public/state_utils.ts b/src/plugins/data_view_field_editor/public/state_utils.ts new file mode 100644 index 0000000000000..634dd5d8dc38b --- /dev/null +++ b/src/plugins/data_view_field_editor/public/state_utils.ts @@ -0,0 +1,27 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { BehaviorSubject } from 'rxjs'; +import { distinctUntilChanged, map } from 'rxjs/operators'; +import { useMemo } from 'react'; +import useObservable from 'react-use/lib/useObservable'; + +export type BehaviorObservable = Omit, 'next'>; + +export function useStateSelector( + state$: BehaviorObservable, + selector: (state: S) => R, + equalityFn?: (arg0: R, arg1: R) => boolean +) { + const memoizedObservable = useMemo( + () => state$.pipe(map(selector), distinctUntilChanged(equalityFn)), + [state$, selector, equalityFn] + ); + const defaultValue = useMemo(() => selector(state$.value), [selector, state$]); + return useObservable(memoizedObservable, defaultValue); +} diff --git a/src/plugins/data_views/common/data_views/data_views.ts b/src/plugins/data_views/common/data_views/data_views.ts index fb284be0c7d09..af40e4137f75f 100644 --- a/src/plugins/data_views/common/data_views/data_views.ts +++ b/src/plugins/data_views/common/data_views/data_views.ts @@ -11,7 +11,7 @@ import type { PublicMethodsOf } from '@kbn/utility-types'; import { castEsToKbnFieldTypeName } from '@kbn/field-types'; import { FieldFormatsStartCommon, FORMATS_UI_SETTINGS } from '@kbn/field-formats-plugin/common'; import { SavedObjectNotFound } from '@kbn/kibana-utils-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DATA_VIEW_SAVED_OBJECT_TYPE } from '..'; import { SavedObjectsClientCommon } from '../types'; @@ -916,7 +916,7 @@ export class DataViewsService { const metaFields = await this.config.get(META_FIELDS); const spec = { - id: id ?? uuid.v4(), + id: id ?? uuidv4(), title, name: name || title, ...restOfSpec, diff --git a/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.test.tsx b/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.test.tsx index 48eeaaaef4ac8..d99340da89857 100644 --- a/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.test.tsx +++ b/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.test.tsx @@ -69,7 +69,9 @@ const mountComponent = ({ services.data.query.timefilter.timefilter.getAbsoluteTime = () => { return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; }; - + services.data.query.timefilter.timefilter.getTime = () => { + return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; + }; (services.data.query.queryString.getDefaultQuery as jest.Mock).mockReturnValue({ language: 'kuery', query: '', @@ -123,6 +125,7 @@ const mountComponent = ({ setExpandedDoc: jest.fn(), savedSearch, savedSearchData$, + savedSearchFetch$: new Subject(), savedSearchRefetch$: new Subject(), stateContainer, onFieldEdited: jest.fn(), diff --git a/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.tsx b/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.tsx index 7c948d8a29f60..aa4027c22aedc 100644 --- a/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.tsx +++ b/src/plugins/discover/public/application/main/components/layout/discover_histogram_layout.tsx @@ -15,6 +15,7 @@ import type { DiscoverSearchSessionManager } from '../../services/discover_searc import type { InspectorAdapters } from '../../hooks/use_inspector'; import { type DiscoverMainContentProps, DiscoverMainContent } from './discover_main_content'; import { ResetSearchButton } from './reset_search_button'; +import type { DataFetch$ } from '../../hooks/use_saved_search'; export interface DiscoverHistogramLayoutProps extends DiscoverMainContentProps { resetSavedSearch: () => void; @@ -22,6 +23,7 @@ export interface DiscoverHistogramLayoutProps extends DiscoverMainContentProps { resizeRef: RefObject; inspectorAdapters: InspectorAdapters; searchSessionManager: DiscoverSearchSessionManager; + savedSearchFetch$: DataFetch$; } export const DiscoverHistogramLayout = ({ @@ -30,6 +32,7 @@ export const DiscoverHistogramLayout = ({ resetSavedSearch, savedSearch, savedSearchData$, + savedSearchFetch$, stateContainer, isTimeBased, resizeRef, @@ -51,6 +54,7 @@ export const DiscoverHistogramLayout = ({ isTimeBased, inspectorAdapters, searchSessionManager, + savedSearchFetch$, ...commonProps, }); diff --git a/src/plugins/discover/public/application/main/components/layout/discover_layout.test.tsx b/src/plugins/discover/public/application/main/components/layout/discover_layout.test.tsx index 6a9bd2d381d98..2d6998df4898f 100644 --- a/src/plugins/discover/public/application/main/components/layout/discover_layout.test.tsx +++ b/src/plugins/discover/public/application/main/components/layout/discover_layout.test.tsx @@ -24,6 +24,7 @@ import { dataViewWithTimefieldMock } from '../../../../__mocks__/data_view_with_ import { AvailableFields$, DataDocuments$, + DataFetch$, DataMain$, DataRefetch$, DataTotalHits$, @@ -58,7 +59,9 @@ function mountComponent( [SIDEBAR_CLOSED_KEY]: prevSidebarClosed, }) as unknown as Storage, } as unknown as DiscoverServices; - + services.data.query.timefilter.timefilter.getTime = () => { + return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; + }; (services.data.query.queryString.getDefaultQuery as jest.Mock).mockReturnValue({ language: 'kuery', query: '', @@ -113,6 +116,7 @@ function mountComponent( resetSavedSearch: jest.fn(), savedSearch: savedSearchMock, savedSearchData$, + savedSearchFetch$: new Subject() as DataFetch$, savedSearchRefetch$: new Subject() as DataRefetch$, searchSource: searchSourceMock, state: { columns: [], query, hideChart: false, interval: 'auto' }, diff --git a/src/plugins/discover/public/application/main/components/layout/discover_layout.tsx b/src/plugins/discover/public/application/main/components/layout/discover_layout.tsx index c9f52bd548f25..f93bb7b9ff8ea 100644 --- a/src/plugins/discover/public/application/main/components/layout/discover_layout.tsx +++ b/src/plugins/discover/public/application/main/components/layout/discover_layout.tsx @@ -62,6 +62,7 @@ export function DiscoverLayout({ onChangeDataView, onUpdateQuery, setExpandedDoc, + savedSearchFetch$, savedSearchRefetch$, resetSavedSearch, savedSearchData$, @@ -237,6 +238,7 @@ export function DiscoverLayout({ setExpandedDoc={setExpandedDoc} savedSearch={savedSearch} savedSearchData$={savedSearchData$} + savedSearchFetch$={savedSearchFetch$} savedSearchRefetch$={savedSearchRefetch$} stateContainer={stateContainer} isTimeBased={isTimeBased} @@ -270,6 +272,7 @@ export function DiscoverLayout({ resultState, savedSearch, savedSearchData$, + savedSearchFetch$, savedSearchRefetch$, searchSessionManager, setExpandedDoc, diff --git a/src/plugins/discover/public/application/main/components/layout/types.ts b/src/plugins/discover/public/application/main/components/layout/types.ts index f2a8ebe9269e8..34b8650ffc153 100644 --- a/src/plugins/discover/public/application/main/components/layout/types.ts +++ b/src/plugins/discover/public/application/main/components/layout/types.ts @@ -9,10 +9,10 @@ import type { Query, TimeRange, AggregateQuery } from '@kbn/es-query'; import type { DataView } from '@kbn/data-views-plugin/public'; import type { ISearchSource } from '@kbn/data-plugin/public'; -import { SavedSearch } from '@kbn/saved-search-plugin/public'; -import { DataTableRecord } from '../../../../types'; -import { DiscoverStateContainer } from '../../services/discover_state'; -import { DataRefetch$, SavedSearchData } from '../../hooks/use_saved_search'; +import type { SavedSearch } from '@kbn/saved-search-plugin/public'; +import type { DataTableRecord } from '../../../../types'; +import type { DiscoverStateContainer } from '../../services/discover_state'; +import type { DataFetch$, DataRefetch$, SavedSearchData } from '../../hooks/use_saved_search'; import type { DiscoverSearchSessionManager } from '../../services/discover_search_session'; import type { InspectorAdapters } from '../../hooks/use_inspector'; @@ -29,6 +29,7 @@ export interface DiscoverLayoutProps { setExpandedDoc: (doc?: DataTableRecord) => void; savedSearch: SavedSearch; savedSearchData$: SavedSearchData; + savedSearchFetch$: DataFetch$; savedSearchRefetch$: DataRefetch$; searchSource: ISearchSource; stateContainer: DiscoverStateContainer; diff --git a/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.test.tsx b/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.test.tsx index 950b2d4571a40..89059db91e7f5 100644 --- a/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.test.tsx +++ b/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.test.tsx @@ -9,11 +9,12 @@ import React, { ReactElement } from 'react'; import { buildDataTableRecord } from '../../../../utils/build_data_record'; import { esHits } from '../../../../__mocks__/es_hits'; import { act, renderHook, WrapperComponent } from '@testing-library/react-hooks'; -import { BehaviorSubject } from 'rxjs'; +import { BehaviorSubject, Subject } from 'rxjs'; import { FetchStatus } from '../../../types'; import { AvailableFields$, DataDocuments$, + DataFetch$, DataMain$, DataTotalHits$, RecordRawType, @@ -72,6 +73,15 @@ jest.mock('@kbn/unified-field-list-plugin/public', () => { return { ...originalModule, getVisualizeInformation: jest.fn(() => Promise.resolve(mockCanVisualize)), + useQuerySubscriber: jest.fn(() => ({ + query: { + query: 'query', + language: 'kuery', + }, + filters: [], + fromDate: 'now-15m', + toDate: 'now', + })), }; }); @@ -120,6 +130,7 @@ describe('useDiscoverHistogram', () => { recordRawType: isPlainRecord ? RecordRawType.PLAIN : RecordRawType.DOCUMENT, foundDocuments: true, }) as DataMain$, + savedSearchFetch$ = new Subject() as DataFetch$, }: { isPlainRecord?: boolean; isTimeBased?: boolean; @@ -131,6 +142,7 @@ describe('useDiscoverHistogram', () => { inspectorAdapters?: InspectorAdapters; totalHits$?: DataTotalHits$; main$?: DataMain$; + savedSearchFetch$?: DataFetch$; } = {}) => { mockStorage = storage; mockCanVisualize = canVisualize; @@ -161,6 +173,7 @@ describe('useDiscoverHistogram', () => { const initialProps = { stateContainer, savedSearchData$, + savedSearchFetch$, dataView: dataViewWithTimefieldMock, savedSearch: savedSearchMock, isTimeBased, @@ -188,11 +201,20 @@ describe('useDiscoverHistogram', () => { return { hook, initialProps }; }; - it('should return undefined if there is no search session', async () => { - const { - hook: { result }, - } = await renderUseDiscoverHistogram({ searchSessionId: null }); - expect(result.current).toBeUndefined(); + describe('result', () => { + it('should return undefined if there is no search session', async () => { + const { + hook: { result }, + } = await renderUseDiscoverHistogram({ searchSessionId: null }); + expect(result.current).toBeUndefined(); + }); + + it('it should not return undefined if there is no search session, but isPlainRecord is true', async () => { + const { + hook: { result }, + } = await renderUseDiscoverHistogram({ searchSessionId: null, isPlainRecord: true }); + expect(result.current).toBeDefined(); + }); }); describe('contexts', () => { @@ -263,6 +285,21 @@ describe('useDiscoverHistogram', () => { }); }); + describe('search params', () => { + it('should return the correct query, filters, and timeRange', async () => { + const { hook } = await renderUseDiscoverHistogram(); + expect(hook.result.current?.query).toEqual({ + query: 'query', + language: 'kuery', + }); + expect(hook.result.current?.filters).toEqual([]); + expect(hook.result.current?.timeRange).toEqual({ + from: 'now-15m', + to: 'now', + }); + }); + }); + describe('onEditVisualization', () => { it('returns a callback for onEditVisualization when the data view can be visualized', async () => { const { @@ -364,7 +401,7 @@ describe('useDiscoverHistogram', () => { } = await renderUseDiscoverHistogram({ inspectorAdapters }); expect(inspectorAdapters.lensRequests).toBeUndefined(); act(() => { - result.current?.onChartLoad({ complete: true, adapters: { requests: lensRequests } }); + result.current?.onChartLoad({ adapters: { requests: lensRequests } }); }); expect(inspectorAdapters.lensRequests).toBeDefined(); }); @@ -486,4 +523,63 @@ describe('useDiscoverHistogram', () => { expect(mockCheckHitCount).not.toHaveBeenCalled(); }); }); + + describe('refetching', () => { + it("should call input$.next({ type: 'refetch' }) when savedSearchFetch$ is triggered", async () => { + const savedSearchFetch$ = new BehaviorSubject({ reset: false, searchSessionId: '1234' }); + const { hook } = await renderUseDiscoverHistogram({ savedSearchFetch$ }); + const onRefetch = jest.fn(); + hook.result.current?.input$.subscribe(onRefetch); + act(() => { + savedSearchFetch$.next({ reset: false, searchSessionId: '1234' }); + }); + expect(onRefetch).toHaveBeenCalledWith({ type: 'refetch' }); + }); + + it("should not call input$.next({ type: 'refetch' }) when searchSessionId is not set", async () => { + const savedSearchFetch$ = new BehaviorSubject({ reset: false, searchSessionId: '1234' }); + const { hook } = await renderUseDiscoverHistogram({ + savedSearchFetch$, + searchSessionId: null, + }); + const onRefetch = jest.fn(); + hook.result.current?.input$.subscribe(onRefetch); + act(() => { + savedSearchFetch$.next({ reset: false, searchSessionId: '1234' }); + }); + expect(onRefetch).not.toHaveBeenCalled(); + }); + + it("should call input$.next({ type: 'refetch' }) when searchSessionId is not set and isPlainRecord is true", async () => { + const savedSearchFetch$ = new BehaviorSubject({ reset: false, searchSessionId: '1234' }); + const { hook } = await renderUseDiscoverHistogram({ + savedSearchFetch$, + searchSessionId: null, + isPlainRecord: true, + }); + const onRefetch = jest.fn(); + hook.result.current?.input$.subscribe(onRefetch); + act(() => { + savedSearchFetch$.next({ reset: false, searchSessionId: '1234' }); + }); + expect(onRefetch).toHaveBeenCalledWith({ type: 'refetch' }); + }); + + it('should skip the next refetch when state.hideChart changes from true to false', async () => { + const savedSearchFetch$ = new BehaviorSubject({ reset: false, searchSessionId: '1234' }); + const { hook } = await renderUseDiscoverHistogram({ savedSearchFetch$ }); + const onRefetch = jest.fn(); + hook.result.current?.input$.subscribe(onRefetch); + act(() => { + hook.result.current?.onChartHiddenChange(true); + }); + act(() => { + hook.result.current?.onChartHiddenChange(false); + }); + act(() => { + savedSearchFetch$.next({ reset: false, searchSessionId: '1234' }); + }); + expect(onRefetch).not.toHaveBeenCalled(); + }); + }); }); diff --git a/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.ts b/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.ts index 53ddc74ad99d6..d380244fe875b 100644 --- a/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.ts +++ b/src/plugins/discover/public/application/main/components/layout/use_discover_histogram.ts @@ -8,20 +8,22 @@ import type { DataView, DataViewField } from '@kbn/data-views-plugin/common'; import type { SavedSearch } from '@kbn/saved-search-plugin/public'; -import { getVisualizeInformation } from '@kbn/unified-field-list-plugin/public'; -import { useCallback, useEffect, useMemo, useState } from 'react'; +import { getVisualizeInformation, useQuerySubscriber } from '@kbn/unified-field-list-plugin/public'; +import { useCallback, useEffect, useMemo, useRef, useState } from 'react'; import { UnifiedHistogramFetchStatus, UnifiedHistogramHitsContext, + UnifiedHistogramInputMessage, } from '@kbn/unified-histogram-plugin/public'; import type { UnifiedHistogramChartLoadEvent } from '@kbn/unified-histogram-plugin/public'; import useObservable from 'react-use/lib/useObservable'; import type { TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import { Subject } from 'rxjs'; import { useAppStateSelector } from '../../services/discover_app_state_container'; import { getUiActions } from '../../../../kibana_services'; import { useDiscoverServices } from '../../../../hooks/use_discover_services'; import { useDataState } from '../../hooks/use_data_state'; -import type { SavedSearchData } from '../../hooks/use_saved_search'; +import type { DataFetch$, SavedSearchData } from '../../hooks/use_saved_search'; import type { DiscoverStateContainer } from '../../services/discover_state'; import { FetchStatus } from '../../../types'; import type { DiscoverSearchSessionManager } from '../../services/discover_search_session'; @@ -41,6 +43,7 @@ export interface UseDiscoverHistogramProps { isPlainRecord: boolean; inspectorAdapters: InspectorAdapters; searchSessionManager: DiscoverSearchSessionManager; + savedSearchFetch$: DataFetch$; } export const useDiscoverHistogram = ({ @@ -52,6 +55,7 @@ export const useDiscoverHistogram = ({ isPlainRecord, inspectorAdapters, searchSessionManager, + savedSearchFetch$, }: UseDiscoverHistogramProps) => { const { storage, data, lens } = useDiscoverServices(); const [hideChart, interval, breakdownField] = useAppStateSelector((state) => [ @@ -124,21 +128,6 @@ export const useDiscoverHistogram = ({ [stateContainer] ); - /** - * Request - */ - - // The searchSessionId will be updated whenever a new search - // is started and will trigger a unified histogram refetch - const searchSessionId = useObservable(searchSessionManager.searchSessionId$); - const request = useMemo( - () => ({ - searchSessionId, - adapter: inspectorAdapters.requests, - }), - [inspectorAdapters.requests, searchSessionId] - ); - /** * Total hits */ @@ -216,32 +205,23 @@ export const useDiscoverHistogram = ({ [inspectorAdapters] ); - const [chartHidden, setChartHidden] = useState(hideChart); const chart = useMemo( () => isPlainRecord || !isTimeBased ? undefined : { - hidden: chartHidden, + hidden: hideChart, timeInterval: interval, }, - [chartHidden, interval, isPlainRecord, isTimeBased] + [hideChart, interval, isPlainRecord, isTimeBased] ); // Clear the Lens request adapter when the chart is hidden useEffect(() => { - if (chartHidden || !chart) { + if (hideChart || !chart) { inspectorAdapters.lensRequests = undefined; } - }, [chart, chartHidden, inspectorAdapters]); - - // state.chartHidden is updated before searchSessionId, which can trigger duplicate - // requests, so instead of using state.chartHidden directly, we update chartHidden - // when searchSessionId changes - useEffect(() => { - setChartHidden(hideChart); - // eslint-disable-next-line react-hooks/exhaustive-deps - }, [searchSessionId]); + }, [chart, hideChart, inspectorAdapters]); /** * Breakdown @@ -264,18 +244,78 @@ export const useDiscoverHistogram = ({ [field, isPlainRecord, isTimeBased] ); + /** + * Search params + */ + + const { query, filters, fromDate: from, toDate: to } = useQuerySubscriber({ data }); + const timeRange = useMemo( + () => (from && to ? { from, to } : data.query.timefilter.timefilter.getTimeDefaults()), + [data.query.timefilter.timefilter, from, to] + ); + + /** + * Request + */ + + // The searchSessionId will be updated whenever a new search is started + const searchSessionId = useObservable(searchSessionManager.searchSessionId$); + const request = useMemo( + () => ({ + searchSessionId, + adapter: inspectorAdapters.requests, + }), + [inspectorAdapters.requests, searchSessionId] + ); + + /** + * Data fetching + */ + + const input$ = useMemo(() => new Subject(), []); + // Initialized when the first search has been requested or // when in SQL mode since search sessions are not supported const isInitialized = Boolean(searchSessionId) || isPlainRecord; + const skipRefetch = useRef(); + + // Skip refetching when showing the chart since Lens will + // automatically fetch when the chart is shown + useEffect(() => { + if (skipRefetch.current === undefined) { + skipRefetch.current = false; + } else { + skipRefetch.current = !hideChart; + } + }, [hideChart]); + + // Trigger a unified histogram refetch when savedSearchFetch$ is triggered + useEffect(() => { + const subscription = savedSearchFetch$.subscribe(() => { + if (isInitialized && !skipRefetch.current) { + input$.next({ type: 'refetch' }); + } + skipRefetch.current = false; + }); + + return () => { + subscription.unsubscribe(); + }; + }, [input$, isInitialized, savedSearchFetch$]); // Don't render the unified histogram layout until initialized return isInitialized ? { + query, + filters, + timeRange, topPanelHeight, request, hits, chart, breakdown, + disableAutoFetching: true, + input$, onEditVisualization: canVisualize ? onEditVisualization : undefined, onTopPanelHeightChange, onChartHiddenChange, diff --git a/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx b/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx index 5aa9fb6c65a5e..237fc2b4ab574 100644 --- a/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx +++ b/src/plugins/discover/public/application/main/components/top_nav/on_save_search.tsx @@ -187,7 +187,7 @@ export async function onSaveSearch({ onClose={onClose ?? (() => {})} /> ); - showSaveModal(saveModal, services.core.i18n.Context); + showSaveModal(saveModal); } const SaveSearchObjectModal: React.FC<{ diff --git a/src/plugins/discover/public/application/main/discover_main_app.test.tsx b/src/plugins/discover/public/application/main/discover_main_app.test.tsx index 7ea5e944cc6a7..f3cc7f9cee43d 100644 --- a/src/plugins/discover/public/application/main/discover_main_app.test.tsx +++ b/src/plugins/discover/public/application/main/discover_main_app.test.tsx @@ -25,6 +25,10 @@ import { DiscoverMainProvider } from './services/discover_state_provider'; setHeaderActionMenuMounter(jest.fn()); setUrlTracker(urlTrackerMock); +discoverServiceMock.data.query.timefilter.timefilter.getTime = () => { + return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; +}; + describe('DiscoverMainApp', () => { test('renders', async () => { const dataViewList = [dataViewMock].map((ip) => { diff --git a/src/plugins/discover/public/application/main/discover_main_app.tsx b/src/plugins/discover/public/application/main/discover_main_app.tsx index a91ed42a55a62..92f155f57bafc 100644 --- a/src/plugins/discover/public/application/main/discover_main_app.tsx +++ b/src/plugins/discover/public/application/main/discover_main_app.tsx @@ -55,6 +55,7 @@ export function DiscoverMainApp(props: DiscoverMainProps) { onUpdateQuery, persistDataView, updateAdHocDataViewId, + fetch$, refetch$, resetSavedSearch, searchSource, @@ -118,6 +119,7 @@ export function DiscoverMainApp(props: DiscoverMainProps) { navigateTo={navigateTo} savedSearch={savedSearch} savedSearchData$={data$} + savedSearchFetch$={fetch$} savedSearchRefetch$={refetch$} searchSource={searchSource} stateContainer={stateContainer} diff --git a/src/plugins/discover/public/application/main/hooks/use_adhoc_data_views.ts b/src/plugins/discover/public/application/main/hooks/use_adhoc_data_views.ts index 0ba8eb6ec2394..c87c13b0e9fb7 100644 --- a/src/plugins/discover/public/application/main/hooks/use_adhoc_data_views.ts +++ b/src/plugins/discover/public/application/main/hooks/use_adhoc_data_views.ts @@ -7,7 +7,7 @@ */ import { useCallback, useEffect } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import type { DataView, DataViewsContract } from '@kbn/data-views-plugin/public'; import { SavedSearch } from '@kbn/saved-search-plugin/public'; import type { FilterManager } from '@kbn/data-plugin/public'; @@ -57,7 +57,7 @@ export const useAdHocDataViews = ({ */ const updateAdHocDataViewId = useCallback( async (prevDataView: DataView) => { - const newDataView = await dataViews.create({ ...prevDataView.toSpec(), id: uuid() }); + const newDataView = await dataViews.create({ ...prevDataView.toSpec(), id: uuidv4() }); dataViews.clearInstanceCache(prevDataView.id); updateFiltersReferences(prevDataView, newDataView); diff --git a/src/plugins/discover/public/application/main/hooks/use_discover_state.ts b/src/plugins/discover/public/application/main/hooks/use_discover_state.ts index 6eefb25580969..a8ff93ef94547 100644 --- a/src/plugins/discover/public/application/main/hooks/use_discover_state.ts +++ b/src/plugins/discover/public/application/main/hooks/use_discover_state.ts @@ -121,7 +121,7 @@ export function useDiscoverState({ /** * Data fetching logic */ - const { data$, refetch$, reset, inspectorAdapters } = useSavedSearchData({ + const { data$, fetch$, refetch$, reset, inspectorAdapters } = useSavedSearchData({ initialFetchStatus, searchSessionManager, savedSearch, @@ -322,6 +322,7 @@ export function useDiscoverState({ return { data$, inspectorAdapters, + fetch$, refetch$, resetSavedSearch, onChangeDataView, diff --git a/src/plugins/discover/public/application/main/hooks/use_saved_search.ts b/src/plugins/discover/public/application/main/hooks/use_saved_search.ts index 7f7e4700925a6..1b1a917740d43 100644 --- a/src/plugins/discover/public/application/main/hooks/use_saved_search.ts +++ b/src/plugins/discover/public/application/main/hooks/use_saved_search.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ import { useCallback, useEffect, useMemo, useRef } from 'react'; -import { BehaviorSubject, Subject } from 'rxjs'; +import { BehaviorSubject, filter, map, Observable, share, Subject, tap } from 'rxjs'; import type { AutoRefreshDoneFn } from '@kbn/data-plugin/public'; import { ISearchSource } from '@kbn/data-plugin/public'; import { RequestAdapter } from '@kbn/inspector-plugin/public'; @@ -38,7 +38,10 @@ export type DataMain$ = BehaviorSubject; export type DataDocuments$ = BehaviorSubject; export type DataTotalHits$ = BehaviorSubject; export type AvailableFields$ = BehaviorSubject; - +export type DataFetch$ = Observable<{ + reset: boolean; + searchSessionId: string; +}>; export type DataRefetch$ = Subject; export interface UseSavedSearch { @@ -151,46 +154,70 @@ export const useSavedSearch = ({ }>({}); /** - * This part takes care of triggering the data fetching by creating and subscribing - * to an observable of various possible changes in state + * handler emitted by `timefilter.getAutoRefreshFetch$()` + * to notify when data completed loading and to start a new autorefresh loop */ - useEffect(() => { - /** - * handler emitted by `timefilter.getAutoRefreshFetch$()` - * to notify when data completed loading and to start a new autorefresh loop - */ - const setAutoRefreshDone = (fn: AutoRefreshDoneFn | undefined) => { - refs.current.autoRefreshDone = fn; - }; - const fetch$ = getFetch$({ - setAutoRefreshDone, + const setAutoRefreshDone = useCallback((fn: AutoRefreshDoneFn | undefined) => { + refs.current.autoRefreshDone = fn; + }, []); + + /** + * Observable that allows listening for when fetches are triggered + */ + const fetch$ = useMemo( + () => + getFetch$({ + setAutoRefreshDone, + data, + main$, + refetch$, + searchSessionManager, + searchSource, + initialFetchStatus, + }).pipe( + filter(() => validateTimeRange(timefilter.getTime(), services.toastNotifications)), + tap(() => inspectorAdapters.requests.reset()), + map((val) => ({ + reset: val === 'reset', + searchSessionId: searchSessionManager.getNextSearchSessionId(), + })), + share() + ), + [ data, + initialFetchStatus, + inspectorAdapters.requests, main$, refetch$, searchSessionManager, searchSource, - initialFetchStatus, - }); - let abortController: AbortController; + services.toastNotifications, + setAutoRefreshDone, + timefilter, + ] + ); - const subscription = fetch$.subscribe(async (val) => { - if (!validateTimeRange(timefilter.getTime(), services.toastNotifications)) { - return; - } - inspectorAdapters.requests.reset(); + /** + * This part takes care of triggering the data fetching by creating and subscribing + * to an observable of various possible changes in state + */ + useEffect(() => { + let abortController: AbortController; + const subscription = fetch$.subscribe(async ({ reset, searchSessionId }) => { abortController?.abort(); abortController = new AbortController(); + const autoRefreshDone = refs.current.autoRefreshDone; - await fetchAll(dataSubjects, searchSource, val === 'reset', { + await fetchAll(dataSubjects, searchSource, reset, { abortController, appStateContainer: stateContainer.appState, data, initialFetchStatus, inspectorAdapters, savedSearch, - searchSessionId: searchSessionManager.getNextSearchSessionId(), + searchSessionId, services, useNewFieldsApi, }); @@ -213,6 +240,7 @@ export const useSavedSearch = ({ data, data.query.queryString, dataSubjects, + fetch$, filterManager, initialFetchStatus, inspectorAdapters, @@ -235,6 +263,7 @@ export const useSavedSearch = ({ ); return { + fetch$, refetch$, data$: dataSubjects, reset, diff --git a/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx b/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx index 96c23d085afcf..551f1d0bac626 100644 --- a/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx +++ b/src/plugins/discover/public/embeddable/saved_search_embeddable.tsx @@ -461,6 +461,7 @@ export class SavedSearchEmbeddable ); searchProps.sharedItemTitle = this.panelTitle; + searchProps.searchTitle = this.panelTitle; searchProps.rowHeightState = this.input.rowHeight || this.savedSearch.rowHeight; searchProps.rowsPerPageState = this.input.rowsPerPage || this.savedSearch.rowsPerPage; searchProps.filters = this.savedSearch.searchSource.getField('filter') as Filter[]; diff --git a/src/plugins/discover/public/hooks/use_confirm_persistence_prompt.ts b/src/plugins/discover/public/hooks/use_confirm_persistence_prompt.ts index 5332ffac6e0be..1f98837a8eb25 100644 --- a/src/plugins/discover/public/hooks/use_confirm_persistence_prompt.ts +++ b/src/plugins/discover/public/hooks/use_confirm_persistence_prompt.ts @@ -7,7 +7,7 @@ */ import { useCallback } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import type { DataView } from '@kbn/data-views-plugin/public'; import { SavedSearch } from '@kbn/saved-search-plugin/public'; @@ -25,7 +25,7 @@ export const useConfirmPersistencePrompt = (stateContainer: DiscoverStateContain try { const persistedDataView = await services.dataViews.createAndSave({ ...adHocDataView.toSpec(), - id: uuid(), + id: uuidv4(), }); services.dataViews.clearInstanceCache(adHocDataView.id); diff --git a/src/plugins/embeddable/public/lib/attribute_service/attribute_service.mock.tsx b/src/plugins/embeddable/public/lib/attribute_service/attribute_service.mock.tsx index e8c741cdb2e76..ca84ea6806faa 100644 --- a/src/plugins/embeddable/public/lib/attribute_service/attribute_service.mock.tsx +++ b/src/plugins/embeddable/public/lib/attribute_service/attribute_service.mock.tsx @@ -27,8 +27,6 @@ export const mockAttributeService = < const core = customCore ? customCore : coreMock.createStart(); return new AttributeService( type, - jest.fn(), - core.i18n.Context, core.notifications.toasts, options, jest.fn().mockReturnValue(() => ({ getDisplayName: () => type })) diff --git a/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx b/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx index 17a41e841abff..ff35b5f79f867 100644 --- a/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx +++ b/src/plugins/embeddable/public/lib/attribute_service/attribute_service.tsx @@ -9,8 +9,13 @@ import React from 'react'; import { i18n } from '@kbn/i18n'; import { get, omit } from 'lodash'; -import { I18nStart, NotificationsStart } from '@kbn/core/public'; -import { SavedObjectSaveModal, OnSaveProps, SaveResult } from '@kbn/saved-objects-plugin/public'; +import { NotificationsStart } from '@kbn/core/public'; +import { + SavedObjectSaveModal, + OnSaveProps, + SaveResult, + showSaveModal, +} from '@kbn/saved-objects-plugin/public'; import { EmbeddableInput, SavedObjectEmbeddableInput, @@ -61,11 +66,6 @@ export class AttributeService< > { constructor( private type: string, - private showSaveModal: ( - saveModal: React.ReactElement, - I18nContext: I18nStart['Context'] - ) => void, - private i18nContext: I18nStart['Context'], private toasts: NotificationsStart['toasts'], private options: AttributeServiceOptions, getEmbeddableFactory?: (embeddableFactoryId: string) => EmbeddableFactory @@ -178,7 +178,7 @@ export class AttributeService< } }; if (saveOptions && (saveOptions as { showSaveModal: boolean }).showSaveModal) { - this.showSaveModal( + showSaveModal( {}} @@ -190,8 +190,7 @@ export class AttributeService< showCopyOnSave={false} objectType={this.type} showDescription={false} - />, - this.i18nContext + /> ); } }); diff --git a/src/plugins/embeddable/public/lib/containers/container.ts b/src/plugins/embeddable/public/lib/containers/container.ts index d04350ccf9e59..847d1fa5cd5dc 100644 --- a/src/plugins/embeddable/public/lib/containers/container.ts +++ b/src/plugins/embeddable/public/lib/containers/container.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isEqual, xor } from 'lodash'; import { EMPTY, merge, Subscription } from 'rxjs'; import { @@ -336,7 +336,7 @@ export abstract class Container< factory: EmbeddableFactory, partial: Partial = {} ): PanelState { - const embeddableId = partial.id || uuid.v4(); + const embeddableId = partial.id || uuidv4(); const explicitInput = this.createNewExplicitEmbeddableInput( embeddableId, diff --git a/src/plugins/embeddable/public/plugin.tsx b/src/plugins/embeddable/public/plugin.tsx index fe0e93bdc95b6..698649c2cbd2a 100644 --- a/src/plugins/embeddable/public/plugin.tsx +++ b/src/plugins/embeddable/public/plugin.tsx @@ -10,7 +10,7 @@ import React from 'react'; import { Subscription } from 'rxjs'; import { identity } from 'lodash'; import type { SerializableRecord } from '@kbn/utility-types'; -import { getSavedObjectFinder, showSaveModal } from '@kbn/saved-objects-plugin/public'; +import { getSavedObjectFinder } from '@kbn/saved-objects-plugin/public'; import { UiActionsSetup, UiActionsStart } from '@kbn/ui-actions-plugin/public'; import { Start as InspectorStart } from '@kbn/inspector-plugin/public'; import { @@ -211,14 +211,7 @@ export class EmbeddablePublicPlugin implements Plugin - new AttributeService( - type, - showSaveModal, - core.i18n.Context, - core.notifications.toasts, - options, - this.getEmbeddableFactory - ), + new AttributeService(type, core.notifications.toasts, options, this.getEmbeddableFactory), getStateTransfer: (storage?: Storage) => storage ? new EmbeddableStateTransfer( diff --git a/src/plugins/es_ui_shared/static/forms/components/fields/checkbox_field.tsx b/src/plugins/es_ui_shared/static/forms/components/fields/checkbox_field.tsx index b6a1389ab6d43..a913f73af268b 100644 --- a/src/plugins/es_ui_shared/static/forms/components/fields/checkbox_field.tsx +++ b/src/plugins/es_ui_shared/static/forms/components/fields/checkbox_field.tsx @@ -8,7 +8,7 @@ import React from 'react'; import { EuiFormRow, EuiCheckbox } from '@elastic/eui'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FieldHook, getFieldValidityAndErrorMessage } from '../../hook_form_lib'; @@ -35,7 +35,7 @@ export const CheckBoxField = ({ field, euiFieldProps = {}, idAria, ...rest }: Pr label={field.label} checked={field.value as boolean} onChange={field.onChange} - id={euiFieldProps.id || uuid()} + id={euiFieldProps.id || uuidv4()} data-test-subj="input" {...euiFieldProps} /> diff --git a/src/plugins/expression_shape/common/lib/get_id.ts b/src/plugins/expression_shape/common/lib/get_id.ts index 9e4e4d6486349..c203ce9cf0586 100644 --- a/src/plugins/expression_shape/common/lib/get_id.ts +++ b/src/plugins/expression_shape/common/lib/get_id.ts @@ -6,8 +6,8 @@ * Side Public License, v 1. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export function getId(type: string): string { - return `${type}-${uuid()}`; + return `${type}-${uuidv4()}`; } diff --git a/src/plugins/files_management/kibana.json b/src/plugins/files_management/kibana.json index 2409c597f925e..20c177c7ed0b0 100755 --- a/src/plugins/files_management/kibana.json +++ b/src/plugins/files_management/kibana.json @@ -3,8 +3,8 @@ "version": "1.0.0", "kibanaVersion": "kibana", "owner": { - "name": "@elastic/kibana-global-experience", - "githubTeam": "@elastic/kibana-global-experience" + "name": "@elastic/appex-sharedux", + "githubTeam": "@elastic/appex-sharedux" }, "description": "Simple UI for managing files in Kibana", "server": false, diff --git a/src/plugins/guided_onboarding/common/index.ts b/src/plugins/guided_onboarding/common/index.ts index c6cdc14209df0..626aebed91688 100644 --- a/src/plugins/guided_onboarding/common/index.ts +++ b/src/plugins/guided_onboarding/common/index.ts @@ -7,12 +7,4 @@ */ export { PLUGIN_ID, PLUGIN_NAME, API_BASE_PATH } from './constants'; -export { testGuideConfig, testGuideId } from './test_guide_config'; -export type { - PluginStatus, - PluginState, - StepConfig, - GuideConfig, - GuidesConfig, - StepDescriptionWithLink, -} from './types'; +export type { PluginStatus, PluginState, GuidesConfig } from './types'; diff --git a/src/plugins/guided_onboarding/common/types.ts b/src/plugins/guided_onboarding/common/types.ts index 562807c949871..1081fa2f41358 100644 --- a/src/plugins/guided_onboarding/common/types.ts +++ b/src/plugins/guided_onboarding/common/types.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import type { GuideId, GuideState, GuideStepIds, StepStatus } from '@kbn/guided-onboarding'; +import type { GuideId, GuideState, GuideConfig } from '@kbn/guided-onboarding'; /** * Guided onboarding overall status: @@ -32,59 +32,6 @@ export interface PluginState { activeGuide?: GuideState; } -/* To append a link to the description, specify its text and url in the properties. - * An example: - * { - * description: 'This is a description with a link'. - * linkText: 'My link', - * linkUrl: 'example.com', - * isLinkExternal: true, - * } - * - */ -export interface StepDescriptionWithLink { - descriptionText: string; - linkText: string; - linkUrl: string; - isLinkExternal?: boolean; -} - -export interface StepConfig { - id: GuideStepIds; - title: string; - // description is displayed as a single paragraph, can be combined with description list - description?: string | StepDescriptionWithLink; - // description list is displayed as an unordered list, can be combined with description - descriptionList?: Array; - location?: { - appID: string; - path: string; - }; - status?: StepStatus; - integration?: string; - manualCompletion?: { - title: string; - description: string; - readyToCompleteOnNavigation?: boolean; - }; -} - -export interface GuideConfig { - title: string; - description: string; - guideName: string; - telemetryId: string; - docs?: { - text: string; - url: string; - }; - completedGuideRedirectLocation?: { - appID: string; - path: string; - }; - steps: StepConfig[]; -} - export type GuidesConfig = { [key in GuideId]: GuideConfig; }; diff --git a/src/plugins/guided_onboarding/public/components/guide_button.tsx b/src/plugins/guided_onboarding/public/components/guide_button.tsx index 16c51522bedb1..3e2df70298c60 100644 --- a/src/plugins/guided_onboarding/public/components/guide_button.tsx +++ b/src/plugins/guided_onboarding/public/components/guide_button.tsx @@ -9,9 +9,9 @@ import React from 'react'; import { EuiButton } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import type { GuideState } from '@kbn/guided-onboarding'; +import type { GuideState, GuideConfig } from '@kbn/guided-onboarding'; -import type { GuideConfig, PluginState } from '../../common'; +import type { PluginState } from '../../common'; import { GuideButtonPopover } from './guide_button_popover'; interface GuideButtonProps { diff --git a/src/plugins/guided_onboarding/public/components/guide_panel.test.tsx b/src/plugins/guided_onboarding/public/components/guide_panel.test.tsx index 2fe236a7d999d..d9cce292ad340 100644 --- a/src/plugins/guided_onboarding/public/components/guide_panel.test.tsx +++ b/src/plugins/guided_onboarding/public/components/guide_panel.test.tsx @@ -14,9 +14,10 @@ import { notificationServiceMock } from '@kbn/core-notifications-browser-mocks'; import { httpServiceMock } from '@kbn/core/public/mocks'; import type { HttpSetup } from '@kbn/core/public'; import { registerTestBed, TestBed } from '@kbn/test-jest-helpers'; +import { testGuideConfig, testGuideId } from '@kbn/guided-onboarding'; import type { PluginState } from '../../common'; -import { API_BASE_PATH, testGuideConfig, testGuideId } from '../../common'; +import { API_BASE_PATH } from '../../common'; import { apiService } from '../services/api'; import type { GuidedOnboardingApi } from '../types'; import { diff --git a/src/plugins/guided_onboarding/public/components/guide_panel.tsx b/src/plugins/guided_onboarding/public/components/guide_panel.tsx index 7ba811fec503c..7b84e9b586b7b 100644 --- a/src/plugins/guided_onboarding/public/components/guide_panel.tsx +++ b/src/plugins/guided_onboarding/public/components/guide_panel.tsx @@ -32,10 +32,10 @@ import { i18n } from '@kbn/i18n'; import { ApplicationStart, NotificationsStart } from '@kbn/core/public'; import type { GuideState, GuideStep as GuideStepStatus } from '@kbn/guided-onboarding'; -import { GuideId } from '@kbn/guided-onboarding'; +import type { GuideId, GuideConfig, StepConfig } from '@kbn/guided-onboarding'; import type { GuidedOnboardingApi } from '../types'; -import type { GuideConfig, PluginState, StepConfig } from '../../common'; +import type { PluginState } from '../../common'; import { GuideStep } from './guide_panel_step'; import { QuitGuideModal } from './quit_guide_modal'; diff --git a/src/plugins/guided_onboarding/public/components/guide_panel_step.tsx b/src/plugins/guided_onboarding/public/components/guide_panel_step.tsx index ba3cedae12e0e..447e0453e84dd 100644 --- a/src/plugins/guided_onboarding/public/components/guide_panel_step.tsx +++ b/src/plugins/guided_onboarding/public/components/guide_panel_step.tsx @@ -22,8 +22,7 @@ import { import { i18n } from '@kbn/i18n'; -import type { StepStatus } from '@kbn/guided-onboarding'; -import type { StepDescriptionWithLink, StepConfig } from '../../common'; +import type { StepStatus, StepConfig, StepDescriptionWithLink } from '@kbn/guided-onboarding'; import { getGuidePanelStepStyles } from './guide_panel_step.styles'; interface GuideStepProps { diff --git a/src/plugins/guided_onboarding/public/services/api.test.ts b/src/plugins/guided_onboarding/public/services/api.test.ts index 23a2343f6a6e7..5146d2df72ddb 100644 --- a/src/plugins/guided_onboarding/public/services/api.test.ts +++ b/src/plugins/guided_onboarding/public/services/api.test.ts @@ -9,9 +9,10 @@ import { HttpSetup } from '@kbn/core/public'; import { httpServiceMock } from '@kbn/core/public/mocks'; import type { GuideState } from '@kbn/guided-onboarding'; +import { testGuideConfig, testGuideId } from '@kbn/guided-onboarding'; import { firstValueFrom, Subscription } from 'rxjs'; -import { API_BASE_PATH, testGuideConfig, testGuideId } from '../../common'; +import { API_BASE_PATH } from '../../common'; import { ApiService } from './api'; import { testGuideFirstStep, diff --git a/src/plugins/guided_onboarding/public/services/api.ts b/src/plugins/guided_onboarding/public/services/api.ts index d6ff80cf680b2..5ab9bed187f6b 100644 --- a/src/plugins/guided_onboarding/public/services/api.ts +++ b/src/plugins/guided_onboarding/public/services/api.ts @@ -17,10 +17,16 @@ import { concat, from, } from 'rxjs'; -import type { GuideState, GuideId, GuideStep, GuideStepIds } from '@kbn/guided-onboarding'; +import type { + GuideState, + GuideId, + GuideStep, + GuideStepIds, + GuideConfig, +} from '@kbn/guided-onboarding'; import { API_BASE_PATH } from '../../common'; -import type { PluginState, PluginStatus, GuideConfig } from '../../common'; +import type { PluginState, PluginStatus } from '../../common'; import { GuidedOnboardingApi } from '../types'; import { getInProgressStepId, @@ -169,7 +175,7 @@ export class ApiService implements GuidedOnboardingApi { /** * Activates a guide by guideId. * This is useful for the onboarding landing page, when a user selects a guide to start or continue. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @param {GuideState} guide (optional) the selected guide state, if it exists (i.e., if a user is continuing a guide) * @return {Promise} a promise with the updated plugin state */ @@ -247,7 +253,7 @@ export class ApiService implements GuidedOnboardingApi { * Completes a guide. * Updates the overall guide status to 'complete', and marks it as inactive. * This is useful for the dropdown panel, when the user clicks the "Continue using Elastic" button after completing all steps. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @return {Promise} a promise with the updated plugin state */ public async completeGuide(guideId: GuideId): Promise<{ pluginState: PluginState } | undefined> { @@ -277,7 +283,7 @@ export class ApiService implements GuidedOnboardingApi { * An observable with the boolean value if the step is in progress (i.e., user clicked "Start" on a step). * Returns true, if the passed params identify the guide step that is currently in progress. * Returns false otherwise. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @param {GuideStepIds} stepId the id of the step in the guide * @return {Observable} an observable with the boolean value */ @@ -294,7 +300,7 @@ export class ApiService implements GuidedOnboardingApi { * An observable with the boolean value if the step is ready_to_complete (i.e., user needs to click the "Mark done" button). * Returns true, if the passed params identify the guide step that is currently ready_to_complete. * Returns false otherwise. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @param {GuideStepIds} stepId the id of the step in the guide * @return {Observable} an observable with the boolean value */ @@ -310,7 +316,7 @@ export class ApiService implements GuidedOnboardingApi { /** * Updates the selected step to 'in_progress' state. * This is useful for the dropdown panel, when the user clicks the "Start" button for the active step. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @param {GuideStepIds} stepId the id of the step * @return {Promise} a promise with the updated plugin state */ @@ -352,7 +358,7 @@ export class ApiService implements GuidedOnboardingApi { /** * Completes the guide step identified by the passed params. * A noop if the passed step is not active. - * @param {GuideId} guideId the id of the guide (one of search, observability, security) + * @param {GuideId} guideId the id of the guide (one of search, kubernetes, siem) * @param {GuideStepIds} stepId the id of the step in the guide * @return {Promise} a promise with the updated state or undefined if the operation fails */ diff --git a/src/plugins/guided_onboarding/public/services/config_service.test.ts b/src/plugins/guided_onboarding/public/services/config_service.test.ts index b5be4500732fe..98aa0deb35701 100644 --- a/src/plugins/guided_onboarding/public/services/config_service.test.ts +++ b/src/plugins/guided_onboarding/public/services/config_service.test.ts @@ -7,8 +7,9 @@ */ import { HttpSetup } from '@kbn/core-http-browser'; +import { testGuideConfig, testGuideId } from '@kbn/guided-onboarding'; import { httpServiceMock } from '@kbn/core-http-browser-mocks'; -import { API_BASE_PATH, testGuideConfig, testGuideId } from '../../common'; +import { API_BASE_PATH } from '../../common'; import { testGuideNotActiveState, testGuideStep1InProgressState, diff --git a/src/plugins/guided_onboarding/public/services/config_service.ts b/src/plugins/guided_onboarding/public/services/config_service.ts index b0bea7deb47bc..8dcb478c5af99 100644 --- a/src/plugins/guided_onboarding/public/services/config_service.ts +++ b/src/plugins/guided_onboarding/public/services/config_service.ts @@ -7,8 +7,8 @@ */ import { HttpSetup } from '@kbn/core-http-browser'; -import { GuideId, GuideState, GuideStatus } from '@kbn/guided-onboarding'; -import type { GuideConfig, GuidesConfig } from '../../common'; +import { GuideId, GuideState, GuideStatus, GuideConfig } from '@kbn/guided-onboarding'; +import type { GuidesConfig } from '../../common'; import { API_BASE_PATH } from '../../common'; import { findGuideConfigByGuideId, getInProgressStepConfig } from './helpers'; diff --git a/src/plugins/guided_onboarding/public/services/helpers.test.ts b/src/plugins/guided_onboarding/public/services/helpers.test.ts index 89f78c588d7c9..661f10fcbe5b1 100644 --- a/src/plugins/guided_onboarding/public/services/helpers.test.ts +++ b/src/plugins/guided_onboarding/public/services/helpers.test.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import { testGuideConfig, testGuideId } from '../../common'; +import { testGuideConfig, testGuideId } from '@kbn/guided-onboarding'; import type { GuidesConfig } from '../../common'; import { findGuideConfigByGuideId, diff --git a/src/plugins/guided_onboarding/public/services/helpers.ts b/src/plugins/guided_onboarding/public/services/helpers.ts index 05e8861589da3..c0b29c846a3ca 100644 --- a/src/plugins/guided_onboarding/public/services/helpers.ts +++ b/src/plugins/guided_onboarding/public/services/helpers.ts @@ -12,8 +12,10 @@ import type { GuideState, GuideStep, StepStatus, + GuideConfig, + StepConfig, } from '@kbn/guided-onboarding'; -import type { GuidesConfig, PluginState, GuideConfig, StepConfig } from '../../common'; +import type { GuidesConfig, PluginState } from '../../common'; export const findGuideConfigByGuideId = ( guidesConfig?: GuidesConfig, diff --git a/src/plugins/guided_onboarding/public/types.ts b/src/plugins/guided_onboarding/public/types.ts index 493ff13c8249d..1b0ccc7d925b3 100755 --- a/src/plugins/guided_onboarding/public/types.ts +++ b/src/plugins/guided_onboarding/public/types.ts @@ -8,9 +8,9 @@ import { Observable } from 'rxjs'; import { HttpSetup } from '@kbn/core/public'; -import type { GuideState, GuideId, GuideStepIds } from '@kbn/guided-onboarding'; +import type { GuideState, GuideId, GuideStepIds, GuideConfig } from '@kbn/guided-onboarding'; import type { CloudStart } from '@kbn/cloud-plugin/public'; -import type { PluginStatus, PluginState, GuideConfig } from '../common'; +import type { PluginStatus, PluginState } from '../common'; // eslint-disable-next-line @typescript-eslint/no-empty-interface export interface GuidedOnboardingPluginSetup {} diff --git a/src/plugins/guided_onboarding/server/index.ts b/src/plugins/guided_onboarding/server/index.ts index 75d907b699fee..12eb46043cf23 100755 --- a/src/plugins/guided_onboarding/server/index.ts +++ b/src/plugins/guided_onboarding/server/index.ts @@ -14,4 +14,3 @@ export function plugin(initializerContext: PluginInitializerContext) { } export type { GuidedOnboardingPluginSetup, GuidedOnboardingPluginStart } from './types'; -export { testGuideConfig } from '../common/test_guide_config'; diff --git a/src/plugins/guided_onboarding/server/plugin.ts b/src/plugins/guided_onboarding/server/plugin.ts index 84623695c5fcb..f264771d780ee 100755 --- a/src/plugins/guided_onboarding/server/plugin.ts +++ b/src/plugins/guided_onboarding/server/plugin.ts @@ -8,24 +8,21 @@ import { PluginInitializerContext, CoreSetup, Plugin, Logger } from '@kbn/core/server'; -import type { GuideId } from '@kbn/guided-onboarding'; +import type { GuideId, GuideConfig } from '@kbn/guided-onboarding'; import { GuidedOnboardingPluginSetup, GuidedOnboardingPluginStart } from './types'; import { defineRoutes } from './routes'; import { guideStateSavedObjects, pluginStateSavedObjects } from './saved_objects'; -import type { GuideConfig, GuidesConfig } from '../common'; -import { testGuideConfig, testGuideId } from '../common'; +import type { GuidesConfig } from '../common'; export class GuidedOnboardingPlugin implements Plugin { private readonly logger: Logger; private readonly guidesConfig: GuidesConfig; - private readonly isDevMode: boolean; constructor(initializerContext: PluginInitializerContext) { this.logger = initializerContext.logger.get(); this.guidesConfig = {} as GuidesConfig; - this.isDevMode = initializerContext.env.mode.dev; } public setup(core: CoreSetup) { @@ -39,10 +36,6 @@ export class GuidedOnboardingPlugin core.savedObjects.registerType(guideStateSavedObjects); core.savedObjects.registerType(pluginStateSavedObjects); - // add a config for a test guide if running in dev mode - if (this.isDevMode) { - this.guidesConfig[testGuideId] = testGuideConfig; - } return { registerGuideConfig: (guideId: GuideId, guideConfig: GuideConfig) => { if (this.guidesConfig[guideId]) { diff --git a/src/plugins/guided_onboarding/server/types.ts b/src/plugins/guided_onboarding/server/types.ts index ac3249452998a..bcfa03c0cc41a 100755 --- a/src/plugins/guided_onboarding/server/types.ts +++ b/src/plugins/guided_onboarding/server/types.ts @@ -6,8 +6,7 @@ * Side Public License, v 1. */ -import type { GuideId } from '@kbn/guided-onboarding'; -import type { GuideConfig } from '../common'; +import type { GuideId, GuideConfig } from '@kbn/guided-onboarding'; export interface GuidedOnboardingPluginSetup { registerGuideConfig: (guideId: GuideId, guideConfig: GuideConfig) => void; diff --git a/src/plugins/home/public/application/components/add_data/__snapshots__/add_data.test.tsx.snap b/src/plugins/home/public/application/components/add_data/__snapshots__/add_data.test.tsx.snap index 69a17834fc4d3..5ee8bb9a10d79 100644 --- a/src/plugins/home/public/application/components/add_data/__snapshots__/add_data.test.tsx.snap +++ b/src/plugins/home/public/application/components/add_data/__snapshots__/add_data.test.tsx.snap @@ -103,61 +103,37 @@ exports[`AddData render 1`] = ` - - - - - - - -

    - -

    -
    - - - - - - - - -
    -
    -
    +
    diff --git a/src/plugins/home/public/application/components/add_data/add_data.tsx b/src/plugins/home/public/application/components/add_data/add_data.tsx index 295c058e35e2c..086e28cbb1f83 100644 --- a/src/plugins/home/public/application/components/add_data/add_data.tsx +++ b/src/plugins/home/public/application/components/add_data/add_data.tsx @@ -14,7 +14,6 @@ import { EuiFlexGroup, EuiFlexItem, EuiImage, - EuiPanel, EuiSpacer, EuiText, EuiTitle, @@ -24,6 +23,7 @@ import { FormattedMessage } from '@kbn/i18n-react'; import { METRIC_TYPE } from '@kbn/analytics'; import { ApplicationStart } from '@kbn/core/public'; import { RedirectAppLinks } from '@kbn/kibana-react-plugin/public'; +import { MoveData } from '../move_data'; import { createAppNavigationHandler } from '../app_navigation_handler'; import { getServices } from '../../kibana_services'; @@ -140,62 +140,10 @@ export const AddData: FC = ({ addBasePath, application, isDarkMode, isClo - {!isCloudEnabled ? ( - - - - - - - - -

    - -

    -
    - - - - - - - - - - {/* eslint-disable-next-line @elastic/eui/href-or-on-click */} - { - trackUiMetric(METRIC_TYPE.CLICK, 'migrate_data_to_cloud'); - createAppNavigationHandler('/app/management/data/migrate_data')(event); - }} - > - - -
    -
    -
    -
    - ) : ( - + + {!isCloudEnabled ? ( + + ) : ( = ({ addBasePath, application, isDarkMode, isClo : 'illustration_integrations_lightmode.svg') } /> - - )} + )} + ); diff --git a/src/plugins/home/public/application/components/move_data/index.tsx b/src/plugins/home/public/application/components/move_data/index.tsx new file mode 100644 index 0000000000000..f00275bf7b924 --- /dev/null +++ b/src/plugins/home/public/application/components/move_data/index.tsx @@ -0,0 +1,9 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +export * from './move_data'; diff --git a/src/plugins/home/public/application/components/move_data/move_data.test.tsx b/src/plugins/home/public/application/components/move_data/move_data.test.tsx new file mode 100644 index 0000000000000..9c92afbf01ac3 --- /dev/null +++ b/src/plugins/home/public/application/components/move_data/move_data.test.tsx @@ -0,0 +1,22 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React from 'react'; +import { MoveData } from './move_data'; +import { shallowWithIntl } from '@kbn/test-jest-helpers'; + +const addBasePathMock = jest.fn((path: string) => (path ? path : 'path')); + +describe('MoveData', () => { + test('renders as expected', () => { + const component = shallowWithIntl(); + + const $button = component.find('EuiButton'); + expect($button.props().href).toBe('/app/management/data/migrate_data'); + }); +}); diff --git a/src/plugins/home/public/application/components/move_data/move_data.tsx b/src/plugins/home/public/application/components/move_data/move_data.tsx new file mode 100644 index 0000000000000..ce97e71a6ecd8 --- /dev/null +++ b/src/plugins/home/public/application/components/move_data/move_data.tsx @@ -0,0 +1,80 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import React, { FC, MouseEvent } from 'react'; +import { + EuiButton, + EuiFlexGroup, + EuiFlexItem, + EuiImage, + EuiPanel, + EuiSpacer, + EuiText, + EuiTitle, +} from '@elastic/eui'; +import { FormattedMessage } from '@kbn/i18n-react'; +import { i18n } from '@kbn/i18n'; +import { createAppNavigationHandler } from '../app_navigation_handler'; + +interface Props { + addBasePath: (path: string) => string; +} + +export const MoveData: FC = ({ addBasePath }) => { + const migrateDataUrl = '/app/management/data/migrate_data'; + const buttonLabel = ( + + ); + + return ( + + + + + + + +

    + +

    +
    + + + + + + {/* eslint-disable-next-line @elastic/eui/href-or-on-click */} + { + createAppNavigationHandler(migrateDataUrl)(event); + }} + > + {buttonLabel} + +
    +
    +
    + ); +}; diff --git a/src/plugins/image_embeddable/kibana.json b/src/plugins/image_embeddable/kibana.json index b8398ce935e96..dcf931d779e11 100644 --- a/src/plugins/image_embeddable/kibana.json +++ b/src/plugins/image_embeddable/kibana.json @@ -4,8 +4,8 @@ "server": false, "ui": true, "owner": { - "name": "@elastic/kibana-global-experience", - "githubTeam": "@elastic/kibana-global-experience" + "name": "@elastic/appex-sharedux", + "githubTeam": "@elastic/appex-sharedux" }, "description": "Image embeddable", "requiredPlugins": ["embeddable", "files", "uiActions"], diff --git a/src/plugins/inspector/common/adapters/request/request_adapter.ts b/src/plugins/inspector/common/adapters/request/request_adapter.ts index 913f16f74b8e2..3054441957942 100644 --- a/src/plugins/inspector/common/adapters/request/request_adapter.ts +++ b/src/plugins/inspector/common/adapters/request/request_adapter.ts @@ -7,7 +7,7 @@ */ import { EventEmitter } from 'events'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { RequestResponder } from './request_responder'; import { Request, RequestParams, RequestStatus } from './types'; @@ -47,7 +47,7 @@ export class RequestAdapter extends EventEmitter { name, startTime, status: RequestStatus.PENDING, - id: params.id ?? uuid(), + id: params.id ?? uuidv4(), }; this.requests.set(req.id, req); this._onChange(); diff --git a/src/plugins/saved_objects/public/kibana_services.ts b/src/plugins/saved_objects/public/kibana_services.ts new file mode 100644 index 0000000000000..aae1769afd72a --- /dev/null +++ b/src/plugins/saved_objects/public/kibana_services.ts @@ -0,0 +1,17 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import type { CoreStart } from '@kbn/core/public'; + +let coreStart: CoreStart; +export function setStartServices(core: CoreStart) { + coreStart = core; +} + +export const getI18n = () => coreStart.i18n; +export const getTheme = () => coreStart.theme; diff --git a/src/plugins/saved_objects/public/plugin.ts b/src/plugins/saved_objects/public/plugin.ts index dda247b191a3a..e1b7a16903b72 100644 --- a/src/plugins/saved_objects/public/plugin.ts +++ b/src/plugins/saved_objects/public/plugin.ts @@ -18,6 +18,7 @@ import { } from './saved_object'; import { PER_PAGE_SETTING, LISTING_LIMIT_SETTING } from '../common'; import { SavedObject } from './types'; +import { setStartServices } from './kibana_services'; export interface SavedObjectSetup { registerDecorator: (config: SavedObjectDecoratorConfig) => void; @@ -63,6 +64,7 @@ export class SavedObjectsPublicPlugin }; } public start(core: CoreStart, { data, dataViews }: SavedObjectsStartDeps) { + setStartServices(core); return { SavedObjectClass: createSavedObjectClass( { diff --git a/src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx b/src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx index 615724ae5f237..55c45e276230a 100644 --- a/src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx +++ b/src/plugins/saved_objects/public/save_modal/show_saved_object_save_modal.tsx @@ -9,7 +9,8 @@ import React from 'react'; import ReactDOM from 'react-dom'; -import { I18nStart } from '@kbn/core/public'; +import { KibanaThemeProvider } from '@kbn/kibana-react-plugin/public'; +import { getI18n, getTheme } from '../kibana_services'; /** * Represents the result of trying to persist the saved object. @@ -31,7 +32,6 @@ interface MinimalSaveModalProps { export function showSaveModal( saveModal: React.ReactElement, - I18nContext: I18nStart['Context'], Wrapper?: React.FC ) { const container = document.createElement('div'); @@ -57,13 +57,11 @@ export function showSaveModal( onClose: closeModal, }); - const wrappedElement = Wrapper ? ( - - {element} - - ) : ( - {element} + const I18nContext = getI18n().Context; + ReactDOM.render( + + {Wrapper ? {element} : element} + , + container ); - - ReactDOM.render(wrappedElement, container); } diff --git a/src/plugins/saved_objects_management/public/lib/bulk_delete_objects.ts b/src/plugins/saved_objects_management/public/lib/bulk_delete_objects.ts new file mode 100644 index 0000000000000..30a02f8fa42aa --- /dev/null +++ b/src/plugins/saved_objects_management/public/lib/bulk_delete_objects.ts @@ -0,0 +1,29 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { HttpStart } from '@kbn/core/public'; +import { SavedObjectError, SavedObjectTypeIdTuple } from '@kbn/core-saved-objects-common'; + +interface SavedObjectDeleteStatus { + id: string; + success: boolean; + type: string; + error?: SavedObjectError; +} + +export function bulkDeleteObjects( + http: HttpStart, + objects: SavedObjectTypeIdTuple[] +): Promise { + return http.post( + '/internal/kibana/management/saved_objects/_bulk_delete', + { + body: JSON.stringify(objects), + } + ); +} diff --git a/src/plugins/saved_objects_management/public/lib/index.ts b/src/plugins/saved_objects_management/public/lib/index.ts index 258387c39ecd9..1833e4e75f327 100644 --- a/src/plugins/saved_objects_management/public/lib/index.ts +++ b/src/plugins/saved_objects_management/public/lib/index.ts @@ -18,6 +18,7 @@ export type { ProcessedImportResponse, FailedImport } from './process_import_res export { processImportResponse } from './process_import_response'; export { getDefaultTitle } from './get_default_title'; export { findObjects } from './find_objects'; +export { bulkDeleteObjects } from './bulk_delete_objects'; export { bulkGetObjects } from './bulk_get_objects'; export type { SavedObjectsExportResultDetails } from './extract_export_details'; export { extractExportDetails } from './extract_export_details'; diff --git a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.mocks.ts b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.mocks.ts index 7243955100690..57cb3bb07fdd3 100644 --- a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.mocks.ts +++ b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.mocks.ts @@ -23,3 +23,8 @@ export const bulkGetObjectsMock = jest.fn(); jest.doMock('../../lib/bulk_get_objects', () => ({ bulkGetObjects: bulkGetObjectsMock, })); + +export const bulkDeleteObjectsMock = jest.fn(); +jest.doMock('../../lib/bulk_delete_objects', () => ({ + bulkDeleteObjects: bulkDeleteObjectsMock, +})); diff --git a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.tsx b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.tsx index fd7d71a39dcd2..9bbbfb98a6298 100644 --- a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.tsx +++ b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.test.tsx @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import { bulkGetObjectsMock } from './saved_object_view.test.mocks'; +import { bulkDeleteObjectsMock, bulkGetObjectsMock } from './saved_object_view.test.mocks'; import React from 'react'; import { ShallowWrapper } from 'enzyme'; @@ -16,13 +16,13 @@ import { httpServiceMock, overlayServiceMock, notificationServiceMock, - savedObjectsServiceMock, applicationServiceMock, uiSettingsServiceMock, scopedHistoryMock, docLinksServiceMock, } from '@kbn/core/public/mocks'; +import type { SavedObjectWithMetadata } from '../../types'; import { SavedObjectEdition, SavedObjectEditionProps, @@ -36,7 +36,6 @@ describe('SavedObjectEdition', () => { let http: ReturnType; let overlays: ReturnType; let notifications: ReturnType; - let savedObjects: ReturnType; let uiSettings: ReturnType; let history: ReturnType; let applications: ReturnType; @@ -56,7 +55,6 @@ describe('SavedObjectEdition', () => { http = httpServiceMock.createStartContract(); overlays = overlayServiceMock.createStartContract(); notifications = notificationServiceMock.createStartContract(); - savedObjects = savedObjectsServiceMock.createStartContract(); uiSettings = uiSettingsServiceMock.createStartContract(); history = scopedHistoryMock.create(); docLinks = docLinksServiceMock.createStartContract(); @@ -81,35 +79,32 @@ describe('SavedObjectEdition', () => { capabilities: applications.capabilities, overlays, notifications, - savedObjectsClient: savedObjects.client, history, uiSettings, docLinks: docLinks.links, }; - bulkGetObjectsMock.mockImplementation(() => [{}]); + bulkDeleteObjectsMock.mockResolvedValue([{}]); }); it('should render normally', async () => { - bulkGetObjectsMock.mockImplementation(() => - Promise.resolve([ - { - id: '1', - type: 'dashboard', - attributes: { - title: `MyDashboard*`, - }, - meta: { - title: `MyDashboard*`, - icon: 'dashboardApp', - inAppUrl: { - path: '/app/dashboards#/view/1', - uiCapabilitiesPath: 'management.kibana.dashboard', - }, + bulkGetObjectsMock.mockResolvedValue([ + { + id: '1', + type: 'dashboard', + attributes: { + title: `MyDashboard*`, + }, + meta: { + title: `MyDashboard*`, + icon: 'dashboardApp', + inAppUrl: { + path: '/app/dashboards#/view/1', + uiCapabilitiesPath: 'management.kibana.dashboard', }, }, - ]) - ); + } as SavedObjectWithMetadata, + ]); const component = shallowRender(); // Ensure all promises resolve await resolvePromises(); @@ -119,15 +114,15 @@ describe('SavedObjectEdition', () => { }); it('should add danger toast when bulk get fails', async () => { - bulkGetObjectsMock.mockImplementation(() => - Promise.resolve([ - { - error: { - message: 'Not found', - }, + bulkGetObjectsMock.mockResolvedValue([ + { + error: { + error: '', + message: 'Not found', + statusCode: 404, }, - ]) - ); + } as SavedObjectWithMetadata, + ]); const component = shallowRender({ notFoundType: 'does_not_exist' }); await resolvePromises(); @@ -165,8 +160,8 @@ describe('SavedObjectEdition', () => { }, hiddenType: false, }, - }; - bulkGetObjectsMock.mockImplementation(() => Promise.resolve([savedObjectItem])); + } as SavedObjectWithMetadata; + bulkGetObjectsMock.mockResolvedValue([savedObjectItem]); applications.capabilities = { navLinks: {}, management: {}, @@ -232,14 +227,9 @@ describe('SavedObjectEdition', () => { }, hiddenType: false, }, - }; + } as SavedObjectWithMetadata; - it('should display a confirmation message on deleting the saved object', async () => { - bulkGetObjectsMock.mockImplementation(() => Promise.resolve([savedObjectItem])); - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - delete: jest.fn().mockImplementation(() => ({})), - }; + beforeEach(() => { applications.capabilities = { navLinks: {}, management: {}, @@ -250,13 +240,13 @@ describe('SavedObjectEdition', () => { delete: true, }, }; + }); + + it('should display a confirmation message on deleting the saved object', async () => { + bulkGetObjectsMock.mockResolvedValue([savedObjectItem]); overlays.openConfirm.mockResolvedValue(false); - const component = shallowRender({ - capabilities: applications.capabilities, - savedObjectsClient: mockSavedObjectsClient, - overlays, - }); + const component = shallowRender(); await resolvePromises(); component.update(); @@ -272,28 +262,10 @@ describe('SavedObjectEdition', () => { }); it('should route back if action is confirm and user accepted', async () => { - bulkGetObjectsMock.mockImplementation(() => Promise.resolve([savedObjectItem])); - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - delete: jest.fn().mockImplementation(() => ({})), - }; - applications.capabilities = { - navLinks: {}, - management: {}, - catalogue: {}, - savedObjectsManagement: { - read: true, - edit: false, - delete: true, - }, - }; + bulkGetObjectsMock.mockResolvedValue([savedObjectItem]); overlays.openConfirm.mockResolvedValue(true); - const component = shallowRender({ - capabilities: applications.capabilities, - savedObjectsClient: mockSavedObjectsClient, - overlays, - }); + const component = shallowRender(); await resolvePromises(); component.update(); @@ -303,27 +275,34 @@ describe('SavedObjectEdition', () => { }); it('should not enable delete if the saved object is hidden', async () => { - bulkGetObjectsMock.mockImplementation(() => - Promise.resolve([{ ...savedObjectItem, meta: { hiddenType: true } }]) - ); - applications.capabilities = { - navLinks: {}, - management: {}, - catalogue: {}, - savedObjectsManagement: { - read: true, - edit: false, - delete: true, - }, - }; - const component = shallowRender({ - capabilities: applications.capabilities, - }); + bulkGetObjectsMock.mockResolvedValue([{ ...savedObjectItem, meta: { hiddenType: true } }]); + const component = shallowRender(); await resolvePromises(); component.update(); expect(component.find('Header').prop('canDelete')).toBe(false); }); + + it('should show a danger toast when bulk deletion fails', async () => { + bulkGetObjectsMock.mockResolvedValue([savedObjectItem]); + bulkDeleteObjectsMock.mockResolvedValue([ + { + error: { message: 'Something went wrong.' }, + success: false, + }, + ]); + + const component = shallowRender(); + await resolvePromises(); + + component.update(); + await component.instance().delete(); + expect(notifications.toasts.addDanger).toHaveBeenCalledWith( + expect.objectContaining({ + text: 'Something went wrong.', + }) + ); + }); }); }); diff --git a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.tsx b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.tsx index 6a695858fca35..e5e62fbf95c92 100644 --- a/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.tsx +++ b/src/plugins/saved_objects_management/public/management_section/object_view/saved_object_view.tsx @@ -13,7 +13,6 @@ import { get } from 'lodash'; import { KibanaContextProvider } from '@kbn/kibana-react-plugin/public'; import { Capabilities, - SavedObjectsClientContract, OverlayStart, NotificationsStart, ScopedHistory, @@ -22,7 +21,7 @@ import { DocLinksStart, } from '@kbn/core/public'; import { Header, Inspect, NotFoundErrors } from './components'; -import { bulkGetObjects } from '../../lib/bulk_get_objects'; +import { bulkDeleteObjects, bulkGetObjects } from '../../lib'; import { SavedObjectWithMetadata } from '../../types'; import './saved_object_view.scss'; export interface SavedObjectEditionProps { @@ -33,7 +32,6 @@ export interface SavedObjectEditionProps { overlays: OverlayStart; notifications: NotificationsStart; notFoundType?: string; - savedObjectsClient: SavedObjectsClientContract; history: ScopedHistory; uiSettings: IUiSettingsClient; docLinks: DocLinksStart['links']; @@ -129,7 +127,7 @@ export class SavedObjectEdition extends Component< } async delete() { - const { id, savedObjectsClient, overlays, notifications } = this.props; + const { http, id, overlays, notifications } = this.props; const { type, object } = this.state; const confirmed = await overlays.openConfirm( @@ -146,17 +144,37 @@ export class SavedObjectEdition extends Component< title: i18n.translate('savedObjectsManagement.deleteConfirm.modalTitle', { defaultMessage: `Delete '{title}'?`, values: { - title: object?.attributes?.title || 'saved Kibana object', + title: object?.meta?.title || 'saved Kibana object', }, }), buttonColor: 'danger', } ); - if (confirmed) { - await savedObjectsClient.delete(type, id); - notifications.toasts.addSuccess(`Deleted '${object!.attributes.title}' ${type} object`); - this.redirectToListing(); + if (!confirmed) { + return; } + + const [{ success, error }] = await bulkDeleteObjects(http, [{ id, type }]); + if (!success) { + notifications.toasts.addDanger({ + title: i18n.translate( + 'savedObjectsManagement.objectView.unableDeleteSavedObjectNotificationMessage', + { + defaultMessage: `Failed to delete '{title}' {type} object`, + values: { + type, + title: object?.meta?.title, + }, + } + ), + text: error?.message, + }); + + return; + } + + notifications.toasts.addSuccess(`Deleted '${object?.meta?.title}' ${type} object`); + this.redirectToListing(); } redirectToListing() { diff --git a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.mocks.ts b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.mocks.ts index 8c6b3db0bce94..e5ece8b707cf1 100644 --- a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.mocks.ts +++ b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.mocks.ts @@ -58,3 +58,13 @@ export const getRelationshipsMock = jest.fn(); jest.doMock('../../lib/get_relationships', () => ({ getRelationships: getRelationshipsMock, })); + +export const bulkGetObjectsMock = jest.fn(); +jest.doMock('../../lib/bulk_get_objects', () => ({ + bulkGetObjects: bulkGetObjectsMock, +})); + +export const bulkDeleteObjectsMock = jest.fn(); +jest.doMock('../../lib/bulk_delete_objects', () => ({ + bulkDeleteObjects: bulkDeleteObjectsMock, +})); diff --git a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.tsx b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.tsx index 28a31890664b9..e08d0cde6c7cd 100644 --- a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.tsx +++ b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.test.tsx @@ -7,6 +7,8 @@ */ import { + bulkDeleteObjectsMock, + bulkGetObjectsMock, extractExportDetailsMock, fetchExportByTypeAndSearchMock, fetchExportObjectsMock, @@ -17,6 +19,7 @@ import { } from './saved_objects_table.test.mocks'; import React from 'react'; +import { pick } from 'lodash'; import { Query } from '@elastic/eui'; import { ShallowWrapper } from 'enzyme'; import { shallowWithI18nProvider } from '@kbn/test-jest-helpers'; @@ -24,7 +27,6 @@ import { httpServiceMock, overlayServiceMock, notificationServiceMock, - savedObjectsServiceMock, applicationServiceMock, } from '@kbn/core/public/mocks'; import { dataPluginMock } from '@kbn/data-plugin/public/mocks'; @@ -85,7 +87,6 @@ describe('SavedObjectsTable', () => { let http: ReturnType; let overlays: ReturnType; let notifications: ReturnType; - let savedObjects: ReturnType; let search: ReturnType['search']; const shallowRender = (overrides: Partial = {}) => { @@ -104,7 +105,6 @@ describe('SavedObjectsTable', () => { http = httpServiceMock.createStartContract(); overlays = overlayServiceMock.createStartContract(); notifications = notificationServiceMock.createStartContract(); - savedObjects = savedObjectsServiceMock.createStartContract(); search = dataPluginMock.createStartContract().search; const applications = applicationServiceMock.createStartContract(); @@ -132,7 +132,6 @@ describe('SavedObjectsTable', () => { allowedTypes, actionRegistry: actionServiceMock.createStart(), columnRegistry: columnServiceMock.createStart(), - savedObjectsClient: savedObjects.client, dataViews: dataViewPluginMocks.createStartContract(), http, overlays, @@ -236,15 +235,9 @@ describe('SavedObjectsTable', () => { _id: obj.id, _source: {}, })); + bulkGetObjectsMock.mockResolvedValue(mockSavedObjects); - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - bulkGet: jest.fn().mockImplementation(() => ({ - savedObjects: mockSavedObjects, - })), - }; - - const component = shallowRender({ savedObjectsClient: mockSavedObjectsClient }); + const component = shallowRender(); // Ensure all promises resolve await new Promise((resolve) => process.nextTick(resolve)); @@ -272,13 +265,7 @@ describe('SavedObjectsTable', () => { _id: obj.id, _source: {}, })); - - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - bulkGet: jest.fn().mockImplementation(() => ({ - savedObjects: mockSavedObjects, - })), - }; + bulkGetObjectsMock.mockResolvedValue(mockSavedObjects); extractExportDetailsMock.mockImplementation(() => ({ exportedCount: 2, @@ -288,7 +275,7 @@ describe('SavedObjectsTable', () => { excludedObjects: [], })); - const component = shallowRender({ savedObjectsClient: mockSavedObjectsClient }); + const component = shallowRender(); // Ensure all promises resolve await new Promise((resolve) => process.nextTick(resolve)); @@ -319,13 +306,7 @@ describe('SavedObjectsTable', () => { _id: obj.id, _source: {}, })); - - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - bulkGet: jest.fn().mockImplementation(() => ({ - savedObjects: mockSavedObjects, - })), - }; + bulkGetObjectsMock.mockResolvedValue(mockSavedObjects); extractExportDetailsMock.mockImplementation(() => ({ exportedCount: 2, @@ -335,7 +316,7 @@ describe('SavedObjectsTable', () => { excludedObjects: [{ id: '7', type: 'visualisation' }], })); - const component = shallowRender({ savedObjectsClient: mockSavedObjectsClient }); + const component = shallowRender(); // Ensure all promises resolve await new Promise((resolve) => process.nextTick(resolve)); @@ -553,6 +534,7 @@ describe('SavedObjectsTable', () => { const mockSelectedSavedObjects = [ { id: '1', type: 'index-pattern', meta: {} }, { id: '3', type: 'dashboard', meta: {} }, + { id: '4', type: 'dashboard', meta: { hiddenType: false } }, ] as SavedObjectWithMetadata[]; const mockSavedObjects = mockSelectedSavedObjects.map((obj) => ({ @@ -560,16 +542,13 @@ describe('SavedObjectsTable', () => { type: obj.type, source: {}, })); + bulkGetObjectsMock.mockResolvedValue(mockSavedObjects); + bulkDeleteObjectsMock.mockResolvedValueOnce([ + { id: '1', type: 'index-pattern', success: true }, + { id: '3', type: 'dashboard', success: true }, + ]); - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - bulkGet: jest.fn().mockImplementation(() => ({ - savedObjects: mockSavedObjects, - })), - delete: jest.fn(), - }; - - const component = shallowRender({ savedObjectsClient: mockSavedObjectsClient }); + const component = shallowRender(); // Ensure all promises resolve await new Promise((resolve) => process.nextTick(resolve)); @@ -582,23 +561,20 @@ describe('SavedObjectsTable', () => { await component.instance().delete(); expect(defaultProps.dataViews.clearCache).toHaveBeenCalled(); - expect(mockSavedObjectsClient.delete).toHaveBeenCalledWith( - mockSavedObjects[0].type, - mockSavedObjects[0].id, - { force: true } - ); - expect(mockSavedObjectsClient.delete).toHaveBeenCalledWith( - mockSavedObjects[1].type, - mockSavedObjects[1].id, - { force: true } + expect(bulkDeleteObjectsMock).toHaveBeenCalledWith( + expect.anything(), + expect.arrayContaining([ + expect.objectContaining(pick(mockSavedObjects[0], 'id', 'type')), + expect.objectContaining(pick(mockSavedObjects[1], 'id', 'type')), + ]) ); expect(component.state('selectedSavedObjects').length).toBe(0); }); - it('should not delete hidden selected objects', async () => { + it('should show a notification when deletion failed', async () => { const mockSelectedSavedObjects = [ { id: '1', type: 'index-pattern', meta: {} }, - { id: '3', type: 'hidden-type', meta: { hiddenType: true } }, + { id: '3', type: 'hidden-type', meta: {} }, ] as SavedObjectWithMetadata[]; const mockSavedObjects = mockSelectedSavedObjects.map((obj) => ({ @@ -606,16 +582,18 @@ describe('SavedObjectsTable', () => { type: obj.type, source: {}, })); + bulkGetObjectsMock.mockResolvedValue(mockSavedObjects); + bulkDeleteObjectsMock.mockResolvedValueOnce([ + { id: '1', type: 'index-pattern', success: true }, + { + id: '3', + type: 'hidden-type', + success: false, + error: { message: 'Something went wrong.' }, + }, + ]); - const mockSavedObjectsClient = { - ...defaultProps.savedObjectsClient, - bulkGet: jest.fn().mockImplementation(() => ({ - savedObjects: mockSavedObjects, - })), - delete: jest.fn(), - }; - - const component = shallowRender({ savedObjectsClient: mockSavedObjectsClient }); + const component = shallowRender(); // Ensure all promises resolve await new Promise((resolve) => process.nextTick(resolve)); @@ -628,10 +606,11 @@ describe('SavedObjectsTable', () => { await component.instance().delete(); expect(defaultProps.dataViews.clearCache).toHaveBeenCalled(); - expect(mockSavedObjectsClient.delete).toHaveBeenCalledTimes(1); - expect(mockSavedObjectsClient.delete).toHaveBeenCalledWith('index-pattern', '1', { - force: true, - }); + expect(notifications.toasts.addInfo).toHaveBeenCalledWith( + expect.objectContaining({ + title: expect.stringContaining('1 object.'), + }) + ); }); }); }); diff --git a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx index e548391b53b5d..0ecd3e0d78a06 100644 --- a/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx +++ b/src/plugins/saved_objects_management/public/management_section/objects_table/saved_objects_table.tsx @@ -7,18 +7,12 @@ */ import React, { Component } from 'react'; -import { debounce } from 'lodash'; +import { debounce, matches } from 'lodash'; // @ts-expect-error import { saveAs } from '@elastic/filesaver'; import { EuiSpacer, Query, CriteriaWithPagination } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { - SavedObjectsClientContract, - HttpStart, - OverlayStart, - NotificationsStart, - ApplicationStart, -} from '@kbn/core/public'; +import { HttpStart, OverlayStart, NotificationsStart, ApplicationStart } from '@kbn/core/public'; import type { SavedObjectsFindOptions } from '@kbn/core-saved-objects-api-server'; import { RedirectAppLinks } from '@kbn/kibana-react-plugin/public'; import { SavedObjectsTaggingApi } from '@kbn/saved-objects-tagging-oss-plugin/public'; @@ -32,6 +26,7 @@ import { fetchExportObjects, fetchExportByTypeAndSearch, findObjects, + bulkDeleteObjects, bulkGetObjects, extractExportDetails, SavedObjectsExportResultDetails, @@ -60,7 +55,6 @@ export interface SavedObjectsTableProps { allowedTypes: SavedObjectManagementTypeInfo[]; actionRegistry: SavedObjectsManagementActionServiceStart; columnRegistry: SavedObjectsManagementColumnServiceStart; - savedObjectsClient: SavedObjectsClientContract; dataViews: DataViewsContract; taggingApi?: SavedObjectsTaggingApi; http: HttpStart; @@ -507,7 +501,7 @@ export class SavedObjectsTable extends Component { - const { savedObjectsClient } = this.props; + const { http, notifications } = this.props; const { selectedSavedObjects, isDeleting } = this.state; if (isDeleting) { @@ -521,14 +515,27 @@ export class SavedObjectsTable extends Component !object.meta.hiddenType) - .map((object) => savedObjectsClient.delete(object.type, object.id, { force: true })); - await Promise.all(deletes); + const deleteStatus = await bulkDeleteObjects( + http, + selectedSavedObjects + .filter((object) => !object.meta.hiddenType) + .map(({ id, type }) => ({ id, type })) + ); + + notifications.toasts.addInfo({ + title: i18n.translate('savedObjectsManagement.objectsTable.delete.successNotification', { + defaultMessage: `Successfully deleted {count, plural, one {# object} other {# objects}}.`, + values: { + count: deleteStatus.filter(({ success }) => !!success).length, + }, + }), + }); // Unset this this.setState({ - selectedSavedObjects: [], + selectedSavedObjects: selectedSavedObjects.filter(({ id, type }) => + deleteStatus.some(matches({ id, type, success: false })) + ), }); // Fetching all data diff --git a/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx b/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx index f77c7bfed86d6..a3ed60fe32808 100644 --- a/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx +++ b/src/plugins/saved_objects_management/public/management_section/saved_objects_edition_page.tsx @@ -57,7 +57,6 @@ const SavedObjectsEditionPage = ({ id={id} savedObjectType={type} http={coreStart.http} - savedObjectsClient={coreStart.savedObjects.client} overlays={coreStart.overlays} notifications={coreStart.notifications} capabilities={capabilities} diff --git a/src/plugins/saved_objects_management/public/management_section/saved_objects_table_page.tsx b/src/plugins/saved_objects_management/public/management_section/saved_objects_table_page.tsx index dac81d87730c0..ec083bf2f5c00 100644 --- a/src/plugins/saved_objects_management/public/management_section/saved_objects_table_page.tsx +++ b/src/plugins/saved_objects_management/public/management_section/saved_objects_table_page.tsx @@ -83,7 +83,6 @@ const SavedObjectsTablePage = ({ actionRegistry={actionRegistry} columnRegistry={columnRegistry} taggingApi={taggingApi} - savedObjectsClient={coreStart.savedObjects.client} dataViews={dataViewsApi} search={dataStart.search} http={coreStart.http} diff --git a/src/plugins/saved_objects_management/server/routes/bulk_delete.ts b/src/plugins/saved_objects_management/server/routes/bulk_delete.ts new file mode 100644 index 0000000000000..e3f4db044ef2f --- /dev/null +++ b/src/plugins/saved_objects_management/server/routes/bulk_delete.ts @@ -0,0 +1,35 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { schema } from '@kbn/config-schema'; +import { IRouter } from '@kbn/core/server'; + +export const registerBulkDeleteRoute = (router: IRouter) => { + router.post( + { + path: '/internal/kibana/management/saved_objects/_bulk_delete', + validate: { + body: schema.arrayOf( + schema.object({ + type: schema.string(), + id: schema.string(), + }) + ), + }, + }, + router.handleLegacyErrors(async (context, req, res) => { + const { getClient } = (await context.core).savedObjects; + + const objects = req.body; + const client = getClient(); + const response = await client.bulkDelete(objects, { force: true }); + + return res.ok({ body: response.statuses }); + }) + ); +}; diff --git a/src/plugins/saved_objects_management/server/routes/index.test.ts b/src/plugins/saved_objects_management/server/routes/index.test.ts index 8c640d261d212..d9c261cabce0f 100644 --- a/src/plugins/saved_objects_management/server/routes/index.test.ts +++ b/src/plugins/saved_objects_management/server/routes/index.test.ts @@ -24,7 +24,7 @@ describe('registerRoutes', () => { expect(httpSetup.createRouter).toHaveBeenCalledTimes(1); expect(router.get).toHaveBeenCalledTimes(3); - expect(router.post).toHaveBeenCalledTimes(2); + expect(router.post).toHaveBeenCalledTimes(3); expect(router.get).toHaveBeenCalledWith( expect.objectContaining({ @@ -32,6 +32,12 @@ describe('registerRoutes', () => { }), expect.any(Function) ); + expect(router.post).toHaveBeenCalledWith( + expect.objectContaining({ + path: '/internal/kibana/management/saved_objects/_bulk_delete', + }), + expect.any(Function) + ); expect(router.post).toHaveBeenCalledWith( expect.objectContaining({ path: '/api/kibana/management/saved_objects/_bulk_get', diff --git a/src/plugins/saved_objects_management/server/routes/index.ts b/src/plugins/saved_objects_management/server/routes/index.ts index a66a3aa28470f..019cc4cc26db0 100644 --- a/src/plugins/saved_objects_management/server/routes/index.ts +++ b/src/plugins/saved_objects_management/server/routes/index.ts @@ -9,6 +9,7 @@ import { HttpServiceSetup } from '@kbn/core/server'; import { ISavedObjectsManagement } from '../services'; import { registerFindRoute } from './find'; +import { registerBulkDeleteRoute } from './bulk_delete'; import { registerBulkGetRoute } from './bulk_get'; import { registerScrollForCountRoute } from './scroll_count'; import { registerRelationshipsRoute } from './relationships'; @@ -22,6 +23,7 @@ interface RegisterRouteOptions { export function registerRoutes({ http, managementServicePromise }: RegisterRouteOptions) { const router = http.createRouter(); registerFindRoute(router, managementServicePromise); + registerBulkDeleteRoute(router); registerBulkGetRoute(router, managementServicePromise); registerScrollForCountRoute(router); registerRelationshipsRoute(router, managementServicePromise); diff --git a/src/plugins/saved_objects_management/tsconfig.json b/src/plugins/saved_objects_management/tsconfig.json index cad061f1a27e0..aa1449d4a9c2e 100644 --- a/src/plugins/saved_objects_management/tsconfig.json +++ b/src/plugins/saved_objects_management/tsconfig.json @@ -22,6 +22,7 @@ "@kbn/i18n-react", "@kbn/test-jest-helpers", "@kbn/core-saved-objects-api-server", + "@kbn/core-saved-objects-common", "@kbn/monaco", "@kbn/config-schema", ], diff --git a/src/plugins/share/public/components/__snapshots__/share_context_menu.test.tsx.snap b/src/plugins/share/public/components/__snapshots__/share_context_menu.test.tsx.snap index 19be58c7792b4..6bbcd15168727 100644 --- a/src/plugins/share/public/components/__snapshots__/share_context_menu.test.tsx.snap +++ b/src/plugins/share/public/components/__snapshots__/share_context_menu.test.tsx.snap @@ -1,5 +1,81 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`shareContextMenuExtensions should render a custom panel title when provided 1`] = ` + + , + "id": 1, + "title": "Permalink", + }, + Object { + "content": , + "id": 2, + "title": "Embed Code", + }, + Object { + "content":
    + panel content +
    , + "id": 3, + "title": "AAA panel", + }, + Object { + "content":
    + panel content +
    , + "id": 4, + "title": "ZZZ panel", + }, + Object { + "id": 5, + "items": Array [ + Object { + "data-test-subj": "sharePanel-Embedcode", + "icon": "console", + "name": "Embed code", + "panel": 2, + }, + Object { + "data-test-subj": "sharePanel-Permalinks", + "disabled": false, + "icon": "link", + "name": "Permalinks", + "panel": 1, + }, + Object { + "data-test-subj": "sharePanel-ZZZpanel", + "name": "ZZZ panel", + "panel": 4, + }, + Object { + "data-test-subj": "sharePanel-AAApanel", + "name": "AAA panel", + "panel": 3, + }, + ], + "title": "Share this Custom object", + }, + ] + } + size="m" + /> +
    +`; + exports[`shareContextMenuExtensions should sort ascending on sort order first and then ascending on name 1`] = ` `; +exports[`should disable the share URL when set 1`] = ` + + , + "id": 1, + "title": "Permalink", + }, + Object { + "content": , + "id": 2, + "title": "Embed Code", + }, + Object { + "id": 3, + "items": Array [ + Object { + "data-test-subj": "sharePanel-Embedcode", + "icon": "console", + "name": "Embed code", + "panel": 2, + }, + Object { + "data-test-subj": "sharePanel-Permalinks", + "disabled": true, + "icon": "link", + "name": "Permalinks", + "panel": 1, + }, + ], + "title": "Share this dashboard", + }, + ] + } + size="m" + /> + +`; + exports[`should only render permalink panel when there are no other panels 1`] = ` expect(component).toMatchSnapshot(); }); +test('should disable the share URL when set', () => { + const component = shallow(); + expect(component).toMatchSnapshot(); +}); + describe('shareContextMenuExtensions', () => { const shareContextMenuItems: ShareMenuItem[] = [ { @@ -69,4 +74,15 @@ describe('shareContextMenuExtensions', () => { ); expect(component).toMatchSnapshot(); }); + + test('should render a custom panel title when provided', () => { + const component = shallow( + + ); + expect(component).toMatchSnapshot(); + }); }); diff --git a/src/plugins/share/public/components/share_context_menu.tsx b/src/plugins/share/public/components/share_context_menu.tsx index c964737026b3b..2d3ae3ac1b911 100644 --- a/src/plugins/share/public/components/share_context_menu.tsx +++ b/src/plugins/share/public/components/share_context_menu.tsx @@ -25,6 +25,7 @@ export interface ShareContextMenuProps { objectId?: string; objectType: string; shareableUrl?: string; + shareableUrlForSavedObject?: string; shareMenuItems: ShareMenuItem[]; sharingData: any; onClose: () => void; @@ -33,6 +34,8 @@ export interface ShareContextMenuProps { showPublicUrlSwitch?: (anonymousUserCapabilities: Capabilities) => boolean; urlService: BrowserUrlService; snapshotShareWarning?: string; + objectTypeTitle?: string; + disabledShareUrl?: boolean; } export class ShareContextMenu extends Component { @@ -64,6 +67,7 @@ export class ShareContextMenu extends Component { objectId={this.props.objectId} objectType={this.props.objectType} shareableUrl={this.props.shareableUrl} + shareableUrlForSavedObject={this.props.shareableUrlForSavedObject} anonymousAccess={this.props.anonymousAccess} showPublicUrlSwitch={this.props.showPublicUrlSwitch} urlService={this.props.urlService} @@ -78,6 +82,7 @@ export class ShareContextMenu extends Component { icon: 'link', panel: permalinkPanel.id, sortOrder: 0, + disabled: Boolean(this.props.disabledShareUrl), }); panels.push(permalinkPanel); @@ -94,6 +99,7 @@ export class ShareContextMenu extends Component { objectId={this.props.objectId} objectType={this.props.objectType} shareableUrl={this.props.shareableUrl} + shareableUrlForSavedObject={this.props.shareableUrlForSavedObject} urlParamExtensions={this.props.embedUrlParamExtensions} anonymousAccess={this.props.anonymousAccess} showPublicUrlSwitch={this.props.showPublicUrlSwitch} @@ -131,7 +137,7 @@ export class ShareContextMenu extends Component { title: i18n.translate('share.contextMenuTitle', { defaultMessage: 'Share this {objectType}', values: { - objectType: this.props.objectType, + objectType: this.props.objectTypeTitle || this.props.objectType, }, }), items: menuItems diff --git a/src/plugins/share/public/components/url_panel_content.test.tsx b/src/plugins/share/public/components/url_panel_content.test.tsx index 969c5dffa864f..f5d3ef0ac652c 100644 --- a/src/plugins/share/public/components/url_panel_content.test.tsx +++ b/src/plugins/share/public/components/url_panel_content.test.tsx @@ -61,6 +61,22 @@ describe('share url panel content', () => { expect(component).toMatchSnapshot(); }); + test('should use custom savedObjectUrl if provided for saved object export', () => { + const component = shallow( + + ); + + act(() => { + component.find(EuiRadioGroup).prop('onChange')!(ExportUrlAsType.EXPORT_URL_AS_SAVED_OBJECT); + }); + expect(component.find(EuiCopy).prop('textToCopy')).toEqual('socustomurl:id1#?_g='); + }); + test('should hide short url section when allowShortUrl is false', () => { const component = shallow( diff --git a/src/plugins/share/public/components/url_panel_content.tsx b/src/plugins/share/public/components/url_panel_content.tsx index 32441ab2945eb..fb2de6811b4d5 100644 --- a/src/plugins/share/public/components/url_panel_content.tsx +++ b/src/plugins/share/public/components/url_panel_content.tsx @@ -42,6 +42,7 @@ export interface UrlPanelContentProps { objectId?: string; objectType: string; shareableUrl?: string; + shareableUrlForSavedObject?: string; urlParamExtensions?: UrlParamExtension[]; anonymousAccess?: AnonymousAccessServiceContract; showPublicUrlSwitch?: (anonymousUserCapabilities: Capabilities) => boolean; @@ -242,7 +243,7 @@ export class UrlPanelContent extends Component { return; } - const url = this.getSnapshotUrl(); + const url = this.getSnapshotUrl(true); const parsedUrl = parseUrl(url); if (!parsedUrl || !parsedUrl.hash) { @@ -269,8 +270,14 @@ export class UrlPanelContent extends Component { return this.updateUrlParams(formattedUrl); }; - private getSnapshotUrl = () => { - const url = this.props.shareableUrl || window.location.href; + private getSnapshotUrl = (forSavedObject?: boolean) => { + let url = ''; + if (forSavedObject && this.props.shareableUrlForSavedObject) { + url = this.props.shareableUrlForSavedObject; + } + if (!url) { + url = this.props.shareableUrl || window.location.href; + } return this.updateUrlParams(url); }; diff --git a/src/plugins/share/public/services/share_menu_manager.tsx b/src/plugins/share/public/services/share_menu_manager.tsx index a393d4aba6033..d63ceaf115e10 100644 --- a/src/plugins/share/public/services/share_menu_manager.tsx +++ b/src/plugins/share/public/services/share_menu_manager.tsx @@ -69,6 +69,7 @@ export class ShareMenuManager { sharingData, menuItems, shareableUrl, + shareableUrlForSavedObject, embedUrlParamExtensions, theme, showPublicUrlSwitch, @@ -76,6 +77,8 @@ export class ShareMenuManager { anonymousAccess, snapshotShareWarning, onClose, + objectTypeTitle, + disabledShareUrl, }: ShowShareMenuOptions & { menuItems: ShareMenuItem[]; urlService: BrowserUrlService; @@ -107,15 +110,18 @@ export class ShareMenuManager { allowShortUrl={allowShortUrl} objectId={objectId} objectType={objectType} + objectTypeTitle={objectTypeTitle} shareMenuItems={menuItems} sharingData={sharingData} shareableUrl={shareableUrl} + shareableUrlForSavedObject={shareableUrlForSavedObject} onClose={onClose} embedUrlParamExtensions={embedUrlParamExtensions} anonymousAccess={anonymousAccess} showPublicUrlSwitch={showPublicUrlSwitch} urlService={urlService} snapshotShareWarning={snapshotShareWarning} + disabledShareUrl={disabledShareUrl} /> diff --git a/src/plugins/share/public/types.ts b/src/plugins/share/public/types.ts index b1cd995a5ff84..bbf857e9847aa 100644 --- a/src/plugins/share/public/types.ts +++ b/src/plugins/share/public/types.ts @@ -41,10 +41,12 @@ export interface ShareContext { * If not set it will default to `window.location.href` */ shareableUrl: string; + shareableUrlForSavedObject?: string; sharingData: { [key: string]: unknown }; isDirty: boolean; onClose: () => void; showPublicUrlSwitch?: (anonymousUserCapabilities: Capabilities) => boolean; + disabledShareUrl?: boolean; } /** @@ -99,4 +101,5 @@ export interface ShowShareMenuOptions extends Omit { embedUrlParamExtensions?: UrlParamExtension[]; snapshotShareWarning?: string; onClose?: () => void; + objectTypeTitle?: string; } diff --git a/src/plugins/ui_actions/public/actions/action.ts b/src/plugins/ui_actions/public/actions/action.ts index 2d797d6bc90e6..bc5beb93309e9 100644 --- a/src/plugins/ui_actions/public/actions/action.ts +++ b/src/plugins/ui_actions/public/actions/action.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import type { Presentable } from '../util/presentable'; +import type { Presentable } from '@kbn/ui-actions-browser'; import type { Trigger } from '../triggers'; /** diff --git a/src/plugins/ui_actions/public/actions/action_internal.ts b/src/plugins/ui_actions/public/actions/action_internal.ts index fde58aedc93e6..5717747521769 100644 --- a/src/plugins/ui_actions/public/actions/action_internal.ts +++ b/src/plugins/ui_actions/public/actions/action_internal.ts @@ -7,8 +7,8 @@ */ import * as React from 'react'; +import { Presentable, PresentableGrouping } from '@kbn/ui-actions-browser'; import { Action, ActionDefinition, ActionMenuItemProps } from './action'; -import { Presentable, PresentableGrouping } from '../util/presentable'; /** * @internal diff --git a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts index 5d37c3f1cdbe0..7a6cb3a4c5265 100644 --- a/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts +++ b/src/plugins/ui_actions/public/context_menu/build_eui_context_menu_panels.test.ts @@ -9,7 +9,7 @@ import { EuiContextMenuPanelDescriptor } from '@elastic/eui'; import { buildContextMenuForActions } from './build_eui_context_menu_panels'; import { Action, createAction } from '../actions'; -import { PresentableGrouping } from '../util'; +import { PresentableGrouping } from '@kbn/ui-actions-browser'; const createTestAction = ({ type, diff --git a/src/plugins/ui_actions/public/index.ts b/src/plugins/ui_actions/public/index.ts index 945b85ff6d712..9719f70c6be15 100644 --- a/src/plugins/ui_actions/public/index.ts +++ b/src/plugins/ui_actions/public/index.ts @@ -22,7 +22,7 @@ export { buildContextMenuForActions } from './context_menu'; export type { Presentable as UiActionsPresentable, PresentableGrouping as UiActionsPresentableGrouping, -} from './util'; +} from '@kbn/ui-actions-browser'; export type { Trigger, RowClickContext } from './triggers'; export { VISUALIZE_FIELD_TRIGGER, diff --git a/src/plugins/ui_actions/tsconfig.json b/src/plugins/ui_actions/tsconfig.json index f1a83bc52b582..b7969a4b44a5d 100644 --- a/src/plugins/ui_actions/tsconfig.json +++ b/src/plugins/ui_actions/tsconfig.json @@ -14,6 +14,7 @@ "@kbn/i18n", "@kbn/es-query", "@kbn/ui-theme", + "@kbn/ui-actions-browser", ], "exclude": [ "target/**/*", diff --git a/src/plugins/unified_field_list/public/utils/field_types/get_field_type_description.ts b/src/plugins/unified_field_list/public/utils/field_types/get_field_type_description.ts index a7b5b6ec3f05e..8b7ab22b93ad5 100644 --- a/src/plugins/unified_field_list/public/utils/field_types/get_field_type_description.ts +++ b/src/plugins/unified_field_list/public/utils/field_types/get_field_type_description.ts @@ -34,7 +34,7 @@ export function getFieldTypeDescription(type?: string) { switch (knownType) { case KNOWN_FIELD_TYPES.DOCUMENT: return i18n.translate('unifiedFieldList.fieldNameDescription.recordField', { - defaultMessage: 'Number of records.', // TODO: add a better description + defaultMessage: 'Count of records.', }); case KNOWN_FIELD_TYPES.BOOLEAN: return i18n.translate('unifiedFieldList.fieldNameDescription.booleanField', { @@ -46,7 +46,8 @@ export function getFieldTypeDescription(type?: string) { }); case KNOWN_FIELD_TYPES.COUNTER: return i18n.translate('unifiedFieldList.fieldNameDescription.counterField', { - defaultMessage: 'Counter metric.', // TODO: add a better description + defaultMessage: + 'A number that only increases or resets to 0 (zero). Available only for numeric and aggregate_metric_double fields.', }); case KNOWN_FIELD_TYPES.DATE: return i18n.translate('unifiedFieldList.fieldNameDescription.dateField', { @@ -58,7 +59,8 @@ export function getFieldTypeDescription(type?: string) { }); case KNOWN_FIELD_TYPES.GAUGE: return i18n.translate('unifiedFieldList.fieldNameDescription.gaugeField', { - defaultMessage: 'Gauge metric.', // TODO: add a better description + defaultMessage: + 'A number that can increase or decrease. Available only for numeric and aggregate_metric_double fields.', }); case KNOWN_FIELD_TYPES.GEO_POINT: return i18n.translate('unifiedFieldList.fieldNameDescription.geoPointField', { diff --git a/src/plugins/unified_histogram/kibana.json b/src/plugins/unified_histogram/kibana.json index 5be043637ed33..aa9e22fab2a08 100755 --- a/src/plugins/unified_histogram/kibana.json +++ b/src/plugins/unified_histogram/kibana.json @@ -11,5 +11,5 @@ "ui": true, "requiredPlugins": [], "optionalPlugins": [], - "requiredBundles": ["data", "dataViews", "embeddable", "kibanaUtils", "inspector"] + "requiredBundles": ["data", "dataViews", "embeddable", "inspector"] } diff --git a/src/plugins/unified_histogram/public/chart/chart.test.tsx b/src/plugins/unified_histogram/public/chart/chart.test.tsx index 21682cb919d3c..bc4115590b4e2 100644 --- a/src/plugins/unified_histogram/public/chart/chart.test.tsx +++ b/src/plugins/unified_histogram/public/chart/chart.test.tsx @@ -39,20 +39,18 @@ async function mountComponent({ dataView?: DataView; onEditVisualization?: null | (() => void); } = {}) { - const services = unifiedHistogramServicesMock; - services.data.query.timefilter.timefilter.getAbsoluteTime = () => { - return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; - }; - (services.data.query.queryString.getDefaultQuery as jest.Mock).mockReturnValue({ - language: 'kuery', - query: '', - }); (searchSourceInstanceMock.fetch$ as jest.Mock).mockImplementation( jest.fn().mockReturnValue(of({ rawResponse: { hits: { total: noHits ? 0 : 2 } } })) ); const props = { dataView, + query: { + language: 'kuery', + query: '', + }, + filters: [], + timeRange: { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }, services: unifiedHistogramServicesMock, hits: noHits ? undefined diff --git a/src/plugins/unified_histogram/public/chart/chart.tsx b/src/plugins/unified_histogram/public/chart/chart.tsx index b1970cd26e365..ccfadcaa07e97 100644 --- a/src/plugins/unified_histogram/public/chart/chart.tsx +++ b/src/plugins/unified_histogram/public/chart/chart.tsx @@ -18,7 +18,9 @@ import { } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { DataView, DataViewField, DataViewType } from '@kbn/data-views-plugin/public'; -import type { TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import type { LensEmbeddableInput, TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import type { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; +import { Subject } from 'rxjs'; import { HitsCounter } from '../hits_counter'; import { Histogram } from './histogram'; import { useChartPanels } from './use_chart_panels'; @@ -30,26 +32,34 @@ import type { UnifiedHistogramChartLoadEvent, UnifiedHistogramRequestContext, UnifiedHistogramServices, + UnifiedHistogramInput$, + UnifiedHistogramInputMessage, } from '../types'; import { BreakdownFieldSelector } from './breakdown_field_selector'; import { useTotalHits } from './use_total_hits'; import { useRequestParams } from './use_request_params'; import { useChartStyles } from './use_chart_styles'; import { useChartActions } from './use_chart_actions'; -import { useRefetchId } from './use_refetch_id'; import { getLensAttributes } from './get_lens_attributes'; +import { useRefetch } from './use_refetch'; export interface ChartProps { className?: string; services: UnifiedHistogramServices; dataView: DataView; - lastReloadRequestTime?: number; + query?: Query | AggregateQuery; + filters?: Filter[]; + timeRange?: TimeRange; request?: UnifiedHistogramRequestContext; hits?: UnifiedHistogramHitsContext; chart?: UnifiedHistogramChartContext; breakdown?: UnifiedHistogramBreakdownContext; appendHitsCounter?: ReactElement; appendHistogram?: ReactElement; + disableAutoFetching?: boolean; + disableTriggers?: LensEmbeddableInput['disableTriggers']; + disabledActions?: LensEmbeddableInput['disabledActions']; + input$?: UnifiedHistogramInput$; onEditVisualization?: (lensAttributes: TypedLensByValueInput['attributes']) => void; onResetChartHeight?: () => void; onChartHiddenChange?: (chartHidden: boolean) => void; @@ -57,6 +67,8 @@ export interface ChartProps { onBreakdownFieldChange?: (breakdownField: DataViewField | undefined) => void; onTotalHitsChange?: (status: UnifiedHistogramFetchStatus, result?: number | Error) => void; onChartLoad?: (event: UnifiedHistogramChartLoadEvent) => void; + onFilter?: LensEmbeddableInput['onFilter']; + onBrushEnd?: LensEmbeddableInput['onBrushEnd']; } const HistogramMemoized = memo(Histogram); @@ -65,13 +77,19 @@ export function Chart({ className, services, dataView, - lastReloadRequestTime, + query: originalQuery, + filters: originalFilters, + timeRange: originalTimeRange, request, hits, chart, breakdown, appendHitsCounter, appendHistogram, + disableAutoFetching, + disableTriggers, + disabledActions, + input$: originalInput$, onEditVisualization: originalOnEditVisualization, onResetChartHeight, onChartHiddenChange, @@ -79,6 +97,8 @@ export function Chart({ onBreakdownFieldChange, onTotalHitsChange, onChartLoad, + onFilter, + onBrushEnd, }: ChartProps) { const { showChartOptionsPopover, @@ -107,15 +127,20 @@ export function Chart({ dataView.isTimeBased() ); - const { filters, query, relativeTimeRange } = useRequestParams({ + const input$ = useMemo( + () => originalInput$ ?? new Subject(), + [originalInput$] + ); + + const { filters, query, getTimeRange, updateTimeRange, relativeTimeRange } = useRequestParams({ services, - lastReloadRequestTime, - request, + query: originalQuery, + filters: originalFilters, + timeRange: originalTimeRange, }); - const refetchId = useRefetchId({ + const refetch$ = useRefetch({ dataView, - lastReloadRequestTime, request, hits, chart, @@ -124,28 +149,21 @@ export function Chart({ filters, query, relativeTimeRange, + disableAutoFetching, + input$, + beforeRefetch: updateTimeRange, }); - // We need to update the absolute time range whenever the refetchId changes - const timeRange = useMemo( - () => services.data.query.timefilter.timefilter.getAbsoluteTime(), - // eslint-disable-next-line react-hooks/exhaustive-deps - [services.data.query.timefilter.timefilter, refetchId] - ); - useTotalHits({ services, dataView, - lastReloadRequestTime, request, hits, - chart, chartVisible, - breakdown, filters, query, - timeRange, - refetchId, + getTimeRange, + refetch$, onTotalHitsChange, }); @@ -288,14 +306,18 @@ export function Chart({ {appendHistogram} diff --git a/src/plugins/unified_histogram/public/chart/histogram.test.tsx b/src/plugins/unified_histogram/public/chart/histogram.test.tsx index 03652a63f5456..7385f20358be3 100644 --- a/src/plugins/unified_histogram/public/chart/histogram.test.tsx +++ b/src/plugins/unified_histogram/public/chart/histogram.test.tsx @@ -6,18 +6,19 @@ * Side Public License, v 1. */ import { mountWithIntl } from '@kbn/test-jest-helpers'; -import { getLensProps, Histogram } from './histogram'; +import { Histogram } from './histogram'; import React from 'react'; import { unifiedHistogramServicesMock } from '../__mocks__/services'; import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield'; import { createDefaultInspectorAdapters } from '@kbn/expressions-plugin/common'; -import { UnifiedHistogramFetchStatus } from '../types'; +import { UnifiedHistogramFetchStatus, UnifiedHistogramInput$ } from '../types'; import { getLensAttributes } from './get_lens_attributes'; -import { REQUEST_DEBOUNCE_MS } from './consts'; import { act } from 'react-dom/test-utils'; import * as buildBucketInterval from './build_bucket_interval'; import * as useTimeRange from './use_time_range'; import { RequestStatus } from '@kbn/inspector-plugin/public'; +import { Subject } from 'rxjs'; +import { getLensProps } from './use_lens_props'; const mockBucketInterval = { description: '1 minute', scale: undefined, scaled: false }; jest.spyOn(buildBucketInterval, 'buildBucketInterval').mockReturnValue(mockBucketInterval); @@ -43,7 +44,7 @@ function mountComponent() { }; const timefilterUpdateHandler = jest.fn(); - + const refetch$: UnifiedHistogramInput$ = new Subject(); const props = { services: unifiedHistogramServicesMock, request: { @@ -59,11 +60,11 @@ function mountComponent() { }, timefilterUpdateHandler, dataView: dataViewWithTimefieldMock, - timeRange: { + getTimeRange: () => ({ from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590', - }, - lastReloadRequestTime: 42, + }), + refetch$, lensAttributes: getMockLensAttributes(), onTotalHitsChange: jest.fn(), onChartLoad: jest.fn(), @@ -81,28 +82,27 @@ describe('Histogram', () => { expect(component.find('[data-test-subj="unifiedHistogramChart"]').exists()).toBe(true); }); - it('should render lens.EmbeddableComponent with debounced props', async () => { + it('should only update lens.EmbeddableComponent props when refetch$ is triggered', async () => { const { component, props } = mountComponent(); const embeddable = unifiedHistogramServicesMock.lens.EmbeddableComponent; expect(component.find(embeddable).exists()).toBe(true); let lensProps = component.find(embeddable).props(); const originalProps = getLensProps({ - timeRange: props.timeRange, + searchSessionId: props.request.searchSessionId, + getTimeRange: props.getTimeRange, attributes: getMockLensAttributes(), - request: props.request, - lastReloadRequestTime: props.lastReloadRequestTime, onLoad: lensProps.onLoad, }); expect(lensProps).toEqual(originalProps); - component.setProps({ lastReloadRequestTime: 43 }).update(); + component.setProps({ request: { ...props.request, searchSessionId: '321' } }).update(); lensProps = component.find(embeddable).props(); expect(lensProps).toEqual(originalProps); await act(async () => { - await new Promise((resolve) => setTimeout(resolve, REQUEST_DEBOUNCE_MS)); + props.refetch$.next({ type: 'refetch' }); }); component.update(); lensProps = component.find(embeddable).props(); - expect(lensProps).toEqual({ ...originalProps, lastReloadRequestTime: 43 }); + expect(lensProps).toEqual({ ...originalProps, searchSessionId: '321' }); }); it('should execute onLoad correctly', async () => { @@ -165,7 +165,7 @@ describe('Histogram', () => { UnifiedHistogramFetchStatus.loading, undefined ); - expect(props.onChartLoad).toHaveBeenLastCalledWith({ complete: false, adapters: {} }); + expect(props.onChartLoad).toHaveBeenLastCalledWith({ adapters: {} }); expect(buildBucketInterval.buildBucketInterval).not.toHaveBeenCalled(); expect(useTimeRange.useTimeRange).toHaveBeenLastCalledWith( expect.objectContaining({ bucketInterval: undefined }) @@ -177,7 +177,7 @@ describe('Histogram', () => { UnifiedHistogramFetchStatus.complete, 100 ); - expect(props.onChartLoad).toHaveBeenLastCalledWith({ complete: true, adapters }); + expect(props.onChartLoad).toHaveBeenLastCalledWith({ adapters }); expect(buildBucketInterval.buildBucketInterval).toHaveBeenCalled(); expect(useTimeRange.useTimeRange).toHaveBeenLastCalledWith( expect.objectContaining({ bucketInterval: mockBucketInterval }) @@ -197,7 +197,7 @@ describe('Histogram', () => { UnifiedHistogramFetchStatus.error, undefined ); - expect(props.onChartLoad).toHaveBeenLastCalledWith({ complete: false, adapters }); + expect(props.onChartLoad).toHaveBeenLastCalledWith({ adapters }); }); it('should execute onLoad correctly when the response has shard failures', async () => { @@ -222,36 +222,6 @@ describe('Histogram', () => { UnifiedHistogramFetchStatus.error, undefined ); - expect(props.onChartLoad).toHaveBeenLastCalledWith({ complete: false, adapters }); - }); - - it('should not recreate onLoad in debounced lens props when hits.total changes', async () => { - const { component, props } = mountComponent(); - const embeddable = unifiedHistogramServicesMock.lens.EmbeddableComponent; - const onLoad = component.find(embeddable).props().onLoad; - onLoad(true, undefined); - expect(props.onTotalHitsChange).toHaveBeenLastCalledWith( - UnifiedHistogramFetchStatus.loading, - undefined - ); - component - .setProps({ - hits: { - status: UnifiedHistogramFetchStatus.complete, - total: 100, - }, - }) - .update(); - expect(component.find(embeddable).props().onLoad).toBe(onLoad); - await act(async () => { - await new Promise((resolve) => setTimeout(resolve, REQUEST_DEBOUNCE_MS)); - }); - component.update(); - expect(component.find(embeddable).props().onLoad).toBe(onLoad); - onLoad(true, undefined); - expect(props.onTotalHitsChange).toHaveBeenLastCalledWith( - UnifiedHistogramFetchStatus.loading, - 100 - ); + expect(props.onChartLoad).toHaveBeenLastCalledWith({ adapters }); }); }); diff --git a/src/plugins/unified_histogram/public/chart/histogram.tsx b/src/plugins/unified_histogram/public/chart/histogram.tsx index c30c6a1410985..01caba4ad48ad 100644 --- a/src/plugins/unified_histogram/public/chart/histogram.tsx +++ b/src/plugins/unified_histogram/public/chart/histogram.tsx @@ -8,16 +8,15 @@ import { useEuiTheme } from '@elastic/eui'; import { css } from '@emotion/react'; -import React, { useCallback, useEffect, useRef, useState } from 'react'; +import React, { useState } from 'react'; import type { DataView } from '@kbn/data-views-plugin/public'; import type { DefaultInspectorAdapters } from '@kbn/expressions-plugin/common'; import type { IKibanaSearchResponse } from '@kbn/data-plugin/public'; import type { estypes } from '@elastic/elasticsearch'; import type { TimeRange } from '@kbn/es-query'; -import useDebounce from 'react-use/lib/useDebounce'; -import { ViewMode } from '@kbn/embeddable-plugin/public'; -import type { TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import type { LensEmbeddableInput, TypedLensByValueInput } from '@kbn/lens-plugin/public'; import { RequestStatus } from '@kbn/inspector-plugin/public'; +import type { Observable } from 'rxjs'; import { UnifiedHistogramBucketInterval, UnifiedHistogramChartContext, @@ -26,53 +25,55 @@ import { UnifiedHistogramChartLoadEvent, UnifiedHistogramRequestContext, UnifiedHistogramServices, + UnifiedHistogramInputMessage, } from '../types'; import { buildBucketInterval } from './build_bucket_interval'; import { useTimeRange } from './use_time_range'; -import { REQUEST_DEBOUNCE_MS } from './consts'; +import { useStableCallback } from './use_stable_callback'; +import { useLensProps } from './use_lens_props'; export interface HistogramProps { services: UnifiedHistogramServices; dataView: DataView; - lastReloadRequestTime: number | undefined; request?: UnifiedHistogramRequestContext; hits?: UnifiedHistogramHitsContext; chart: UnifiedHistogramChartContext; - timeRange: TimeRange; + getTimeRange: () => TimeRange; + refetch$: Observable; lensAttributes: TypedLensByValueInput['attributes']; + disableTriggers?: LensEmbeddableInput['disableTriggers']; + disabledActions?: LensEmbeddableInput['disabledActions']; onTotalHitsChange?: (status: UnifiedHistogramFetchStatus, result?: number | Error) => void; onChartLoad?: (event: UnifiedHistogramChartLoadEvent) => void; + onFilter?: LensEmbeddableInput['onFilter']; + onBrushEnd?: LensEmbeddableInput['onBrushEnd']; } export function Histogram({ services: { data, lens, uiSettings }, dataView, - lastReloadRequestTime, request, hits, chart: { timeInterval }, - timeRange, + getTimeRange, + refetch$, lensAttributes: attributes, + disableTriggers, + disabledActions, onTotalHitsChange, onChartLoad, + onFilter, + onBrushEnd, }: HistogramProps) { const [bucketInterval, setBucketInterval] = useState(); const { timeRangeText, timeRangeDisplay } = useTimeRange({ uiSettings, bucketInterval, - timeRange, + timeRange: getTimeRange(), timeInterval, }); - // Keep track of previous hits in a ref to avoid recreating the - // onLoad callback when the hits change, which triggers a Lens reload - const previousHits = useRef(hits?.total); - - useEffect(() => { - previousHits.current = hits?.total; - }, [hits?.total]); - - const onLoad = useCallback( + const onLoad = useStableCallback( (isLoading: boolean, adapters: Partial | undefined) => { const lensRequest = adapters?.requests?.getRequests()[0]; const requestFailed = lensRequest?.status === RequestStatus.ERROR; @@ -86,7 +87,7 @@ export function Histogram({ // This is incorrect, so we check for request failures and shard failures here, and emit an error instead. if (requestFailed || response?._shards.failed) { onTotalHitsChange?.(UnifiedHistogramFetchStatus.error, undefined); - onChartLoad?.({ complete: false, adapters: adapters ?? {} }); + onChartLoad?.({ adapters: adapters ?? {} }); return; } @@ -94,7 +95,7 @@ export function Histogram({ onTotalHitsChange?.( isLoading ? UnifiedHistogramFetchStatus.loading : UnifiedHistogramFetchStatus.complete, - totalHits ?? previousHits.current + totalHits ?? hits?.total ); if (response) { @@ -102,18 +103,25 @@ export function Histogram({ data, dataView, timeInterval, - timeRange, + timeRange: getTimeRange(), response, }); setBucketInterval(newBucketInterval); } - onChartLoad?.({ complete: !isLoading, adapters: adapters ?? {} }); - }, - [data, dataView, onChartLoad, onTotalHitsChange, timeInterval, timeRange] + onChartLoad?.({ adapters: adapters ?? {} }); + } ); + const lensProps = useLensProps({ + request, + getTimeRange, + refetch$, + attributes, + onLoad, + }); + const { euiTheme } = useEuiTheme(); const chartCss = css` position: relative; @@ -135,58 +143,18 @@ export function Histogram({ } `; - const [debouncedProps, setDebouncedProps] = useState( - getLensProps({ - timeRange, - attributes, - request, - lastReloadRequestTime, - onLoad, - }) - ); - - useDebounce( - () => { - setDebouncedProps( - getLensProps({ timeRange, attributes, request, lastReloadRequestTime, onLoad }) - ); - }, - REQUEST_DEBOUNCE_MS, - [attributes, lastReloadRequestTime, onLoad, request, timeRange] - ); - return ( <>
    - +
    {timeRangeDisplay} ); } - -export const getLensProps = ({ - timeRange, - attributes, - request, - lastReloadRequestTime, - onLoad, -}: { - timeRange: TimeRange; - attributes: TypedLensByValueInput['attributes']; - request: UnifiedHistogramRequestContext | undefined; - lastReloadRequestTime: number | undefined; - onLoad: (isLoading: boolean, adapters: Partial | undefined) => void; -}) => ({ - id: 'unifiedHistogramLensComponent', - viewMode: ViewMode.VIEW, - timeRange, - attributes, - noPadding: true, - searchSessionId: request?.searchSessionId, - executionContext: { - description: 'fetch chart data and total hits', - }, - lastReloadRequestTime, - onLoad, -}); diff --git a/src/plugins/unified_histogram/public/chart/use_lens_props.test.ts b/src/plugins/unified_histogram/public/chart/use_lens_props.test.ts new file mode 100644 index 0000000000000..289536edd0232 --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_lens_props.test.ts @@ -0,0 +1,93 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { renderHook } from '@testing-library/react-hooks'; +import { act } from 'react-test-renderer'; +import { Subject } from 'rxjs'; +import type { UnifiedHistogramInputMessage } from '../types'; +import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield'; +import { getLensAttributes } from './get_lens_attributes'; +import { getLensProps, useLensProps } from './use_lens_props'; + +describe('useLensProps', () => { + it('should return lens props', () => { + const getTimeRange = jest.fn(); + const refetch$ = new Subject(); + const onLoad = jest.fn(); + const attributes = getLensAttributes({ + title: 'test', + filters: [], + query: { + language: 'kuery', + query: '', + }, + dataView: dataViewWithTimefieldMock, + timeInterval: 'auto', + breakdownField: dataViewWithTimefieldMock.getFieldByName('extension'), + }); + const lensProps = renderHook(() => { + return useLensProps({ + request: { + searchSessionId: 'id', + adapter: undefined, + }, + getTimeRange, + refetch$, + attributes, + onLoad, + }); + }); + expect(lensProps.result.current).toEqual( + getLensProps({ + searchSessionId: 'id', + getTimeRange, + attributes, + onLoad, + }) + ); + }); + + it('should only update lens props when refetch$ is triggered', () => { + const getTimeRange = jest.fn(); + const refetch$ = new Subject(); + const onLoad = jest.fn(); + const lensProps = { + request: { + searchSessionId: '123', + adapter: undefined, + }, + getTimeRange, + refetch$, + attributes: getLensAttributes({ + title: 'test', + filters: [], + query: { + language: 'kuery', + query: '', + }, + dataView: dataViewWithTimefieldMock, + timeInterval: 'auto', + breakdownField: dataViewWithTimefieldMock.getFieldByName('extension'), + }), + onLoad, + }; + const hook = renderHook( + (props) => { + return useLensProps(props); + }, + { initialProps: lensProps } + ); + const originalProps = hook.result.current; + hook.rerender({ ...lensProps, request: { searchSessionId: '456', adapter: undefined } }); + expect(hook.result.current).toEqual(originalProps); + act(() => { + refetch$.next({ type: 'refetch' }); + }); + expect(hook.result.current).not.toEqual(originalProps); + }); +}); diff --git a/src/plugins/unified_histogram/public/chart/use_lens_props.ts b/src/plugins/unified_histogram/public/chart/use_lens_props.ts new file mode 100644 index 0000000000000..976f191dba5c3 --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_lens_props.ts @@ -0,0 +1,74 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import type { TimeRange } from '@kbn/data-plugin/common'; +import { ViewMode } from '@kbn/embeddable-plugin/public'; +import type { DefaultInspectorAdapters } from '@kbn/expressions-plugin/common'; +import type { TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import { useCallback, useEffect, useState } from 'react'; +import type { Observable } from 'rxjs'; +import type { UnifiedHistogramInputMessage, UnifiedHistogramRequestContext } from '../types'; +import { useStableCallback } from './use_stable_callback'; + +export const useLensProps = ({ + request, + getTimeRange, + refetch$, + attributes, + onLoad, +}: { + request?: UnifiedHistogramRequestContext; + getTimeRange: () => TimeRange; + refetch$: Observable; + attributes: TypedLensByValueInput['attributes']; + onLoad: (isLoading: boolean, adapters: Partial | undefined) => void; +}) => { + const buildLensProps = useCallback( + () => + getLensProps({ + searchSessionId: request?.searchSessionId, + getTimeRange, + attributes, + onLoad, + }), + [attributes, getTimeRange, onLoad, request?.searchSessionId] + ); + + const [lensProps, setLensProps] = useState(buildLensProps()); + const updateLensProps = useStableCallback(() => setLensProps(buildLensProps())); + + useEffect(() => { + const subscription = refetch$.subscribe(updateLensProps); + return () => subscription.unsubscribe(); + }, [refetch$, updateLensProps]); + + return lensProps; +}; + +export const getLensProps = ({ + searchSessionId, + getTimeRange, + attributes, + onLoad, +}: { + searchSessionId?: string; + getTimeRange: () => TimeRange; + attributes: TypedLensByValueInput['attributes']; + onLoad: (isLoading: boolean, adapters: Partial | undefined) => void; +}) => ({ + id: 'unifiedHistogramLensComponent', + viewMode: ViewMode.VIEW, + timeRange: getTimeRange(), + attributes, + noPadding: true, + searchSessionId, + executionContext: { + description: 'fetch chart data and total hits', + }, + onLoad, +}); diff --git a/src/plugins/unified_histogram/public/chart/use_refetch.test.ts b/src/plugins/unified_histogram/public/chart/use_refetch.test.ts new file mode 100644 index 0000000000000..39381ea661865 --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_refetch.test.ts @@ -0,0 +1,85 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { useRefetch } from './use_refetch'; +import { DataView } from '@kbn/data-views-plugin/common'; +import { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; +import { renderHook } from '@testing-library/react-hooks'; +import { + UnifiedHistogramBreakdownContext, + UnifiedHistogramChartContext, + UnifiedHistogramHitsContext, + UnifiedHistogramInput$, + UnifiedHistogramRequestContext, +} from '../types'; +import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield'; +import { Subject } from 'rxjs'; + +describe('useRefetch', () => { + const getDeps: () => { + dataView: DataView; + request: UnifiedHistogramRequestContext | undefined; + hits: UnifiedHistogramHitsContext | undefined; + chart: UnifiedHistogramChartContext | undefined; + chartVisible: boolean; + breakdown: UnifiedHistogramBreakdownContext | undefined; + filters: Filter[]; + query: Query | AggregateQuery; + relativeTimeRange: TimeRange; + input$: UnifiedHistogramInput$; + beforeRefetch: () => void; + } = () => ({ + dataView: dataViewWithTimefieldMock, + request: undefined, + hits: undefined, + chart: undefined, + chartVisible: true, + breakdown: undefined, + filters: [], + query: { language: 'kuery', query: '' }, + relativeTimeRange: { from: 'now-15m', to: 'now' }, + input$: new Subject(), + beforeRefetch: () => {}, + }); + + it('should trigger the refetch observable when any of the arguments change', () => { + const originalDeps = getDeps(); + const hook = renderHook((deps) => useRefetch(deps), { + initialProps: originalDeps, + }); + const refetch = jest.fn(); + hook.result.current.subscribe(refetch); + hook.rerender({ ...originalDeps }); + expect(refetch).not.toHaveBeenCalled(); + hook.rerender({ ...originalDeps, chartVisible: false }); + expect(refetch).toHaveBeenCalledTimes(1); + }); + + it('should not trigger the refetch observable when disableAutoFetching is true', () => { + const originalDeps = { ...getDeps(), disableAutoFetching: true }; + const hook = renderHook((deps) => useRefetch(deps), { + initialProps: originalDeps, + }); + const refetch = jest.fn(); + hook.result.current.subscribe(refetch); + hook.rerender({ ...originalDeps, chartVisible: false }); + expect(refetch).not.toHaveBeenCalled(); + }); + + it('should trigger the refetch observable when the input$ observable is triggered', () => { + const originalDeps = { ...getDeps(), disableAutoFetching: true }; + const hook = renderHook((deps) => useRefetch(deps), { + initialProps: originalDeps, + }); + const refetch = jest.fn(); + hook.result.current.subscribe(refetch); + expect(refetch).not.toHaveBeenCalled(); + originalDeps.input$.next({ type: 'refetch' }); + expect(refetch).toHaveBeenCalledTimes(1); + }); +}); diff --git a/src/plugins/unified_histogram/public/chart/use_refetch_id.ts b/src/plugins/unified_histogram/public/chart/use_refetch.ts similarity index 79% rename from src/plugins/unified_histogram/public/chart/use_refetch_id.ts rename to src/plugins/unified_histogram/public/chart/use_refetch.ts index 4415be9ccd8b6..31e08f3d732e5 100644 --- a/src/plugins/unified_histogram/public/chart/use_refetch_id.ts +++ b/src/plugins/unified_histogram/public/chart/use_refetch.ts @@ -9,17 +9,18 @@ import type { DataView } from '@kbn/data-views-plugin/common'; import type { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; import { cloneDeep, isEqual } from 'lodash'; -import { useEffect, useRef, useState } from 'react'; -import type { +import { useEffect, useMemo, useRef } from 'react'; +import { filter, share, tap } from 'rxjs'; +import { UnifiedHistogramBreakdownContext, UnifiedHistogramChartContext, UnifiedHistogramHitsContext, + UnifiedHistogramInput$, UnifiedHistogramRequestContext, } from '../types'; -export const useRefetchId = ({ +export const useRefetch = ({ dataView, - lastReloadRequestTime, request, hits, chart, @@ -27,10 +28,12 @@ export const useRefetchId = ({ breakdown, filters, query, - relativeTimeRange: relativeTimeRange, + relativeTimeRange, + disableAutoFetching, + input$, + beforeRefetch, }: { dataView: DataView; - lastReloadRequestTime: number | undefined; request: UnifiedHistogramRequestContext | undefined; hits: UnifiedHistogramHitsContext | undefined; chart: UnifiedHistogramChartContext | undefined; @@ -39,17 +42,23 @@ export const useRefetchId = ({ filters: Filter[]; query: Query | AggregateQuery; relativeTimeRange: TimeRange; + disableAutoFetching?: boolean; + input$: UnifiedHistogramInput$; + beforeRefetch: () => void; }) => { const refetchDeps = useRef>(); - const [refetchId, setRefetchId] = useState(0); // When the unified histogram props change, we must compare the current subset // that should trigger a histogram refetch against the previous subset. If they // are different, we must refetch the histogram to ensure it's up to date. useEffect(() => { + // Skip if auto fetching if disabled + if (disableAutoFetching) { + return; + } + const newRefetchDeps = getRefetchDeps({ dataView, - lastReloadRequestTime, request, hits, chart, @@ -62,7 +71,7 @@ export const useRefetchId = ({ if (!isEqual(refetchDeps.current, newRefetchDeps)) { if (refetchDeps.current) { - setRefetchId((id) => id + 1); + input$.next({ type: 'refetch' }); } refetchDeps.current = newRefetchDeps; @@ -72,20 +81,28 @@ export const useRefetchId = ({ chart, chartVisible, dataView, + disableAutoFetching, filters, hits, - lastReloadRequestTime, + input$, query, - request, relativeTimeRange, + request, ]); - return refetchId; + return useMemo( + () => + input$.pipe( + filter((message) => message.type === 'refetch'), + tap(beforeRefetch), + share() + ), + [beforeRefetch, input$] + ); }; const getRefetchDeps = ({ dataView, - lastReloadRequestTime, request, hits, chart, @@ -96,7 +113,6 @@ const getRefetchDeps = ({ relativeTimeRange, }: { dataView: DataView; - lastReloadRequestTime: number | undefined; request: UnifiedHistogramRequestContext | undefined; hits: UnifiedHistogramHitsContext | undefined; chart: UnifiedHistogramChartContext | undefined; @@ -108,7 +124,6 @@ const getRefetchDeps = ({ }) => cloneDeep([ dataView.id, - lastReloadRequestTime, request?.searchSessionId, Boolean(hits), chartVisible, diff --git a/src/plugins/unified_histogram/public/chart/use_refetch_id.test.ts b/src/plugins/unified_histogram/public/chart/use_refetch_id.test.ts deleted file mode 100644 index 8835173df2599..0000000000000 --- a/src/plugins/unified_histogram/public/chart/use_refetch_id.test.ts +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0 and the Server Side Public License, v 1; you may not use this file except - * in compliance with, at your election, the Elastic License 2.0 or the Server - * Side Public License, v 1. - */ - -import { DataView } from '@kbn/data-views-plugin/common'; -import { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; -import { renderHook } from '@testing-library/react-hooks'; -import { - UnifiedHistogramBreakdownContext, - UnifiedHistogramChartContext, - UnifiedHistogramHitsContext, - UnifiedHistogramRequestContext, -} from '../types'; -import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield'; -import { useRefetchId } from './use_refetch_id'; - -describe('useRefetchId', () => { - const getDeps: () => { - dataView: DataView; - lastReloadRequestTime: number | undefined; - request: UnifiedHistogramRequestContext | undefined; - hits: UnifiedHistogramHitsContext | undefined; - chart: UnifiedHistogramChartContext | undefined; - chartVisible: boolean; - breakdown: UnifiedHistogramBreakdownContext | undefined; - filters: Filter[]; - query: Query | AggregateQuery; - relativeTimeRange: TimeRange; - } = () => ({ - dataView: dataViewWithTimefieldMock, - lastReloadRequestTime: 0, - request: undefined, - hits: undefined, - chart: undefined, - chartVisible: true, - breakdown: undefined, - filters: [], - query: { language: 'kuery', query: '' }, - relativeTimeRange: { from: 'now-15m', to: 'now' }, - }); - - it('should increment the refetchId when any of the arguments change', () => { - const hook = renderHook((props) => useRefetchId(props), { initialProps: getDeps() }); - expect(hook.result.current).toBe(0); - hook.rerender(getDeps()); - expect(hook.result.current).toBe(0); - hook.rerender({ - ...getDeps(), - lastReloadRequestTime: 1, - }); - expect(hook.result.current).toBe(1); - hook.rerender({ - ...getDeps(), - lastReloadRequestTime: 1, - }); - expect(hook.result.current).toBe(1); - hook.rerender({ - ...getDeps(), - lastReloadRequestTime: 1, - query: { language: 'kuery', query: 'foo' }, - }); - expect(hook.result.current).toBe(2); - }); -}); diff --git a/src/plugins/unified_histogram/public/chart/use_request_params.test.ts b/src/plugins/unified_histogram/public/chart/use_request_params.test.ts new file mode 100644 index 0000000000000..c49bcd4ce195b --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_request_params.test.ts @@ -0,0 +1,48 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { renderHook } from '@testing-library/react-hooks'; +import { unifiedHistogramServicesMock } from '../__mocks__/services'; + +const getUseRequestParams = async () => { + jest.doMock('@kbn/data-plugin/common', () => { + return { + ...jest.requireActual('@kbn/data-plugin/common'), + getAbsoluteTimeRange: jest.fn((range) => range), + }; + }); + return (await import('./use_request_params')).useRequestParams; +}; + +describe('useRequestParams', () => { + it('should only update getTimeRange after updateTimeRange is called', async () => { + const useRequestParams = await getUseRequestParams(); + const originalTimeRange = { + from: 'now-15m', + to: 'now', + }; + const originalProps = { + services: unifiedHistogramServicesMock, + timeRange: originalTimeRange, + filters: [], + query: { + query: '', + language: 'kuery', + }, + }; + const hook = renderHook((props) => useRequestParams(props), { + initialProps: originalProps, + }); + expect(hook.result.current.getTimeRange()).toEqual(originalTimeRange); + const newTimeRange = { from: 'now-30m', to: 'now' }; + hook.rerender({ ...originalProps, timeRange: newTimeRange }); + expect(hook.result.current.getTimeRange()).toEqual(originalTimeRange); + hook.result.current.updateTimeRange(); + expect(hook.result.current.getTimeRange()).toEqual(newTimeRange); + }); +}); diff --git a/src/plugins/unified_histogram/public/chart/use_request_params.tsx b/src/plugins/unified_histogram/public/chart/use_request_params.tsx index defa2bdd920d9..8afe803d329af 100644 --- a/src/plugins/unified_histogram/public/chart/use_request_params.tsx +++ b/src/plugins/unified_histogram/public/chart/use_request_params.tsx @@ -6,53 +6,42 @@ * Side Public License, v 1. */ -import { connectToQueryState, QueryState } from '@kbn/data-plugin/public'; -import { createStateContainer, useContainerState } from '@kbn/kibana-utils-plugin/public'; -import { useEffect, useMemo, useRef } from 'react'; -import type { UnifiedHistogramRequestContext, UnifiedHistogramServices } from '../types'; +import { getAbsoluteTimeRange } from '@kbn/data-plugin/common'; +import type { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; +import { useCallback, useMemo, useRef } from 'react'; +import type { UnifiedHistogramServices } from '../types'; +import { useStableCallback } from './use_stable_callback'; export const useRequestParams = ({ services, - lastReloadRequestTime, - request, + query: originalQuery, + filters: originalFilters, + timeRange: originalTimeRange, }: { services: UnifiedHistogramServices; - lastReloadRequestTime: number | undefined; - request?: UnifiedHistogramRequestContext; + query?: Query | AggregateQuery; + filters?: Filter[]; + timeRange?: TimeRange; }) => { const { data } = services; - const queryStateContainer = useRef( - createStateContainer({ - filters: data.query.filterManager.getFilters(), - query: data.query.queryString.getQuery(), - refreshInterval: data.query.timefilter.timefilter.getRefreshInterval(), - time: data.query.timefilter.timefilter.getTime(), - }) - ).current; - - const queryState = useContainerState(queryStateContainer); - - useEffect(() => { - return connectToQueryState(data.query, queryStateContainer, { - time: true, - query: true, - filters: true, - refreshInterval: true, - }); - }, [data.query, queryStateContainer]); - - const filters = useMemo(() => queryState.filters ?? [], [queryState.filters]); + const filters = useMemo(() => originalFilters ?? [], [originalFilters]); const query = useMemo( - () => queryState.query ?? data.query.queryString.getDefaultQuery(), - [data.query.queryString, queryState.query] + () => originalQuery ?? data.query.queryString.getDefaultQuery(), + [data.query.queryString, originalQuery] ); const relativeTimeRange = useMemo( - () => queryState.time ?? data.query.timefilter.timefilter.getTimeDefaults(), - [data.query.timefilter.timefilter, queryState.time] + () => originalTimeRange ?? data.query.timefilter.timefilter.getTimeDefaults(), + [data.query.timefilter.timefilter, originalTimeRange] ); - return { filters, query, relativeTimeRange }; + const timeRange = useRef(getAbsoluteTimeRange(relativeTimeRange)); + const getTimeRange = useCallback(() => timeRange.current, []); + const updateTimeRange = useStableCallback(() => { + timeRange.current = getAbsoluteTimeRange(relativeTimeRange); + }); + + return { filters, query, getTimeRange, updateTimeRange, relativeTimeRange }; }; diff --git a/src/plugins/unified_histogram/public/chart/use_stable_callback.test.ts b/src/plugins/unified_histogram/public/chart/use_stable_callback.test.ts new file mode 100644 index 0000000000000..2ea1be911df0e --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_stable_callback.test.ts @@ -0,0 +1,19 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { renderHook } from '@testing-library/react-hooks'; +import { useStableCallback } from './use_stable_callback'; + +describe('useStableCallback', () => { + it('should return a stable callback', () => { + const hook = renderHook((cb) => useStableCallback(cb), { initialProps: () => {} }); + const firstCallback = hook.result.current; + hook.rerender(() => {}); + expect(hook.result.current).toBe(firstCallback); + }); +}); diff --git a/src/plugins/unified_histogram/public/chart/use_stable_callback.ts b/src/plugins/unified_histogram/public/chart/use_stable_callback.ts new file mode 100644 index 0000000000000..9b81470c5ff5c --- /dev/null +++ b/src/plugins/unified_histogram/public/chart/use_stable_callback.ts @@ -0,0 +1,23 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { useCallback, useEffect, useRef } from 'react'; + +/** + * Accepts a callback and returns a function with a stable identity + * that will always call the latest version of the callback when invoked + */ +export const useStableCallback = any>(fn: T | undefined) => { + const ref = useRef(fn); + + useEffect(() => { + ref.current = fn; + }, [fn]); + + return useCallback((...args: Parameters) => ref.current?.(...args), []); +}; diff --git a/src/plugins/unified_histogram/public/chart/use_total_hits.test.ts b/src/plugins/unified_histogram/public/chart/use_total_hits.test.ts index 4782df3683fcb..ea6ab4676e681 100644 --- a/src/plugins/unified_histogram/public/chart/use_total_hits.test.ts +++ b/src/plugins/unified_histogram/public/chart/use_total_hits.test.ts @@ -7,14 +7,14 @@ */ import { Filter } from '@kbn/es-query'; -import { UnifiedHistogramFetchStatus } from '../types'; +import { UnifiedHistogramFetchStatus, UnifiedHistogramInput$ } from '../types'; import { dataViewWithTimefieldMock } from '../__mocks__/data_view_with_timefield'; import { useTotalHits } from './use_total_hits'; import { useEffect as mockUseEffect } from 'react'; import { renderHook } from '@testing-library/react-hooks'; import { dataPluginMock } from '@kbn/data-plugin/public/mocks'; import { searchSourceInstanceMock } from '@kbn/data-plugin/common/search/search_source/mocks'; -import { of, throwError } from 'rxjs'; +import { of, Subject, throwError } from 'rxjs'; import { waitFor } from '@testing-library/dom'; import { RequestAdapter } from '@kbn/inspector-plugin/common'; import { DataViewType, SearchSourceSearchOptions } from '@kbn/data-plugin/common'; @@ -26,25 +26,21 @@ jest.mock('react-use/lib/useDebounce', () => { }); describe('useTotalHits', () => { + const timeRange = { from: 'now-15m', to: 'now' }; + const refetch$: UnifiedHistogramInput$ = new Subject(); const getDeps = () => ({ services: { data: dataPluginMock.createStartContract() } as any, dataView: dataViewWithTimefieldMock, - lastReloadRequestTime: undefined, request: undefined, hits: { status: UnifiedHistogramFetchStatus.uninitialized, total: undefined, }, - chart: { - hidden: true, - timeInterval: 'auto', - }, chartVisible: false, - breakdown: undefined, filters: [], query: { query: '', language: 'kuery' }, - timeRange: { from: 'now-15m', to: 'now' }, - refetchId: 0, + getTimeRange: () => timeRange, + refetch$, onTotalHitsChange: jest.fn(), }); @@ -68,7 +64,6 @@ describe('useTotalHits', () => { }); const setFieldSpy = jest.spyOn(searchSourceInstanceMock, 'setField').mockClear(); const data = dataPluginMock.createStartContract(); - const timeRange = { from: 'now-15m', to: 'now' }; jest .spyOn(data.query.timefilter.timefilter, 'createFilter') .mockClear() @@ -86,7 +81,7 @@ describe('useTotalHits', () => { }, query, filters, - timeRange, + refetch$, onTotalHitsChange, }) ); @@ -128,11 +123,11 @@ describe('useTotalHits', () => { expect(fetchSpy).not.toHaveBeenCalled(); }); - it('should not fetch a second time if fetchId is the same', async () => { + it('should not fetch a second time if refetch$ is not triggered', async () => { const onTotalHitsChange = jest.fn(); const fetchSpy = jest.spyOn(searchSourceInstanceMock, 'fetch$').mockClear(); const setFieldSpy = jest.spyOn(searchSourceInstanceMock, 'setField').mockClear(); - const options = { ...getDeps(), refetchId: 0, onTotalHitsChange }; + const options = { ...getDeps(), onTotalHitsChange }; const { rerender } = renderHook(() => useTotalHits(options)); expect(onTotalHitsChange).toBeCalledTimes(1); expect(setFieldSpy).toHaveBeenCalled(); @@ -146,12 +141,12 @@ describe('useTotalHits', () => { expect(fetchSpy).toHaveBeenCalledTimes(1); }); - it('should fetch a second time if fetchId is different', async () => { + it('should fetch a second time if refetch$ is triggered', async () => { const abortSpy = jest.spyOn(AbortController.prototype, 'abort').mockClear(); const onTotalHitsChange = jest.fn(); const fetchSpy = jest.spyOn(searchSourceInstanceMock, 'fetch$').mockClear(); const setFieldSpy = jest.spyOn(searchSourceInstanceMock, 'setField').mockClear(); - const options = { ...getDeps(), refetchId: 0, onTotalHitsChange }; + const options = { ...getDeps(), onTotalHitsChange }; const { rerender } = renderHook(() => useTotalHits(options)); expect(onTotalHitsChange).toBeCalledTimes(1); expect(setFieldSpy).toHaveBeenCalled(); @@ -159,7 +154,7 @@ describe('useTotalHits', () => { await waitFor(() => { expect(onTotalHitsChange).toBeCalledTimes(2); }); - options.refetchId = 1; + refetch$.next({ type: 'refetch' }); rerender(); expect(abortSpy).toHaveBeenCalled(); expect(onTotalHitsChange).toBeCalledTimes(3); @@ -190,7 +185,6 @@ describe('useTotalHits', () => { .mockClear(); const setFieldSpy = jest.spyOn(searchSourceInstanceMock, 'setField').mockClear(); const data = dataPluginMock.createStartContract(); - const timeRange = { from: 'now-15m', to: 'now' }; jest .spyOn(data.query.timefilter.timefilter, 'createFilter') .mockClear() diff --git a/src/plugins/unified_histogram/public/chart/use_total_hits.ts b/src/plugins/unified_histogram/public/chart/use_total_hits.ts index 3f24b642c81bf..e7227edd76684 100644 --- a/src/plugins/unified_histogram/public/chart/use_total_hits.ts +++ b/src/plugins/unified_histogram/public/chart/use_total_hits.ts @@ -10,68 +10,63 @@ import { isCompleteResponse } from '@kbn/data-plugin/public'; import { DataView, DataViewType } from '@kbn/data-views-plugin/public'; import type { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; import { i18n } from '@kbn/i18n'; -import { MutableRefObject, useRef } from 'react'; -import useDebounce from 'react-use/lib/useDebounce'; -import { catchError, filter, lastValueFrom, map, of } from 'rxjs'; +import { MutableRefObject, useEffect, useRef } from 'react'; +import useEffectOnce from 'react-use/lib/useEffectOnce'; +import { catchError, filter, lastValueFrom, map, Observable, of } from 'rxjs'; import { - UnifiedHistogramBreakdownContext, - UnifiedHistogramChartContext, UnifiedHistogramFetchStatus, UnifiedHistogramHitsContext, + UnifiedHistogramInputMessage, UnifiedHistogramRequestContext, UnifiedHistogramServices, } from '../types'; -import { REQUEST_DEBOUNCE_MS } from './consts'; +import { useStableCallback } from './use_stable_callback'; export const useTotalHits = ({ services, dataView, - lastReloadRequestTime, request, hits, - chart, chartVisible, - breakdown, filters, query, - timeRange, - refetchId, + getTimeRange, + refetch$, onTotalHitsChange, }: { services: UnifiedHistogramServices; dataView: DataView; - lastReloadRequestTime: number | undefined; request: UnifiedHistogramRequestContext | undefined; hits: UnifiedHistogramHitsContext | undefined; - chart: UnifiedHistogramChartContext | undefined; chartVisible: boolean; - breakdown: UnifiedHistogramBreakdownContext | undefined; filters: Filter[]; query: Query | AggregateQuery; - timeRange: TimeRange; - refetchId: number; + getTimeRange: () => TimeRange; + refetch$: Observable; onTotalHitsChange?: (status: UnifiedHistogramFetchStatus, result?: number | Error) => void; }) => { const abortController = useRef(); - - useDebounce( - () => { - fetchTotalHits({ - services, - abortController, - dataView, - request, - hits, - chartVisible, - filters, - query, - timeRange, - onTotalHitsChange, - }); - }, - REQUEST_DEBOUNCE_MS, - [onTotalHitsChange, refetchId, services] - ); + const fetch = useStableCallback(() => { + fetchTotalHits({ + services, + abortController, + dataView, + request, + hits, + chartVisible, + filters, + query, + timeRange: getTimeRange(), + onTotalHitsChange, + }); + }); + + useEffectOnce(fetch); + + useEffect(() => { + const subscription = refetch$.subscribe(fetch); + return () => subscription.unsubscribe(); + }, [fetch, refetch$]); }; const fetchTotalHits = async ({ diff --git a/src/plugins/unified_histogram/public/index.ts b/src/plugins/unified_histogram/public/index.ts index 4a8f73477c0b6..97cebb51fdc2f 100644 --- a/src/plugins/unified_histogram/public/index.ts +++ b/src/plugins/unified_histogram/public/index.ts @@ -18,6 +18,9 @@ export type { UnifiedHistogramBreakdownContext, UnifiedHistogramChartLoadEvent, UnifiedHistogramAdapters, + UnifiedHistogramRefetchMessage, + UnifiedHistogramInputMessage, + UnifiedHistogramInput$, } from './types'; export { UnifiedHistogramFetchStatus } from './types'; diff --git a/src/plugins/unified_histogram/public/layout/layout.test.tsx b/src/plugins/unified_histogram/public/layout/layout.test.tsx index d77bbfa05be30..aee62e3c7d3b8 100644 --- a/src/plugins/unified_histogram/public/layout/layout.test.tsx +++ b/src/plugins/unified_histogram/public/layout/layout.test.tsx @@ -56,14 +56,6 @@ describe('Layout', () => { hits?: UnifiedHistogramHitsContext | null; chart?: UnifiedHistogramChartContext | null; } = {}) => { - services.data.query.timefilter.timefilter.getAbsoluteTime = () => { - return { from: '2020-05-14T11:05:13.590', to: '2020-05-14T11:20:13.590' }; - }; - - (services.data.query.queryString.getDefaultQuery as jest.Mock).mockReturnValue({ - language: 'kuery', - query: '', - }); (searchSourceInstanceMock.fetch$ as jest.Mock).mockImplementation( jest.fn().mockReturnValue(of({ rawResponse: { hits: { total: 2 } } })) ); @@ -75,6 +67,15 @@ describe('Layout', () => { chart={chart ?? undefined} resizeRef={resizeRef} dataView={dataViewWithTimefieldMock} + query={{ + language: 'kuery', + query: '', + }} + filters={[]} + timeRange={{ + from: '2020-05-14T11:05:13.590', + to: '2020-05-14T11:20:13.590', + }} {...rest} /> ); diff --git a/src/plugins/unified_histogram/public/layout/layout.tsx b/src/plugins/unified_histogram/public/layout/layout.tsx index 87d4170a1035f..db6a161a81b7e 100644 --- a/src/plugins/unified_histogram/public/layout/layout.tsx +++ b/src/plugins/unified_histogram/public/layout/layout.tsx @@ -12,7 +12,8 @@ import React, { useMemo } from 'react'; import { createHtmlPortalNode, InPortal, OutPortal } from 'react-reverse-portal'; import { css } from '@emotion/css'; import type { DataView, DataViewField } from '@kbn/data-views-plugin/public'; -import type { TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import type { LensEmbeddableInput, TypedLensByValueInput } from '@kbn/lens-plugin/public'; +import type { AggregateQuery, Filter, Query, TimeRange } from '@kbn/es-query'; import { Chart } from '../chart'; import { Panels, PANELS_MODE } from '../panels'; import type { @@ -23,6 +24,7 @@ import type { UnifiedHistogramFetchStatus, UnifiedHistogramRequestContext, UnifiedHistogramChartLoadEvent, + UnifiedHistogramInput$, } from '../types'; export interface UnifiedHistogramLayoutProps extends PropsWithChildren { @@ -39,9 +41,17 @@ export interface UnifiedHistogramLayoutProps extends PropsWithChildren */ dataView: DataView; /** - * Can be updated to `Date.now()` to force a refresh + * The current query */ - lastReloadRequestTime?: number; + query?: Query | AggregateQuery; + /** + * The current filters + */ + filters?: Filter[]; + /** + * The current time range + */ + timeRange?: TimeRange; /** * Context object for requests made by unified histogram components -- optional */ @@ -70,6 +80,22 @@ export interface UnifiedHistogramLayoutProps extends PropsWithChildren * Append a custom element to the right of the hits count */ appendHitsCounter?: ReactElement; + /** + * Disable automatic refetching based on props changes, and instead wait for a `refetch` message + */ + disableAutoFetching?: boolean; + /** + * Disable triggers for the Lens embeddable + */ + disableTriggers?: LensEmbeddableInput['disableTriggers']; + /** + * Disabled action IDs for the Lens embeddable + */ + disabledActions?: LensEmbeddableInput['disabledActions']; + /** + * Input observable + */ + input$?: UnifiedHistogramInput$; /** * Callback to update the topPanelHeight prop when a resize is triggered */ @@ -99,13 +125,23 @@ export interface UnifiedHistogramLayoutProps extends PropsWithChildren * Called when the histogram loading status changes */ onChartLoad?: (event: UnifiedHistogramChartLoadEvent) => void; + /** + * Callback to pass to the Lens embeddable to handle filter changes + */ + onFilter?: LensEmbeddableInput['onFilter']; + /** + * Callback to pass to the Lens embeddable to handle brush events + */ + onBrushEnd?: LensEmbeddableInput['onBrushEnd']; } export const UnifiedHistogramLayout = ({ className, services, dataView, - lastReloadRequestTime, + query, + filters, + timeRange, request, hits, chart, @@ -113,6 +149,10 @@ export const UnifiedHistogramLayout = ({ resizeRef, topPanelHeight, appendHitsCounter, + disableAutoFetching, + disableTriggers, + disabledActions, + input$, onTopPanelHeightChange, onEditVisualization, onChartHiddenChange, @@ -120,6 +160,8 @@ export const UnifiedHistogramLayout = ({ onBreakdownFieldChange, onTotalHitsChange, onChartLoad, + onFilter, + onBrushEnd, children, }: UnifiedHistogramLayoutProps) => { const topPanelNode = useMemo( @@ -167,13 +209,19 @@ export const UnifiedHistogramLayout = ({ className={chartClassName} services={services} dataView={dataView} - lastReloadRequestTime={lastReloadRequestTime} + query={query} + filters={filters} + timeRange={timeRange} request={request} hits={hits} chart={chart} breakdown={breakdown} appendHitsCounter={appendHitsCounter} appendHistogram={showFixedPanels ? : } + disableAutoFetching={disableAutoFetching} + disableTriggers={disableTriggers} + disabledActions={disabledActions} + input$={input$} onEditVisualization={onEditVisualization} onResetChartHeight={onResetChartHeight} onChartHiddenChange={onChartHiddenChange} @@ -181,6 +229,8 @@ export const UnifiedHistogramLayout = ({ onBreakdownFieldChange={onBreakdownFieldChange} onTotalHitsChange={onTotalHitsChange} onChartLoad={onChartLoad} + onFilter={onFilter} + onBrushEnd={onBrushEnd} /> {children} diff --git a/src/plugins/unified_histogram/public/panels/panels_resizable.test.tsx b/src/plugins/unified_histogram/public/panels/panels_resizable.test.tsx index a21e137e87ed7..add0281cfc0fd 100644 --- a/src/plugins/unified_histogram/public/panels/panels_resizable.test.tsx +++ b/src/plugins/unified_histogram/public/panels/panels_resizable.test.tsx @@ -176,22 +176,19 @@ describe('Panels resizable', () => { const attachTo = document.createElement('div'); document.body.appendChild(attachTo); const component = mountComponent({ attachTo }); - const wrapper = component.find('[data-test-subj="unifiedHistogramResizableContainerWrapper"]'); + const getContainer = () => + component.find('[data-test-subj="unifiedHistogramResizableContainer"]').at(0); const resizeButton = component.find('button[data-test-subj="unifiedHistogramResizableButton"]'); - const resizeButtonInner = component.find( - '[data-test-subj="unifiedHistogramResizableButtonInner"]' - ); - const mouseEvent = { - pageX: 0, - pageY: 0, - clientX: 0, - clientY: 0, - }; - resizeButtonInner.simulate('mousedown', mouseEvent); - resizeButton.simulate('mousedown', mouseEvent); + act(() => { + const onResizeStart = getContainer().prop('onResizeStart') as Function; + onResizeStart('pointer'); + }); (resizeButton.getDOMNode() as HTMLElement).focus(); - wrapper.simulate('mouseup', mouseEvent); - resizeButton.simulate('click', mouseEvent); + forceRender(component); + act(() => { + const onResizeEnd = getContainer().prop('onResizeEnd') as Function; + onResizeEnd(); + }); expect(resizeButton.getDOMNode()).toHaveFocus(); await waitFor(() => { expect(resizeButton.getDOMNode()).not.toHaveFocus(); diff --git a/src/plugins/unified_histogram/public/panels/panels_resizable.tsx b/src/plugins/unified_histogram/public/panels/panels_resizable.tsx index 76fecd42d2aed..bbf4a70f90e9d 100644 --- a/src/plugins/unified_histogram/public/panels/panels_resizable.tsx +++ b/src/plugins/unified_histogram/public/panels/panels_resizable.tsx @@ -12,6 +12,7 @@ import { useGeneratedHtmlId, useResizeObserver, } from '@elastic/eui'; +import type { ResizeTrigger } from '@elastic/eui/src/components/resizable_container/types'; import { css } from '@emotion/react'; import { isEqual, round } from 'lodash'; import type { ReactElement, RefObject } from 'react'; @@ -51,24 +52,23 @@ export const PanelsResizable = ({ // end to toggle the rendering of a transparent overlay which prevents the cancellation. // EUI issue: https://github.com/elastic/eui/issues/6199 const [resizeWithPortalsHackIsResizing, setResizeWithPortalsHackIsResizing] = useState(false); - const enableResizeWithPortalsHack = () => setResizeWithPortalsHackIsResizing(true); - const disableResizeWithPortalsHack = () => setResizeWithPortalsHackIsResizing(false); - const resizeWithPortalsHackFillCss = css` + const enableResizeWithPortalsHack = useCallback( + () => setResizeWithPortalsHackIsResizing(true), + [] + ); + const disableResizeWithPortalsHack = useCallback( + () => setResizeWithPortalsHackIsResizing(false), + [] + ); + const resizeWithPortalsHackButtonCss = css` + z-index: 3; + `; + const resizeWithPortalsHackOverlayCss = css` position: absolute; top: 0; left: 0; width: 100%; height: 100%; - `; - const resizeWithPortalsHackButtonCss = css` - z-index: 3; - `; - const resizeWithPortalsHackButtonInnerCss = css` - ${resizeWithPortalsHackFillCss} - z-index: 1; - `; - const resizeWithPortalsHackOverlayCss = css` - ${resizeWithPortalsHackFillCss} z-index: 2; `; @@ -133,11 +133,26 @@ export const PanelsResizable = ({ } }, [containerHeight, minMainPanelHeight, minTopPanelHeight, panelSizes, topPanelHeight]); - const onResizeEnd = () => { + const onResizeStart = useCallback( + (trigger: ResizeTrigger) => { + if (trigger !== 'pointer') { + return; + } + + enableResizeWithPortalsHack(); + }, + [enableResizeWithPortalsHack] + ); + + const onResizeEnd = useCallback(() => { + if (!resizeWithPortalsHackIsResizing) { + return; + } + // We don't want the resize button to retain focus after the resize is complete, // but EuiResizableContainer will force focus it onClick. To work around this we // use setTimeout to wait until after onClick has been called before blurring. - if (resizeWithPortalsHackIsResizing && document.activeElement instanceof HTMLElement) { + if (document.activeElement instanceof HTMLElement) { const button = document.activeElement; setTimeout(() => { button.blur(); @@ -145,7 +160,7 @@ export const PanelsResizable = ({ } disableResizeWithPortalsHack(); - }; + }, [disableResizeWithPortalsHack, resizeWithPortalsHackIsResizing]); const { euiTheme } = useEuiTheme(); const buttonCss = css` @@ -156,57 +171,40 @@ export const PanelsResizable = ({ `; return ( -
    - - {(EuiResizablePanel, EuiResizableButton) => ( - <> - - {topPanel} - - - - - - {mainPanel} - - {resizeWithPortalsHackIsResizing ? ( -
    - ) : ( - <> - )} - - )} - -
    + {(EuiResizablePanel, EuiResizableButton) => ( + <> + + {topPanel} + + + + {mainPanel} + + {resizeWithPortalsHackIsResizing ?
    : <>} + + )} + ); }; diff --git a/src/plugins/unified_histogram/public/types.ts b/src/plugins/unified_histogram/public/types.ts index a4b253274abde..f77bfa1bbdbee 100644 --- a/src/plugins/unified_histogram/public/types.ts +++ b/src/plugins/unified_histogram/public/types.ts @@ -14,6 +14,7 @@ import type { LensPublicStart } from '@kbn/lens-plugin/public'; import type { DataViewField } from '@kbn/data-views-plugin/public'; import type { RequestAdapter } from '@kbn/inspector-plugin/public'; import type { DefaultInspectorAdapters } from '@kbn/expressions-plugin/common'; +import type { Subject } from 'rxjs'; /** * The fetch status of a unified histogram request @@ -52,10 +53,6 @@ export type UnifiedHistogramAdapters = Partial; * Emitted when the histogram loading status changes */ export interface UnifiedHistogramChartLoadEvent { - /** - * True if loading is complete - */ - complete: boolean; /** * Inspector adapters for the request */ @@ -117,3 +114,20 @@ export interface UnifiedHistogramBreakdownContext { */ field?: DataViewField; } + +/** + * Message to refetch the chart and total hits + */ +export interface UnifiedHistogramRefetchMessage { + type: 'refetch'; +} + +/** + * Unified histogram input message + */ +export type UnifiedHistogramInputMessage = UnifiedHistogramRefetchMessage; + +/** + * Unified histogram input observable + */ +export type UnifiedHistogramInput$ = Subject; diff --git a/src/plugins/unified_histogram/tsconfig.json b/src/plugins/unified_histogram/tsconfig.json index a6bd54ed5e6ea..eb7da12b70b29 100644 --- a/src/plugins/unified_histogram/tsconfig.json +++ b/src/plugins/unified_histogram/tsconfig.json @@ -18,7 +18,6 @@ "@kbn/i18n", "@kbn/es-query", "@kbn/embeddable-plugin", - "@kbn/kibana-utils-plugin", "@kbn/core-ui-settings-browser", "@kbn/datemath", "@kbn/core-ui-settings-browser-mocks", diff --git a/src/plugins/unified_search/public/filter_bar/filter_item/filter_item.tsx b/src/plugins/unified_search/public/filter_bar/filter_item/filter_item.tsx index fcd6cb94a1747..d994f35c1ff37 100644 --- a/src/plugins/unified_search/public/filter_bar/filter_item/filter_item.tsx +++ b/src/plugins/unified_search/public/filter_bar/filter_item/filter_item.tsx @@ -389,7 +389,7 @@ function FilterItemComponent(props: FilterItemProps) { onSubmit={onSubmit} onLocalFilterUpdate={onLocalFilterUpdate} onLocalFilterCreate={onLocalFilterCreate} - onCancel={closePopover} + onCancel={() => setIsPopoverOpen(false)} timeRangeForSuggestionsOverride={props.timeRangeForSuggestionsOverride} />
    , diff --git a/src/plugins/unified_search/public/query_string_input/add_filter_popover.tsx b/src/plugins/unified_search/public/query_string_input/add_filter_popover.tsx index 796db77c6be2f..2f65274c99c13 100644 --- a/src/plugins/unified_search/public/query_string_input/add_filter_popover.tsx +++ b/src/plugins/unified_search/public/query_string_input/add_filter_popover.tsx @@ -102,7 +102,9 @@ const AddFilterPopoverComponent = React.memo(function AddFilterPopover({ closePopoverOnAdd={() => { setShowAddFilterPopover(false); }} - closePopoverOnCancel={closePopover} + closePopoverOnCancel={() => { + setShowAddFilterPopover(false); + }} /> diff --git a/src/plugins/unified_search/public/query_string_input/query_bar_menu.tsx b/src/plugins/unified_search/public/query_string_input/query_bar_menu.tsx index 4a31214d2f6ae..0c742daebd836 100644 --- a/src/plugins/unified_search/public/query_string_input/query_bar_menu.tsx +++ b/src/plugins/unified_search/public/query_string_input/query_bar_menu.tsx @@ -190,7 +190,7 @@ function QueryBarMenuComponent({ onLocalFilterUpdate={onLocalFilterUpdate} onLocalFilterCreate={onLocalFilterCreate} closePopoverOnAdd={plainClosePopover} - closePopoverOnCancel={closePopover} + closePopoverOnCancel={plainClosePopover} />, ]} /> diff --git a/src/plugins/unified_search/public/search_bar/create_search_bar.tsx b/src/plugins/unified_search/public/search_bar/create_search_bar.tsx index d522991778ead..9ef1772ed47d8 100644 --- a/src/plugins/unified_search/public/search_bar/create_search_bar.tsx +++ b/src/plugins/unified_search/public/search_bar/create_search_bar.tsx @@ -193,45 +193,47 @@ export function createSearchBar({ ...core, }} > - + + + ); }; diff --git a/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.test.ts b/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.test.ts index 0b2bab509341d..de88fb0a7a866 100644 --- a/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.test.ts +++ b/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.test.ts @@ -68,7 +68,7 @@ describe('getConfiguration', () => { }) ).toEqual({ colorMode: 'palette', - labelMajorMode: 'none', + labelMajorMode: 'auto', labelMinor: undefined, layerId: 'layer-id', layerType: 'data', diff --git a/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.ts b/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.ts index 9a5483d038c2e..9da64a38f8811 100644 --- a/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.ts +++ b/src/plugins/vis_types/gauge/public/convert_to_lens/configurations/gauge.ts @@ -34,7 +34,7 @@ export const getConfiguration = ( maxAccessor, shape: 'horizontalBullet', ticksPosition: 'bands', - labelMajorMode: showLabels ? 'auto' : 'none', + labelMajorMode: 'auto', colorMode: palette ? 'palette' : 'none', labelMinor: showLabels ? params.gauge.style.subText : undefined, }; diff --git a/src/plugins/vis_types/gauge/public/convert_to_lens/gauge.ts b/src/plugins/vis_types/gauge/public/convert_to_lens/gauge.ts index 080d5e84561a9..27d1f8a674939 100644 --- a/src/plugins/vis_types/gauge/public/convert_to_lens/gauge.ts +++ b/src/plugins/vis_types/gauge/public/convert_to_lens/gauge.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Column, ColumnWithMeta, @@ -81,7 +81,7 @@ export const convertToLens: ConvertGaugeVisToLensVisualization = async (vis, tim } } - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; const metricAccessor = layerConfig.metrics[0]; diff --git a/src/plugins/vis_types/gauge/public/convert_to_lens/goal.ts b/src/plugins/vis_types/gauge/public/convert_to_lens/goal.ts index 624ce45b3e848..0dbb88775aae2 100644 --- a/src/plugins/vis_types/gauge/public/convert_to_lens/goal.ts +++ b/src/plugins/vis_types/gauge/public/convert_to_lens/goal.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Column, ColumnWithMeta, @@ -84,7 +84,7 @@ export const convertToLens: ConvertGoalVisToLensVisualization = async (vis, time const maxColumn = createStaticValueColumn(isPercentageMode ? 1 : max); const columns = [...layerConfig.columns, maxColumn]; - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; return { diff --git a/src/plugins/vis_types/heatmap/public/convert_to_lens/index.ts b/src/plugins/vis_types/heatmap/public/convert_to_lens/index.ts index 546d497e80560..1cf122de73fe3 100644 --- a/src/plugins/vis_types/heatmap/public/convert_to_lens/index.ts +++ b/src/plugins/vis_types/heatmap/public/convert_to_lens/index.ts @@ -11,7 +11,7 @@ import { convertToLensModule, getDataViewByIndexPatternId, } from '@kbn/visualizations-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getDataViewsStart } from '../services'; import { getConfiguration } from './configurations'; import { ConvertHeatmapToLensVisualization } from './types'; @@ -59,7 +59,7 @@ export const convertToLens: ConvertHeatmapToLensVisualization = async (vis, time const xColumn = layerConfig.columns.find(({ isBucketed, isSplit }) => isBucketed && !isSplit); const xAxisColumn = xColumn ?? - convertToFiltersColumn(uuid(), { filters: [{ input: { language: 'lucene', query: '*' } }] })!; + convertToFiltersColumn(uuidv4(), { filters: [{ input: { language: 'lucene', query: '*' } }] })!; if (xColumn?.columnId !== xAxisColumn?.columnId) { layerConfig.buckets.all.push(xAxisColumn.columnId); @@ -71,7 +71,7 @@ export const convertToLens: ConvertHeatmapToLensVisualization = async (vis, time return null; } - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; const configuration = await getConfiguration(layerId, vis, { diff --git a/src/plugins/vis_types/metric/public/convert_to_lens/index.ts b/src/plugins/vis_types/metric/public/convert_to_lens/index.ts index 5b9cb985a2799..98f3c865ab4a5 100644 --- a/src/plugins/vis_types/metric/public/convert_to_lens/index.ts +++ b/src/plugins/vis_types/metric/public/convert_to_lens/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Column, ColumnWithMeta } from '@kbn/visualizations-plugin/common'; import { convertToLensModule, @@ -74,7 +74,7 @@ export const convertToLens: ConvertMetricVisToLensVisualization = async (vis, ti } } - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; return { diff --git a/src/plugins/vis_types/pie/public/convert_to_lens/index.ts b/src/plugins/vis_types/pie/public/convert_to_lens/index.ts index c7231af7098c8..d9f80e4645243 100644 --- a/src/plugins/vis_types/pie/public/convert_to_lens/index.ts +++ b/src/plugins/vis_types/pie/public/convert_to_lens/index.ts @@ -11,7 +11,7 @@ import { convertToLensModule, getDataViewByIndexPatternId, } from '@kbn/visualizations-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getDataViewsStart } from '../services'; import { getConfiguration } from './configurations'; import { ConvertPieToLensVisualization } from './types'; @@ -62,7 +62,7 @@ export const convertToLens: ConvertPieToLensVisualization = async (vis, timefilt return null; } - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; return { diff --git a/src/plugins/vis_types/table/public/convert_to_lens/index.ts b/src/plugins/vis_types/table/public/convert_to_lens/index.ts index ed23d612cb68c..66b61250648d1 100644 --- a/src/plugins/vis_types/table/public/convert_to_lens/index.ts +++ b/src/plugins/vis_types/table/public/convert_to_lens/index.ts @@ -13,7 +13,7 @@ import { getVisSchemas, getDataViewByIndexPatternId, } from '@kbn/visualizations-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getDataViewsStart } from '../services'; import { getConfiguration } from './configurations'; import { ConvertTableToLensVisualization } from './types'; @@ -89,7 +89,7 @@ export const convertToLens: ConvertTableToLensVisualization = async (vis, timefi layerConfig.columnsWithoutReferenced.push(percentageColumn); } - const layerId = uuid(); + const layerId = uuidv4(); const indexPatternId = dataView.id!; return { type: 'lnsDatatable', diff --git a/src/plugins/vis_types/timeseries/public/application/components/aggs/percentile_ui.js b/src/plugins/vis_types/timeseries/public/application/components/aggs/percentile_ui.js index f03b807e55a46..ec7101c93e0b0 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/aggs/percentile_ui.js +++ b/src/plugins/vis_types/timeseries/public/application/components/aggs/percentile_ui.js @@ -13,7 +13,7 @@ import _ from 'lodash'; import { TSVB_DEFAULT_COLOR } from '../../../../common/constants'; import { collectionActions } from '../lib/collection_actions'; import { AddDeleteButtons } from '../add_delete_buttons'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { htmlIdGenerator, EuiFlexGroup, @@ -28,7 +28,7 @@ import { ColorPicker } from '../color_picker'; import { FormattedMessage } from '@kbn/i18n-react'; export const newPercentile = (opts) => { - return _.assign({ id: uuid.v1(), mode: 'line', shade: 0.2, color: TSVB_DEFAULT_COLOR }, opts); + return _.assign({ id: uuidv1(), mode: 'line', shade: 0.2, color: TSVB_DEFAULT_COLOR }, opts); }; export class Percentiles extends Component { diff --git a/src/plugins/vis_types/timeseries/public/application/components/aggs/vars.js b/src/plugins/vis_types/timeseries/public/application/components/aggs/vars.js index ba06b0fffd307..27549f5335bd1 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/aggs/vars.js +++ b/src/plugins/vis_types/timeseries/public/application/components/aggs/vars.js @@ -8,7 +8,7 @@ import PropTypes from 'prop-types'; import React, { Component } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { i18n } from '@kbn/i18n'; import _ from 'lodash'; import { AddDeleteButtons } from '../add_delete_buttons'; @@ -17,7 +17,7 @@ import { MetricSelect } from './metric_select'; import { EuiFlexGroup, EuiFlexItem, EuiFieldText } from '@elastic/eui'; import { getIndexPatternKey } from '../../../../common/index_patterns_utils'; -export const newVariable = (opts) => ({ id: uuid.v1(), name: '', field: '', ...opts }); +export const newVariable = (opts) => ({ id: uuidv1(), name: '', field: '', ...opts }); export class CalculationVars extends Component { constructor(props) { diff --git a/src/plugins/vis_types/timeseries/public/application/components/annotations_editor.tsx b/src/plugins/vis_types/timeseries/public/application/components/annotations_editor.tsx index 4275738106b7f..e0ee9adb08a90 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/annotations_editor.tsx +++ b/src/plugins/vis_types/timeseries/public/application/components/annotations_editor.tsx @@ -7,7 +7,7 @@ */ import React, { useCallback } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { EuiSpacer, EuiTitle, EuiButton, EuiText } from '@elastic/eui'; import { FormattedMessage } from '@kbn/i18n-react'; import type { DataView } from '@kbn/data-views-plugin/public'; @@ -28,7 +28,7 @@ interface AnnotationsEditorProps { } export const newAnnotation = (defaultIndexPattern?: DataView) => () => ({ - id: uuid.v1(), + id: uuidv1(), color: '#F00', index_pattern: defaultIndexPattern && defaultIndexPattern.id ? { id: defaultIndexPattern.id } : '', diff --git a/src/plugins/vis_types/timeseries/public/application/components/lib/collection_actions.ts b/src/plugins/vis_types/timeseries/public/application/components/lib/collection_actions.ts index e4cb53fd2d743..8d12c2a5f96cb 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/lib/collection_actions.ts +++ b/src/plugins/vis_types/timeseries/public/application/components/lib/collection_actions.ts @@ -6,14 +6,14 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; interface DocType { id: string; type?: string; } -const newFn = (): DocType => ({ id: uuid.v1() }); +const newFn = (): DocType => ({ id: uuidv1() }); export interface CollectionActionsProps { model: T; diff --git a/src/plugins/vis_types/timeseries/public/application/components/lib/new_metric_agg_fn.ts b/src/plugins/vis_types/timeseries/public/application/components/lib/new_metric_agg_fn.ts index 5c36b202b7b07..f78aa3638d002 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/lib/new_metric_agg_fn.ts +++ b/src/plugins/vis_types/timeseries/public/application/components/lib/new_metric_agg_fn.ts @@ -6,13 +6,13 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { METRIC_TYPES } from '@kbn/data-plugin/common'; import type { Metric } from '../../../../common/types'; export const newMetricAggFn = (): Metric => { return { - id: uuid.v1(), + id: uuidv1(), type: METRIC_TYPES.COUNT, }; }; diff --git a/src/plugins/vis_types/timeseries/public/application/components/lib/new_series_fn.js b/src/plugins/vis_types/timeseries/public/application/components/lib/new_series_fn.js index 4c665dfb53472..92458f0858245 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/lib/new_series_fn.js +++ b/src/plugins/vis_types/timeseries/public/application/components/lib/new_series_fn.js @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import _ from 'lodash'; import { newMetricAggFn } from './new_metric_agg_fn'; import { STACKED_OPTIONS } from '../../visualizations/constants'; @@ -14,7 +14,7 @@ import { STACKED_OPTIONS } from '../../visualizations/constants'; export const newSeriesFn = (obj = {}) => { return _.assign( { - id: uuid.v1(), + id: uuidv1(), color: '#68BC00', split_mode: 'everything', palette: { diff --git a/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.js b/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.js index 16dcc487e8a34..b24899bf2c52b 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.js +++ b/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.js @@ -6,14 +6,14 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import _ from 'lodash'; export const reIdSeries = (source) => { const series = _.cloneDeep(source); - series.id = uuid.v1(); + series.id = uuidv1(); series.metrics.forEach((metric) => { - const id = uuid.v1(); + const id = uuidv1(); const metricId = metric.id; metric.id = id; if (series.terms_order_by === metricId) series.terms_order_by = id; @@ -24,7 +24,7 @@ export const reIdSeries = (source) => { r.variables .filter((v) => v.field === metricId) .forEach((v) => { - v.id = uuid.v1(); + v.id = uuidv1(); v.field = id; }); }); diff --git a/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.test.js b/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.test.js index 707025d1ab631..47ea383ad3b1c 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.test.js +++ b/src/plugins/vis_types/timeseries/public/application/components/lib/re_id_series.test.js @@ -6,15 +6,15 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { reIdSeries } from './re_id_series'; describe('reIdSeries()', () => { test('reassign ids for series with just basic metrics', () => { const series = { - id: uuid.v1(), - metrics: [{ id: uuid.v1() }, { id: uuid.v1() }], + id: uuidv1(), + metrics: [{ id: uuidv1() }, { id: uuidv1() }], }; const newSeries = reIdSeries(series); expect(newSeries).not.toEqual(series); @@ -25,10 +25,10 @@ describe('reIdSeries()', () => { }); test('reassign ids for series with just basic metrics and group by', () => { - const firstMetricId = uuid.v1(); + const firstMetricId = uuidv1(); const series = { - id: uuid.v1(), - metrics: [{ id: firstMetricId }, { id: uuid.v1() }], + id: uuidv1(), + metrics: [{ id: firstMetricId }, { id: uuidv1() }], terms_order_by: firstMetricId, }; const newSeries = reIdSeries(series); @@ -41,10 +41,10 @@ describe('reIdSeries()', () => { }); test('reassign ids for series with pipeline metrics', () => { - const firstMetricId = uuid.v1(); + const firstMetricId = uuidv1(); const series = { - id: uuid.v1(), - metrics: [{ id: firstMetricId }, { id: uuid.v1(), field: firstMetricId }], + id: uuidv1(), + metrics: [{ id: firstMetricId }, { id: uuidv1(), field: firstMetricId }], }; const newSeries = reIdSeries(series); expect(newSeries).not.toEqual(series); @@ -53,15 +53,15 @@ describe('reIdSeries()', () => { }); test('reassign ids for series with calculation vars', () => { - const firstMetricId = uuid.v1(); + const firstMetricId = uuidv1(); const series = { - id: uuid.v1(), + id: uuidv1(), metrics: [ { id: firstMetricId }, { - id: uuid.v1(), + id: uuidv1(), type: 'calculation', - variables: [{ id: uuid.v1(), field: firstMetricId }], + variables: [{ id: uuidv1(), field: firstMetricId }], }, ], }; diff --git a/src/plugins/vis_types/timeseries/public/application/components/panel_config/gauge.tsx b/src/plugins/vis_types/timeseries/public/application/components/panel_config/gauge.tsx index 3d0cfcb00b840..7f36d18725ce0 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/panel_config/gauge.tsx +++ b/src/plugins/vis_types/timeseries/public/application/components/panel_config/gauge.tsx @@ -8,7 +8,7 @@ import { FormattedMessage } from '@kbn/i18n-react'; import { i18n } from '@kbn/i18n'; import React, { Component } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { htmlIdGenerator, EuiComboBox, @@ -55,7 +55,7 @@ export class GaugePanelConfig extends Component< const { model } = this.props; const parts: Writable> = {}; if (!model.gauge_color_rules || !model.gauge_color_rules.length) { - parts.gauge_color_rules = [{ id: uuid.v1() }]; + parts.gauge_color_rules = [{ id: uuidv1() }]; } if (model.gauge_width == null) parts.gauge_width = 10; if (model.gauge_inner_width == null) parts.gauge_inner_width = 10; diff --git a/src/plugins/vis_types/timeseries/public/application/components/panel_config/metric.tsx b/src/plugins/vis_types/timeseries/public/application/components/panel_config/metric.tsx index 79b47dbc1e986..24dec4c94364c 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/panel_config/metric.tsx +++ b/src/plugins/vis_types/timeseries/public/application/components/panel_config/metric.tsx @@ -8,7 +8,7 @@ import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import React, { Component } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { htmlIdGenerator, EuiTabs, @@ -48,7 +48,7 @@ export class MetricPanelConfig extends Component< (model.background_color_rules && model.background_color_rules.length === 0) ) { this.props.onChange({ - background_color_rules: [{ id: uuid.v1() }], + background_color_rules: [{ id: uuidv1() }], }); } } diff --git a/src/plugins/vis_types/timeseries/public/application/components/panel_config/table.tsx b/src/plugins/vis_types/timeseries/public/application/components/panel_config/table.tsx index 51fedbf5d7f6b..ce05bb514bef8 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/panel_config/table.tsx +++ b/src/plugins/vis_types/timeseries/public/application/components/panel_config/table.tsx @@ -8,7 +8,7 @@ import React, { Component } from 'react'; import { get } from 'lodash'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { htmlIdGenerator, EuiTabs, @@ -55,7 +55,7 @@ export class TablePanelConfig extends Component< UNSAFE_componentWillMount() { const { model } = this.props; if (!model.bar_color_rules || !model.bar_color_rules.length) { - this.props.onChange({ bar_color_rules: [{ id: uuid.v1() }] }); + this.props.onChange({ bar_color_rules: [{ id: uuidv1() }] }); } } diff --git a/src/plugins/vis_types/timeseries/public/application/components/panel_config/top_n.tsx b/src/plugins/vis_types/timeseries/public/application/components/panel_config/top_n.tsx index f002bfbdc38ad..8d2273cc54496 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/panel_config/top_n.tsx +++ b/src/plugins/vis_types/timeseries/public/application/components/panel_config/top_n.tsx @@ -8,7 +8,7 @@ import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import React, { Component } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { htmlIdGenerator, EuiTabs, @@ -48,7 +48,7 @@ export class TopNPanelConfig extends Component< UNSAFE_componentWillMount() { const { model } = this.props; if (!model.bar_color_rules || !model.bar_color_rules.length) { - this.props.onChange({ bar_color_rules: [{ id: uuid.v1() }] }); + this.props.onChange({ bar_color_rules: [{ id: uuidv1() }] }); } } diff --git a/src/plugins/vis_types/timeseries/public/application/components/split.js b/src/plugins/vis_types/timeseries/public/application/components/split.js index 33156f72bc5d2..9033e570b6943 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/split.js +++ b/src/plugins/vis_types/timeseries/public/application/components/split.js @@ -8,7 +8,7 @@ import PropTypes from 'prop-types'; import React, { Component } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { get } from 'lodash'; import { SplitByTerms } from './splits/terms'; import { SplitByFilter } from './splits/filter'; @@ -33,7 +33,7 @@ export class Split extends Component { split_filters: [ { color: model.color, - id: uuid.v1(), + id: uuidv1(), filter: { query: '', language: getDefaultQueryLanguage(), diff --git a/src/plugins/vis_types/timeseries/public/application/components/splits/filter_items.js b/src/plugins/vis_types/timeseries/public/application/components/splits/filter_items.js index ec5a42e2a6551..6a59f85d6180a 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/splits/filter_items.js +++ b/src/plugins/vis_types/timeseries/public/application/components/splits/filter_items.js @@ -12,7 +12,7 @@ import _ from 'lodash'; import { collectionActions } from '../lib/collection_actions'; import { AddDeleteButtons } from '../add_delete_buttons'; import { ColorPicker } from '../color_picker'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { EuiFieldText, EuiFlexGroup, EuiFlexItem, withEuiTheme } from '@elastic/eui'; import { injectI18n } from '@kbn/i18n-react'; import { getDefaultQueryLanguage } from '../lib/get_default_query_language'; @@ -50,7 +50,7 @@ class FilterItemsUi extends Component { const newFilter = () => ({ color: this.props.model.color, - id: uuid.v1(), + id: uuidv1(), filter: { language: model.filter.language || getDefaultQueryLanguage(), query: '' }, }); const handleAdd = collectionActions.handleAdd.bind(null, this.props, newFilter); diff --git a/src/plugins/vis_types/timeseries/public/application/components/vis_types/table/config.js b/src/plugins/vis_types/timeseries/public/application/components/vis_types/table/config.js index 506ce0dbdf2a9..99edee5cfefe7 100644 --- a/src/plugins/vis_types/timeseries/public/application/components/vis_types/table/config.js +++ b/src/plugins/vis_types/timeseries/public/application/components/vis_types/table/config.js @@ -8,7 +8,7 @@ import React, { Component } from 'react'; import PropTypes from 'prop-types'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { last } from 'lodash'; import { KBN_FIELD_TYPES } from '@kbn/data-plugin/public'; @@ -45,7 +45,7 @@ class TableSeriesConfigUi extends Component { const { model } = this.props; if (!model.color_rules || (model.color_rules && model.color_rules.length === 0)) { this.props.onChange({ - color_rules: [{ id: uuid.v1() }], + color_rules: [{ id: uuidv1() }], }); } } diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/gauge/index.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/gauge/index.ts index c6a2bd4429b7b..5f33a1a4f0a59 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/gauge/index.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/gauge/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { parseTimeShift } from '@kbn/data-plugin/common'; import { FormulaColumn, @@ -101,7 +101,7 @@ export const convertToLens: ConvertTsvbToLensVisualization = async ( const extendedLayer: ExtendedLayer = { indexPatternId, - layerId: uuid(), + layerId: uuidv4(), columns: [...metricsColumns, ...(bucket ? [bucket] : [])], columnOrder: [], }; diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/column.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/column.ts index 2be4e09bf8898..9634654ad069f 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/column.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/column.ts @@ -14,7 +14,7 @@ import { GenericColumnWithMeta, FormatParams, } from '@kbn/visualizations-plugin/common/convert_to_lens'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Metric, Series } from '../../../../common/types'; import { DATA_FORMATTERS } from '../../../../common/enums'; import { getTimeScale } from '../metrics'; @@ -65,7 +65,7 @@ export const createColumn = ( isAssignTimeScale = true, }: ExtraColumnFields = {} ): GeneralColumnWithMeta => ({ - columnId: uuid(), + columnId: uuidv4(), dataType: (field?.type as DataType) ?? undefined, label: series.label, isBucketed, diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/date_histogram.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/date_histogram.ts index 0887ad1168ddf..4c2def5429900 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/date_histogram.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/date_histogram.ts @@ -7,7 +7,7 @@ */ import type { DataView } from '@kbn/data-views-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DateHistogramParams, DataType } from '@kbn/visualizations-plugin/common/convert_to_lens'; import { DateHistogramColumn, DateHistogramSeries } from './types'; import type { Panel } from '../../../../common/types'; @@ -49,7 +49,7 @@ export const convertToDateHistogramColumn = ( const params = convertToDateHistogramParams(model, series, includeEmptyRows); return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'date_histogram', dataType: dateField.type as DataType, isBucketed: true, diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/filters.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/filters.ts index 05d74337e848d..ce122aee82a6b 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/filters.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/filters.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FiltersParams } from '@kbn/visualizations-plugin/common/convert_to_lens'; import { FiltersColumn, FiltersSeries } from './types'; @@ -44,7 +44,7 @@ export const convertToFiltersColumn = ( } return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'filters', dataType: 'string', isBucketed: true, diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/formula.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/formula.ts index 91d887f6a6680..eff4cee31438a 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/formula.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/formula.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { METRIC_TYPES } from '@kbn/data-plugin/public'; import { FormulaParams, @@ -46,7 +46,7 @@ export const createFormulaColumn = ( export const createFormulaColumnWithoutMeta = (formula: string): BaseFormulaColumn => { const params = convertToFormulaParams(formula); return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'formula', references: [], dataType: 'string', diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/static_value.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/static_value.ts index 7990107bb5bf9..c1bec9b4c48bb 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/static_value.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/static_value.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { StaticValueParams, StaticValueColumn as BaseStaticValueColumn, @@ -47,7 +47,7 @@ export const convertToStaticValueColumn = ( }; export const createStaticValueColumn = (staticValue: number): BaseStaticValueColumn => ({ - columnId: uuid(), + columnId: uuidv4(), operationType: 'static_value', references: [], dataType: 'number', diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/terms.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/terms.ts index c31d8dca68ced..3f6adcd7cdbcd 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/terms.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/lib/convert/terms.ts @@ -8,7 +8,7 @@ import type { DataView } from '@kbn/data-views-plugin/common'; import { DataType, TermsParams } from '@kbn/visualizations-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { excludeMetaFromColumn, getFormat, isColumnWithMeta } from './column'; import { Column, TermsColumn, TermsSeries } from './types'; @@ -28,7 +28,7 @@ const getOrderByWithAgg = (series: TermsSeries, columns: Column[]): OrderByWithA orderAgg: { operationType: 'count', sourceField: 'document', - columnId: uuid(), + columnId: uuidv4(), isBucketed: true, isSplit: false, dataType: 'number', @@ -102,7 +102,7 @@ export const convertToTermsColumn = ( } return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'terms', dataType: (field.type as DataType) ?? undefined, sourceField: field.name, diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/metric/index.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/metric/index.ts index f4eb2966f5e4f..95c7d0d6db0e3 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/metric/index.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/metric/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DataView, parseTimeShift } from '@kbn/data-plugin/common'; import { getIndexPatternIds } from '@kbn/visualizations-plugin/common/convert_to_lens'; import { PANEL_TYPES } from '../../../common/enums'; @@ -118,7 +118,7 @@ export const convertToLens: ConvertTsvbToLensVisualization = async ( const extendedLayer: ExtendedLayer = { indexPatternId: indexPatternId as string, - layerId: uuid(), + layerId: uuidv4(), columns: [...metrics, ...(bucket ? [bucket] : [])], columnOrder: [], }; diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/table/index.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/table/index.ts index 3f5aaf65f2889..42955cccfab2e 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/table/index.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/table/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { parseTimeShift } from '@kbn/data-plugin/common'; import { getIndexPatternIds, Layer } from '@kbn/visualizations-plugin/common/convert_to_lens'; import { PANEL_TYPES } from '../../../common/enums'; @@ -166,7 +166,7 @@ export const convertToLens: ConvertTsvbToLensVisualization = async ( const extendedLayer: ExtendedLayer = { indexPatternId: indexPatternId as string, - layerId: uuid(), + layerId: uuidv4(), columns: [...metrics, ...commonBucketsColumns, ...bucketsColumns], columnOrder: [], }; diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/timeseries/index.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/timeseries/index.ts index 3bdb208da78ad..09c2e07ebd0b9 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/timeseries/index.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/timeseries/index.ts @@ -12,7 +12,7 @@ import { isAnnotationsLayer, Layer, } from '@kbn/visualizations-plugin/common/convert_to_lens'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { DataViewsPublicPluginStart } from '@kbn/data-views-plugin/public'; import { PANEL_TYPES } from '../../../common/enums'; import { getDataViewsStart } from '../../services'; @@ -109,7 +109,7 @@ export const convertToLens: ConvertTsvbToLensVisualization = async ({ params: mo throw invalidModelError(); } - const layerId = uuid(); + const layerId = uuidv4(); extendedLayers[layerIdx] = { indexPatternId, layerId, diff --git a/src/plugins/vis_types/timeseries/public/convert_to_lens/top_n/index.ts b/src/plugins/vis_types/timeseries/public/convert_to_lens/top_n/index.ts index f4a4ed27b0024..8f93ced2b8a83 100644 --- a/src/plugins/vis_types/timeseries/public/convert_to_lens/top_n/index.ts +++ b/src/plugins/vis_types/timeseries/public/convert_to_lens/top_n/index.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { parseTimeShift } from '@kbn/data-plugin/common'; import { getIndexPatternIds, Layer } from '@kbn/visualizations-plugin/common/convert_to_lens'; import { PANEL_TYPES } from '../../../common/enums'; @@ -83,7 +83,7 @@ export const convertToLens: ConvertTsvbToLensVisualization = async ( throw invalidModelError(); } - const layerId = uuid(); + const layerId = uuidv4(); extendedLayers[layerIdx] = { indexPatternId, layerId, diff --git a/src/plugins/vis_types/timeseries/public/metrics_type.ts b/src/plugins/vis_types/timeseries/public/metrics_type.ts index 43be3ee3004f4..2390894b5d69d 100644 --- a/src/plugins/vis_types/timeseries/public/metrics_type.ts +++ b/src/plugins/vis_types/timeseries/public/metrics_type.ts @@ -7,7 +7,7 @@ */ import { i18n } from '@kbn/i18n'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import type { DataViewsContract, DataView } from '@kbn/data-views-plugin/public'; import { Vis, @@ -108,11 +108,11 @@ export const metricsVisDefinition: VisTypeDefinition< group: VisGroups.PROMOTED, visConfig: { defaults: { - id: () => uuid(), + id: () => uuidv4(), type: PANEL_TYPES.TIMESERIES, series: [ { - id: () => uuid(), + id: () => uuidv4(), color: TSVB_DEFAULT_COLOR, split_mode: 'everything', palette: { @@ -121,7 +121,7 @@ export const metricsVisDefinition: VisTypeDefinition< }, metrics: [ { - id: () => uuid(), + id: () => uuidv4(), type: 'count', }, ], diff --git a/src/plugins/vis_types/xy/public/convert_to_lens/index.ts b/src/plugins/vis_types/xy/public/convert_to_lens/index.ts index 88965cc77f118..da1c50d94672e 100644 --- a/src/plugins/vis_types/xy/public/convert_to_lens/index.ts +++ b/src/plugins/vis_types/xy/public/convert_to_lens/index.ts @@ -161,10 +161,10 @@ export const convertToLens: ConvertXYToLensVisualization = async (vis, timefilte const indexPatternId = dataView.id!; - const uuid = await import('uuid/v4'); + const { v4: uuidv4 } = await import('uuid'); const layers = dataLayers.map((l) => { - const layerId = uuid.default(); + const layerId = uuidv4(); const seriesIdsMap: Record = {}; visibleSeries.forEach((s) => { const column = l.columns.find( @@ -197,7 +197,7 @@ export const convertToLens: ConvertXYToLensVisualization = async (vis, timefilte const staticValueColumn = createStaticValueColumn(vis.params.thresholdLine.value || 0); layers.push({ indexPatternId, - layerId: uuid.default(), + layerId: uuidv4(), columns: [staticValueColumn], columnOrder: [], metrics: [staticValueColumn.columnId], diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/column.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/column.ts index 7fe98b9f7ec65..b5738571b62b6 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/column.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/column.ts @@ -6,7 +6,7 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { DataViewField } from '@kbn/data-views-plugin/common'; import { DataType, FormatParams } from '../../types'; import { SchemaConfig } from '../../../types'; @@ -24,7 +24,7 @@ export const createColumn = ( field?: DataViewField, { isBucketed = false, isSplit = false, reducedTimeRange }: ExtraColumnFields = {} ): GeneralColumnWithMeta => ({ - columnId: uuid(), + columnId: uuidv4(), dataType: (field?.type as DataType) ?? 'number', label: getLabel(agg), isBucketed, diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/date_histogram.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/date_histogram.ts index 5a00ebdd90aa3..d45ae1b174fe0 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/date_histogram.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/date_histogram.ts @@ -8,7 +8,7 @@ import { AggParamsDateHistogram } from '@kbn/data-plugin/common'; import type { DataView } from '@kbn/data-views-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DataType, DateHistogramParams } from '../../types'; import { getFieldNameFromField } from '../utils'; import { DateHistogramColumn } from './types'; @@ -50,7 +50,7 @@ export const convertToDateHistogramColumn = ( const label = getLabel(aggParams, dateFieldName); return { - columnId: uuid(), + columnId: uuidv4(), label, operationType: 'date_histogram', dataType: dateField.type as DataType, diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/filters.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/filters.ts index 416efdc53a72d..9078e61b89d56 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/filters.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/filters.ts @@ -7,7 +7,7 @@ */ import { AggParamsFilters } from '@kbn/data-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FiltersColumn } from './types'; export const convertToFiltersColumn = ( @@ -20,7 +20,7 @@ export const convertToFiltersColumn = ( } return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'filters', dataType: 'string', isBucketed: true, diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/range.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/range.ts index 98200c321935c..6921b4034ba37 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/range.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/range.ts @@ -8,7 +8,7 @@ import { AggParamsRange, AggParamsHistogram } from '@kbn/data-plugin/common'; import type { DataView } from '@kbn/data-views-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { RANGE_MODES } from '../../constants'; import { DataType, RangeParams } from '../../types'; import { getFieldNameFromField } from '../utils'; @@ -63,7 +63,7 @@ export const convertToRangeColumn = ( const params = convertToRangeParams(aggParams); return { - columnId: uuid(), + columnId: uuidv4(), label, operationType: 'range', dataType: field.type as DataType, diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/static_value.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/static_value.ts index 0310e162b8e85..bfb40adbf3852 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/static_value.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/static_value.ts @@ -6,12 +6,12 @@ * Side Public License, v 1. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { StaticValueColumn } from '../../types'; export const createStaticValueColumn = (value: number): StaticValueColumn => ({ operationType: 'static_value', - columnId: uuid(), + columnId: uuidv4(), isBucketed: false, isSplit: false, dataType: 'number', diff --git a/src/plugins/visualizations/common/convert_to_lens/lib/convert/terms.ts b/src/plugins/visualizations/common/convert_to_lens/lib/convert/terms.ts index a54a3857e20f6..06cfe4f18e3bf 100644 --- a/src/plugins/visualizations/common/convert_to_lens/lib/convert/terms.ts +++ b/src/plugins/visualizations/common/convert_to_lens/lib/convert/terms.ts @@ -7,7 +7,7 @@ */ import { BUCKET_TYPES } from '@kbn/data-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DataType, TermsParams } from '../../types'; import { getFieldNameFromField, isColumnWithMeta } from '../utils'; import { convertToSchemaConfig } from '../../../vis_schemas'; @@ -137,7 +137,7 @@ export const convertToTermsColumn = ( } return { - columnId: uuid(), + columnId: uuidv4(), operationType: 'terms', label, dataType: (field.type as DataType) ?? undefined, diff --git a/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx b/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx index 22d3529229fd7..ca8eb372c4fbc 100644 --- a/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx +++ b/src/plugins/visualizations/public/visualize_app/utils/get_top_nav_config.tsx @@ -15,7 +15,6 @@ import { parse } from 'query-string'; import { Capabilities } from '@kbn/core/public'; import { TopNavMenuData } from '@kbn/navigation-plugin/public'; -import { KibanaThemeProvider } from '@kbn/kibana-react-plugin/public'; import { showSaveModal, SavedObjectSaveModalOrigin, @@ -598,18 +597,7 @@ export const getTopNavConfig = ( ); } - const WrapperComponent = ({ children }: { children?: React.ReactNode }) => { - const ContextProvider = !originatingApp - ? presentationUtil.ContextProvider - : React.Fragment; - return ( - - {children} - - ); - }; - - showSaveModal(saveModal, I18nContext, WrapperComponent); + showSaveModal(saveModal, presentationUtil.ContextProvider); }, }, ] diff --git a/src/plugins/visualizations/server/migrations/visualization_common_migrations.ts b/src/plugins/visualizations/server/migrations/visualization_common_migrations.ts index 456a0d18afda7..df6e575e79cc2 100644 --- a/src/plugins/visualizations/server/migrations/visualization_common_migrations.ts +++ b/src/plugins/visualizations/server/migrations/visualization_common_migrations.ts @@ -7,7 +7,7 @@ */ import { get, last } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export const commonAddSupportOfDualIndexSelectionModeInTSVB = (visState: any) => { if (visState && visState.type === 'metrics') { @@ -93,7 +93,7 @@ export const commonAddEmptyValueColorRule = (visState: any) => { const convertRuleToEmpty = (rule: any = {}) => ({ ...rule, - id: uuid.v4(), + id: uuidv4(), operator: 'empty', value: null, }); diff --git a/test/api_integration/apis/guided_onboarding/put_state.ts b/test/api_integration/apis/guided_onboarding/put_state.ts index 80b842a7434a4..1aa800a70c1b6 100644 --- a/test/api_integration/apis/guided_onboarding/put_state.ts +++ b/test/api_integration/apis/guided_onboarding/put_state.ts @@ -16,7 +16,7 @@ import { pluginStateSavedObjectsId, guideStateSavedObjectsType, } from '@kbn/guided-onboarding-plugin/server/saved_objects/guided_setup'; -import { testGuideId } from '@kbn/guided-onboarding-plugin/common'; +import { testGuideId } from '@kbn/guided-onboarding'; import type { FtrProviderContext } from '../../ftr_provider_context'; import { createGuides, createPluginState } from './helpers'; diff --git a/test/api_integration/apis/saved_objects_management/bulk_delete.ts b/test/api_integration/apis/saved_objects_management/bulk_delete.ts new file mode 100644 index 0000000000000..8a9f582823de8 --- /dev/null +++ b/test/api_integration/apis/saved_objects_management/bulk_delete.ts @@ -0,0 +1,82 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import expect from '@kbn/expect'; +import type { Response } from 'supertest'; +import type { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ getService }: FtrProviderContext) { + const supertest = getService('supertest'); + const kibanaServer = getService('kibanaServer'); + + describe('_bulk_delete', () => { + const endpoint = '/internal/kibana/management/saved_objects/_bulk_delete'; + const validObject = { type: 'visualization', id: 'dd7caf20-9efd-11e7-acb3-3dab96693fab' }; + const invalidObject = { type: 'wigwags', id: 'foo' }; + + beforeEach(() => + kibanaServer.importExport.load( + 'test/api_integration/fixtures/kbn_archiver/saved_objects/basic.json' + ) + ); + afterEach(() => + kibanaServer.importExport.unload( + 'test/api_integration/fixtures/kbn_archiver/saved_objects/basic.json' + ) + ); + + function expectSuccess(index: number, { body }: Response) { + const { type, id, error } = body[index]; + expect(type).to.eql(validObject.type); + expect(id).to.eql(validObject.id); + expect(error).to.equal(undefined); + } + + function expectBadRequest(index: number, { body }: Response) { + const { type, id, error } = body[index]; + expect(type).to.eql(invalidObject.type); + expect(id).to.eql(invalidObject.id); + expect(error).to.eql({ + message: `Unsupported saved object type: '${invalidObject.type}': Bad Request`, + statusCode: 400, + error: 'Bad Request', + }); + } + + it('should return 200 for an existing object', async () => + await supertest + .post(endpoint) + .send([validObject]) + .expect(200) + .then((response: Response) => { + expect(response.body).to.have.length(1); + expectSuccess(0, response); + })); + + it('should return error for invalid object type', async () => + await supertest + .post(endpoint) + .send([invalidObject]) + .expect(200) + .then((response: Response) => { + expect(response.body).to.have.length(1); + expectBadRequest(0, response); + })); + + it('should return mix of successes and errors', async () => + await supertest + .post(endpoint) + .send([validObject, invalidObject]) + .expect(200) + .then((response: Response) => { + expect(response.body).to.have.length(2); + expectSuccess(0, response); + expectBadRequest(1, response); + })); + }); +} diff --git a/test/api_integration/apis/saved_objects_management/index.ts b/test/api_integration/apis/saved_objects_management/index.ts index 208ded1d50706..2adf4524a37f7 100644 --- a/test/api_integration/apis/saved_objects_management/index.ts +++ b/test/api_integration/apis/saved_objects_management/index.ts @@ -11,6 +11,7 @@ import { FtrProviderContext } from '../../ftr_provider_context'; export default function ({ loadTestFile }: FtrProviderContext) { describe('saved objects management apis', () => { loadTestFile(require.resolve('./find')); + loadTestFile(require.resolve('./bulk_delete')); loadTestFile(require.resolve('./bulk_get')); loadTestFile(require.resolve('./relationships')); loadTestFile(require.resolve('./scroll_count')); diff --git a/test/functional/apps/dashboard/group3/panel_context_menu.ts b/test/functional/apps/dashboard/group3/panel_context_menu.ts index f78cd27614b3b..4abf860cb17fc 100644 --- a/test/functional/apps/dashboard/group3/panel_context_menu.ts +++ b/test/functional/apps/dashboard/group3/panel_context_menu.ts @@ -41,7 +41,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('are hidden in view mode', async function () { await PageObjects.dashboard.saveDashboard(dashboardName); - await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.expectMissingEditPanelAction(); await dashboardPanelActions.expectMissingRemovePanelAction(); }); @@ -79,6 +78,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { describe('visualization object edit menu', () => { it('opens a visualization when edit link is clicked', async () => { + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.header.waitUntilLoadingHasFinished(); const currentUrl = await browser.getCurrentUrl(); @@ -120,6 +120,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { }); it('opens a saved search when edit link is clicked', async () => { + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.header.waitUntilLoadingHasFinished(); const queryName = await PageObjects.discover.getCurrentQueryName(); @@ -148,6 +149,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { }); before('expand panel to "full screen"', async () => { + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickExpandPanelToggle(); }); diff --git a/test/functional/apps/dashboard_elements/controls/control_group_chaining.ts b/test/functional/apps/dashboard_elements/controls/control_group_chaining.ts index b70404f1338bf..4fc9101ed67a5 100644 --- a/test/functional/apps/dashboard_elements/controls/control_group_chaining.ts +++ b/test/functional/apps/dashboard_elements/controls/control_group_chaining.ts @@ -196,7 +196,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('Creating "does not exist" query from first control filters the second and third controls', async () => { await dashboardControls.optionsListOpenPopover(controlIds[0]); - await dashboardControls.optionsListPopoverSelectOption('exists'); + await dashboardControls.optionsListPopoverSelectExists(); await dashboardControls.optionsListEnsurePopoverIsClosed(controlIds[0]); await dashboard.waitForRenderComplete(); diff --git a/test/functional/apps/dashboard_elements/controls/options_list.ts b/test/functional/apps/dashboard_elements/controls/options_list.ts deleted file mode 100644 index 8186d9702ae3e..0000000000000 --- a/test/functional/apps/dashboard_elements/controls/options_list.ts +++ /dev/null @@ -1,783 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0 and the Server Side Public License, v 1; you may not use this file except - * in compliance with, at your election, the Elastic License 2.0 or the Server - * Side Public License, v 1. - */ - -import { pick } from 'lodash'; - -import { OPTIONS_LIST_CONTROL } from '@kbn/controls-plugin/common'; -import expect from '@kbn/expect'; - -import { OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS } from '../../../page_objects/dashboard_page_controls'; -import { FtrProviderContext } from '../../../ftr_provider_context'; - -export default function ({ getService, getPageObjects }: FtrProviderContext) { - const retry = getService('retry'); - const queryBar = getService('queryBar'); - const pieChart = getService('pieChart'); - const security = getService('security'); - const elasticChart = getService('elasticChart'); - const filterBar = getService('filterBar'); - const testSubjects = getService('testSubjects'); - const dashboardAddPanel = getService('dashboardAddPanel'); - const dashboardPanelActions = getService('dashboardPanelActions'); - - const { dashboardControls, timePicker, console, common, dashboard, header, settings } = - getPageObjects([ - 'dashboardControls', - 'timePicker', - 'dashboard', - 'settings', - 'console', - 'common', - 'header', - ]); - - const DASHBOARD_NAME = 'Test Options List Control'; - - describe('Dashboard options list integration', () => { - let controlId: string; - - const returnToDashboard = async () => { - await common.navigateToApp('dashboard'); - await header.waitUntilLoadingHasFinished(); - await elasticChart.setNewChartUiDebugFlag(); - await dashboard.loadSavedDashboard(DASHBOARD_NAME); - if (await dashboard.getIsInViewMode()) { - await dashboard.switchToEditMode(); - } - await dashboard.waitForRenderComplete(); - }; - - before(async () => { - await security.testUser.setRoles(['kibana_admin', 'test_logstash_reader', 'animals']); - - await common.navigateToApp('dashboard'); - await dashboard.gotoDashboardLandingPage(); - await dashboard.clickNewDashboard(); - await timePicker.setDefaultDataRange(); - await elasticChart.setNewChartUiDebugFlag(); - await dashboard.saveDashboard(DASHBOARD_NAME, { - exitFromEditMode: false, - storeTimeWithDashboard: true, - }); - }); - - describe('Options List Control Editor selects relevant data views', async () => { - it('selects the default data view when the dashboard is blank', async () => { - expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( - 'logstash-*' - ); - }); - - it('selects a relevant data view based on the panels on the dashboard', async () => { - await dashboardAddPanel.addVisualization('Rendering-Test:-animal-sounds-pie'); - await dashboard.waitForRenderComplete(); - expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( - 'animals-*' - ); - await dashboardPanelActions.removePanelByTitle('Rendering Test: animal sounds pie'); - await dashboard.waitForRenderComplete(); - expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( - 'logstash-*' - ); - }); - - it('selects the last used data view by default', async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'animals-*', - fieldName: 'sound.keyword', - }); - expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( - 'animals-*' - ); - await dashboardControls.deleteAllControls(); - }); - }); - - // Skip on cloud until issue is fixed - // Issue: https://github.com/elastic/kibana/issues/141280 - describe('Options List Control creation and editing experience', function () { - this.tags(['skipCloudFailedTest']); - it('can add a new options list control from a blank state', async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'logstash-*', - fieldName: 'machine.os.raw', - }); - expect(await dashboardControls.getControlsCount()).to.be(1); - await dashboard.clearUnsavedChanges(); - }); - - it('can add a second options list control with a non-default data view', async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'animals-*', - fieldName: 'sound.keyword', - }); - expect(await dashboardControls.getControlsCount()).to.be(2); - - // data views should be properly propagated from the control group to the dashboard - expect(await filterBar.getIndexPatterns()).to.be('logstash-*,animals-*'); - await dashboard.clearUnsavedChanges(); - }); - - it('renames an existing control', async () => { - const secondId = (await dashboardControls.getAllControlIds())[1]; - - const newTitle = 'wow! Animal sounds?'; - await dashboardControls.editExistingControl(secondId); - await dashboardControls.controlEditorSetTitle(newTitle); - await dashboardControls.controlEditorSave(); - expect(await dashboardControls.doesControlTitleExist(newTitle)).to.be(true); - await dashboard.clearUnsavedChanges(); - }); - - it('can change the data view and field of an existing options list', async () => { - const firstId = (await dashboardControls.getAllControlIds())[0]; - await dashboardControls.editExistingControl(firstId); - - const saveButton = await testSubjects.find('control-editor-save'); - expect(await saveButton.isEnabled()).to.be(true); - await dashboardControls.controlsEditorSetDataView('animals-*'); - expect(await saveButton.isEnabled()).to.be(false); - await dashboardControls.controlsEditorSetfield('animal.keyword', OPTIONS_LIST_CONTROL); - await dashboardControls.controlEditorSave(); - - // when creating a new filter, the ability to select a data view should be removed, because the dashboard now only has one data view - await retry.try(async () => { - await testSubjects.click('addFilter'); - const indexPatternSelectExists = await testSubjects.exists('filterIndexPatternsSelect'); - await filterBar.ensureFieldEditorModalIsClosed(); - expect(indexPatternSelectExists).to.be(false); - }); - await dashboard.clearUnsavedChanges(); - }); - - it('editing field clears selections', async () => { - const secondId = (await dashboardControls.getAllControlIds())[1]; - await dashboardControls.optionsListOpenPopover(secondId); - await dashboardControls.optionsListPopoverSelectOption('hiss'); - await dashboardControls.optionsListEnsurePopoverIsClosed(secondId); - - await dashboardControls.editExistingControl(secondId); - await dashboardControls.controlsEditorSetfield('animal.keyword', OPTIONS_LIST_CONTROL); - await dashboardControls.controlEditorSave(); - - const selectionString = await dashboardControls.optionsListGetSelectionsString(secondId); - expect(selectionString).to.be('Any'); - }); - - it('editing other control settings keeps selections', async () => { - const secondId = (await dashboardControls.getAllControlIds())[1]; - await dashboardControls.optionsListOpenPopover(secondId); - await dashboardControls.optionsListPopoverSelectOption('dog'); - await dashboardControls.optionsListPopoverSelectOption('cat'); - await dashboardControls.optionsListEnsurePopoverIsClosed(secondId); - - await dashboardControls.editExistingControl(secondId); - await dashboardControls.controlEditorSetTitle('Animal'); - await dashboardControls.controlEditorSetWidth('large'); - await dashboardControls.controlEditorSave(); - - const selectionString = await dashboardControls.optionsListGetSelectionsString(secondId); - expect(selectionString).to.be('dog, cat'); - }); - - it('deletes an existing control', async () => { - const firstId = (await dashboardControls.getAllControlIds())[0]; - - await dashboardControls.removeExistingControl(firstId); - expect(await dashboardControls.getControlsCount()).to.be(1); - await dashboard.clearUnsavedChanges(); - }); - - it('cannot create options list for scripted field', async () => { - await dashboardControls.openCreateControlFlyout(); - expect(await dashboardControls.optionsListEditorGetCurrentDataView(false)).to.eql( - 'animals-*' - ); - await testSubjects.missingOrFail('field-picker-select-isDog'); - await dashboardControls.controlEditorCancel(true); - }); - - after(async () => { - await dashboardControls.clearAllControls(); - }); - }); - - describe('Options List Control suggestions', async () => { - before(async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'animals-*', - fieldName: 'sound.keyword', - }); - controlId = (await dashboardControls.getAllControlIds())[0]; - await dashboard.clickQuickSave(); - await header.waitUntilLoadingHasFinished(); - - await dashboardControls.optionsListOpenPopover(controlId); - }); - - it('sort alphabetically - descending', async () => { - await dashboardControls.optionsListPopoverSetSort({ by: '_key', direction: 'desc' }); - await dashboardControls.optionsListWaitForLoading(controlId); - - const sortedSuggestions = Object.keys(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) - .sort() - .reverse() - .reduce((result, key) => { - return { ...result, [key]: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS[key] }; - }, {}); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { suggestions: sortedSuggestions, invalidSelections: [] }, - true - ); - }); - - it('sort alphabetically - ascending', async () => { - await dashboardControls.optionsListPopoverSetSort({ by: '_key', direction: 'asc' }); - await dashboardControls.optionsListWaitForLoading(controlId); - - const sortedSuggestions = Object.keys(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) - .sort() - .reduce((result, key) => { - return { ...result, [key]: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS[key] }; - }, {}); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { suggestions: sortedSuggestions, invalidSelections: [] }, - true - ); - }); - - it('sort by document count - descending', async () => { - await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'desc' }); - await dashboardControls.optionsListWaitForLoading(controlId); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { - suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, // keys are already sorted descending by doc count - invalidSelections: [], - }, - true - ); - }); - - it('sort by document count - ascending', async () => { - await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'asc' }); - await dashboardControls.optionsListWaitForLoading(controlId); - const sortedSuggestions = Object.entries(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) - .sort(([, docCountA], [, docCountB]) => { - return docCountB - docCountA; - }) - .reduce((result, [key, docCount]) => { - return { ...result, [key]: docCount }; - }, {}); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { suggestions: sortedSuggestions, invalidSelections: [] }, - true - ); - }); - - it('non-default value should cause unsaved changes', async () => { - await testSubjects.existOrFail('dashboardUnsavedChangesBadge'); - }); - - it('returning to default value should remove unsaved changes', async () => { - await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'desc' }); - await dashboardControls.optionsListWaitForLoading(controlId); - await testSubjects.missingOrFail('dashboardUnsavedChangesBadge'); - }); - - after(async () => { - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - }); - - describe('Interactions between options list and dashboard', async () => { - before(async () => { - await dashboardAddPanel.addVisualization('Rendering-Test:-animal-sounds-pie'); - }); - - describe('Applies query settings to controls', async () => { - it('Applies dashboard query to options list control', async () => { - await queryBar.setQuery('animal.keyword : "dog" '); - await queryBar.submitQuery(); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - - const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ - 'ruff', - 'bark', - 'grrr', - 'bow ow ow', - 'grr', - ]); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: { ...suggestions, grr: suggestions.grr - 1 }, - invalidSelections: [], - }); - await queryBar.setQuery(''); - await queryBar.submitQuery(); - - // using the query hides the time range. Clicking anywhere else shows it again. - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - - it('Applies dashboard time range to options list control', async () => { - // set time range to time with no documents - await timePicker.setAbsoluteRange( - 'Jan 1, 2017 @ 00:00:00.000', - 'Jan 1, 2017 @ 00:00:00.000' - ); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - - await dashboardControls.optionsListOpenPopover(controlId); - expect(await dashboardControls.optionsListPopoverGetAvailableOptionsCount()).to.be(0); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await timePicker.setDefaultDataRange(); - }); - - describe('dashboard filters', async () => { - before(async () => { - await filterBar.addFilter({ - field: 'sound.keyword', - operation: 'is one of', - value: ['bark', 'bow ow ow', 'ruff'], - }); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - }); - - it('Applies dashboard filters to options list control', async () => { - const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ - 'ruff', - 'bark', - 'bow ow ow', - ]); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions, - invalidSelections: [], - }); - }); - - it('Does not apply disabled dashboard filters to options list control', async () => { - await filterBar.toggleFilterEnabled('sound.keyword'); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, - invalidSelections: [], - }); - await filterBar.toggleFilterEnabled('sound.keyword'); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - }); - - it('Negated filters apply to options control', async () => { - await filterBar.toggleFilterNegated('sound.keyword'); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - - const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ - 'hiss', - 'grrr', - 'meow', - 'growl', - 'grr', - ]); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions, - invalidSelections: [], - }); - }); - - after(async () => { - await filterBar.removeAllFilters(); - }); - }); - }); - - describe('Selections made in control apply to dashboard', async () => { - it('Shows available options in options list', async () => { - await queryBar.setQuery(''); - await queryBar.submitQuery(); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, - invalidSelections: [], - }); - }); - - it('Can search options list for available options', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSearchForOption('meo'); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { - suggestions: { meow: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow }, - invalidSelections: [], - }, - true - ); - await dashboardControls.optionsListPopoverClearSearch(); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - - it('Can search options list for available options case insensitive', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSearchForOption('MEO'); - await dashboardControls.ensureAvailableOptionsEqual( - controlId, - { - suggestions: { meow: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow }, - invalidSelections: [], - }, - true - ); - await dashboardControls.optionsListPopoverClearSearch(); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - - it('Can select multiple available options', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('hiss'); - await dashboardControls.optionsListPopoverSelectOption('grr'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - - it('Selected options appear in control', async () => { - const selectionString = await dashboardControls.optionsListGetSelectionsString(controlId); - expect(selectionString).to.be('hiss, grr'); - }); - - it('Applies options list control options to dashboard', async () => { - await retry.try(async () => { - expect(await pieChart.getPieSliceCount()).to.be(2); - }); - }); - - it('Applies options list control options to dashboard by default on open', async () => { - await dashboard.gotoDashboardLandingPage(); - await header.waitUntilLoadingHasFinished(); - await dashboard.clickUnsavedChangesContinueEditing(DASHBOARD_NAME); - await header.waitUntilLoadingHasFinished(); - expect(await pieChart.getPieSliceCount()).to.be(2); - - const selectionString = await dashboardControls.optionsListGetSelectionsString(controlId); - expect(selectionString).to.be('hiss, grr'); - }); - - it('excluding selections has expected results', async () => { - await dashboard.clickQuickSave(); - await dashboard.waitForRenderComplete(); - - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSetIncludeSelections(false); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboard.waitForRenderComplete(); - - expect(await pieChart.getPieSliceCount()).to.be(5); - await dashboard.clearUnsavedChanges(); - }); - - it('including selections has expected results', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSetIncludeSelections(true); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboard.waitForRenderComplete(); - - expect(await pieChart.getPieSliceCount()).to.be(2); - await dashboard.clearUnsavedChanges(); - }); - - it('changes to selections can be discarded', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('bark'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - let selections = await dashboardControls.optionsListGetSelectionsString(controlId); - expect(selections).to.equal('hiss, grr, bark'); - - await dashboard.clickCancelOutOfEditMode(); - selections = await dashboardControls.optionsListGetSelectionsString(controlId); - expect(selections).to.equal('hiss, grr'); - }); - - it('dashboard does not load with unsaved changes when changes are discarded', async () => { - await dashboard.switchToEditMode(); - await testSubjects.missingOrFail('dashboardUnsavedChangesBadge'); - }); - }); - - describe('test data view runtime field', async () => { - const FIELD_NAME = 'testRuntimeField'; - const FIELD_VALUES = { - G: - OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.growl + - OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.grr + - OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.grrr, - H: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, - B: - OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.bark + - OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS['bow ow ow'], - R: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.ruff, - M: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow, - }; - - before(async () => { - await common.navigateToApp('settings'); - await settings.clickKibanaIndexPatterns(); - await settings.clickIndexPatternByName('animals-*'); - await settings.addRuntimeField( - FIELD_NAME, - 'keyword', - `emit(doc['sound.keyword'].value.substring(0, 1).toUpperCase())` - ); - await header.waitUntilLoadingHasFinished(); - - await returnToDashboard(); - await dashboardControls.deleteAllControls(); - }); - - it('can create options list control on runtime field', async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - fieldName: FIELD_NAME, - dataViewTitle: 'animals-*', - }); - expect(await dashboardControls.getControlsCount()).to.be(1); - }); - - it('new control has expected suggestions', async () => { - controlId = (await dashboardControls.getAllControlIds())[0]; - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: FIELD_VALUES, - invalidSelections: [], - }); - }); - - it('making selection has expected results', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('B'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboard.waitForRenderComplete(); - - expect(await pieChart.getPieChartLabels()).to.eql(['bark', 'bow ow ow']); - }); - - after(async () => { - await dashboardControls.deleteAllControls(); - await dashboard.clickQuickSave(); - await header.waitUntilLoadingHasFinished(); - - await common.navigateToApp('settings'); - await settings.clickKibanaIndexPatterns(); - await settings.clickIndexPatternByName('animals-*'); - await settings.filterField('testRuntimeField'); - await testSubjects.click('deleteField'); - await settings.confirmDelete(); - }); - }); - - describe('test exists query', async () => { - const newDocuments: Array<{ index: string; id: string }> = []; - - const addDocument = async (index: string, document: string) => { - await console.enterRequest('\nPOST ' + index + '/_doc/ \n{\n ' + document); - await console.clickPlay(); - await header.waitUntilLoadingHasFinished(); - const response = JSON.parse(await console.getResponse()); - newDocuments.push({ index, id: response._id }); - }; - - before(async () => { - await common.navigateToApp('console'); - await console.collapseHelp(); - await console.clearTextArea(); - await addDocument( - 'animals-cats-2018-01-01', - '"@timestamp": "2018-01-01T16:00:00.000Z", \n"name": "Rosie", \n"sound": "hiss"' - ); - await returnToDashboard(); - - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'animals-*', - fieldName: 'animal.keyword', - title: 'Animal', - }); - controlId = (await dashboardControls.getAllControlIds())[0]; - await header.waitUntilLoadingHasFinished(); - await dashboard.waitForRenderComplete(); - }); - - it('creating exists query has expected results', async () => { - expect((await pieChart.getPieChartValues())[0]).to.be(6); - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('exists'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboard.waitForRenderComplete(); - - expect(await pieChart.getPieSliceCount()).to.be(5); - expect((await pieChart.getPieChartValues())[0]).to.be(5); - }); - - it('negating exists query has expected results', async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSetIncludeSelections(false); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboard.waitForRenderComplete(); - - expect(await pieChart.getPieSliceCount()).to.be(1); - expect((await pieChart.getPieChartValues())[0]).to.be(1); - }); - - after(async () => { - await common.navigateToApp('console'); - await console.clearTextArea(); - for (const { index, id } of newDocuments) { - await console.enterRequest(`\nDELETE /${index}/_doc/${id}`); - await console.clickPlay(); - await header.waitUntilLoadingHasFinished(); - } - - await returnToDashboard(); - await dashboardControls.deleteAllControls(); - }); - }); - - describe('Options List dashboard validation', async () => { - before(async () => { - await dashboardControls.createControl({ - controlType: OPTIONS_LIST_CONTROL, - dataViewTitle: 'animals-*', - fieldName: 'sound.keyword', - title: 'Animal Sounds', - }); - controlId = (await dashboardControls.getAllControlIds())[0]; - - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('meow'); - await dashboardControls.optionsListPopoverSelectOption('bark'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - }); - - after(async () => { - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverClearSelections(); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await filterBar.removeAllFilters(); - }); - - it('Can mark selections invalid with Query', async () => { - await queryBar.setQuery('NOT animal.keyword : "dog" '); - await queryBar.submitQuery(); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - - const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ - 'hiss', - 'meow', - 'growl', - 'grr', - ]); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: { ...suggestions, grr: suggestions.grr - 1 }, - invalidSelections: ['bark'], - }); - // only valid selections are applied as filters. - expect(await pieChart.getPieSliceCount()).to.be(1); - }); - - it('can make invalid selections valid again if the parent filter changes', async () => { - await queryBar.setQuery(''); - await queryBar.submitQuery(); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, - invalidSelections: [], - }); - expect(await pieChart.getPieSliceCount()).to.be(2); - }); - - it('Can mark multiple selections invalid with Filter', async () => { - await filterBar.addFilter({ field: 'sound.keyword', operation: 'is', value: 'hiss' }); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: { - hiss: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, - }, - invalidSelections: ['meow', 'bark'], - }); - // only valid selections are applied as filters. - expect(await pieChart.getPieSliceCount()).to.be(1); - }); - }); - - describe('Options List dashboard no validation', async () => { - before(async () => { - await filterBar.removeAllFilters(); - await queryBar.clickQuerySubmitButton(); - await dashboardControls.optionsListOpenPopover(controlId); - await dashboardControls.optionsListPopoverSelectOption('meow'); - await dashboardControls.optionsListPopoverSelectOption('bark'); - await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); - await dashboardControls.updateValidationSetting(false); - }); - - it('Does not mark selections invalid with Query', async () => { - await queryBar.setQuery('NOT animal.keyword : "dog" '); - await queryBar.submitQuery(); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - - const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ - 'hiss', - 'meow', - 'growl', - 'grr', - ]); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: { ...suggestions, grr: suggestions.grr - 1 }, - invalidSelections: [], - }); - }); - - it('Does not mark multiple selections invalid with Filter', async () => { - await filterBar.addFilter({ field: 'sound.keyword', operation: 'is', value: 'hiss' }); - await dashboard.waitForRenderComplete(); - await header.waitUntilLoadingHasFinished(); - await dashboardControls.ensureAvailableOptionsEqual(controlId, { - suggestions: { - hiss: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, - }, - invalidSelections: [], - }); - }); - }); - - after(async () => { - await filterBar.removeAllFilters(); - await queryBar.clickQuerySubmitButton(); - await dashboardControls.clearAllControls(); - }); - }); - - after(async () => { - await security.testUser.restoreDefaults(); - }); - }); -} diff --git a/test/functional/apps/dashboard_elements/controls/options_list/index.ts b/test/functional/apps/dashboard_elements/controls/options_list/index.ts new file mode 100644 index 0000000000000..9d4cb7d18d525 --- /dev/null +++ b/test/functional/apps/dashboard_elements/controls/options_list/index.ts @@ -0,0 +1,50 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { FtrProviderContext } from '../../../../ftr_provider_context'; + +export const OPTIONS_LIST_DASHBOARD_NAME = 'Test Options List Control'; + +export default function ({ loadTestFile, getService, getPageObjects }: FtrProviderContext) { + const elasticChart = getService('elasticChart'); + const security = getService('security'); + + const { timePicker, dashboard } = getPageObjects([ + 'dashboardControls', + 'timePicker', + 'dashboard', + 'common', + ]); + + async function setup() { + await security.testUser.setRoles(['kibana_admin', 'test_logstash_reader', 'animals']); + + await dashboard.gotoDashboardLandingPage(); + await dashboard.clickNewDashboard(); + await timePicker.setDefaultDataRange(); + await elasticChart.setNewChartUiDebugFlag(); + await dashboard.saveDashboard(OPTIONS_LIST_DASHBOARD_NAME, { + exitFromEditMode: false, + storeTimeWithDashboard: true, + }); + } + + async function teardown() { + await security.testUser.restoreDefaults(); + } + + describe('Options list control', function () { + before(setup); + after(teardown); + + loadTestFile(require.resolve('./options_list_creation_and_editing')); + loadTestFile(require.resolve('./options_list_dashboard_interaction')); + loadTestFile(require.resolve('./options_list_suggestions')); + loadTestFile(require.resolve('./options_list_validation')); + }); +} diff --git a/test/functional/apps/dashboard_elements/controls/options_list/options_list_creation_and_editing.ts b/test/functional/apps/dashboard_elements/controls/options_list/options_list_creation_and_editing.ts new file mode 100644 index 0000000000000..2281c5ce112be --- /dev/null +++ b/test/functional/apps/dashboard_elements/controls/options_list/options_list_creation_and_editing.ts @@ -0,0 +1,181 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { OPTIONS_LIST_CONTROL } from '@kbn/controls-plugin/common'; +import expect from '@kbn/expect'; + +import { FtrProviderContext } from '../../../../ftr_provider_context'; + +export default function ({ getService, getPageObjects }: FtrProviderContext) { + const retry = getService('retry'); + const filterBar = getService('filterBar'); + const testSubjects = getService('testSubjects'); + const dashboardAddPanel = getService('dashboardAddPanel'); + const dashboardPanelActions = getService('dashboardPanelActions'); + + const { dashboardControls, dashboard } = getPageObjects([ + 'dashboardControls', + 'timePicker', + 'dashboard', + 'settings', + 'console', + 'common', + 'header', + ]); + + describe('Dashboard options list creation and editing', () => { + before(async () => { + await dashboard.ensureDashboardIsInEditMode(); + }); + + after(async () => { + await dashboardControls.deleteAllControls(); + await dashboard.clickQuickSave(); + }); + + describe('Options List Control Editor selects relevant data views', async () => { + it('selects the default data view when the dashboard is blank', async () => { + expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( + 'logstash-*' + ); + }); + + it('selects a relevant data view based on the panels on the dashboard', async () => { + await dashboardAddPanel.addVisualization('Rendering-Test:-animal-sounds-pie'); + await dashboard.waitForRenderComplete(); + expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( + 'animals-*' + ); + await dashboard.waitForRenderComplete(); + await dashboardPanelActions.removePanelByTitle('Rendering Test: animal sounds pie'); + expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( + 'logstash-*' + ); + }); + + it('selects the last used data view by default', async () => { + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'sound.keyword', + }); + expect(await dashboardControls.optionsListEditorGetCurrentDataView(true)).to.eql( + 'animals-*' + ); + await dashboardControls.deleteAllControls(); + }); + }); + + // Skip on cloud until issue is fixed + // Issue: https://github.com/elastic/kibana/issues/141280 + describe('Options List Control creation and editing experience', function () { + this.tags(['skipCloudFailedTest']); + it('can add a new options list control from a blank state', async () => { + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'logstash-*', + fieldName: 'machine.os.raw', + }); + expect(await dashboardControls.getControlsCount()).to.be(1); + await dashboard.clearUnsavedChanges(); + }); + + it('can add a second options list control with a non-default data view', async () => { + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'sound.keyword', + }); + expect(await dashboardControls.getControlsCount()).to.be(2); + + // data views should be properly propagated from the control group to the dashboard + expect(await filterBar.getIndexPatterns()).to.be('logstash-*,animals-*'); + await dashboard.clearUnsavedChanges(); + }); + + it('renames an existing control', async () => { + const secondId = (await dashboardControls.getAllControlIds())[1]; + + const newTitle = 'wow! Animal sounds?'; + await dashboardControls.editExistingControl(secondId); + await dashboardControls.controlEditorSetTitle(newTitle); + await dashboardControls.controlEditorSave(); + expect(await dashboardControls.doesControlTitleExist(newTitle)).to.be(true); + await dashboard.clearUnsavedChanges(); + }); + + it('can change the data view and field of an existing options list', async () => { + const firstId = (await dashboardControls.getAllControlIds())[0]; + await dashboardControls.editExistingControl(firstId); + + const saveButton = await testSubjects.find('control-editor-save'); + expect(await saveButton.isEnabled()).to.be(true); + await dashboardControls.controlsEditorSetDataView('animals-*'); + expect(await saveButton.isEnabled()).to.be(false); + await dashboardControls.controlsEditorSetfield('animal.keyword', OPTIONS_LIST_CONTROL); + await dashboardControls.controlEditorSave(); + + // when creating a new filter, the ability to select a data view should be removed, because the dashboard now only has one data view + await retry.try(async () => { + await testSubjects.click('addFilter'); + const indexPatternSelectExists = await testSubjects.exists('filterIndexPatternsSelect'); + await filterBar.ensureFieldEditorModalIsClosed(); + expect(indexPatternSelectExists).to.be(false); + }); + await dashboard.clearUnsavedChanges(); + }); + + it('editing field clears selections', async () => { + const secondId = (await dashboardControls.getAllControlIds())[1]; + await dashboardControls.optionsListOpenPopover(secondId); + await dashboardControls.optionsListPopoverSelectOption('hiss'); + await dashboardControls.optionsListEnsurePopoverIsClosed(secondId); + + await dashboardControls.editExistingControl(secondId); + await dashboardControls.controlsEditorSetfield('animal.keyword', OPTIONS_LIST_CONTROL); + await dashboardControls.controlEditorSave(); + + const selectionString = await dashboardControls.optionsListGetSelectionsString(secondId); + expect(selectionString).to.be('Any'); + }); + + it('editing other control settings keeps selections', async () => { + const secondId = (await dashboardControls.getAllControlIds())[1]; + await dashboardControls.optionsListOpenPopover(secondId); + await dashboardControls.optionsListPopoverSelectOption('dog'); + await dashboardControls.optionsListPopoverSelectOption('cat'); + await dashboardControls.optionsListEnsurePopoverIsClosed(secondId); + + await dashboardControls.editExistingControl(secondId); + await dashboardControls.controlEditorSetTitle('Animal'); + await dashboardControls.controlEditorSetWidth('large'); + await dashboardControls.controlEditorSave(); + + const selectionString = await dashboardControls.optionsListGetSelectionsString(secondId); + expect(selectionString).to.be('dog, cat'); + }); + + it('deletes an existing control', async () => { + const firstId = (await dashboardControls.getAllControlIds())[0]; + + await dashboardControls.removeExistingControl(firstId); + expect(await dashboardControls.getControlsCount()).to.be(1); + await dashboard.clearUnsavedChanges(); + }); + + it('cannot create options list for scripted field', async () => { + await dashboardControls.openCreateControlFlyout(); + expect(await dashboardControls.optionsListEditorGetCurrentDataView(false)).to.eql( + 'animals-*' + ); + await testSubjects.missingOrFail('field-picker-select-isDog'); + await dashboardControls.controlEditorCancel(true); + }); + }); + }); +} diff --git a/test/functional/apps/dashboard_elements/controls/options_list/options_list_dashboard_interaction.ts b/test/functional/apps/dashboard_elements/controls/options_list/options_list_dashboard_interaction.ts new file mode 100644 index 0000000000000..43bde4798e3d5 --- /dev/null +++ b/test/functional/apps/dashboard_elements/controls/options_list/options_list_dashboard_interaction.ts @@ -0,0 +1,413 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { pick } from 'lodash'; + +import { OPTIONS_LIST_CONTROL } from '@kbn/controls-plugin/common'; +import expect from '@kbn/expect'; + +import { OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS } from '../../../../page_objects/dashboard_page_controls'; +import { FtrProviderContext } from '../../../../ftr_provider_context'; +import { OPTIONS_LIST_DASHBOARD_NAME } from '.'; + +export default function ({ getService, getPageObjects }: FtrProviderContext) { + const retry = getService('retry'); + const queryBar = getService('queryBar'); + const pieChart = getService('pieChart'); + const elasticChart = getService('elasticChart'); + const filterBar = getService('filterBar'); + const testSubjects = getService('testSubjects'); + const dashboardAddPanel = getService('dashboardAddPanel'); + const dashboardPanelActions = getService('dashboardPanelActions'); + + const { dashboardControls, timePicker, console, common, dashboard, header, settings } = + getPageObjects([ + 'dashboardControls', + 'timePicker', + 'dashboard', + 'settings', + 'console', + 'common', + 'header', + ]); + + describe('Interactions between options list and dashboard', () => { + let controlId: string; + + const returnToDashboard = async () => { + await common.navigateToApp('dashboard'); + await header.waitUntilLoadingHasFinished(); + await elasticChart.setNewChartUiDebugFlag(); + await dashboard.loadSavedDashboard(OPTIONS_LIST_DASHBOARD_NAME); + await dashboard.ensureDashboardIsInEditMode(); + }; + + before(async () => { + await dashboard.ensureDashboardIsInEditMode(); + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'sound.keyword', + }); + controlId = (await dashboardControls.getAllControlIds())[0]; + await dashboardAddPanel.addVisualization('Rendering-Test:-animal-sounds-pie'); + await dashboard.clickQuickSave(); + await header.waitUntilLoadingHasFinished(); + }); + + after(async () => { + await dashboardControls.deleteAllControls(); + await dashboardPanelActions.removePanelByTitle('Rendering Test: animal sounds pie'); + await dashboard.clickQuickSave(); + }); + + describe('Applies query settings to controls', async () => { + it('Applies dashboard query to options list control', async () => { + await queryBar.setQuery('animal.keyword : "dog" '); + await queryBar.submitQuery(); // quicker than clicking the submit button, but hides the time picker + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + + const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ + 'ruff', + 'bark', + 'grrr', + 'bow ow ow', + 'grr', + ]); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: { ...suggestions, grr: suggestions.grr - 1 }, + invalidSelections: [], + }); + await queryBar.setQuery(''); + await queryBar.clickQuerySubmitButton(); // ensures that the time picker is visible for the next test + }); + + it('Applies dashboard time range to options list control', async () => { + // set time range to time with no documents + await timePicker.setAbsoluteRange( + 'Jan 1, 2017 @ 00:00:00.000', + 'Jan 1, 2017 @ 00:00:00.000' + ); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + + await dashboardControls.optionsListOpenPopover(controlId); + expect(await dashboardControls.optionsListPopoverGetAvailableOptionsCount()).to.be(0); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await timePicker.setDefaultDataRange(); + }); + + describe('dashboard filters', async () => { + before(async () => { + await filterBar.addFilter({ + field: 'sound.keyword', + operation: 'is one of', + value: ['bark', 'bow ow ow', 'ruff'], + }); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + }); + + it('Applies dashboard filters to options list control', async () => { + const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ + 'ruff', + 'bark', + 'bow ow ow', + ]); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions, + invalidSelections: [], + }); + }); + + it('Does not apply disabled dashboard filters to options list control', async () => { + await filterBar.toggleFilterEnabled('sound.keyword'); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, + invalidSelections: [], + }); + await filterBar.toggleFilterEnabled('sound.keyword'); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + }); + + it('Negated filters apply to options control', async () => { + await filterBar.toggleFilterNegated('sound.keyword'); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + + const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ + 'hiss', + 'grrr', + 'meow', + 'growl', + 'grr', + ]); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions, + invalidSelections: [], + }); + }); + + after(async () => { + await filterBar.removeAllFilters(); + }); + }); + }); + + describe('Selections made in control apply to dashboard', async () => { + it('Shows available options in options list', async () => { + await queryBar.setQuery(''); + await queryBar.submitQuery(); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, + invalidSelections: [], + }); + }); + + it('Can search options list for available options', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSearchForOption('meo'); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { + suggestions: { meow: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow }, + invalidSelections: [], + }, + true + ); + await dashboardControls.optionsListPopoverClearSearch(); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + }); + + it('Can search options list for available options case insensitive', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSearchForOption('MEO'); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { + suggestions: { meow: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow }, + invalidSelections: [], + }, + true + ); + await dashboardControls.optionsListPopoverClearSearch(); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + }); + + it('Can select multiple available options', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectOption('hiss'); + await dashboardControls.optionsListPopoverSelectOption('grr'); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + }); + + it('Selected options appear in control', async () => { + const selectionString = await dashboardControls.optionsListGetSelectionsString(controlId); + expect(selectionString).to.be('hiss, grr'); + }); + + it('Applies options list control options to dashboard', async () => { + await retry.try(async () => { + expect(await pieChart.getPieSliceCount()).to.be(2); + }); + }); + + it('Applies options list control options to dashboard by default on open', async () => { + await dashboard.gotoDashboardLandingPage(); + await header.waitUntilLoadingHasFinished(); + await dashboard.clickUnsavedChangesContinueEditing(OPTIONS_LIST_DASHBOARD_NAME); + await header.waitUntilLoadingHasFinished(); + expect(await pieChart.getPieSliceCount()).to.be(2); + + const selectionString = await dashboardControls.optionsListGetSelectionsString(controlId); + expect(selectionString).to.be('hiss, grr'); + }); + + it('excluding selections has expected results', async () => { + await dashboard.clickQuickSave(); + await dashboard.waitForRenderComplete(); + + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSetIncludeSelections(false); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboard.waitForRenderComplete(); + + expect(await pieChart.getPieSliceCount()).to.be(5); + await dashboard.clearUnsavedChanges(); + }); + + it('including selections has expected results', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSetIncludeSelections(true); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboard.waitForRenderComplete(); + + expect(await pieChart.getPieSliceCount()).to.be(2); + await dashboard.clearUnsavedChanges(); + }); + + it('changes to selections can be discarded', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectOption('bark'); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + let selections = await dashboardControls.optionsListGetSelectionsString(controlId); + expect(selections).to.equal('hiss, grr, bark'); + + await dashboard.clickCancelOutOfEditMode(); + selections = await dashboardControls.optionsListGetSelectionsString(controlId); + expect(selections).to.equal('hiss, grr'); + }); + + it('dashboard does not load with unsaved changes when changes are discarded', async () => { + await dashboard.switchToEditMode(); + await testSubjects.missingOrFail('dashboardUnsavedChangesBadge'); + }); + }); + + describe('Test data view runtime field', async () => { + const FIELD_NAME = 'testRuntimeField'; + const FIELD_VALUES = { + G: + OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.growl + + OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.grr + + OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.grrr, + H: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, + B: + OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.bark + + OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS['bow ow ow'], + R: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.ruff, + M: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.meow, + }; + + before(async () => { + await common.navigateToApp('settings'); + await settings.clickKibanaIndexPatterns(); + await settings.clickIndexPatternByName('animals-*'); + await settings.addRuntimeField( + FIELD_NAME, + 'keyword', + `emit(doc['sound.keyword'].value.substring(0, 1).toUpperCase())` + ); + await header.waitUntilLoadingHasFinished(); + + await returnToDashboard(); + await dashboardControls.deleteAllControls(); + }); + + it('can create options list control on runtime field', async () => { + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + fieldName: FIELD_NAME, + dataViewTitle: 'animals-*', + }); + expect(await dashboardControls.getControlsCount()).to.be(1); + }); + + it('new control has expected suggestions', async () => { + controlId = (await dashboardControls.getAllControlIds())[0]; + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: FIELD_VALUES, + invalidSelections: [], + }); + }); + + it('making selection has expected results', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectOption('B'); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboard.waitForRenderComplete(); + + expect(await pieChart.getPieChartLabels()).to.eql(['bark', 'bow ow ow']); + }); + + after(async () => { + await dashboardControls.deleteAllControls(); + await dashboard.clickQuickSave(); + await header.waitUntilLoadingHasFinished(); + + await common.navigateToApp('settings'); + await settings.clickKibanaIndexPatterns(); + await settings.clickIndexPatternByName('animals-*'); + await settings.filterField('testRuntimeField'); + await testSubjects.click('deleteField'); + await settings.confirmDelete(); + }); + }); + + describe('Test exists query', async () => { + const newDocuments: Array<{ index: string; id: string }> = []; + + const addDocument = async (index: string, document: string) => { + await console.enterRequest('\nPOST ' + index + '/_doc/ \n{\n ' + document); + await console.clickPlay(); + await header.waitUntilLoadingHasFinished(); + const response = JSON.parse(await console.getResponse()); + newDocuments.push({ index, id: response._id }); + }; + + before(async () => { + await common.navigateToApp('console'); + await console.collapseHelp(); + await console.clearTextArea(); + await addDocument( + 'animals-cats-2018-01-01', + '"@timestamp": "2018-01-01T16:00:00.000Z", \n"name": "Rosie", \n"sound": "hiss"' + ); + await returnToDashboard(); + + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'animal.keyword', + title: 'Animal', + }); + controlId = (await dashboardControls.getAllControlIds())[0]; + await header.waitUntilLoadingHasFinished(); + await dashboard.waitForRenderComplete(); + }); + + it('creating exists query has expected results', async () => { + expect((await pieChart.getPieChartValues())[0]).to.be(6); + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectExists(); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboard.waitForRenderComplete(); + + expect(await pieChart.getPieSliceCount()).to.be(5); + expect((await pieChart.getPieChartValues())[0]).to.be(5); + }); + + it('negating exists query has expected results', async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSetIncludeSelections(false); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboard.waitForRenderComplete(); + + expect(await pieChart.getPieSliceCount()).to.be(1); + expect((await pieChart.getPieChartValues())[0]).to.be(1); + }); + + after(async () => { + await common.navigateToApp('console'); + await console.clearTextArea(); + for (const { index, id } of newDocuments) { + await console.enterRequest(`\nDELETE /${index}/_doc/${id}`); + await console.clickPlay(); + await header.waitUntilLoadingHasFinished(); + } + await returnToDashboard(); + }); + }); + }); +} diff --git a/test/functional/apps/dashboard_elements/controls/options_list/options_list_suggestions.ts b/test/functional/apps/dashboard_elements/controls/options_list/options_list_suggestions.ts new file mode 100644 index 0000000000000..6c69dc99bc4d3 --- /dev/null +++ b/test/functional/apps/dashboard_elements/controls/options_list/options_list_suggestions.ts @@ -0,0 +1,116 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { OPTIONS_LIST_CONTROL } from '@kbn/controls-plugin/common'; + +import { OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS } from '../../../../page_objects/dashboard_page_controls'; +import { FtrProviderContext } from '../../../../ftr_provider_context'; + +export default function ({ getService, getPageObjects }: FtrProviderContext) { + const testSubjects = getService('testSubjects'); + + const { dashboardControls, dashboard, header } = getPageObjects([ + 'dashboardControls', + 'timePicker', + 'dashboard', + 'settings', + 'console', + 'common', + 'header', + ]); + + describe('Dashboard options list suggestions', () => { + let controlId: string; + + before(async () => { + await dashboard.ensureDashboardIsInEditMode(); + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'sound.keyword', + }); + controlId = (await dashboardControls.getAllControlIds())[0]; + await dashboard.clickQuickSave(); + await header.waitUntilLoadingHasFinished(); + + await dashboardControls.optionsListOpenPopover(controlId); + }); + + after(async () => { + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboardControls.deleteAllControls(); + await dashboard.clickQuickSave(); + }); + + it('sort alphabetically - descending', async () => { + await dashboardControls.optionsListPopoverSetSort({ by: '_key', direction: 'desc' }); + const sortedSuggestions = Object.keys(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) + .sort() + .reverse() + .reduce((result, key) => { + return { ...result, [key]: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS[key] }; + }, {}); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { suggestions: sortedSuggestions, invalidSelections: [] }, + true + ); + }); + + it('sort alphabetically - ascending', async () => { + await dashboardControls.optionsListPopoverSetSort({ by: '_key', direction: 'asc' }); + const sortedSuggestions = Object.keys(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) + .sort() + .reduce((result, key) => { + return { ...result, [key]: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS[key] }; + }, {}); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { suggestions: sortedSuggestions, invalidSelections: [] }, + true + ); + }); + + it('sort by document count - descending', async () => { + await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'desc' }); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { + suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, // keys are already sorted descending by doc count + invalidSelections: [], + }, + true + ); + }); + + it('sort by document count - ascending', async () => { + await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'asc' }); + const sortedSuggestions = Object.entries(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS) + .sort(([, docCountA], [, docCountB]) => { + return docCountB - docCountA; + }) + .reduce((result, [key, docCount]) => { + return { ...result, [key]: docCount }; + }, {}); + await dashboardControls.ensureAvailableOptionsEqual( + controlId, + { suggestions: sortedSuggestions, invalidSelections: [] }, + true + ); + }); + + it('non-default sort value should cause unsaved changes', async () => { + await testSubjects.existOrFail('dashboardUnsavedChangesBadge'); + }); + + it('returning to default sort value should remove unsaved changes', async () => { + await dashboardControls.optionsListPopoverSetSort({ by: '_count', direction: 'desc' }); + await testSubjects.missingOrFail('dashboardUnsavedChangesBadge'); + }); + }); +} diff --git a/test/functional/apps/dashboard_elements/controls/options_list/options_list_validation.ts b/test/functional/apps/dashboard_elements/controls/options_list/options_list_validation.ts new file mode 100644 index 0000000000000..f48bc5d9e4c42 --- /dev/null +++ b/test/functional/apps/dashboard_elements/controls/options_list/options_list_validation.ts @@ -0,0 +1,161 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +import { pick } from 'lodash'; + +import expect from '@kbn/expect'; +import { OPTIONS_LIST_CONTROL } from '@kbn/controls-plugin/common'; + +import { FtrProviderContext } from '../../../../ftr_provider_context'; +import { OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS } from '../../../../page_objects/dashboard_page_controls'; + +export default function ({ getService, getPageObjects }: FtrProviderContext) { + const queryBar = getService('queryBar'); + const pieChart = getService('pieChart'); + const filterBar = getService('filterBar'); + const dashboardAddPanel = getService('dashboardAddPanel'); + const dashboardPanelActions = getService('dashboardPanelActions'); + + const { dashboardControls, dashboard, header } = getPageObjects([ + 'dashboardControls', + 'timePicker', + 'dashboard', + 'settings', + 'console', + 'common', + 'header', + ]); + + describe('Dashboard options list validation', () => { + let controlId: string; + + before(async () => { + await dashboard.ensureDashboardIsInEditMode(); + await dashboardControls.createControl({ + controlType: OPTIONS_LIST_CONTROL, + dataViewTitle: 'animals-*', + fieldName: 'sound.keyword', + title: 'Animal Sounds', + }); + controlId = (await dashboardControls.getAllControlIds())[0]; + await dashboardAddPanel.addVisualization('Rendering-Test:-animal-sounds-pie'); + await dashboard.clickQuickSave(); + await header.waitUntilLoadingHasFinished(); + }); + + after(async () => { + await filterBar.removeAllFilters(); + await dashboardControls.deleteAllControls(); + await dashboardPanelActions.removePanelByTitle('Rendering Test: animal sounds pie'); + await dashboard.clickQuickSave(); + }); + + describe('Options List dashboard validation', async () => { + before(async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectOption('meow'); + await dashboardControls.optionsListPopoverSelectOption('bark'); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + }); + + after(async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverClearSelections(); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await filterBar.removeAllFilters(); + await queryBar.clickQuerySubmitButton(); + }); + + it('Can mark selections invalid with Query', async () => { + await queryBar.setQuery('NOT animal.keyword : "dog" '); + await queryBar.submitQuery(); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + + const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ + 'hiss', + 'meow', + 'growl', + 'grr', + ]); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: { ...suggestions, grr: suggestions.grr - 1 }, + invalidSelections: ['bark'], + }); + // only valid selections are applied as filters. + expect(await pieChart.getPieSliceCount()).to.be(1); + }); + + it('can make invalid selections valid again if the parent filter changes', async () => { + await queryBar.setQuery(''); + await queryBar.submitQuery(); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, + invalidSelections: [], + }); + expect(await pieChart.getPieSliceCount()).to.be(2); + }); + + it('Can mark multiple selections invalid with Filter', async () => { + await filterBar.addFilter({ field: 'sound.keyword', operation: 'is', value: 'hiss' }); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: { + hiss: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, + }, + invalidSelections: ['meow', 'bark'], + }); + // only valid selections are applied as filters. + expect(await pieChart.getPieSliceCount()).to.be(1); + }); + }); + + describe('Options List dashboard no validation', async () => { + before(async () => { + await dashboardControls.optionsListOpenPopover(controlId); + await dashboardControls.optionsListPopoverSelectOption('meow'); + await dashboardControls.optionsListPopoverSelectOption('bark'); + await dashboardControls.optionsListEnsurePopoverIsClosed(controlId); + await dashboardControls.updateValidationSetting(false); + }); + + it('Does not mark selections invalid with Query', async () => { + await queryBar.setQuery('NOT animal.keyword : "dog" '); + await queryBar.submitQuery(); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + + const suggestions = pick(OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS, [ + 'hiss', + 'meow', + 'growl', + 'grr', + ]); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: { ...suggestions, grr: suggestions.grr - 1 }, + invalidSelections: [], + }); + }); + + it('Does not mark multiple selections invalid with Filter', async () => { + await filterBar.addFilter({ field: 'sound.keyword', operation: 'is', value: 'hiss' }); + await dashboard.waitForRenderComplete(); + await header.waitUntilLoadingHasFinished(); + await dashboardControls.ensureAvailableOptionsEqual(controlId, { + suggestions: { + hiss: OPTIONS_LIST_ANIMAL_SOUND_SUGGESTIONS.hiss, + }, + invalidSelections: [], + }); + }); + }); + }); +} diff --git a/test/functional/apps/discover/group1/_discover_histogram.ts b/test/functional/apps/discover/group1/_discover_histogram.ts index 70a1fba5afafc..e451eee881335 100644 --- a/test/functional/apps/discover/group1/_discover_histogram.ts +++ b/test/functional/apps/discover/group1/_discover_histogram.ts @@ -30,6 +30,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { before(async () => { await esArchiver.loadIfNeeded('test/functional/fixtures/es_archiver/logstash_functional'); await esArchiver.load('test/functional/fixtures/es_archiver/long_window_logstash'); + await kibanaServer.importExport.load('test/functional/fixtures/kbn_archiver/discover'); await kibanaServer.importExport.load( 'test/functional/fixtures/kbn_archiver/long_window_logstash_index_pattern' ); @@ -96,6 +97,20 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { }); }); + it('should update correctly when switching data views and brushing the histogram', async () => { + await PageObjects.common.navigateToApp('discover'); + await PageObjects.discover.waitUntilSearchingHasFinished(); + await PageObjects.timePicker.setDefaultAbsoluteRange(); + await PageObjects.discover.waitUntilSearchingHasFinished(); + await PageObjects.discover.selectIndexPattern('logstash-*'); + await PageObjects.discover.waitUntilSearchingHasFinished(); + await PageObjects.discover.selectIndexPattern('long-window-logstash-*'); + await PageObjects.discover.waitUntilSearchingHasFinished(); + await PageObjects.discover.brushHistogram(); + await PageObjects.discover.waitUntilSearchingHasFinished(); + expect(await PageObjects.discover.getHitCount()).to.be('7'); + }); + it('should update the histogram timerange when the query is resubmitted', async function () { await kibanaServer.uiSettings.update({ 'timepicker:timeDefaults': '{ "from": "2015-09-18T19:37:13.000Z", "to": "now"}', diff --git a/test/functional/page_objects/dashboard_page.ts b/test/functional/page_objects/dashboard_page.ts index 0f5a6d41e6fe0..1f9656c9ff548 100644 --- a/test/functional/page_objects/dashboard_page.ts +++ b/test/functional/page_objects/dashboard_page.ts @@ -281,6 +281,13 @@ export class DashboardPageObject extends FtrService { return await this.testSubjects.exists('dashboardEditMode'); } + public async ensureDashboardIsInEditMode() { + if (await this.getIsInViewMode()) { + await this.switchToEditMode(); + } + await this.waitForRenderComplete(); + } + public async clickCancelOutOfEditMode(accept = true) { this.log.debug('clickCancelOutOfEditMode'); if (await this.getIsInViewMode()) return; diff --git a/test/functional/page_objects/dashboard_page_controls.ts b/test/functional/page_objects/dashboard_page_controls.ts index cdb48b067aec5..85908bce3d35c 100644 --- a/test/functional/page_objects/dashboard_page_controls.ts +++ b/test/functional/page_objects/dashboard_page_controls.ts @@ -14,8 +14,8 @@ import { } from '@kbn/controls-plugin/common'; import { ControlGroupChainingSystem } from '@kbn/controls-plugin/common/control_group/types'; import { OptionsListSortingType } from '@kbn/controls-plugin/common/options_list/suggestions_sorting'; -import { WebElementWrapper } from '../services/lib/web_element_wrapper'; +import { WebElementWrapper } from '../services/lib/web_element_wrapper'; import { FtrService } from '../ftr_provider_context'; const CONTROL_DISPLAY_NAMES: { [key: string]: string } = { @@ -48,6 +48,7 @@ export class DashboardPageControls extends FtrService { private readonly log = this.ctx.getService('log'); private readonly find = this.ctx.getService('find'); private readonly retry = this.ctx.getService('retry'); + private readonly browser = this.ctx.getService('browser'); private readonly testSubjects = this.ctx.getService('testSubjects'); private readonly common = this.ctx.getPageObject('common'); @@ -354,6 +355,7 @@ export class DashboardPageControls extends FtrService { public async optionsListGetSelectionsString(controlId: string) { this.log.debug(`Getting selections string for Options List: ${controlId}`); + await this.optionsListWaitForLoading(controlId); const controlElement = await this.getControlElementById(controlId); return (await controlElement.getVisibleText()).split('\n')[1]; } @@ -362,7 +364,7 @@ export class DashboardPageControls extends FtrService { this.log.debug(`Opening popover for Options List: ${controlId}`); await this.testSubjects.click(`optionsList-control-${controlId}`); await this.retry.try(async () => { - await this.testSubjects.existOrFail(`optionsList-control-available-options`); + await this.testSubjects.existOrFail(`optionsList-control-popover`); }); } @@ -382,25 +384,27 @@ export class DashboardPageControls extends FtrService { public async optionsListPopoverGetAvailableOptionsCount() { this.log.debug(`getting available options count from options list`); + await this.optionsListPopoverWaitForLoading(); const availableOptions = await this.testSubjects.find(`optionsList-control-available-options`); return +(await availableOptions.getAttribute('data-option-count')); } public async optionsListPopoverGetAvailableOptions() { this.log.debug(`getting available options from options list`); + await this.optionsListPopoverWaitForLoading(); const availableOptions = await this.testSubjects.find(`optionsList-control-available-options`); - - const suggestionElements = await availableOptions.findAllByClassName( - 'optionsList__validSuggestion' - ); - const suggestions: { [key: string]: number } = await suggestionElements.reduce( - async (promise, option) => { - const acc = await promise; - const [key, docCount] = (await option.getVisibleText()).split('\n'); - return { ...acc, [key]: Number(docCount) }; - }, - Promise.resolve({} as { [key: string]: number }) - ); + const optionsCount = await this.optionsListPopoverGetAvailableOptionsCount(); + + const selectableListItems = await availableOptions.findByClassName('euiSelectableList__list'); + const suggestions: { [key: string]: number } = {}; + while (Object.keys(suggestions).length < optionsCount) { + await selectableListItems._webElement.sendKeys(this.browser.keys.ARROW_DOWN); + const currentOption = await selectableListItems.findByCssSelector('[aria-selected="true"]'); + const [suggestion, docCount] = (await currentOption.getVisibleText()).split('\n'); + if (suggestion !== 'Exists') { + suggestions[suggestion] = Number(docCount); + } + } const invalidSelectionElements = await availableOptions.findAllByClassName( 'optionsList__selectionInvalid' @@ -419,6 +423,7 @@ export class DashboardPageControls extends FtrService { expectation: { suggestions: { [key: string]: number }; invalidSelections: string[] }, skipOpen?: boolean ) { + await this.optionsListWaitForLoading(controlId); if (!skipOpen) await this.optionsListOpenPopover(controlId); await this.retry.try(async () => { expect(await this.optionsListPopoverGetAvailableOptions()).to.eql(expectation); @@ -456,10 +461,25 @@ export class DashboardPageControls extends FtrService { }); } + public async optionsListPopoverSelectExists() { + await this.retry.try(async () => { + await this.testSubjects.existOrFail(`optionsList-control-selection-exists`); + await this.testSubjects.click(`optionsList-control-selection-exists`); + }); + } + public async optionsListPopoverSelectOption(availableOption: string) { this.log.debug(`selecting ${availableOption} from options list`); - await this.optionsListPopoverAssertOpen(); - await this.testSubjects.click(`optionsList-control-selection-${availableOption}`); + await this.optionsListPopoverSearchForOption(availableOption); + await this.optionsListPopoverWaitForLoading(); + + await this.retry.try(async () => { + await this.testSubjects.existOrFail(`optionsList-control-selection-${availableOption}`); + await this.testSubjects.click(`optionsList-control-selection-${availableOption}`); + }); + + await this.optionsListPopoverClearSearch(); + await this.optionsListPopoverWaitForLoading(); } public async optionsListPopoverClearSelections() { @@ -482,9 +502,16 @@ export class DashboardPageControls extends FtrService { } public async optionsListWaitForLoading(controlId: string) { + this.log.debug(`wait for ${controlId} to load`); await this.testSubjects.waitForEnabled(`optionsList-control-${controlId}`); } + public async optionsListPopoverWaitForLoading() { + this.log.debug(`wait for the suggestions in the popover to load`); + await this.optionsListPopoverAssertOpen(); + await this.testSubjects.waitForDeleted('optionsList-control-popover-loading'); + } + /* ----------------------------------------------------------- Control editor flyout ----------------------------------------------------------- */ diff --git a/test/functional/services/common/browser.ts b/test/functional/services/common/browser.ts index cfca7391202e5..9de8ba0d569f0 100644 --- a/test/functional/services/common/browser.ts +++ b/test/functional/services/common/browser.ts @@ -461,6 +461,14 @@ class BrowserService extends FtrService { await this.driver.switchTo().window(tabs[tabIndex]); } + /** + * Opens a blank new tab. + * @return {Promise} + */ + public async openNewTab() { + await this.driver.switchTo().newWindow('tab'); + } + /** * Sets a value in local storage for the focused window/frame. * diff --git a/test/functional/services/dashboard/panel_actions.ts b/test/functional/services/dashboard/panel_actions.ts index 74bf34d3f364b..d3d9338c4f1a2 100644 --- a/test/functional/services/dashboard/panel_actions.ts +++ b/test/functional/services/dashboard/panel_actions.ts @@ -42,19 +42,19 @@ export class DashboardPanelActionsService extends FtrService { } async toggleContextMenu(parent?: WebElementWrapper) { - this.log.debug('toggleContextMenu'); + this.log.debug(`toggleContextMenu(${parent})`); await (parent ? parent.moveMouseTo() : this.testSubjects.moveMouseTo('dashboardPanelTitle')); const toggleMenuItem = await this.findContextMenu(parent); await toggleMenuItem.click(); } async expectContextMenuToBeOpen() { + this.log.debug('expectContextMenuToBeOpen'); await this.testSubjects.existOrFail('embeddablePanelContextMenuOpen'); } async openContextMenu(parent?: WebElementWrapper) { this.log.debug(`openContextMenu(${parent}`); - if (await this.testSubjects.exists('embeddablePanelContextMenuOpen')) return; await this.toggleContextMenu(parent); await this.expectContextMenuToBeOpen(); } @@ -64,7 +64,9 @@ export class DashboardPanelActionsService extends FtrService { } async clickContextMenuMoreItem() { - const hasMoreSubPanel = await this.testSubjects.exists('embeddablePanelMore-mainMenu'); + this.log.debug('clickContextMenuMoreItem'); + await this.expectContextMenuToBeOpen(); + const hasMoreSubPanel = await this.hasContextMenuMoreItem(); if (hasMoreSubPanel) { await this.testSubjects.click('embeddablePanelMore-mainMenu'); } @@ -77,7 +79,7 @@ export class DashboardPanelActionsService extends FtrService { async clickEdit() { this.log.debug('clickEdit'); - await this.openContextMenu(); + await this.expectContextMenuToBeOpen(); const isActionVisible = await this.testSubjects.exists(EDIT_PANEL_DATA_TEST_SUBJ); if (!isActionVisible) await this.clickContextMenuMoreItem(); await this.testSubjects.clickWhenNotDisabledWithoutRetry(EDIT_PANEL_DATA_TEST_SUBJ); @@ -98,7 +100,7 @@ export class DashboardPanelActionsService extends FtrService { async clickExpandPanelToggle() { this.log.debug(`clickExpandPanelToggle`); - await this.openContextMenu(); + await this.expectContextMenuToBeOpen(); const isActionVisible = await this.testSubjects.exists(TOGGLE_EXPAND_PANEL_DATA_TEST_SUBJ); if (!isActionVisible) await this.clickContextMenuMoreItem(); await this.testSubjects.click(TOGGLE_EXPAND_PANEL_DATA_TEST_SUBJ); @@ -342,7 +344,6 @@ export class DashboardPanelActionsService extends FtrService { await this.customizePanel(panel); await this.testSubjects.click('resetCustomEmbeddablePanelTitle'); await this.testSubjects.click('saveNewTitleButton'); - await this.toggleContextMenu(panel); } async getActionWebElementByText(text: string): Promise { diff --git a/test/functional/services/flyout.ts b/test/functional/services/flyout.ts index e7b57dc0fb66b..819fa7b480bc4 100644 --- a/test/functional/services/flyout.ts +++ b/test/functional/services/flyout.ts @@ -17,12 +17,11 @@ export class FlyoutService extends FtrService { public async close(dataTestSubj: string): Promise { this.log.debug('Closing flyout', dataTestSubj); const flyoutElement = await this.testSubjects.find(dataTestSubj); - const closeBtn = await flyoutElement.findByCssSelector('[aria-label*="Close"]'); - await closeBtn.click(); - await this.retry.waitFor( - 'flyout closed', - async () => !(await this.testSubjects.exists(dataTestSubj, { timeout: 1000 })) - ); + await this.retry.try(async () => { + const closeBtn = await flyoutElement.findByCssSelector('[aria-label*="Close"]'); + await closeBtn.click(); + await this.testSubjects.missingOrFail(dataTestSubj); + }); } public async ensureClosed(dataTestSubj: string): Promise { diff --git a/test/functional/services/lib/web_element_wrapper/web_element_wrapper.ts b/test/functional/services/lib/web_element_wrapper/web_element_wrapper.ts index 144b625121f7e..319a3b8b4ce03 100644 --- a/test/functional/services/lib/web_element_wrapper/web_element_wrapper.ts +++ b/test/functional/services/lib/web_element_wrapper/web_element_wrapper.ts @@ -466,6 +466,7 @@ export class WebElementWrapper { * @return {Promise} */ public async findByCssSelector(selector: string) { + this.logger.debug(`WebElementWrapper.findByCssSelector(${selector})`); return await this.retryCall(async function findByCssSelector(wrapper) { return wrapper._wrap( await wrapper._webElement.findElement(wrapper.By.css(selector)), diff --git a/test/plugin_functional/test_suites/core_plugins/rendering.ts b/test/plugin_functional/test_suites/core_plugins/rendering.ts index 5c51d00f5afd1..a13d19e5246eb 100644 --- a/test/plugin_functional/test_suites/core_plugins/rendering.ts +++ b/test/plugin_functional/test_suites/core_plugins/rendering.ts @@ -218,6 +218,7 @@ export default function ({ getService }: PluginFunctionalProviderContext) { 'xpack.security.sameSiteCookies (alternatives)', 'xpack.security.showInsecureClusterWarning (boolean)', 'xpack.securitySolution.enableExperimental (array)', + 'xpack.securitySolution.prebuiltRulesPackageVersion (string)', 'xpack.snapshot_restore.slm_ui.enabled (boolean)', 'xpack.snapshot_restore.ui.enabled (boolean)', 'xpack.trigger_actions_ui.enableExperimental (array)', diff --git a/test/scripts/jenkins_storybook.sh b/test/scripts/jenkins_storybook.sh index 1c6faa93d01d1..17460c4e08012 100755 --- a/test/scripts/jenkins_storybook.sh +++ b/test/scripts/jenkins_storybook.sh @@ -6,6 +6,7 @@ cd "$KIBANA_DIR" yarn storybook --site apm yarn storybook --site canvas +yarn storybook --site cell_actions yarn storybook --site ci_composite yarn storybook --site content_management yarn storybook --site custom_integrations diff --git a/tsconfig.base.json b/tsconfig.base.json index 8b2aed59945cf..a53ee3a4f73ed 100644 --- a/tsconfig.base.json +++ b/tsconfig.base.json @@ -92,6 +92,8 @@ "@kbn/cases-fixture-plugin/*": ["x-pack/test/functional_with_es_ssl/plugins/cases/*"], "@kbn/cases-plugin": ["x-pack/plugins/cases"], "@kbn/cases-plugin/*": ["x-pack/plugins/cases/*"], + "@kbn/cell-actions": ["packages/kbn-cell-actions"], + "@kbn/cell-actions/*": ["packages/kbn-cell-actions/*"], "@kbn/chart-expressions-common": ["src/plugins/chart_expressions/common"], "@kbn/chart-expressions-common/*": ["src/plugins/chart_expressions/common/*"], "@kbn/chart-icons": ["packages/kbn-chart-icons"], @@ -1216,6 +1218,8 @@ "@kbn/ts-type-check-cli/*": ["packages/kbn-ts-type-check-cli/*"], "@kbn/typed-react-router-config": ["packages/kbn-typed-react-router-config"], "@kbn/typed-react-router-config/*": ["packages/kbn-typed-react-router-config/*"], + "@kbn/ui-actions-browser": ["packages/kbn-ui-actions-browser"], + "@kbn/ui-actions-browser/*": ["packages/kbn-ui-actions-browser/*"], "@kbn/ui-actions-enhanced-examples-plugin": ["x-pack/examples/ui_actions_enhanced_examples"], "@kbn/ui-actions-enhanced-examples-plugin/*": ["x-pack/examples/ui_actions_enhanced_examples/*"], "@kbn/ui-actions-enhanced-plugin": ["src/plugins/ui_actions_enhanced"], diff --git a/x-pack/examples/alerting_example/server/alert_types/always_firing.ts b/x-pack/examples/alerting_example/server/alert_types/always_firing.ts index 9735a640720f0..9b653fc08576e 100644 --- a/x-pack/examples/alerting_example/server/alert_types/always_firing.ts +++ b/x-pack/examples/alerting_example/server/alert_types/always_firing.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { range } from 'lodash'; import { RuleType } from '@kbn/alerting-plugin/server'; import { @@ -63,7 +63,7 @@ export const alertType: RuleType< const count = (state.count ?? 0) + 1; range(instances) - .map(() => uuid.v4()) + .map(() => uuidv4()) .forEach((id: string) => { services.alertFactory .create(id) diff --git a/x-pack/performance/journeys/dashboard_listing_page.ts b/x-pack/performance/journeys/dashboard_listing_page.ts index 0c528ac7c4559..d3fdd63dd55d8 100644 --- a/x-pack/performance/journeys/dashboard_listing_page.ts +++ b/x-pack/performance/journeys/dashboard_listing_page.ts @@ -6,6 +6,7 @@ */ import { Journey } from '@kbn/journeys'; +import { v4 as uuidv4 } from 'uuid'; export const journey = new Journey({ esArchives: ['x-pack/performance/es_archives/sample_data_flights'], @@ -18,15 +19,28 @@ export const journey = new Journey({ await page.goto(kbnUrl.get(`/app/dashboards`)); await page.waitForSelector(`[data-test-subj="table-is-ready"]`); }) - .step('Search dashboards page', async ({ page, inputDelays }) => { + .step('Search dashboards', async ({ page, inputDelays }) => { await page.type('[data-test-subj="tableListSearchBox"]', 'Web', { delay: inputDelays.TYPING, }); await page.waitForSelector(`[data-test-subj="table-is-ready"]`); }) - .step('Delete dashboard', async ({ page, log }) => { + .step('Delete dashboard', async ({ page }) => { await page.click('[data-test-subj="checkboxSelectRow-edf84fe0-e1a0-11e7-b6d5-4dc382ef7f5b"]'); await page.click('[data-test-subj="deleteSelectedItems"]'); await page.click('[data-test-subj="confirmModalConfirmButton"]'); await page.waitForSelector(`[data-test-subj="table-is-ready"]`); + }) + .step('Add dashboard', async ({ page, inputDelays }) => { + await page.click('[data-test-subj="newItemButton"]'); + await page.click('[data-test-subj="dashboardSaveMenuItem"]'); + await page.type('[data-test-subj="savedObjectTitle"]', `foobar dashboard ${uuidv4()}`, { + delay: inputDelays.TYPING, + }); + await page.click('[data-test-subj="confirmSaveSavedObjectButton"]'); + await page.locator('[data-test-subj="saveDashboardSuccess"]'); + }) + .step('Return to dashboard list', async ({ page }) => { + await page.click('[data-test-subj="breadcrumb dashboardListingBreadcrumb first"]'); + await page.waitForSelector(`[data-test-subj="table-is-ready"]`); }); diff --git a/x-pack/performance/journeys/ecommerce_dashboard_saved_search_only.ts b/x-pack/performance/journeys/ecommerce_dashboard_saved_search_only.ts index fc32c62ce6bae..c63f239c5a491 100644 --- a/x-pack/performance/journeys/ecommerce_dashboard_saved_search_only.ts +++ b/x-pack/performance/journeys/ecommerce_dashboard_saved_search_only.ts @@ -10,8 +10,6 @@ import { subj } from '@kbn/test-subj-selector'; import { waitForVisualizations } from '../utils'; export const journey = new Journey({ - // FAILING: https://github.com/elastic/kibana/issues/148221 - skipped: true, esArchives: ['x-pack/performance/es_archives/sample_data_ecommerce'], kbnArchives: ['x-pack/performance/kbn_archives/ecommerce_saved_search_only_dashboard'], }) diff --git a/x-pack/plugins/actions/docs/openapi/bundled.json b/x-pack/plugins/actions/docs/openapi/bundled.json index 85c2d1ec66a55..0919fea40668b 100644 --- a/x-pack/plugins/actions/docs/openapi/bundled.json +++ b/x-pack/plugins/actions/docs/openapi/bundled.json @@ -25,6 +25,146 @@ } ], "paths": { + "/s/{spaceId}/api/actions/connector": { + "post": { + "summary": "Creates a connector.", + "operationId": "createConnector", + "description": "You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges.\n", + "tags": [ + "connectors" + ], + "parameters": [ + { + "$ref": "#/components/parameters/kbn_xsrf" + }, + { + "$ref": "#/components/parameters/space_id" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "title": "Create connector request body properties", + "description": "The properties vary depending on the connector type.", + "oneOf": [ + { + "$ref": "#/components/schemas/create_connector_request_cases_webhook" + }, + { + "$ref": "#/components/schemas/create_connector_request_email" + }, + { + "$ref": "#/components/schemas/create_connector_request_index" + }, + { + "$ref": "#/components/schemas/create_connector_request_jira" + }, + { + "$ref": "#/components/schemas/create_connector_request_opsgenie" + }, + { + "$ref": "#/components/schemas/create_connector_request_pagerduty" + }, + { + "$ref": "#/components/schemas/create_connector_request_resilient" + }, + { + "$ref": "#/components/schemas/create_connector_request_serverlog" + }, + { + "$ref": "#/components/schemas/create_connector_request_servicenow" + }, + { + "$ref": "#/components/schemas/create_connector_request_servicenow_itom" + }, + { + "$ref": "#/components/schemas/create_connector_request_servicenow_sir" + }, + { + "$ref": "#/components/schemas/create_connector_request_slack" + }, + { + "$ref": "#/components/schemas/create_connector_request_swimlane" + }, + { + "$ref": "#/components/schemas/create_connector_request_teams" + }, + { + "$ref": "#/components/schemas/create_connector_request_tines" + }, + { + "$ref": "#/components/schemas/create_connector_request_webhook" + }, + { + "$ref": "#/components/schemas/create_connector_request_xmatters" + } + ], + "discriminator": { + "propertyName": "connector_type_id" + } + }, + "examples": { + "createIndexConnectorRequest": { + "$ref": "#/components/examples/create_index_connector_request" + } + } + } + } + }, + "responses": { + "200": { + "description": "Indicates a successful call.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/connector_response_properties" + }, + "examples": { + "createIndexConnectorResponse": { + "$ref": "#/components/examples/create_index_connector_response" + } + } + } + } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } + } + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] + }, "/s/{spaceId}/api/actions/connector/{connectorId}": { "get": { "summary": "Retrieves a connector by ID.", @@ -44,52 +184,62 @@ "responses": { "200": { "description": "Indicates a successful call.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/connector_response_properties" + }, + "examples": { + "getConnectorResponse": { + "$ref": "#/components/examples/get_connector_response" + } + } + } + } + }, + "401": { + "description": "Authorization information is missing or invalid.", "content": { "application/json": { "schema": { "type": "object", - "required": [ - "connector_type_id", - "id", - "is_deprecated", - "is_preconfigured", - "name" - ], "properties": { - "config": { - "type": "object", - "description": "The configuration for the connector. Configuration properties vary depending on the connector type.", - "additionalProperties": true, - "nullable": true - }, - "connector_type_id": { - "$ref": "#/components/schemas/connector_types" - }, - "id": { + "error": { "type": "string", - "description": "The identifier for the connector.", - "example": "b0766e10-d190-11ec-b04c-776c77d14fca" + "example": "Unauthorized" }, - "is_deprecated": { - "$ref": "#/components/schemas/is_deprecated" + "message": { + "type": "string" }, - "is_missing_secrets": { - "$ref": "#/components/schemas/is_missing_secrets" - }, - "is_preconfigured": { - "$ref": "#/components/schemas/is_preconfigured" + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Not Found" }, - "name": { + "message": { "type": "string", - "description": "The display name for the connector.", - "example": "my-connector" + "example": "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + }, + "statusCode": { + "type": "integer", + "example": 404 } } - }, - "examples": { - "getConnectorResponse": { - "$ref": "#/components/examples/get_connector_response" - } } } } @@ -122,6 +272,205 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Not Found" + }, + "message": { + "type": "string", + "example": "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + }, + "statusCode": { + "type": "integer", + "example": 404 + } + } + } + } + } + } + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] + }, + "put": { + "summary": "Updates the attributes for a connector.", + "operationId": "updateConnector", + "description": "You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges.\n", + "tags": [ + "connectors" + ], + "parameters": [ + { + "$ref": "#/components/parameters/kbn_xsrf" + }, + { + "$ref": "#/components/parameters/connector_id" + }, + { + "$ref": "#/components/parameters/space_id" + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "title": "Update connector request body properties", + "description": "The properties vary depending on the connector type.", + "oneOf": [ + { + "$ref": "#/components/schemas/update_connector_request_cases_webhook" + }, + { + "$ref": "#/components/schemas/update_connector_request_index" + }, + { + "$ref": "#/components/schemas/update_connector_request_jira" + }, + { + "$ref": "#/components/schemas/update_connector_request_opsgenie" + }, + { + "$ref": "#/components/schemas/update_connector_request_resilient" + }, + { + "$ref": "#/components/schemas/update_connector_request_serverlog" + }, + { + "$ref": "#/components/schemas/update_connector_request_servicenow" + }, + { + "$ref": "#/components/schemas/update_connector_request_servicenow_itom" + }, + { + "$ref": "#/components/schemas/update_connector_request_swimlane" + } + ] + }, + "examples": { + "updateIndexConnectorRequest": { + "$ref": "#/components/examples/update_index_connector_request" + } + } + } + } + }, + "responses": { + "200": { + "description": "Indicates a successful call.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/connector_response_properties" + } + } + } + }, + "400": { + "description": "Indicates a bad request.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Bad Request" + }, + "message": { + "type": "string", + "example": "error validating action type config: [index]: expected value of type [string] but got [undefined]" + }, + "statusCode": { + "type": "integer", + "example": 400 + } + } + } + } + } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Not Found" + }, + "message": { + "type": "string", + "example": "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + }, + "statusCode": { + "type": "integer", + "example": 404 + } + } + } + } + } } }, "servers": [ @@ -157,6 +506,8 @@ "schema": { "type": "array", "items": { + "title": "Get connectors response body properties", + "description": "The properties vary for each connector type.", "type": "object", "required": [ "connector_type_id", @@ -211,6 +562,29 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } } }, "servers": [ @@ -252,6 +626,8 @@ "content": { "application/json": { "schema": { + "title": "Get connector types response body properties", + "description": "The properties vary for each connector type.", "type": "array", "items": { "type": "object", @@ -306,6 +682,29 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + } + } + } } }, "servers": [ @@ -334,15 +733,13 @@ } }, "parameters": { - "connector_id": { - "in": "path", - "name": "connectorId", - "description": "An identifier for the connector.", - "required": true, + "kbn_xsrf": { "schema": { - "type": "string", - "example": "df770e30-8b8b-11ed-a780-3b746c987a81" - } + "type": "string" + }, + "in": "header", + "name": "kbn-xsrf", + "required": true }, "space_id": { "in": "path", @@ -354,17 +751,2176 @@ "example": "default" } }, - "kbn_xsrf": { + "connector_id": { + "in": "path", + "name": "connectorId", + "description": "An identifier for the connector.", + "required": true, "schema": { - "type": "string" - }, - "in": "header", - "name": "kbn-xsrf", - "required": true - } - }, + "type": "string", + "example": "df770e30-8b8b-11ed-a780-3b746c987a81" + } + } + }, "schemas": { + "config_properties_cases_webhook": { + "title": "Connector request properties for Webhook - Case Management connector", + "required": [ + "createIncidentJson", + "createIncidentResponseKey", + "createIncidentUrl", + "getIncidentResponseExternalTitleKey", + "getIncidentUrl", + "updateIncidentJson", + "updateIncidentUrl", + "viewIncidentUrl" + ], + "description": "Defines properties for connectors when type is `.cases-webhook`.", + "type": "object", + "properties": { + "createCommentJson": { + "type": "string", + "description": "A JSON payload sent to the create comment URL to create a case comment. You can use variables to add Kibana Cases data to the payload. The required variable is `case.comment`. Due to Mustache template variables (the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated once the Mustache variables have been placed when the REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass.\n", + "example": { + "body": { + "[object Object]": null + } + } + }, + "createCommentMethod": { + "type": "string", + "description": "The REST API HTTP request method to create a case comment in the third-party system. Valid values are `patch`, `post`, and `put`.\n", + "default": "put", + "enum": [ + "patch", + "post", + "put" + ] + }, + "createCommentUrl": { + "type": "string", + "description": "The REST API URL to create a case comment by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the `xpack.actions.allowedHosts setting`, add the hostname to the allowed hosts.\n", + "example": "https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}}/comment" + }, + "createIncidentJson": { + "type": "string", + "description": "A JSON payload sent to the create case URL to create a case. You can use variables to add case data to the payload. Required variables are `case.title` and `case.description`. Due to Mustache template variables (which is the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review.\n", + "example": { + "fields": { + "summary": { + "[object Object]": null + }, + "description": { + "[object Object]": null + }, + "labels": { + "[object Object]": null + } + } + } + }, + "createIncidentMethod": { + "type": "string", + "description": "The REST API HTTP request method to create a case in the third-party system. Valid values are `patch`, `post`, and `put`.\n", + "enum": [ + "patch", + "post", + "put" + ], + "default": "post" + }, + "createIncidentResponseKey": { + "type": "string", + "description": "The JSON key in the create case response that contains the external case ID." + }, + "createIncidentUrl": { + "type": "string", + "description": "The REST API URL to create a case in the third-party system. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts.\n" + }, + "getIncidentResponseExternalTitleKey": { + "type": "string", + "description": "The JSON key in get case response that contains the external case title." + }, + "getIncidentUrl": { + "type": "string", + "description": "The REST API URL to get the case by ID from the third-party system. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. You can use a variable to add the external system ID to the URL. Due to Mustache template variables (the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass.\n", + "example": "https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}}" + }, + "hasAuth": { + "type": "boolean", + "description": "If true, a username and password for login type authentication must be provided.", + "default": true + }, + "headers": { + "type": "string", + "description": "A set of key-value pairs sent as headers with the request URLs for the create case, update case, get case, and create comment methods.\n" + }, + "updateIncidentJson": { + "type": "string", + "description": "The JSON payload sent to the update case URL to update the case. You can use variables to add Kibana Cases data to the payload. Required variables are `case.title` and `case.description`. Due to Mustache template variables (which is the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review.\n", + "example": { + "fields": { + "summary": { + "[object Object]": null + }, + "description": { + "[object Object]": null + }, + "labels": { + "[object Object]": null + } + } + } + }, + "updateIncidentMethod": { + "type": "string", + "description": "The REST API HTTP request method to update the case in the third-party system. Valid values are `patch`, `post`, and `put`.\n", + "default": "put", + "enum": [ + "patch", + "post", + "put" + ] + }, + "updateIncidentUrl": { + "type": "string", + "description": "The REST API URL to update the case by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts.\n", + "example": "https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.ID}}}" + }, + "viewIncidentUrl": { + "type": "string", + "description": "The URL to view the case in the external system. You can use variables to add the external system ID or external system title to the URL.\n", + "example": "https://testing-jira.atlassian.net/browse/{{{external.system.title}}}" + } + } + }, + "secrets_properties_cases_webhook": { + "title": "Connector secrets properties for Webhook - Case Management connector", + "type": "object", + "properties": { + "password": { + "type": "string", + "description": "The password for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required." + }, + "user": { + "type": "string", + "description": "The username for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required." + } + } + }, + "create_connector_request_cases_webhook": { + "title": "Create Webhook - Case Managment connector request", + "description": "The Webhook - Case Management connector uses axios to send POST, PUT, and GET requests to a case management RESTful API web service.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_cases_webhook" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".cases-webhook" + ], + "example": ".cases-webhook" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_cases_webhook" + } + } + }, + "config_properties_email": { + "title": "Connector request properties for an email connector", + "description": "Defines properties for connectors when type is `.email`.", + "type": "object", + "additionalProperties": true + }, + "secrets_properties_email": { + "title": "Connector secrets properties for an email connector", + "description": "Defines secrets for connectors when type is `.email`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_email": { + "title": "Create email connector request", + "description": "The email connector uses the SMTP protocol to send mail messages, using an integration of Nodemailer. An exception is Microsoft Exchange, which uses HTTP protocol for sending emails, Send mail. Email message text is sent as both plain text and html text.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_email" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".email" + ], + "example": ".email" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_email" + } + } + }, + "config_properties_index": { + "title": "Connector request properties for an index connector", + "required": [ + "index" + ], + "description": "Defines properties for connectors when type is `.index`.", + "type": "object", + "properties": { + "executionTimeField": { + "description": "Specifies a field that will contain the time the alert condition was detected.", + "default": null, + "type": "string", + "nullable": true + }, + "index": { + "description": "The Elasticsearch index to be written to.", + "type": "string" + }, + "refresh": { + "description": "The refresh policy for the write request, which affects when changes are made visible to search. Refer to the refresh setting for Elasticsearch document APIs.\n", + "default": false, + "type": "boolean" + } + } + }, + "create_connector_request_index": { + "title": "Create index connector request", + "description": "The index connector indexes a document into Elasticsearch.", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_index" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".index" + ], + "example": ".index" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + } + } + }, + "config_properties_jira": { + "title": "Connector request properties for a Jira connector", + "required": [ + "apiUrl", + "projectKey" + ], + "description": "Defines properties for connectors when type is `.jira`.", + "type": "object", + "properties": { + "apiUrl": { + "description": "The Jira instance URL.", + "type": "string" + }, + "projectKey": { + "description": "The Jira project key.", + "type": "string" + } + } + }, + "secrets_properties_jira": { + "title": "Connector secrets properties for a Jira connector", + "required": [ + "apiToken", + "email" + ], + "description": "Defines secrets for connectors when type is `.jira`.", + "type": "object", + "properties": { + "apiToken": { + "description": "The Jira API authentication token for HTTP basic authentication.", + "type": "string" + }, + "email": { + "description": "The account email for HTTP Basic authentication.", + "type": "string" + } + } + }, + "create_connector_request_jira": { + "title": "Create Jira connector request", + "description": "The Jira connector uses the REST API v2 to create Jira issues.", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_jira" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".jira" + ], + "example": ".jira" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_jira" + } + } + }, + "config_properties_opsgenie": { + "title": "Connector request properties for an Opsgenie connector", + "required": [ + "apiUrl" + ], + "description": "Defines properties for connectors when type is `.opsgenie`.", + "type": "object", + "properties": { + "apiUrl": { + "description": "The Opsgenie URL. For example, `https://api.opsgenie.com` or `https://api.eu.opsgenie.com`. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts.\n", + "type": "string" + } + } + }, + "secrets_properties_opsgenie": { + "title": "Connector secrets properties for an Opsgenie connector", + "required": [ + "apiKey" + ], + "description": "Defines secrets for connectors when type is `.opsgenie`.", + "type": "object", + "properties": { + "apiKey": { + "description": "The Opsgenie API authentication key for HTTP Basic authentication.", + "type": "string" + } + } + }, + "create_connector_request_opsgenie": { + "title": "Create Opsgenie connector request", + "description": "The Opsgenie connector uses the Opsgenie alert API.", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_opsgenie" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".opsgenie" + ], + "example": ".opsgenie" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_opsgenie" + } + } + }, + "config_properties_pagerduty": { + "title": "Connector request properties for a PagerDuty connector", + "description": "Defines properties for connectors when type is `.pagerduty`.", + "type": "object", + "additionalProperties": true + }, + "secrets_properties_pagerduty": { + "title": "Connector secrets properties for a PagerDuty connector", + "description": "Defines secrets for connectors when type is `.pagerduty`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_pagerduty": { + "title": "Create PagerDuty connector request", + "description": "The PagerDuty connector uses the v2 Events API to trigger, acknowledge, and resolve PagerDuty alerts.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_pagerduty" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".pagerduty" + ], + "example": ".pagerduty" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_pagerduty" + } + } + }, + "config_properties_resilient": { + "title": "Connector request properties for a IBM Resilient connector", + "required": [ + "apiUrl", + "orgId" + ], + "description": "Defines properties for connectors when type is `.resilient`.", + "type": "object", + "properties": { + "apiUrl": { + "description": "The IBM Resilient instance URL.", + "type": "string" + }, + "orgId": { + "description": "The IBM Resilient organization ID.", + "type": "string" + } + } + }, + "secrets_properties_resilient": { + "title": "Connector secrets properties for IBM Resilient connector", + "required": [ + "apiKeyId", + "apiKeySecret" + ], + "description": "Defines secrets for connectors when type is `.resilient`.", + "type": "object", + "properties": { + "apiKeyId": { + "type": "string", + "description": "The authentication key ID for HTTP Basic authentication." + }, + "apiKeySecret": { + "type": "string", + "description": "The authentication key secret for HTTP Basic authentication." + } + } + }, + "create_connector_request_resilient": { + "title": "Create IBM Resilient connector request", + "description": "The IBM Resilient connector uses the RESILIENT REST v2 to create IBM Resilient incidents.", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_resilient" + }, + "connector_type_id": { + "description": "The type of connector.", + "type": "string", + "example": ".resilient", + "enum": [ + ".resilient" + ] + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_resilient" + } + } + }, + "create_connector_request_serverlog": { + "title": "Create server log connector request", + "description": "This connector writes an entry to the Kibana server log.", + "type": "object", + "required": [ + "connector_type_id", + "name" + ], + "properties": { + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".server-log" + ], + "example": ".server-log" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + } + } + }, + "config_properties_servicenow": { + "title": "Connector request properties for a ServiceNow ITSM connector", + "required": [ + "apiUrl" + ], + "description": "Defines properties for connectors when type is `.servicenow`.", + "type": "object", + "properties": { + "apiUrl": { + "type": "string", + "description": "The ServiceNow instance URL." + }, + "clientId": { + "description": "The client ID assigned to your OAuth application. This property is required when `isOAuth` is `true`.\n", + "type": "string" + }, + "isOAuth": { + "description": "The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth).\n", + "default": false, + "type": "string" + }, + "jwtKeyId": { + "description": "The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when `isOAuth` is `true`.\n", + "type": "string" + }, + "userIdentifierValue": { + "description": "The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is `Email`, the user identifier should be the user's email address. This property is required when `isOAuth` is `true`.\n", + "type": "string" + }, + "usesTableApi": { + "description": "Determines whether the connector uses the Table API or the Import Set API. This property is supported only for ServiceNow ITSM and ServiceNow SecOps connectors. NOTE: If this property is set to `false`, the Elastic application should be installed in ServiceNow.\n", + "default": true, + "type": "boolean" + } + } + }, + "secrets_properties_servicenow": { + "title": "Connector secrets properties for ServiceNow ITOM, ServiceNow ITSM, and ServiceNow SecOps connectors", + "description": "Defines secrets for connectors when type is `.servicenow`, `.servicenow-sir`, or `.servicenow-itom`.", + "type": "object", + "properties": { + "clientSecret": { + "type": "string", + "description": "The client secret assigned to your OAuth application. This property is required when `isOAuth` is `true`." + }, + "password": { + "type": "string", + "description": "The password for HTTP basic authentication. This property is required when `isOAuth` is `false`." + }, + "privateKey": { + "type": "string", + "description": "The RSA private key that you created for use in ServiceNow. This property is required when `isOAuth` is `true`." + }, + "privateKeyPassword": { + "type": "string", + "description": "The password for the RSA private key. This property is required when `isOAuth` is `true` and you set a password on your private key." + }, + "username": { + "type": "string", + "description": "The username for HTTP basic authentication. This property is required when `isOAuth` is `false`." + } + } + }, + "create_connector_request_servicenow": { + "title": "Create ServiceNow ITSM connector request", + "description": "The ServiceNow ITSM connector uses the import set API to create ServiceNow incidents. You can use the connector for rule actions and cases.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow" + ], + "example": ".servicenow" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_servicenow" + } + } + }, + "config_properties_servicenow_itom": { + "title": "Connector request properties for a ServiceNow ITSM connector", + "required": [ + "apiUrl" + ], + "description": "Defines properties for connectors when type is `.servicenow`.", + "type": "object", + "properties": { + "apiUrl": { + "type": "string", + "description": "The ServiceNow instance URL." + }, + "clientId": { + "description": "The client ID assigned to your OAuth application. This property is required when `isOAuth` is `true`.\n", + "type": "string" + }, + "isOAuth": { + "description": "The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth).\n", + "default": false, + "type": "string" + }, + "jwtKeyId": { + "description": "The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when `isOAuth` is `true`.\n", + "type": "string" + }, + "userIdentifierValue": { + "description": "The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is `Email`, the user identifier should be the user's email address. This property is required when `isOAuth` is `true`.\n", + "type": "string" + } + } + }, + "create_connector_request_servicenow_itom": { + "title": "Create ServiceNow ITOM connector request", + "description": "The ServiceNow ITOM connector uses the event API to create ServiceNow events. You can use the connector for rule actions.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow_itom" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow-itom" + ], + "example": ".servicenow-itom" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_servicenow" + } + } + }, + "create_connector_request_servicenow_sir": { + "title": "Create ServiceNow SecOps connector request", + "description": "The ServiceNow SecOps connector uses the import set API to create ServiceNow security incidents. You can use the connector for rule actions and cases.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow-sir" + ], + "example": ".servicenow-sir" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_servicenow" + } + } + }, + "secrets_properties_slack": { + "title": "Connector secrets properties for a Slack connector", + "description": "Defines secrets for connectors when type is `.slack`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_slack": { + "title": "Create Slack connector request", + "description": "The Slack connector uses Slack Incoming Webhooks.", + "type": "object", + "required": [ + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".slack" + ], + "example": ".slack" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_slack" + } + } + }, + "config_properties_swimlane": { + "title": "Connector request properties for a Swimlane connector", + "required": [ + "apiUrl", + "appId", + "connectorType" + ], + "description": "Defines properties for connectors when type is `.swimlane`.", + "type": "object", + "properties": { + "apiUrl": { + "description": "The Swimlane instance URL.", + "type": "string" + }, + "appId": { + "description": "The Swimlane application ID.", + "type": "string" + }, + "connectorType": { + "description": "The type of connector. Valid values are `all`, `alerts`, and `cases`.", + "type": "string", + "enum": [ + "all", + "alerts", + "cases" + ] + }, + "mappings": { + "title": "Connector mappings properties for a Swimlane connector", + "description": "The field mapping.", + "type": "object", + "properties": { + "alertIdConfig": { + "title": "Alert identifier mapping", + "description": "Mapping for the alert ID.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "caseIdConfig": { + "title": "Case identifier mapping", + "description": "Mapping for the case ID.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "caseNameConfig": { + "title": "Case name mapping", + "description": "Mapping for the case name.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "commentsConfig": { + "title": "Case comment mapping", + "description": "Mapping for the case comments.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "descriptionConfig": { + "title": "Case description mapping", + "description": "Mapping for the case description.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "ruleNameConfig": { + "title": "Rule name mapping", + "description": "Mapping for the name of the alert's rule.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + }, + "severityConfig": { + "title": "Severity mapping", + "description": "Mapping for the severity.", + "type": "object", + "required": [ + "fieldType", + "id", + "key", + "name" + ], + "properties": { + "fieldType": { + "type": "string", + "description": "The type of field in Swimlane." + }, + "id": { + "type": "string", + "description": "The identifier for the field in Swimlane." + }, + "key": { + "type": "string", + "description": "The key for the field in Swimlane." + }, + "name": { + "type": "string", + "description": "The name of the field in Swimlane." + } + } + } + } + } + } + }, + "secrets_properties_swimlane": { + "title": "Connector secrets properties for a Swimlane connector", + "description": "Defines secrets for connectors when type is `.swimlane`.", + "type": "object", + "properties": { + "apiToken": { + "description": "Swimlane API authentication token.", + "type": "string" + } + } + }, + "create_connector_request_swimlane": { + "title": "Create Swimlane connector request", + "description": "The Swimlane connector uses the Swimlane REST API to create Swimlane records.", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_swimlane" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".swimlane" + ], + "example": ".swimlane" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_swimlane" + } + } + }, + "secrets_properties_teams": { + "title": "Connector secrets properties for a Microsoft Teams connector", + "description": "Defines secrets for connectors when type is `.teams`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_teams": { + "title": "Create Microsoft Teams connector request", + "description": "The Microsoft Teams connector uses Incoming Webhooks.", + "type": "object", + "required": [ + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".teams" + ], + "example": ".teams" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_teams" + } + } + }, + "config_properties_tines": { + "title": "Connector request properties for a Tines connector", + "description": "Defines properties for connectors when type is `.tines`.", + "type": "object", + "additionalProperties": true + }, + "secrets_properties_tines": { + "title": "Connector secrets properties for a Tines connector", + "description": "Defines secrets for connectors when type is `.tines`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_tines": { + "title": "Create Tines connector request", + "description": "The Tines connector uses Tines Webhook actions to send events via POST request.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_tines" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".tines" + ], + "example": ".tines" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_tines" + } + } + }, + "config_properties_webhook": { + "title": "Connector request properties for a Webhook connector", + "description": "Defines properties for connectors when type is `.webhook`.", + "type": "object", + "additionalProperties": true + }, + "secrets_properties_webhook": { + "title": "Connector secrets properties for a Webhook connector", + "description": "Defines secrets for connectors when type is `.webhook`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_webhook": { + "title": "Create Webhook connector request", + "description": "The Webhook connector uses axios to send a POST or PUT request to a web service.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_webhook" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".webhook" + ], + "example": ".webhook" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_webhook" + } + } + }, + "config_properties_xmatters": { + "title": "Connector request properties for a xMatters connector", + "description": "Defines properties for connectors when type is `.xmatters`.", + "type": "object", + "additionalProperties": true + }, + "secrets_properties_xmatters": { + "title": "Connector secrets properties for an xMatters connector", + "description": "Defines secrets for connectors when type is `.xmatters`.", + "type": "object", + "additionalProperties": true + }, + "create_connector_request_xmatters": { + "title": "Create xMatters connector request", + "description": "The xMatters connector uses the xMatters Workflow for Elastic to send actionable alerts to on-call xMatters resources.\n", + "type": "object", + "required": [ + "config", + "connector_type_id", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_xmatters" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".xmatters" + ], + "example": ".xmatters" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_xmatters" + } + } + }, + "is_deprecated": { + "type": "boolean", + "description": "Indicates whether the connector type is deprecated.", + "example": false + }, + "is_missing_secrets": { + "type": "boolean", + "description": "Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.", + "example": false + }, + "is_preconfigured": { + "type": "boolean", + "description": "Indicates whether it is a preconfigured connector. If true, the `config` and `is_missing_secrets` properties are omitted from the response.", + "example": false + }, + "connector_response_properties_cases_webhook": { + "title": "Connector request properties for a Webhook - Case Management connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_cases_webhook" + }, + "connector_type_id": { + "description": "The type of connector.", + "type": "string", + "enum": [ + ".cases-webhook" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_email": { + "title": "Connector response properties for an email connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_email" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".email" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_index": { + "title": "Connector response properties for an index connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_index" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".index" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_jira": { + "title": "Connector response properties for a Jira connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_jira" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".jira" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_opsgenie": { + "title": "Connector response properties for an Opsgenie connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_opsgenie" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".opsgenie" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_pagerduty": { + "title": "Connector response properties for a PagerDuty connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_pagerduty" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".pagerduty" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_resilient": { + "title": "Connector response properties for a IBM Resilient connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_resilient" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".resilient" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_serverlog": { + "title": "Connector response properties for a server log connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "type": "object", + "nullable": true + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".server-log" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_servicenow": { + "title": "Connector response properties for a ServiceNow ITSM connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_servicenow_itom": { + "title": "Connector response properties for a ServiceNow ITOM connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow_itom" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow-itom" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_servicenow_sir": { + "title": "Connector response properties for a ServiceNow SecOps connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".servicenow-sir" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_slack": { + "title": "Connector response properties for a Slack connector", + "type": "object", + "required": [ + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".slack" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_swimlane": { + "title": "Connector response properties for a Swimlane connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_swimlane" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".swimlane" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_teams": { + "title": "Connector response properties for a Microsoft Teams connector", + "type": "object", + "required": [ + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".teams" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_tines": { + "title": "Connector response properties for a Tines connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_tines" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".tines" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_webhook": { + "title": "Connector response properties for a Webhook connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_webhook" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".webhook" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties_xmatters": { + "title": "Connector response properties for an xMatters connector", + "type": "object", + "required": [ + "config", + "connector_type_id", + "id", + "is_deprecated", + "is_preconfigured", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_xmatters" + }, + "connector_type_id": { + "type": "string", + "description": "The type of connector.", + "enum": [ + ".xmatters" + ] + }, + "id": { + "type": "string", + "description": "The identifier for the connector." + }, + "is_deprecated": { + "$ref": "#/components/schemas/is_deprecated" + }, + "is_missing_secrets": { + "$ref": "#/components/schemas/is_missing_secrets" + }, + "is_preconfigured": { + "$ref": "#/components/schemas/is_preconfigured" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "connector_response_properties": { + "title": "Connector response properties", + "description": "The properties vary depending on the connector type.", + "oneOf": [ + { + "$ref": "#/components/schemas/connector_response_properties_cases_webhook" + }, + { + "$ref": "#/components/schemas/connector_response_properties_email" + }, + { + "$ref": "#/components/schemas/connector_response_properties_index" + }, + { + "$ref": "#/components/schemas/connector_response_properties_jira" + }, + { + "$ref": "#/components/schemas/connector_response_properties_opsgenie" + }, + { + "$ref": "#/components/schemas/connector_response_properties_pagerduty" + }, + { + "$ref": "#/components/schemas/connector_response_properties_resilient" + }, + { + "$ref": "#/components/schemas/connector_response_properties_serverlog" + }, + { + "$ref": "#/components/schemas/connector_response_properties_servicenow" + }, + { + "$ref": "#/components/schemas/connector_response_properties_servicenow_itom" + }, + { + "$ref": "#/components/schemas/connector_response_properties_servicenow_sir" + }, + { + "$ref": "#/components/schemas/connector_response_properties_slack" + }, + { + "$ref": "#/components/schemas/connector_response_properties_swimlane" + }, + { + "$ref": "#/components/schemas/connector_response_properties_teams" + }, + { + "$ref": "#/components/schemas/connector_response_properties_tines" + }, + { + "$ref": "#/components/schemas/connector_response_properties_webhook" + }, + { + "$ref": "#/components/schemas/connector_response_properties_xmatters" + } + ], + "discriminator": { + "propertyName": "connector_type_id" + } + }, + "update_connector_request_cases_webhook": { + "title": "Update Webhook - Case Managment connector request", + "type": "object", + "required": [ + "config", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_cases_webhook" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_cases_webhook" + } + } + }, + "update_connector_request_index": { + "title": "Update index connector request", + "type": "object", + "required": [ + "config", + "name" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_index" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "update_connector_request_jira": { + "title": "Update Jira connector request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_jira" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_jira" + } + } + }, + "update_connector_request_opsgenie": { + "title": "Update Opsgenie connector request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_opsgenie" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_opsgenie" + } + } + }, + "update_connector_request_resilient": { + "title": "Update IBM Resilient connector request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_resilient" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_resilient" + } + } + }, + "update_connector_request_serverlog": { + "title": "Update server log connector request", + "type": "object", + "required": [ + "name" + ], + "properties": { + "name": { + "type": "string", + "description": "The display name for the connector." + } + } + }, + "update_connector_request_servicenow": { + "title": "Update ServiceNow ITSM connector or ServiceNow SecOps request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_servicenow" + } + } + }, + "update_connector_request_servicenow_itom": { + "title": "Create ServiceNow ITOM connector request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_servicenow_itom" + }, + "name": { + "type": "string", + "description": "The display name for the connector." + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_servicenow" + } + } + }, + "update_connector_request_swimlane": { + "title": "Update Swimlane connector request", + "type": "object", + "required": [ + "config", + "name", + "secrets" + ], + "properties": { + "config": { + "$ref": "#/components/schemas/config_properties_swimlane" + }, + "name": { + "type": "string", + "description": "The display name for the connector.", + "example": "my-connector" + }, + "secrets": { + "$ref": "#/components/schemas/secrets_properties_swimlane" + } + } + }, "connector_types": { + "title": "Connector types", "type": "string", "description": "The type of connector. For example, `.email`, `.index`, `.jira`, `.opsgenie`, or `.server-log`.", "enum": [ @@ -388,21 +2944,6 @@ ], "example": ".server-log" }, - "is_deprecated": { - "type": "boolean", - "description": "Indicates whether the connector type is deprecated.", - "example": false - }, - "is_missing_secrets": { - "type": "boolean", - "description": "Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type.", - "example": false - }, - "is_preconfigured": { - "type": "boolean", - "description": "Indicates whether it is a preconfigured connector. If true, the `config` and `is_missing_secrets` properties are omitted from the response.", - "example": false - }, "features": { "type": "string", "description": "The feature that uses the connector. Valid values are `alerting`, `cases`, `uptime`, and `siem`.\n", @@ -415,6 +2956,32 @@ } }, "examples": { + "create_index_connector_request": { + "summary": "Create an index connector.", + "value": { + "name": "my-connector", + "connector_type_id": ".index", + "config": { + "index": "test-index" + } + } + }, + "create_index_connector_response": { + "summary": "A new index connector.", + "value": { + "id": "c55b6eb0-6bad-11eb-9f3b-611eebc6c3ad", + "connector_type_id": ".index", + "name": "my-connector", + "config": { + "index": "test-index", + "refresh": false, + "executionTimeField": null + }, + "is_preconfigured": false, + "is_deprecated": false, + "is_missing_secrets": false + } + }, "get_connector_response": { "summary": "A list of connector types", "value": { @@ -427,6 +2994,15 @@ "is_missing_secrets": false } }, + "update_index_connector_request": { + "summary": "Update an index connector.", + "value": { + "name": "updated-connector", + "config": { + "index": "updated-index" + } + } + }, "get_connectors_response": { "summary": "A list of connectors", "value": [ diff --git a/x-pack/plugins/actions/docs/openapi/bundled.yaml b/x-pack/plugins/actions/docs/openapi/bundled.yaml index 8d52047d1181b..1ffc0dc5da1eb 100644 --- a/x-pack/plugins/actions/docs/openapi/bundled.yaml +++ b/x-pack/plugins/actions/docs/openapi/bundled.yaml @@ -15,6 +15,76 @@ servers: - url: http://localhost:5601 description: local paths: + /s/{spaceId}/api/actions/connector: + post: + summary: Creates a connector. + operationId: createConnector + description: | + You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges. + tags: + - connectors + parameters: + - $ref: '#/components/parameters/kbn_xsrf' + - $ref: '#/components/parameters/space_id' + requestBody: + required: true + content: + application/json: + schema: + title: Create connector request body properties + description: The properties vary depending on the connector type. + oneOf: + - $ref: '#/components/schemas/create_connector_request_cases_webhook' + - $ref: '#/components/schemas/create_connector_request_email' + - $ref: '#/components/schemas/create_connector_request_index' + - $ref: '#/components/schemas/create_connector_request_jira' + - $ref: '#/components/schemas/create_connector_request_opsgenie' + - $ref: '#/components/schemas/create_connector_request_pagerduty' + - $ref: '#/components/schemas/create_connector_request_resilient' + - $ref: '#/components/schemas/create_connector_request_serverlog' + - $ref: '#/components/schemas/create_connector_request_servicenow' + - $ref: '#/components/schemas/create_connector_request_servicenow_itom' + - $ref: '#/components/schemas/create_connector_request_servicenow_sir' + - $ref: '#/components/schemas/create_connector_request_slack' + - $ref: '#/components/schemas/create_connector_request_swimlane' + - $ref: '#/components/schemas/create_connector_request_teams' + - $ref: '#/components/schemas/create_connector_request_tines' + - $ref: '#/components/schemas/create_connector_request_webhook' + - $ref: '#/components/schemas/create_connector_request_xmatters' + discriminator: + propertyName: connector_type_id + examples: + createIndexConnectorRequest: + $ref: '#/components/examples/create_index_connector_request' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + $ref: '#/components/schemas/connector_response_properties' + examples: + createIndexConnectorResponse: + $ref: '#/components/examples/create_index_connector_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + servers: + - url: https://localhost:5601 + servers: + - url: https://localhost:5601 /s/{spaceId}/api/actions/connector/{connectorId}: get: summary: Retrieves a connector by ID. @@ -29,41 +99,44 @@ paths: responses: '200': description: Indicates a successful call. + content: + application/json: + schema: + $ref: '#/components/schemas/connector_response_properties' + examples: + getConnectorResponse: + $ref: '#/components/examples/get_connector_response' + '401': + description: Authorization information is missing or invalid. content: application/json: schema: type: object - required: - - connector_type_id - - id - - is_deprecated - - is_preconfigured - - name properties: - config: - type: object - description: The configuration for the connector. Configuration properties vary depending on the connector type. - additionalProperties: true - nullable: true - connector_type_id: - $ref: '#/components/schemas/connector_types' - id: + error: type: string - description: The identifier for the connector. - example: b0766e10-d190-11ec-b04c-776c77d14fca - is_deprecated: - $ref: '#/components/schemas/is_deprecated' - is_missing_secrets: - $ref: '#/components/schemas/is_missing_secrets' - is_preconfigured: - $ref: '#/components/schemas/is_preconfigured' - name: + example: Unauthorized + message: type: string - description: The display name for the connector. - example: my-connector - examples: - getConnectorResponse: - $ref: '#/components/examples/get_connector_response' + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found + statusCode: + type: integer + example: 404 servers: - url: https://localhost:5601 delete: @@ -80,6 +153,124 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found + statusCode: + type: integer + example: 404 + servers: + - url: https://localhost:5601 + put: + summary: Updates the attributes for a connector. + operationId: updateConnector + description: | + You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges. + tags: + - connectors + parameters: + - $ref: '#/components/parameters/kbn_xsrf' + - $ref: '#/components/parameters/connector_id' + - $ref: '#/components/parameters/space_id' + requestBody: + required: true + content: + application/json: + schema: + title: Update connector request body properties + description: The properties vary depending on the connector type. + oneOf: + - $ref: '#/components/schemas/update_connector_request_cases_webhook' + - $ref: '#/components/schemas/update_connector_request_index' + - $ref: '#/components/schemas/update_connector_request_jira' + - $ref: '#/components/schemas/update_connector_request_opsgenie' + - $ref: '#/components/schemas/update_connector_request_resilient' + - $ref: '#/components/schemas/update_connector_request_serverlog' + - $ref: '#/components/schemas/update_connector_request_servicenow' + - $ref: '#/components/schemas/update_connector_request_servicenow_itom' + - $ref: '#/components/schemas/update_connector_request_swimlane' + examples: + updateIndexConnectorRequest: + $ref: '#/components/examples/update_index_connector_request' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + $ref: '#/components/schemas/connector_response_properties' + '400': + description: Indicates a bad request. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Bad Request + message: + type: string + example: 'error validating action type config: [index]: expected value of type [string] but got [undefined]' + statusCode: + type: integer + example: 400 + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found + statusCode: + type: integer + example: 404 servers: - url: https://localhost:5601 servers: @@ -102,6 +293,8 @@ paths: schema: type: array items: + title: Get connectors response body properties + description: The properties vary for each connector type. type: object required: - connector_type_id @@ -140,6 +333,21 @@ paths: examples: getConnectorsResponse: $ref: '#/components/examples/get_connectors_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 servers: - url: https://localhost:5601 servers: @@ -165,6 +373,8 @@ paths: content: application/json: schema: + title: Get connector types response body properties + description: The properties vary for each connector type. type: array items: type: object @@ -203,6 +413,21 @@ paths: examples: getConnectorTypesResponse: $ref: '#/components/examples/get_connector_types_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 servers: - url: https://localhost:5601 servers: @@ -217,14 +442,12 @@ components: in: header name: ApiKey parameters: - connector_id: - in: path - name: connectorId - description: An identifier for the connector. - required: true + kbn_xsrf: schema: type: string - example: df770e30-8b8b-11ed-a780-3b746c987a81 + in: header + name: kbn-xsrf + required: true space_id: in: path name: spaceId @@ -233,14 +456,1630 @@ components: schema: type: string example: default - kbn_xsrf: + connector_id: + in: path + name: connectorId + description: An identifier for the connector. + required: true schema: type: string - in: header - name: kbn-xsrf - required: true + example: df770e30-8b8b-11ed-a780-3b746c987a81 schemas: + config_properties_cases_webhook: + title: Connector request properties for Webhook - Case Management connector + required: + - createIncidentJson + - createIncidentResponseKey + - createIncidentUrl + - getIncidentResponseExternalTitleKey + - getIncidentUrl + - updateIncidentJson + - updateIncidentUrl + - viewIncidentUrl + description: Defines properties for connectors when type is `.cases-webhook`. + type: object + properties: + createCommentJson: + type: string + description: | + A JSON payload sent to the create comment URL to create a case comment. You can use variables to add Kibana Cases data to the payload. The required variable is `case.comment`. Due to Mustache template variables (the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated once the Mustache variables have been placed when the REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass. + example: + body: + '[object Object]': null + createCommentMethod: + type: string + description: | + The REST API HTTP request method to create a case comment in the third-party system. Valid values are `patch`, `post`, and `put`. + default: put + enum: + - patch + - post + - put + createCommentUrl: + type: string + description: | + The REST API URL to create a case comment by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the `xpack.actions.allowedHosts setting`, add the hostname to the allowed hosts. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}}/comment + createIncidentJson: + type: string + description: | + A JSON payload sent to the create case URL to create a case. You can use variables to add case data to the payload. Required variables are `case.title` and `case.description`. Due to Mustache template variables (which is the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review. + example: + fields: + summary: + '[object Object]': null + description: + '[object Object]': null + labels: + '[object Object]': null + createIncidentMethod: + type: string + description: | + The REST API HTTP request method to create a case in the third-party system. Valid values are `patch`, `post`, and `put`. + enum: + - patch + - post + - put + default: post + createIncidentResponseKey: + type: string + description: The JSON key in the create case response that contains the external case ID. + createIncidentUrl: + type: string + description: | + The REST API URL to create a case in the third-party system. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + getIncidentResponseExternalTitleKey: + type: string + description: The JSON key in get case response that contains the external case title. + getIncidentUrl: + type: string + description: | + The REST API URL to get the case by ID from the third-party system. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. You can use a variable to add the external system ID to the URL. Due to Mustache template variables (the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid, disregarding the Mustache variables, so the later validation will pass. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}} + hasAuth: + type: boolean + description: If true, a username and password for login type authentication must be provided. + default: true + headers: + type: string + description: | + A set of key-value pairs sent as headers with the request URLs for the create case, update case, get case, and create comment methods. + updateIncidentJson: + type: string + description: | + The JSON payload sent to the update case URL to update the case. You can use variables to add Kibana Cases data to the payload. Required variables are `case.title` and `case.description`. Due to Mustache template variables (which is the text enclosed in triple braces, for example, `{{{case.title}}}`), the JSON is not validated when you create the connector. The JSON is validated after the Mustache variables have been placed when REST method runs. Manually ensure that the JSON is valid to avoid future validation errors; disregard Mustache variables during your review. + example: + fields: + summary: + '[object Object]': null + description: + '[object Object]': null + labels: + '[object Object]': null + updateIncidentMethod: + type: string + description: | + The REST API HTTP request method to update the case in the third-party system. Valid values are `patch`, `post`, and `put`. + default: put + enum: + - patch + - post + - put + updateIncidentUrl: + type: string + description: | + The REST API URL to update the case by ID in the third-party system. You can use a variable to add the external system ID to the URL. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.ID}}} + viewIncidentUrl: + type: string + description: | + The URL to view the case in the external system. You can use variables to add the external system ID or external system title to the URL. + example: https://testing-jira.atlassian.net/browse/{{{external.system.title}}} + secrets_properties_cases_webhook: + title: Connector secrets properties for Webhook - Case Management connector + type: object + properties: + password: + type: string + description: The password for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required. + user: + type: string + description: The username for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required. + create_connector_request_cases_webhook: + title: Create Webhook - Case Managment connector request + description: | + The Webhook - Case Management connector uses axios to send POST, PUT, and GET requests to a case management RESTful API web service. + type: object + required: + - config + - connector_type_id + - name + properties: + config: + $ref: '#/components/schemas/config_properties_cases_webhook' + connector_type_id: + type: string + description: The type of connector. + enum: + - .cases-webhook + example: .cases-webhook + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_cases_webhook' + config_properties_email: + title: Connector request properties for an email connector + description: Defines properties for connectors when type is `.email`. + type: object + additionalProperties: true + secrets_properties_email: + title: Connector secrets properties for an email connector + description: Defines secrets for connectors when type is `.email`. + type: object + additionalProperties: true + create_connector_request_email: + title: Create email connector request + description: | + The email connector uses the SMTP protocol to send mail messages, using an integration of Nodemailer. An exception is Microsoft Exchange, which uses HTTP protocol for sending emails, Send mail. Email message text is sent as both plain text and html text. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_email' + connector_type_id: + type: string + description: The type of connector. + enum: + - .email + example: .email + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_email' + config_properties_index: + title: Connector request properties for an index connector + required: + - index + description: Defines properties for connectors when type is `.index`. + type: object + properties: + executionTimeField: + description: Specifies a field that will contain the time the alert condition was detected. + default: null + type: string + nullable: true + index: + description: The Elasticsearch index to be written to. + type: string + refresh: + description: | + The refresh policy for the write request, which affects when changes are made visible to search. Refer to the refresh setting for Elasticsearch document APIs. + default: false + type: boolean + create_connector_request_index: + title: Create index connector request + description: The index connector indexes a document into Elasticsearch. + type: object + required: + - config + - connector_type_id + - name + properties: + config: + $ref: '#/components/schemas/config_properties_index' + connector_type_id: + type: string + description: The type of connector. + enum: + - .index + example: .index + name: + type: string + description: The display name for the connector. + example: my-connector + config_properties_jira: + title: Connector request properties for a Jira connector + required: + - apiUrl + - projectKey + description: Defines properties for connectors when type is `.jira`. + type: object + properties: + apiUrl: + description: The Jira instance URL. + type: string + projectKey: + description: The Jira project key. + type: string + secrets_properties_jira: + title: Connector secrets properties for a Jira connector + required: + - apiToken + - email + description: Defines secrets for connectors when type is `.jira`. + type: object + properties: + apiToken: + description: The Jira API authentication token for HTTP basic authentication. + type: string + email: + description: The account email for HTTP Basic authentication. + type: string + create_connector_request_jira: + title: Create Jira connector request + description: The Jira connector uses the REST API v2 to create Jira issues. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_jira' + connector_type_id: + type: string + description: The type of connector. + enum: + - .jira + example: .jira + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_jira' + config_properties_opsgenie: + title: Connector request properties for an Opsgenie connector + required: + - apiUrl + description: Defines properties for connectors when type is `.opsgenie`. + type: object + properties: + apiUrl: + description: | + The Opsgenie URL. For example, `https://api.opsgenie.com` or `https://api.eu.opsgenie.com`. If you are using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + type: string + secrets_properties_opsgenie: + title: Connector secrets properties for an Opsgenie connector + required: + - apiKey + description: Defines secrets for connectors when type is `.opsgenie`. + type: object + properties: + apiKey: + description: The Opsgenie API authentication key for HTTP Basic authentication. + type: string + create_connector_request_opsgenie: + title: Create Opsgenie connector request + description: The Opsgenie connector uses the Opsgenie alert API. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_opsgenie' + connector_type_id: + type: string + description: The type of connector. + enum: + - .opsgenie + example: .opsgenie + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_opsgenie' + config_properties_pagerduty: + title: Connector request properties for a PagerDuty connector + description: Defines properties for connectors when type is `.pagerduty`. + type: object + additionalProperties: true + secrets_properties_pagerduty: + title: Connector secrets properties for a PagerDuty connector + description: Defines secrets for connectors when type is `.pagerduty`. + type: object + additionalProperties: true + create_connector_request_pagerduty: + title: Create PagerDuty connector request + description: | + The PagerDuty connector uses the v2 Events API to trigger, acknowledge, and resolve PagerDuty alerts. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_pagerduty' + connector_type_id: + type: string + description: The type of connector. + enum: + - .pagerduty + example: .pagerduty + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_pagerduty' + config_properties_resilient: + title: Connector request properties for a IBM Resilient connector + required: + - apiUrl + - orgId + description: Defines properties for connectors when type is `.resilient`. + type: object + properties: + apiUrl: + description: The IBM Resilient instance URL. + type: string + orgId: + description: The IBM Resilient organization ID. + type: string + secrets_properties_resilient: + title: Connector secrets properties for IBM Resilient connector + required: + - apiKeyId + - apiKeySecret + description: Defines secrets for connectors when type is `.resilient`. + type: object + properties: + apiKeyId: + type: string + description: The authentication key ID for HTTP Basic authentication. + apiKeySecret: + type: string + description: The authentication key secret for HTTP Basic authentication. + create_connector_request_resilient: + title: Create IBM Resilient connector request + description: The IBM Resilient connector uses the RESILIENT REST v2 to create IBM Resilient incidents. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_resilient' + connector_type_id: + description: The type of connector. + type: string + example: .resilient + enum: + - .resilient + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_resilient' + create_connector_request_serverlog: + title: Create server log connector request + description: This connector writes an entry to the Kibana server log. + type: object + required: + - connector_type_id + - name + properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .server-log + example: .server-log + name: + type: string + description: The display name for the connector. + example: my-connector + config_properties_servicenow: + title: Connector request properties for a ServiceNow ITSM connector + required: + - apiUrl + description: Defines properties for connectors when type is `.servicenow`. + type: object + properties: + apiUrl: + type: string + description: The ServiceNow instance URL. + clientId: + description: | + The client ID assigned to your OAuth application. This property is required when `isOAuth` is `true`. + type: string + isOAuth: + description: | + The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth). + default: false + type: string + jwtKeyId: + description: | + The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when `isOAuth` is `true`. + type: string + userIdentifierValue: + description: | + The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is `Email`, the user identifier should be the user's email address. This property is required when `isOAuth` is `true`. + type: string + usesTableApi: + description: | + Determines whether the connector uses the Table API or the Import Set API. This property is supported only for ServiceNow ITSM and ServiceNow SecOps connectors. NOTE: If this property is set to `false`, the Elastic application should be installed in ServiceNow. + default: true + type: boolean + secrets_properties_servicenow: + title: Connector secrets properties for ServiceNow ITOM, ServiceNow ITSM, and ServiceNow SecOps connectors + description: Defines secrets for connectors when type is `.servicenow`, `.servicenow-sir`, or `.servicenow-itom`. + type: object + properties: + clientSecret: + type: string + description: The client secret assigned to your OAuth application. This property is required when `isOAuth` is `true`. + password: + type: string + description: The password for HTTP basic authentication. This property is required when `isOAuth` is `false`. + privateKey: + type: string + description: The RSA private key that you created for use in ServiceNow. This property is required when `isOAuth` is `true`. + privateKeyPassword: + type: string + description: The password for the RSA private key. This property is required when `isOAuth` is `true` and you set a password on your private key. + username: + type: string + description: The username for HTTP basic authentication. This property is required when `isOAuth` is `false`. + create_connector_request_servicenow: + title: Create ServiceNow ITSM connector request + description: | + The ServiceNow ITSM connector uses the import set API to create ServiceNow incidents. You can use the connector for rule actions and cases. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow + example: .servicenow + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_servicenow' + config_properties_servicenow_itom: + title: Connector request properties for a ServiceNow ITSM connector + required: + - apiUrl + description: Defines properties for connectors when type is `.servicenow`. + type: object + properties: + apiUrl: + type: string + description: The ServiceNow instance URL. + clientId: + description: | + The client ID assigned to your OAuth application. This property is required when `isOAuth` is `true`. + type: string + isOAuth: + description: | + The type of authentication to use. The default value is false, which means basic authentication is used instead of open authorization (OAuth). + default: false + type: string + jwtKeyId: + description: | + The key identifier assigned to the JWT verifier map of your OAuth application. This property is required when `isOAuth` is `true`. + type: string + userIdentifierValue: + description: | + The identifier to use for OAuth authentication. This identifier should be the user field you selected when you created an OAuth JWT API endpoint for external clients in your ServiceNow instance. For example, if the selected user field is `Email`, the user identifier should be the user's email address. This property is required when `isOAuth` is `true`. + type: string + create_connector_request_servicenow_itom: + title: Create ServiceNow ITOM connector request + description: | + The ServiceNow ITOM connector uses the event API to create ServiceNow events. You can use the connector for rule actions. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow_itom' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-itom + example: .servicenow-itom + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_servicenow' + create_connector_request_servicenow_sir: + title: Create ServiceNow SecOps connector request + description: | + The ServiceNow SecOps connector uses the import set API to create ServiceNow security incidents. You can use the connector for rule actions and cases. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-sir + example: .servicenow-sir + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_servicenow' + secrets_properties_slack: + title: Connector secrets properties for a Slack connector + description: Defines secrets for connectors when type is `.slack`. + type: object + additionalProperties: true + create_connector_request_slack: + title: Create Slack connector request + description: The Slack connector uses Slack Incoming Webhooks. + type: object + required: + - connector_type_id + - name + - secrets + properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .slack + example: .slack + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_slack' + config_properties_swimlane: + title: Connector request properties for a Swimlane connector + required: + - apiUrl + - appId + - connectorType + description: Defines properties for connectors when type is `.swimlane`. + type: object + properties: + apiUrl: + description: The Swimlane instance URL. + type: string + appId: + description: The Swimlane application ID. + type: string + connectorType: + description: The type of connector. Valid values are `all`, `alerts`, and `cases`. + type: string + enum: + - all + - alerts + - cases + mappings: + title: Connector mappings properties for a Swimlane connector + description: The field mapping. + type: object + properties: + alertIdConfig: + title: Alert identifier mapping + description: Mapping for the alert ID. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + caseIdConfig: + title: Case identifier mapping + description: Mapping for the case ID. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + caseNameConfig: + title: Case name mapping + description: Mapping for the case name. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + commentsConfig: + title: Case comment mapping + description: Mapping for the case comments. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + descriptionConfig: + title: Case description mapping + description: Mapping for the case description. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + ruleNameConfig: + title: Rule name mapping + description: Mapping for the name of the alert's rule. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + severityConfig: + title: Severity mapping + description: Mapping for the severity. + type: object + required: + - fieldType + - id + - key + - name + properties: + fieldType: + type: string + description: The type of field in Swimlane. + id: + type: string + description: The identifier for the field in Swimlane. + key: + type: string + description: The key for the field in Swimlane. + name: + type: string + description: The name of the field in Swimlane. + secrets_properties_swimlane: + title: Connector secrets properties for a Swimlane connector + description: Defines secrets for connectors when type is `.swimlane`. + type: object + properties: + apiToken: + description: Swimlane API authentication token. + type: string + create_connector_request_swimlane: + title: Create Swimlane connector request + description: The Swimlane connector uses the Swimlane REST API to create Swimlane records. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_swimlane' + connector_type_id: + type: string + description: The type of connector. + enum: + - .swimlane + example: .swimlane + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_swimlane' + secrets_properties_teams: + title: Connector secrets properties for a Microsoft Teams connector + description: Defines secrets for connectors when type is `.teams`. + type: object + additionalProperties: true + create_connector_request_teams: + title: Create Microsoft Teams connector request + description: The Microsoft Teams connector uses Incoming Webhooks. + type: object + required: + - connector_type_id + - name + - secrets + properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .teams + example: .teams + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_teams' + config_properties_tines: + title: Connector request properties for a Tines connector + description: Defines properties for connectors when type is `.tines`. + type: object + additionalProperties: true + secrets_properties_tines: + title: Connector secrets properties for a Tines connector + description: Defines secrets for connectors when type is `.tines`. + type: object + additionalProperties: true + create_connector_request_tines: + title: Create Tines connector request + description: | + The Tines connector uses Tines Webhook actions to send events via POST request. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_tines' + connector_type_id: + type: string + description: The type of connector. + enum: + - .tines + example: .tines + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_tines' + config_properties_webhook: + title: Connector request properties for a Webhook connector + description: Defines properties for connectors when type is `.webhook`. + type: object + additionalProperties: true + secrets_properties_webhook: + title: Connector secrets properties for a Webhook connector + description: Defines secrets for connectors when type is `.webhook`. + type: object + additionalProperties: true + create_connector_request_webhook: + title: Create Webhook connector request + description: | + The Webhook connector uses axios to send a POST or PUT request to a web service. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_webhook' + connector_type_id: + type: string + description: The type of connector. + enum: + - .webhook + example: .webhook + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_webhook' + config_properties_xmatters: + title: Connector request properties for a xMatters connector + description: Defines properties for connectors when type is `.xmatters`. + type: object + additionalProperties: true + secrets_properties_xmatters: + title: Connector secrets properties for an xMatters connector + description: Defines secrets for connectors when type is `.xmatters`. + type: object + additionalProperties: true + create_connector_request_xmatters: + title: Create xMatters connector request + description: | + The xMatters connector uses the xMatters Workflow for Elastic to send actionable alerts to on-call xMatters resources. + type: object + required: + - config + - connector_type_id + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_xmatters' + connector_type_id: + type: string + description: The type of connector. + enum: + - .xmatters + example: .xmatters + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_xmatters' + is_deprecated: + type: boolean + description: Indicates whether the connector type is deprecated. + example: false + is_missing_secrets: + type: boolean + description: Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type. + example: false + is_preconfigured: + type: boolean + description: Indicates whether it is a preconfigured connector. If true, the `config` and `is_missing_secrets` properties are omitted from the response. + example: false + connector_response_properties_cases_webhook: + title: Connector request properties for a Webhook - Case Management connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_cases_webhook' + connector_type_id: + description: The type of connector. + type: string + enum: + - .cases-webhook + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_email: + title: Connector response properties for an email connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_email' + connector_type_id: + type: string + description: The type of connector. + enum: + - .email + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_index: + title: Connector response properties for an index connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_index' + connector_type_id: + type: string + description: The type of connector. + enum: + - .index + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_jira: + title: Connector response properties for a Jira connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_jira' + connector_type_id: + type: string + description: The type of connector. + enum: + - .jira + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_opsgenie: + title: Connector response properties for an Opsgenie connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_opsgenie' + connector_type_id: + type: string + description: The type of connector. + enum: + - .opsgenie + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_pagerduty: + title: Connector response properties for a PagerDuty connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_pagerduty' + connector_type_id: + type: string + description: The type of connector. + enum: + - .pagerduty + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_resilient: + title: Connector response properties for a IBM Resilient connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_resilient' + connector_type_id: + type: string + description: The type of connector. + enum: + - .resilient + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_serverlog: + title: Connector response properties for a server log connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + type: object + nullable: true + connector_type_id: + type: string + description: The type of connector. + enum: + - .server-log + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_servicenow: + title: Connector response properties for a ServiceNow ITSM connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_servicenow_itom: + title: Connector response properties for a ServiceNow ITOM connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow_itom' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-itom + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_servicenow_sir: + title: Connector response properties for a ServiceNow SecOps connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-sir + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_slack: + title: Connector response properties for a Slack connector + type: object + required: + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .slack + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_swimlane: + title: Connector response properties for a Swimlane connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_swimlane' + connector_type_id: + type: string + description: The type of connector. + enum: + - .swimlane + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_teams: + title: Connector response properties for a Microsoft Teams connector + type: object + required: + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .teams + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_tines: + title: Connector response properties for a Tines connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_tines' + connector_type_id: + type: string + description: The type of connector. + enum: + - .tines + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_webhook: + title: Connector response properties for a Webhook connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_webhook' + connector_type_id: + type: string + description: The type of connector. + enum: + - .webhook + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties_xmatters: + title: Connector response properties for an xMatters connector + type: object + required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name + properties: + config: + $ref: '#/components/schemas/config_properties_xmatters' + connector_type_id: + type: string + description: The type of connector. + enum: + - .xmatters + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: '#/components/schemas/is_deprecated' + is_missing_secrets: + $ref: '#/components/schemas/is_missing_secrets' + is_preconfigured: + $ref: '#/components/schemas/is_preconfigured' + name: + type: string + description: The display name for the connector. + connector_response_properties: + title: Connector response properties + description: The properties vary depending on the connector type. + oneOf: + - $ref: '#/components/schemas/connector_response_properties_cases_webhook' + - $ref: '#/components/schemas/connector_response_properties_email' + - $ref: '#/components/schemas/connector_response_properties_index' + - $ref: '#/components/schemas/connector_response_properties_jira' + - $ref: '#/components/schemas/connector_response_properties_opsgenie' + - $ref: '#/components/schemas/connector_response_properties_pagerduty' + - $ref: '#/components/schemas/connector_response_properties_resilient' + - $ref: '#/components/schemas/connector_response_properties_serverlog' + - $ref: '#/components/schemas/connector_response_properties_servicenow' + - $ref: '#/components/schemas/connector_response_properties_servicenow_itom' + - $ref: '#/components/schemas/connector_response_properties_servicenow_sir' + - $ref: '#/components/schemas/connector_response_properties_slack' + - $ref: '#/components/schemas/connector_response_properties_swimlane' + - $ref: '#/components/schemas/connector_response_properties_teams' + - $ref: '#/components/schemas/connector_response_properties_tines' + - $ref: '#/components/schemas/connector_response_properties_webhook' + - $ref: '#/components/schemas/connector_response_properties_xmatters' + discriminator: + propertyName: connector_type_id + update_connector_request_cases_webhook: + title: Update Webhook - Case Managment connector request + type: object + required: + - config + - name + properties: + config: + $ref: '#/components/schemas/config_properties_cases_webhook' + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_cases_webhook' + update_connector_request_index: + title: Update index connector request + type: object + required: + - config + - name + properties: + config: + $ref: '#/components/schemas/config_properties_index' + name: + type: string + description: The display name for the connector. + update_connector_request_jira: + title: Update Jira connector request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_jira' + name: + type: string + description: The display name for the connector. + secrets: + $ref: '#/components/schemas/secrets_properties_jira' + update_connector_request_opsgenie: + title: Update Opsgenie connector request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_opsgenie' + name: + type: string + description: The display name for the connector. + secrets: + $ref: '#/components/schemas/secrets_properties_opsgenie' + update_connector_request_resilient: + title: Update IBM Resilient connector request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_resilient' + name: + type: string + description: The display name for the connector. + secrets: + $ref: '#/components/schemas/secrets_properties_resilient' + update_connector_request_serverlog: + title: Update server log connector request + type: object + required: + - name + properties: + name: + type: string + description: The display name for the connector. + update_connector_request_servicenow: + title: Update ServiceNow ITSM connector or ServiceNow SecOps request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow' + name: + type: string + description: The display name for the connector. + secrets: + $ref: '#/components/schemas/secrets_properties_servicenow' + update_connector_request_servicenow_itom: + title: Create ServiceNow ITOM connector request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_servicenow_itom' + name: + type: string + description: The display name for the connector. + secrets: + $ref: '#/components/schemas/secrets_properties_servicenow' + update_connector_request_swimlane: + title: Update Swimlane connector request + type: object + required: + - config + - name + - secrets + properties: + config: + $ref: '#/components/schemas/config_properties_swimlane' + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: '#/components/schemas/secrets_properties_swimlane' connector_types: + title: Connector types type: string description: The type of connector. For example, `.email`, `.index`, `.jira`, `.opsgenie`, or `.server-log`. enum: @@ -262,18 +2101,6 @@ components: - .webhook - .xmatters example: .server-log - is_deprecated: - type: boolean - description: Indicates whether the connector type is deprecated. - example: false - is_missing_secrets: - type: boolean - description: Indicates whether secrets are missing for the connector. Secrets configuration properties vary depending on the connector type. - example: false - is_preconfigured: - type: boolean - description: Indicates whether it is a preconfigured connector. If true, the `config` and `is_missing_secrets` properties are omitted from the response. - example: false features: type: string description: | @@ -284,6 +2111,26 @@ components: - uptime - siem examples: + create_index_connector_request: + summary: Create an index connector. + value: + name: my-connector + connector_type_id: .index + config: + index: test-index + create_index_connector_response: + summary: A new index connector. + value: + id: c55b6eb0-6bad-11eb-9f3b-611eebc6c3ad + connector_type_id: .index + name: my-connector + config: + index: test-index + refresh: false + executionTimeField: null + is_preconfigured: false + is_deprecated: false + is_missing_secrets: false get_connector_response: summary: A list of connector types value: @@ -294,6 +2141,12 @@ components: is_preconfigured: false is_deprecated: false is_missing_secrets: false + update_index_connector_request: + summary: Update an index connector. + value: + name: updated-connector + config: + index: updated-index get_connectors_response: summary: A list of connectors value: diff --git a/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_request.yaml b/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_request.yaml new file mode 100644 index 0000000000000..3a0a3daa043dd --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_request.yaml @@ -0,0 +1,6 @@ +summary: Create an index connector. +value: + name: my-connector + connector_type_id: .index + config: + index: test-index \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_response.yaml b/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_response.yaml new file mode 100644 index 0000000000000..4d13a5d413598 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/examples/create_index_connector_response.yaml @@ -0,0 +1,12 @@ +summary: A new index connector. +value: + id: c55b6eb0-6bad-11eb-9f3b-611eebc6c3ad + connector_type_id: .index + name: my-connector + config: + index: test-index + refresh: false + executionTimeField: null + is_preconfigured: false + is_deprecated: false + is_missing_secrets: false \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/examples/update_index_connector_request.yaml b/x-pack/plugins/actions/docs/openapi/components/examples/update_index_connector_request.yaml new file mode 100644 index 0000000000000..79b9463a6be51 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/examples/update_index_connector_request.yaml @@ -0,0 +1,5 @@ +summary: Update an index connector. +value: + name: updated-connector + config: + index: updated-index \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_cases_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_cases_webhook.yaml new file mode 100644 index 0000000000000..43945fbb241a2 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_cases_webhook.yaml @@ -0,0 +1,135 @@ +title: Connector request properties for Webhook - Case Management connector +required: + - createIncidentJson + - createIncidentResponseKey + - createIncidentUrl + - getIncidentResponseExternalTitleKey + - getIncidentUrl + - updateIncidentJson + - updateIncidentUrl + - viewIncidentUrl +description: Defines properties for connectors when type is `.cases-webhook`. +type: object +properties: + createCommentJson: + type: string + description: > + A JSON payload sent to the create comment URL to create a case comment. + You can use variables to add Kibana Cases data to the payload. + The required variable is `case.comment`. Due to Mustache template + variables (the text enclosed in triple braces, for example, + `{{{case.title}}}`), the JSON is not validated when you create the + connector. The JSON is validated once the Mustache variables have been + placed when the REST method runs. Manually ensure that the JSON is valid, + disregarding the Mustache variables, so the later validation will pass. + example: {"body": {{{case.comment}}}} + createCommentMethod: + type: string + description: > + The REST API HTTP request method to create a case comment in the + third-party system. Valid values are `patch`, `post`, and `put`. + default: put + enum: + - patch + - post + - put + createCommentUrl: + type: string + description: > + The REST API URL to create a case comment by ID in the third-party system. + You can use a variable to add the external system ID to the URL. If you + are using the `xpack.actions.allowedHosts setting`, add the hostname to + the allowed hosts. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}}/comment + createIncidentJson: + type: string + description: > + A JSON payload sent to the create case URL to create a case. You can use + variables to add case data to the payload. Required variables are + `case.title` and `case.description`. Due to Mustache template variables + (which is the text enclosed in triple braces, for example, + `{{{case.title}}}`), the JSON is not validated when you create the + connector. The JSON is validated after the Mustache variables have been + placed when REST method runs. Manually ensure that the JSON is valid to + avoid future validation errors; disregard Mustache variables during your review. + example: {"fields": {"summary": {{{case.title}}},"description": {{{case.description}}},"labels": {{{case.tags}}}}} + createIncidentMethod: + type: string + description: > + The REST API HTTP request method to create a case in the third-party + system. Valid values are `patch`, `post`, and `put`. + enum: + - patch + - post + - put + default: post + createIncidentResponseKey: + type: string + description: The JSON key in the create case response that contains the external case ID. + createIncidentUrl: + type: string + description: > + The REST API URL to create a case in the third-party system. If you are + using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + getIncidentResponseExternalTitleKey: + type: string + description: The JSON key in get case response that contains the external case title. + getIncidentUrl: + type: string + description: > + The REST API URL to get the case by ID from the third-party system. If you + are using the `xpack.actions.allowedHosts` setting, add the hostname to + the allowed hosts. You can use a variable to add the external system ID to + the URL. Due to Mustache template variables (the text enclosed in triple + braces, for example, `{{{case.title}}}`), the JSON is not validated when + you create the connector. The JSON is validated after the Mustache + variables have been placed when REST method runs. Manually ensure that the + JSON is valid, disregarding the Mustache variables, so the later + validation will pass. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.id}}} + hasAuth: + type: boolean + description: If true, a username and password for login type authentication must be provided. + default: true + headers: + type: string + description: > + A set of key-value pairs sent as headers with the request URLs for the + create case, update case, get case, and create comment methods. + updateIncidentJson: + type: string + description: > + The JSON payload sent to the update case URL to update the case. You can + use variables to add Kibana Cases data to the payload. Required variables + are `case.title` and `case.description`. Due to Mustache template + variables (which is the text enclosed in triple braces, for example, + `{{{case.title}}}`), the JSON is not validated when you create the + connector. The JSON is validated after the Mustache variables have been + placed when REST method runs. Manually ensure that the JSON is valid to + avoid future validation errors; disregard Mustache variables during your review. + example: {"fields": {"summary": {{{case.title}}},"description": {{{case.description}}},"labels": {{{case.tags}}}}} + updateIncidentMethod: + type: string + description: > + The REST API HTTP request method to update the case in the third-party + system. Valid values are `patch`, `post`, and `put`. + default: put + enum: + - patch + - post + - put + updateIncidentUrl: + type: string + description: > + The REST API URL to update the case by ID in the third-party system. You + can use a variable to add the external system ID to the URL. If you are + using the `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + example: https://testing-jira.atlassian.net/rest/api/2/issue/{{{external.system.ID}}} + viewIncidentUrl: + type: string + description: > + The URL to view the case in the external system. You can use variables to + add the external system ID or external system title to the URL. + example: https://testing-jira.atlassian.net/browse/{{{external.system.title}}} + + diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_email.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_email.yaml new file mode 100644 index 0000000000000..d87c36be08936 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_email.yaml @@ -0,0 +1,5 @@ +title: Connector request properties for an email connector +description: Defines properties for connectors when type is `.email`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_index.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_index.yaml new file mode 100644 index 0000000000000..c82f775fe15dc --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_index.yaml @@ -0,0 +1,21 @@ +title: Connector request properties for an index connector +required: + - index +description: Defines properties for connectors when type is `.index`. +type: object +properties: + executionTimeField: + description: Specifies a field that will contain the time the alert condition was detected. + default: null + type: string + nullable: true + index: + description: The Elasticsearch index to be written to. + type: string + refresh: + description: > + The refresh policy for the write request, which affects when changes are + made visible to search. Refer to the refresh setting for Elasticsearch + document APIs. + default: false + type: boolean diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_jira.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_jira.yaml new file mode 100644 index 0000000000000..1634eb83cbf59 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_jira.yaml @@ -0,0 +1,13 @@ +title: Connector request properties for a Jira connector +required: + - apiUrl + - projectKey +description: Defines properties for connectors when type is `.jira`. +type: object +properties: + apiUrl: + description: The Jira instance URL. + type: string + projectKey: + description: The Jira project key. + type: string diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_opsgenie.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_opsgenie.yaml new file mode 100644 index 0000000000000..504d536cbde3e --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_opsgenie.yaml @@ -0,0 +1,12 @@ +title: Connector request properties for an Opsgenie connector +required: + - apiUrl +description: Defines properties for connectors when type is `.opsgenie`. +type: object +properties: + apiUrl: + description: > + The Opsgenie URL. For example, `https://api.opsgenie.com` or + `https://api.eu.opsgenie.com`. If you are using the + `xpack.actions.allowedHosts` setting, add the hostname to the allowed hosts. + type: string \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_pagerduty.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_pagerduty.yaml new file mode 100644 index 0000000000000..c9a98a9619d85 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_pagerduty.yaml @@ -0,0 +1,5 @@ +title: Connector request properties for a PagerDuty connector +description: Defines properties for connectors when type is `.pagerduty`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_resilient.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_resilient.yaml new file mode 100644 index 0000000000000..444be13ce4885 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_resilient.yaml @@ -0,0 +1,13 @@ +title: Connector request properties for a IBM Resilient connector +required: + - apiUrl + - orgId +description: Defines properties for connectors when type is `.resilient`. +type: object +properties: + apiUrl: + description: The IBM Resilient instance URL. + type: string + orgId: + description: The IBM Resilient organization ID. + type: string \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow.yaml new file mode 100644 index 0000000000000..f7013535f2e51 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow.yaml @@ -0,0 +1,41 @@ +title: Connector request properties for a ServiceNow ITSM connector +required: + - apiUrl +description: Defines properties for connectors when type is `.servicenow`. +type: object +properties: + apiUrl: + type: string + description: The ServiceNow instance URL. + clientId: + description: > + The client ID assigned to your OAuth application. + This property is required when `isOAuth` is `true`. + type: string + isOAuth: + description: > + The type of authentication to use. The default value is false, which means + basic authentication is used instead of open authorization (OAuth). + default: false + type: string + jwtKeyId: + description: > + The key identifier assigned to the JWT verifier map of your OAuth application. + This property is required when `isOAuth` is `true`. + type: string + userIdentifierValue: + description: > + The identifier to use for OAuth authentication. This identifier should be + the user field you selected when you created an OAuth JWT API endpoint for + external clients in your ServiceNow instance. For example, if the selected + user field is `Email`, the user identifier should be the user's email + address. This property is required when `isOAuth` is `true`. + type: string + usesTableApi: + description: > + Determines whether the connector uses the Table API or the Import Set API. + This property is supported only for ServiceNow ITSM and ServiceNow SecOps + connectors. NOTE: If this property is set to `false`, the Elastic + application should be installed in ServiceNow. + default: true + type: boolean \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow_itom.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow_itom.yaml new file mode 100644 index 0000000000000..f35f96629c861 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_servicenow_itom.yaml @@ -0,0 +1,33 @@ +title: Connector request properties for a ServiceNow ITSM connector +required: + - apiUrl +description: Defines properties for connectors when type is `.servicenow`. +type: object +properties: + apiUrl: + type: string + description: The ServiceNow instance URL. + clientId: + description: > + The client ID assigned to your OAuth application. + This property is required when `isOAuth` is `true`. + type: string + isOAuth: + description: > + The type of authentication to use. The default value is false, which means + basic authentication is used instead of open authorization (OAuth). + default: false + type: string + jwtKeyId: + description: > + The key identifier assigned to the JWT verifier map of your OAuth application. + This property is required when `isOAuth` is `true`. + type: string + userIdentifierValue: + description: > + The identifier to use for OAuth authentication. This identifier should be + the user field you selected when you created an OAuth JWT API endpoint for + external clients in your ServiceNow instance. For example, if the selected + user field is `Email`, the user identifier should be the user's email + address. This property is required when `isOAuth` is `true`. + type: string \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_swimlane.yaml new file mode 100644 index 0000000000000..905112276acbe --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_swimlane.yaml @@ -0,0 +1,103 @@ +title: Connector request properties for a Swimlane connector +required: + - apiUrl + - appId + - connectorType +description: Defines properties for connectors when type is `.swimlane`. +type: object +properties: + apiUrl: + description: The Swimlane instance URL. + type: string + appId: + description: The Swimlane application ID. + type: string + connectorType: + description: The type of connector. Valid values are `all`, `alerts`, and `cases`. + type: string + enum: + - all + - alerts + - cases + mappings: + title: Connector mappings properties for a Swimlane connector + description: The field mapping. + type: object + properties: + alertIdConfig: + title: Alert identifier mapping + description: Mapping for the alert ID. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + caseIdConfig: + title: Case identifier mapping + description: Mapping for the case ID. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + caseNameConfig: + title: Case name mapping + description: Mapping for the case name. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + commentsConfig: + title: Case comment mapping + description: Mapping for the case comments. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + descriptionConfig: + title: Case description mapping + description: Mapping for the case description. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + ruleNameConfig: + title: Rule name mapping + description: Mapping for the name of the alert's rule. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' + severityConfig: + title: Severity mapping + description: Mapping for the severity. + type: object + required: + - fieldType + - id + - key + - name + properties: + $ref: 'mapping_properties_swimlane.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_tines.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_tines.yaml new file mode 100644 index 0000000000000..336a312d9ac8e --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_tines.yaml @@ -0,0 +1,5 @@ +title: Connector request properties for a Tines connector +description: Defines properties for connectors when type is `.tines`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_webhook.yaml new file mode 100644 index 0000000000000..6fffd356527af --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_webhook.yaml @@ -0,0 +1,5 @@ +title: Connector request properties for a Webhook connector +description: Defines properties for connectors when type is `.webhook`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_xmatters.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_xmatters.yaml new file mode 100644 index 0000000000000..6625eb09b4d35 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/config_properties_xmatters.yaml @@ -0,0 +1,5 @@ +title: Connector request properties for a xMatters connector +description: Defines properties for connectors when type is `.xmatters`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties.yaml new file mode 100644 index 0000000000000..b73584568df6b --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties.yaml @@ -0,0 +1,22 @@ +title: Connector response properties +description: The properties vary depending on the connector type. +oneOf: + - $ref: 'connector_response_properties_cases_webhook.yaml' + - $ref: 'connector_response_properties_email.yaml' + - $ref: 'connector_response_properties_index.yaml' + - $ref: 'connector_response_properties_jira.yaml' + - $ref: 'connector_response_properties_opsgenie.yaml' + - $ref: 'connector_response_properties_pagerduty.yaml' + - $ref: 'connector_response_properties_resilient.yaml' + - $ref: 'connector_response_properties_serverlog.yaml' + - $ref: 'connector_response_properties_servicenow.yaml' + - $ref: 'connector_response_properties_servicenow_itom.yaml' + - $ref: 'connector_response_properties_servicenow_sir.yaml' + - $ref: 'connector_response_properties_slack.yaml' + - $ref: 'connector_response_properties_swimlane.yaml' + - $ref: 'connector_response_properties_teams.yaml' + - $ref: 'connector_response_properties_tines.yaml' + - $ref: 'connector_response_properties_webhook.yaml' + - $ref: 'connector_response_properties_xmatters.yaml' +discriminator: + propertyName: connector_type_id diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_cases_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_cases_webhook.yaml new file mode 100644 index 0000000000000..88611b62b2c99 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_cases_webhook.yaml @@ -0,0 +1,29 @@ +title: Connector request properties for a Webhook - Case Management connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_cases_webhook.yaml' + connector_type_id: + description: The type of connector. + type: string + enum: + - .cases-webhook + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_email.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_email.yaml new file mode 100644 index 0000000000000..62dac0309889e --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_email.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for an email connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_email.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .email + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_index.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_index.yaml new file mode 100644 index 0000000000000..d78d609a09b9d --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_index.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for an index connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_index.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .index + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_jira.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_jira.yaml new file mode 100644 index 0000000000000..5ff5807e200a8 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_jira.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a Jira connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_jira.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .jira + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_opsgenie.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_opsgenie.yaml new file mode 100644 index 0000000000000..850454db1a3ad --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_opsgenie.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for an Opsgenie connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_opsgenie.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .opsgenie + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_pagerduty.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_pagerduty.yaml new file mode 100644 index 0000000000000..137108efd3e14 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_pagerduty.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a PagerDuty connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_pagerduty.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .pagerduty + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_resilient.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_resilient.yaml new file mode 100644 index 0000000000000..9250c4157c660 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_resilient.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a IBM Resilient connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_resilient.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .resilient + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_serverlog.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_serverlog.yaml new file mode 100644 index 0000000000000..999a8f375d117 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_serverlog.yaml @@ -0,0 +1,30 @@ +title: Connector response properties for a server log connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + type: object + nullable: true + connector_type_id: + type: string + description: The type of connector. + enum: + - .server-log + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow.yaml new file mode 100644 index 0000000000000..a5f9d1afa0077 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a ServiceNow ITSM connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_servicenow.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_itom.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_itom.yaml new file mode 100644 index 0000000000000..812d367cfb17c --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_itom.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a ServiceNow ITOM connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_servicenow_itom.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-itom + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_sir.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_sir.yaml new file mode 100644 index 0000000000000..ff99f5682f129 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_servicenow_sir.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a ServiceNow SecOps connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_servicenow.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-sir + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_slack.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_slack.yaml new file mode 100644 index 0000000000000..d0254e0518316 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_slack.yaml @@ -0,0 +1,26 @@ +title: Connector response properties for a Slack connector +type: object +required: + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .slack + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_swimlane.yaml new file mode 100644 index 0000000000000..421abcf666038 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_swimlane.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a Swimlane connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_swimlane.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .swimlane + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_teams.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_teams.yaml new file mode 100644 index 0000000000000..bafc86f2b2977 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_teams.yaml @@ -0,0 +1,26 @@ +title: Connector response properties for a Microsoft Teams connector +type: object +required: + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .teams + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_tines.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_tines.yaml new file mode 100644 index 0000000000000..f89f85a30cd4f --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_tines.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a Tines connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_tines.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .tines + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_webhook.yaml new file mode 100644 index 0000000000000..011c39abd7ae0 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_webhook.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for a Webhook connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_webhook.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .webhook + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_xmatters.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_xmatters.yaml new file mode 100644 index 0000000000000..6476adb1ab937 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_response_properties_xmatters.yaml @@ -0,0 +1,29 @@ +title: Connector response properties for an xMatters connector +type: object +required: + - config + - connector_type_id + - id + - is_deprecated + - is_preconfigured + - name +properties: + config: + $ref: 'config_properties_xmatters.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .xmatters + id: + type: string + description: The identifier for the connector. + is_deprecated: + $ref: 'is_deprecated.yaml' + is_missing_secrets: + $ref: 'is_missing_secrets.yaml' + is_preconfigured: + $ref: 'is_preconfigured.yaml' + name: + type: string + description: The display name for the connector. diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_types.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_types.yaml index 1923096b858c7..fed928120b395 100644 --- a/x-pack/plugins/actions/docs/openapi/components/schemas/connector_types.yaml +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/connector_types.yaml @@ -1,3 +1,4 @@ +title: Connector types type: string description: The type of connector. For example, `.email`, `.index`, `.jira`, `.opsgenie`, or `.server-log`. enum: diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_cases_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_cases_webhook.yaml new file mode 100644 index 0000000000000..bcbe840c03513 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_cases_webhook.yaml @@ -0,0 +1,24 @@ +title: Create Webhook - Case Managment connector request +description: > + The Webhook - Case Management connector uses axios to send POST, PUT, and GET + requests to a case management RESTful API web service. +type: object +required: + - config + - connector_type_id + - name +properties: + config: + $ref: 'config_properties_cases_webhook.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .cases-webhook + example: .cases-webhook + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_cases_webhook.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_email.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_email.yaml new file mode 100644 index 0000000000000..89f0b79c4e74b --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_email.yaml @@ -0,0 +1,27 @@ +title: Create email connector request +description: > + The email connector uses the SMTP protocol to send mail messages, using an + integration of Nodemailer. An exception is Microsoft Exchange, which uses + HTTP protocol for sending emails, Send mail. Email message text is sent as + both plain text and html text. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_email.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .email + example: .email + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_email.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_index.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_index.yaml new file mode 100644 index 0000000000000..26d6e118c1fe8 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_index.yaml @@ -0,0 +1,20 @@ +title: Create index connector request +description: The index connector indexes a document into Elasticsearch. +type: object +required: + - config + - connector_type_id + - name +properties: + config: + $ref: 'config_properties_index.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .index + example: .index + name: + type: string + description: The display name for the connector. + example: my-connector \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_jira.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_jira.yaml new file mode 100644 index 0000000000000..5b6077e875b24 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_jira.yaml @@ -0,0 +1,23 @@ +title: Create Jira connector request +description: The Jira connector uses the REST API v2 to create Jira issues. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_jira.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .jira + example: .jira + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_jira.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_opsgenie.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_opsgenie.yaml new file mode 100644 index 0000000000000..6de1296dac43c --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_opsgenie.yaml @@ -0,0 +1,23 @@ +title: Create Opsgenie connector request +description: The Opsgenie connector uses the Opsgenie alert API. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_opsgenie.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .opsgenie + example: .opsgenie + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_opsgenie.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_pagerduty.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_pagerduty.yaml new file mode 100644 index 0000000000000..498488299afd3 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_pagerduty.yaml @@ -0,0 +1,25 @@ +title: Create PagerDuty connector request +description: > + The PagerDuty connector uses the v2 Events API to trigger, acknowledge, and + resolve PagerDuty alerts. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_pagerduty.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .pagerduty + example: .pagerduty + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_pagerduty.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_resilient.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_resilient.yaml new file mode 100644 index 0000000000000..c3f766625b7da --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_resilient.yaml @@ -0,0 +1,23 @@ +title: Create IBM Resilient connector request +description: The IBM Resilient connector uses the RESILIENT REST v2 to create IBM Resilient incidents. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_resilient.yaml' + connector_type_id: + description: The type of connector. + type: string + example: .resilient + enum: + - .resilient + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_resilient.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_serverlog.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_serverlog.yaml new file mode 100644 index 0000000000000..eac0a0d65b69f --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_serverlog.yaml @@ -0,0 +1,17 @@ +title: Create server log connector request +description: This connector writes an entry to the Kibana server log. +type: object +required: + - connector_type_id + - name +properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .server-log + example: .server-log + name: + type: string + description: The display name for the connector. + example: my-connector \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow.yaml new file mode 100644 index 0000000000000..e03303dcada4f --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow.yaml @@ -0,0 +1,25 @@ +title: Create ServiceNow ITSM connector request +description: > + The ServiceNow ITSM connector uses the import set API to create ServiceNow incidents. + You can use the connector for rule actions and cases. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_servicenow.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow + example: .servicenow + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_servicenow.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_itom.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_itom.yaml new file mode 100644 index 0000000000000..70a4c05c96522 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_itom.yaml @@ -0,0 +1,25 @@ +title: Create ServiceNow ITOM connector request +description: > + The ServiceNow ITOM connector uses the event API to create ServiceNow events. + You can use the connector for rule actions. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_servicenow_itom.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-itom + example: .servicenow-itom + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_servicenow.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_sir.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_sir.yaml new file mode 100644 index 0000000000000..4d247c456f3e6 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_servicenow_sir.yaml @@ -0,0 +1,25 @@ +title: Create ServiceNow SecOps connector request +description: > + The ServiceNow SecOps connector uses the import set API to create ServiceNow security incidents. + You can use the connector for rule actions and cases. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_servicenow.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .servicenow-sir + example: .servicenow-sir + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_servicenow.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_slack.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_slack.yaml new file mode 100644 index 0000000000000..0634d48b543a1 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_slack.yaml @@ -0,0 +1,20 @@ +title: Create Slack connector request +description: The Slack connector uses Slack Incoming Webhooks. +type: object +required: + - connector_type_id + - name + - secrets +properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .slack + example: .slack + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_slack.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_swimlane.yaml new file mode 100644 index 0000000000000..3de4f5ecbccef --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_swimlane.yaml @@ -0,0 +1,23 @@ +title: Create Swimlane connector request +description: The Swimlane connector uses the Swimlane REST API to create Swimlane records. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_swimlane.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .swimlane + example: .swimlane + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_swimlane.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_teams.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_teams.yaml new file mode 100644 index 0000000000000..5e0d449bf5546 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_teams.yaml @@ -0,0 +1,20 @@ +title: Create Microsoft Teams connector request +description: The Microsoft Teams connector uses Incoming Webhooks. +type: object +required: + - connector_type_id + - name + - secrets +properties: + connector_type_id: + type: string + description: The type of connector. + enum: + - .teams + example: .teams + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_teams.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_tines.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_tines.yaml new file mode 100644 index 0000000000000..224c3e03c4363 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_tines.yaml @@ -0,0 +1,24 @@ +title: Create Tines connector request +description: > + The Tines connector uses Tines Webhook actions to send events via POST request. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_tines.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .tines + example: .tines + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_tines.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_webhook.yaml new file mode 100644 index 0000000000000..e0ead115d48dc --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_webhook.yaml @@ -0,0 +1,24 @@ +title: Create Webhook connector request +description: > + The Webhook connector uses axios to send a POST or PUT request to a web service. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_webhook.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .webhook + example: .webhook + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_webhook.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_xmatters.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_xmatters.yaml new file mode 100644 index 0000000000000..13213d39561b2 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/create_connector_request_xmatters.yaml @@ -0,0 +1,25 @@ +title: Create xMatters connector request +description: > + The xMatters connector uses the xMatters Workflow for Elastic to send + actionable alerts to on-call xMatters resources. +type: object +required: + - config + - connector_type_id + - name + - secrets +properties: + config: + $ref: 'config_properties_xmatters.yaml' + connector_type_id: + type: string + description: The type of connector. + enum: + - .xmatters + example: .xmatters + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_xmatters.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/mapping_properties_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/mapping_properties_swimlane.yaml new file mode 100644 index 0000000000000..9adacdd102d58 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/mapping_properties_swimlane.yaml @@ -0,0 +1,13 @@ +fieldType: + type: string + description: The type of field in Swimlane. +id: + type: string + description: The identifier for the field in Swimlane. +key: + type: string + description: The key for the field in Swimlane. +name: + type: string + description: The name of the field in Swimlane. + \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_cases_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_cases_webhook.yaml new file mode 100644 index 0000000000000..571a88975a0e8 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_cases_webhook.yaml @@ -0,0 +1,9 @@ +title: Connector secrets properties for Webhook - Case Management connector +type: object +properties: + password: + type: string + description: The password for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required. + user: + type: string + description: The username for HTTP basic authentication. If `hasAuth` is set to `true`, this property is required. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_email.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_email.yaml new file mode 100644 index 0000000000000..04a3526b72ce3 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_email.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for an email connector +description: Defines secrets for connectors when type is `.email`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_jira.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_jira.yaml new file mode 100644 index 0000000000000..dba25d0646ae8 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_jira.yaml @@ -0,0 +1,13 @@ +title: Connector secrets properties for a Jira connector +required: + - apiToken + - email +description: Defines secrets for connectors when type is `.jira`. +type: object +properties: + apiToken: + description: The Jira API authentication token for HTTP basic authentication. + type: string + email: + description: The account email for HTTP Basic authentication. + type: string diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_opsgenie.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_opsgenie.yaml new file mode 100644 index 0000000000000..fc827886e3136 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_opsgenie.yaml @@ -0,0 +1,9 @@ +title: Connector secrets properties for an Opsgenie connector +required: + - apiKey +description: Defines secrets for connectors when type is `.opsgenie`. +type: object +properties: + apiKey: + description: The Opsgenie API authentication key for HTTP Basic authentication. + type: string \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_pagerduty.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_pagerduty.yaml new file mode 100644 index 0000000000000..14d0c6fbefd69 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_pagerduty.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for a PagerDuty connector +description: Defines secrets for connectors when type is `.pagerduty`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_resilient.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_resilient.yaml new file mode 100644 index 0000000000000..c4500a208ee94 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_resilient.yaml @@ -0,0 +1,13 @@ +title: Connector secrets properties for IBM Resilient connector +required: + - apiKeyId + - apiKeySecret +description: Defines secrets for connectors when type is `.resilient`. +type: object +properties: + apiKeyId: + type: string + description: The authentication key ID for HTTP Basic authentication. + apiKeySecret: + type: string + description: The authentication key secret for HTTP Basic authentication. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_servicenow.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_servicenow.yaml new file mode 100644 index 0000000000000..ed70fa840ecc0 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_servicenow.yaml @@ -0,0 +1,19 @@ +title: Connector secrets properties for ServiceNow ITOM, ServiceNow ITSM, and ServiceNow SecOps connectors +description: Defines secrets for connectors when type is `.servicenow`, `.servicenow-sir`, or `.servicenow-itom`. +type: object +properties: + clientSecret: + type: string + description: The client secret assigned to your OAuth application. This property is required when `isOAuth` is `true`. + password: + type: string + description: The password for HTTP basic authentication. This property is required when `isOAuth` is `false`. + privateKey: + type: string + description: The RSA private key that you created for use in ServiceNow. This property is required when `isOAuth` is `true`. + privateKeyPassword: + type: string + description: The password for the RSA private key. This property is required when `isOAuth` is `true` and you set a password on your private key. + username: + type: string + description: The username for HTTP basic authentication. This property is required when `isOAuth` is `false`. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_slack.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_slack.yaml new file mode 100644 index 0000000000000..4a681e8a195f3 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_slack.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for a Slack connector +description: Defines secrets for connectors when type is `.slack`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_swimlane.yaml new file mode 100644 index 0000000000000..e9cf5679b0c45 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_swimlane.yaml @@ -0,0 +1,7 @@ +title: Connector secrets properties for a Swimlane connector +description: Defines secrets for connectors when type is `.swimlane`. +type: object +properties: + apiToken: + description: Swimlane API authentication token. + type: string \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_teams.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_teams.yaml new file mode 100644 index 0000000000000..f5e3aa51c7528 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_teams.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for a Microsoft Teams connector +description: Defines secrets for connectors when type is `.teams`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_tines.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_tines.yaml new file mode 100644 index 0000000000000..2373f14beae50 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_tines.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for a Tines connector +description: Defines secrets for connectors when type is `.tines`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_webhook.yaml new file mode 100644 index 0000000000000..5a465932fb898 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_webhook.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for a Webhook connector +description: Defines secrets for connectors when type is `.webhook`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_xmatters.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_xmatters.yaml new file mode 100644 index 0000000000000..67071884663dd --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/secrets_properties_xmatters.yaml @@ -0,0 +1,5 @@ +title: Connector secrets properties for an xMatters connector +description: Defines secrets for connectors when type is `.xmatters`. +type: object +additionalProperties: true +# TO-DO: Add the properties for this connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_cases_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_cases_webhook.yaml new file mode 100644 index 0000000000000..66250b31a94eb --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_cases_webhook.yaml @@ -0,0 +1,14 @@ +title: Update Webhook - Case Managment connector request +type: object +required: + - config + - name +properties: + config: + $ref: 'config_properties_cases_webhook.yaml' + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_cases_webhook.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_email.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_email.yaml new file mode 100644 index 0000000000000..b52ba071bef53 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_email.yaml @@ -0,0 +1,13 @@ +title: Update email connector request +type: object +required: + - config + - name +properties: + config: + $ref: 'config_properties_email.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_email.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_index.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_index.yaml new file mode 100644 index 0000000000000..3fe293832a39d --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_index.yaml @@ -0,0 +1,11 @@ +title: Update index connector request +type: object +required: + - config + - name +properties: + config: + $ref: 'config_properties_index.yaml' + name: + type: string + description: The display name for the connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_jira.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_jira.yaml new file mode 100644 index 0000000000000..009442e87182f --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_jira.yaml @@ -0,0 +1,14 @@ +title: Update Jira connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_jira.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_jira.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_opsgenie.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_opsgenie.yaml new file mode 100644 index 0000000000000..ee3c511242715 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_opsgenie.yaml @@ -0,0 +1,14 @@ +title: Update Opsgenie connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_opsgenie.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_opsgenie.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_pagerduty.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_pagerduty.yaml new file mode 100644 index 0000000000000..8906c84d3d604 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_pagerduty.yaml @@ -0,0 +1,14 @@ +title: Update PagerDuty connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_pagerduty.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_pagerduty.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_resilient.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_resilient.yaml new file mode 100644 index 0000000000000..4e3957af5fa78 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_resilient.yaml @@ -0,0 +1,14 @@ +title: Update IBM Resilient connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_resilient.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_resilient.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_serverlog.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_serverlog.yaml new file mode 100644 index 0000000000000..eec0e738ca726 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_serverlog.yaml @@ -0,0 +1,8 @@ +title: Update server log connector request +type: object +required: + - name +properties: + name: + type: string + description: The display name for the connector. \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow.yaml new file mode 100644 index 0000000000000..a2fd56c21558e --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow.yaml @@ -0,0 +1,14 @@ +title: Update ServiceNow ITSM connector or ServiceNow SecOps request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_servicenow.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_servicenow.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow_itom.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow_itom.yaml new file mode 100644 index 0000000000000..81b3220bbbeb3 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_servicenow_itom.yaml @@ -0,0 +1,14 @@ +title: Create ServiceNow ITOM connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_servicenow_itom.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_servicenow.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_slack.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_slack.yaml new file mode 100644 index 0000000000000..6e1bf95b3944a --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_slack.yaml @@ -0,0 +1,11 @@ +title: Update Slack connector request +type: object +required: + - name + - secrets +properties: + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_slack.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_swimlane.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_swimlane.yaml new file mode 100644 index 0000000000000..81321351b74ec --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_swimlane.yaml @@ -0,0 +1,15 @@ +title: Update Swimlane connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_swimlane.yaml' + name: + type: string + description: The display name for the connector. + example: my-connector + secrets: + $ref: 'secrets_properties_swimlane.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_teams.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_teams.yaml new file mode 100644 index 0000000000000..37a1741474ea5 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_teams.yaml @@ -0,0 +1,11 @@ +title: Update Microsoft Teams connector request +type: object +required: + - name + - secrets +properties: + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_teams.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_tines.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_tines.yaml new file mode 100644 index 0000000000000..8572f474d8bd6 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_tines.yaml @@ -0,0 +1,14 @@ +title: Update Tines connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_tines.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_tines.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_webhook.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_webhook.yaml new file mode 100644 index 0000000000000..6023a6795ae80 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_webhook.yaml @@ -0,0 +1,14 @@ +title: Update Webhook connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_webhook.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_webhook.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_xmatters.yaml b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_xmatters.yaml new file mode 100644 index 0000000000000..de3e962bc7543 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/components/schemas/update_connector_request_xmatters.yaml @@ -0,0 +1,14 @@ +title: Update xMatters connector request +type: object +required: + - config + - name + - secrets +properties: + config: + $ref: 'config_properties_xmatters.yaml' + name: + type: string + description: The display name for the connector. + secrets: + $ref: 'secrets_properties_xmatters.yaml' \ No newline at end of file diff --git a/x-pack/plugins/actions/docs/openapi/entrypoint.yaml b/x-pack/plugins/actions/docs/openapi/entrypoint.yaml index c85da6d4d51ae..98a50c7304d58 100644 --- a/x-pack/plugins/actions/docs/openapi/entrypoint.yaml +++ b/x-pack/plugins/actions/docs/openapi/entrypoint.yaml @@ -15,8 +15,8 @@ servers: - url: 'http://localhost:5601' description: local paths: -# '/s/{spaceId}/api/actions/connector': -# $ref: 'paths/s@{spaceid}@api@actions@connector.yaml' + '/s/{spaceId}/api/actions/connector': + $ref: 'paths/s@{spaceid}@api@actions@connector.yaml' '/s/{spaceId}/api/actions/connector/{connectorId}': $ref: 'paths/s@{spaceid}@api@actions@connector@{connectorid}.yaml' '/s/{spaceId}/api/actions/connectors': diff --git a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector.yaml b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector.yaml new file mode 100644 index 0000000000000..110f35c650e91 --- /dev/null +++ b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector.yaml @@ -0,0 +1,69 @@ +post: + summary: Creates a connector. + operationId: createConnector + description: > + You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges. + tags: + - connectors + parameters: + - $ref: ../components/headers/kbn_xsrf.yaml + - $ref: '../components/parameters/space_id.yaml' + requestBody: + required: true + content: + application/json: + schema: + title: Create connector request body properties + description: The properties vary depending on the connector type. + oneOf: + - $ref: '../components/schemas/create_connector_request_cases_webhook.yaml' + - $ref: '../components/schemas/create_connector_request_email.yaml' + - $ref: '../components/schemas/create_connector_request_index.yaml' + - $ref: '../components/schemas/create_connector_request_jira.yaml' + - $ref: '../components/schemas/create_connector_request_opsgenie.yaml' + - $ref: '../components/schemas/create_connector_request_pagerduty.yaml' + - $ref: '../components/schemas/create_connector_request_resilient.yaml' + - $ref: '../components/schemas/create_connector_request_serverlog.yaml' + - $ref: '../components/schemas/create_connector_request_servicenow.yaml' + - $ref: '../components/schemas/create_connector_request_servicenow_itom.yaml' + - $ref: '../components/schemas/create_connector_request_servicenow_sir.yaml' + - $ref: '../components/schemas/create_connector_request_slack.yaml' + - $ref: '../components/schemas/create_connector_request_swimlane.yaml' + - $ref: '../components/schemas/create_connector_request_teams.yaml' + - $ref: '../components/schemas/create_connector_request_tines.yaml' + - $ref: '../components/schemas/create_connector_request_webhook.yaml' + - $ref: '../components/schemas/create_connector_request_xmatters.yaml' + discriminator: + propertyName: connector_type_id + examples: + createIndexConnectorRequest: + $ref: '../components/examples/create_index_connector_request.yaml' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + $ref: '../components/schemas/connector_response_properties.yaml' + examples: + createIndexConnectorResponse: + $ref: '../components/examples/create_index_connector_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + servers: + - url: https://localhost:5601 +servers: + - url: https://localhost:5601 diff --git a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector@{connectorid}.yaml b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector@{connectorid}.yaml index 53df4bcdf78ce..c1cb7df5aa0f1 100644 --- a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector@{connectorid}.yaml +++ b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector@{connectorid}.yaml @@ -11,41 +11,44 @@ get: responses: '200': description: Indicates a successful call. + content: + application/json: + schema: + $ref: '../components/schemas/connector_response_properties.yaml' + examples: + getConnectorResponse: + $ref: '../components/examples/get_connector_response.yaml' + '401': + description: Authorization information is missing or invalid. content: application/json: schema: type: object - required: - - connector_type_id - - id - - is_deprecated - - is_preconfigured - - name properties: - config: - type: object - description: The configuration for the connector. Configuration properties vary depending on the connector type. - additionalProperties: true - nullable: true - connector_type_id: - $ref: '../components/schemas/connector_types.yaml' - id: + error: type: string - description: The identifier for the connector. - example: b0766e10-d190-11ec-b04c-776c77d14fca - is_deprecated: - $ref: '../components/schemas/is_deprecated.yaml' - is_missing_secrets: - $ref: '../components/schemas/is_missing_secrets.yaml' - is_preconfigured: - $ref: '../components/schemas/is_preconfigured.yaml' - name: + example: Unauthorized + message: type: string - description: The display name for the connector. - example: my-connector - examples: - getConnectorResponse: - $ref: '../components/examples/get_connector_response.yaml' + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + statusCode: + type: integer + example: 404 servers: - url: https://localhost:5601 @@ -64,6 +67,132 @@ delete: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + statusCode: + type: integer + example: 404 + servers: + - url: https://localhost:5601 + +put: + summary: Updates the attributes for a connector. + operationId: updateConnector + description: > + You must have `all` privileges for the **Actions and Connectors** feature in the **Management** section of the Kibana feature privileges. + tags: + - connectors + parameters: + - $ref: ../components/headers/kbn_xsrf.yaml + - $ref: '../components/parameters/connector_id.yaml' + - $ref: '../components/parameters/space_id.yaml' + requestBody: + required: true + content: + application/json: + schema: + title: Update connector request body properties + description: The properties vary depending on the connector type. + oneOf: + - $ref: '../components/schemas/update_connector_request_cases_webhook.yaml' +# - $ref: '../components/schemas/update_connector_request_email.yaml' + - $ref: '../components/schemas/update_connector_request_index.yaml' + - $ref: '../components/schemas/update_connector_request_jira.yaml' + - $ref: '../components/schemas/update_connector_request_opsgenie.yaml' +# - $ref: '../components/schemas/update_connector_request_pagerduty.yaml' + - $ref: '../components/schemas/update_connector_request_resilient.yaml' + - $ref: '../components/schemas/update_connector_request_serverlog.yaml' + - $ref: '../components/schemas/update_connector_request_servicenow.yaml' + - $ref: '../components/schemas/update_connector_request_servicenow_itom.yaml' +# - $ref: '../components/schemas/update_connector_request_slack.yaml' + - $ref: '../components/schemas/update_connector_request_swimlane.yaml' +# - $ref: '../components/schemas/update_connector_request_teams.yaml' +# - $ref: '../components/schemas/update_connector_request_tines.yaml' +# - $ref: '../components/schemas/update_connector_request_webhook.yaml' +# - $ref: '../components/schemas/update_connector_request_xmatters.yaml' + examples: + updateIndexConnectorRequest: + $ref: '../components/examples/update_index_connector_request.yaml' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + $ref: '../components/schemas/connector_response_properties.yaml' + '400': + description: Indicates a bad request. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Bad Request + message: + type: string + example: "error validating action type config: [index]: expected value of type [string] but got [undefined]" + statusCode: + type: integer + example: 400 + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + '404': + description: Object is not found. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Not Found + message: + type: string + example: "Saved object [action/baf33fc0-920c-11ed-b36a-874bd1548a00] not found" + statusCode: + type: integer + example: 404 servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector_types.yaml b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector_types.yaml index 5dcd403aea99c..001da54c13c14 100644 --- a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector_types.yaml +++ b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connector_types.yaml @@ -18,6 +18,8 @@ get: content: application/json: schema: + title: Get connector types response body properties + description: The properties vary for each connector type. type: array items: type: object @@ -56,6 +58,21 @@ get: examples: getConnectorTypesResponse: $ref: '../components/examples/get_connector_types_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connectors.yaml b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connectors.yaml index 36bd852c12f6f..2a0a075703f8a 100644 --- a/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connectors.yaml +++ b/x-pack/plugins/actions/docs/openapi/paths/s@{spaceid}@api@actions@connectors.yaml @@ -15,6 +15,8 @@ get: schema: type: array items: + title: Get connectors response body properties + description: The properties vary for each connector type. type: object required: - connector_type_id @@ -53,6 +55,21 @@ get: examples: getConnectorsResponse: $ref: '../components/examples/get_connectors_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + type: object + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/actions/server/actions_client.test.ts b/x-pack/plugins/actions/server/actions_client.test.ts index 79810d6cd8572..017b8f4d1b5ea 100644 --- a/x-pack/plugins/actions/server/actions_client.test.ts +++ b/x-pack/plugins/actions/server/actions_client.test.ts @@ -27,7 +27,7 @@ import { import { auditLoggerMock } from '@kbn/security-plugin/server/audit/mocks'; import { usageCountersServiceMock } from '@kbn/usage-collection-plugin/server/usage_counters/usage_counters_service.mock'; import { actionExecutorMock } from './lib/action_executor.mock'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ActionsAuthorization } from './authorization/actions_authorization'; import { getAuthorizationModeBySource, @@ -2193,7 +2193,7 @@ describe('execute()', () => { }); test('calls the actionExecutor with the appropriate parameters', async () => { - const actionId = uuid.v4(); + const actionId = uuidv4(); actionExecutor.execute.mockResolvedValue({ status: 'ok', actionId }); await expect( actionsClient.execute({ @@ -2285,7 +2285,7 @@ describe('enqueueExecution()', () => { return AuthorizationMode.RBAC; }); await actionsClient.enqueueExecution({ - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', @@ -2304,7 +2304,7 @@ describe('enqueueExecution()', () => { await expect( actionsClient.enqueueExecution({ - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', @@ -2321,7 +2321,7 @@ describe('enqueueExecution()', () => { }); await actionsClient.enqueueExecution({ - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', @@ -2337,7 +2337,7 @@ describe('enqueueExecution()', () => { test('calls the executionEnqueuer with the appropriate parameters', async () => { const opts = { - id: uuid.v4(), + id: uuidv4(), params: { baz: false }, spaceId: 'default', executionId: '123abc', @@ -2357,14 +2357,14 @@ describe('bulkEnqueueExecution()', () => { }); await actionsClient.bulkEnqueueExecution([ { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', apiKey: null, }, { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '456def', @@ -2385,14 +2385,14 @@ describe('bulkEnqueueExecution()', () => { await expect( actionsClient.bulkEnqueueExecution([ { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', apiKey: null, }, { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '456def', @@ -2411,14 +2411,14 @@ describe('bulkEnqueueExecution()', () => { await actionsClient.bulkEnqueueExecution([ { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', apiKey: null, }, { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '456def', @@ -2440,14 +2440,14 @@ describe('bulkEnqueueExecution()', () => { }); const opts = [ { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '123abc', apiKey: null, }, { - id: uuid.v4(), + id: uuidv4(), params: {}, spaceId: 'default', executionId: '456def', @@ -2565,6 +2565,6 @@ describe('isPreconfigured()', () => { }), }); - expect(actionsClient.isPreconfigured(uuid.v4())).toEqual(false); + expect(actionsClient.isPreconfigured(uuidv4())).toEqual(false); }); }); diff --git a/x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.test.ts b/x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.test.ts index 459997130cf64..199d8a97bd623 100644 --- a/x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.test.ts +++ b/x-pack/plugins/actions/server/authorization/get_authorization_mode_by_source.test.ts @@ -11,7 +11,7 @@ import { AuthorizationMode, } from './get_authorization_mode_by_source'; import { savedObjectsClientMock } from '@kbn/core/server/mocks'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { asSavedObjectExecutionSource } from '../lib'; const unsecuredSavedObjectsClient = savedObjectsClientMock.create(); @@ -29,14 +29,14 @@ describe(`#getAuthorizationModeBySource`, () => { unsecuredSavedObjectsClient, asSavedObjectExecutionSource({ type: 'action', - id: uuid.v4(), + id: uuidv4(), }) ) ).toEqual(AuthorizationMode.RBAC); }); test('should return RBAC if source alert is not marked as legacy', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.get.mockResolvedValue(mockAlert({ id })); expect( await getAuthorizationModeBySource( @@ -50,7 +50,7 @@ describe(`#getAuthorizationModeBySource`, () => { }); test('should return Legacy if source alert is marked as legacy', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.get.mockResolvedValue( mockAlert({ id, attributes: { meta: { versionApiKeyLastmodified: 'pre-7.10.0' } } }) ); @@ -66,7 +66,7 @@ describe(`#getAuthorizationModeBySource`, () => { }); test('should return RBAC if source alert is marked as modern', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.get.mockResolvedValue( mockAlert({ id, attributes: { meta: { versionApiKeyLastmodified: '7.10.0' } } }) ); @@ -82,7 +82,7 @@ describe(`#getAuthorizationModeBySource`, () => { }); test('should return RBAC if source alert doesnt have a last modified version', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.get.mockResolvedValue(mockAlert({ id, attributes: { meta: {} } })); expect( await getAuthorizationModeBySource( @@ -111,14 +111,14 @@ describe(`#getBulkAuthorizationModeBySource`, () => { await getBulkAuthorizationModeBySource(unsecuredSavedObjectsClient, [ asSavedObjectExecutionSource({ type: 'action', - id: uuid.v4(), + id: uuidv4(), }), ]) ).toEqual({ [AuthorizationMode.RBAC]: 1, [AuthorizationMode.Legacy]: 0 }); }); test('should return RBAC if source alert is not marked as legacy', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.bulkGet.mockResolvedValue({ saved_objects: [mockAlert({ id })] }); expect( await getBulkAuthorizationModeBySource(unsecuredSavedObjectsClient, [ @@ -131,7 +131,7 @@ describe(`#getBulkAuthorizationModeBySource`, () => { }); test('should return Legacy if source alert is marked as legacy', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.bulkGet.mockResolvedValue({ saved_objects: [ mockAlert({ id, attributes: { meta: { versionApiKeyLastmodified: 'pre-7.10.0' } } }), @@ -148,7 +148,7 @@ describe(`#getBulkAuthorizationModeBySource`, () => { }); test('should return RBAC if source alert is marked as modern', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.bulkGet.mockResolvedValue({ saved_objects: [ mockAlert({ id, attributes: { meta: { versionApiKeyLastmodified: '7.10.0' } } }), @@ -165,7 +165,7 @@ describe(`#getBulkAuthorizationModeBySource`, () => { }); test('should return RBAC if source alert doesnt have a last modified version', async () => { - const id = uuid.v4(); + const id = uuidv4(); unsecuredSavedObjectsClient.bulkGet.mockResolvedValue({ saved_objects: [mockAlert({ id, attributes: { meta: {} } })], }); diff --git a/x-pack/plugins/actions/server/create_execute_function.test.ts b/x-pack/plugins/actions/server/create_execute_function.test.ts index 6e1c9aded6a3d..8147e14d2a943 100644 --- a/x-pack/plugins/actions/server/create_execute_function.test.ts +++ b/x-pack/plugins/actions/server/create_execute_function.test.ts @@ -6,7 +6,7 @@ */ import { KibanaRequest } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { taskManagerMock } from '@kbn/task-manager-plugin/server/mocks'; import { createExecutionEnqueuerFunction, @@ -256,7 +256,7 @@ describe('execute()', () => { }, ], }); - const source = { type: 'alert', id: uuid.v4() }; + const source = { type: 'alert', id: uuidv4() }; savedObjectsClient.get.mockResolvedValueOnce({ id: '123', @@ -334,7 +334,7 @@ describe('execute()', () => { }, ], }); - const source = { type: 'alert', id: uuid.v4() }; + const source = { type: 'alert', id: uuidv4() }; savedObjectsClient.get.mockResolvedValueOnce({ id: '123', @@ -822,7 +822,7 @@ describe('bulkExecute()', () => { }, ], }); - const source = { type: 'alert', id: uuid.v4() }; + const source = { type: 'alert', id: uuidv4() }; savedObjectsClient.bulkGet.mockResolvedValueOnce({ saved_objects: [ @@ -917,7 +917,7 @@ describe('bulkExecute()', () => { }, ], }); - const source = { type: 'alert', id: uuid.v4() }; + const source = { type: 'alert', id: uuidv4() }; savedObjectsClient.bulkGet.mockResolvedValueOnce({ saved_objects: [ diff --git a/x-pack/plugins/actions/server/create_unsecured_execute_function.test.ts b/x-pack/plugins/actions/server/create_unsecured_execute_function.test.ts index ea8407b956276..a61d6193a9ab5 100644 --- a/x-pack/plugins/actions/server/create_unsecured_execute_function.test.ts +++ b/x-pack/plugins/actions/server/create_unsecured_execute_function.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { savedObjectsRepositoryMock } from '@kbn/core/server/mocks'; import { taskManagerMock } from '@kbn/task-manager-plugin/server/mocks'; import { createBulkUnsecuredExecutionEnqueuerFunction } from './create_unsecured_execute_function'; @@ -118,7 +118,7 @@ describe('bulkExecute()', () => { }); test('schedules the actions with all given parameters with a preconfigured connector and source specified', async () => { - const sourceUuid = uuid.v4(); + const sourceUuid = uuidv4(); const source = { type: 'alert', id: sourceUuid }; const executeFn = createBulkUnsecuredExecutionEnqueuerFunction({ taskManager: mockTaskManager, @@ -232,7 +232,7 @@ describe('bulkExecute()', () => { }); test('schedules the actions with all given parameters with a preconfigured connector and relatedSavedObjects specified', async () => { - const sourceUuid = uuid.v4(); + const sourceUuid = uuidv4(); const source = { type: 'alert', id: sourceUuid }; const executeFn = createBulkUnsecuredExecutionEnqueuerFunction({ taskManager: mockTaskManager, diff --git a/x-pack/plugins/actions/server/lib/request_oauth_client_credentials_token.test.ts b/x-pack/plugins/actions/server/lib/request_oauth_client_credentials_token.test.ts index 20896e2691f10..223c8c28b55bc 100644 --- a/x-pack/plugins/actions/server/lib/request_oauth_client_credentials_token.test.ts +++ b/x-pack/plugins/actions/server/lib/request_oauth_client_credentials_token.test.ts @@ -74,6 +74,7 @@ describe('requestOAuthClientCredentialsToken', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, diff --git a/x-pack/plugins/actions/server/lib/request_oauth_jwt_token.test.ts b/x-pack/plugins/actions/server/lib/request_oauth_jwt_token.test.ts index 318775762bbbd..af65bcf67d3db 100644 --- a/x-pack/plugins/actions/server/lib/request_oauth_jwt_token.test.ts +++ b/x-pack/plugins/actions/server/lib/request_oauth_jwt_token.test.ts @@ -75,6 +75,7 @@ describe('requestOAuthJWTToken', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, diff --git a/x-pack/plugins/actions/server/lib/request_oauth_token.test.ts b/x-pack/plugins/actions/server/lib/request_oauth_token.test.ts index cc9ea6a74517a..9843783aadf8d 100644 --- a/x-pack/plugins/actions/server/lib/request_oauth_token.test.ts +++ b/x-pack/plugins/actions/server/lib/request_oauth_token.test.ts @@ -82,6 +82,7 @@ describe('requestOAuthToken', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, diff --git a/x-pack/plugins/actions/server/saved_objects/action_task_params_migrations.test.ts b/x-pack/plugins/actions/server/saved_objects/action_task_params_migrations.test.ts index c352b5dfa3a21..84e682a6170c1 100644 --- a/x-pack/plugins/actions/server/saved_objects/action_task_params_migrations.test.ts +++ b/x-pack/plugins/actions/server/saved_objects/action_task_params_migrations.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getActionTaskParamsMigrations, isPreconfiguredAction, @@ -415,12 +415,12 @@ function getMockData( ): SavedObjectUnsanitizedDoc { return { attributes: { - actionId: uuid.v4(), + actionId: uuidv4(), params: {}, ...overwrites, }, references: [...referencesOverwrites], - id: uuid.v4(), + id: uuidv4(), type: 'action_task_param', }; } diff --git a/x-pack/plugins/actions/server/saved_objects/actions_migrations.test.ts b/x-pack/plugins/actions/server/saved_objects/actions_migrations.test.ts index 12bf3984907b4..3760150760600 100644 --- a/x-pack/plugins/actions/server/saved_objects/actions_migrations.test.ts +++ b/x-pack/plugins/actions/server/saved_objects/actions_migrations.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getActionsMigrations } from './actions_migrations'; import { RawAction } from '../types'; import { SavedObjectUnsanitizedDoc } from '@kbn/core/server'; @@ -341,7 +341,7 @@ function getMockDataForWebhook( secrets, ...overwrites, }, - id: uuid.v4(), + id: uuidv4(), type: 'action', }; } @@ -357,7 +357,7 @@ function getMockDataForEmail( secrets: { user: 'test', password: '123' }, ...overwrites, }, - id: uuid.v4(), + id: uuidv4(), type: 'action', }; } @@ -373,7 +373,7 @@ function getCasesMockData( secrets: {}, ...overwrites, }, - id: uuid.v4(), + id: uuidv4(), type: 'action', }; } @@ -389,7 +389,7 @@ function getMockData( secrets: {}, ...overwrites, }, - id: uuid.v4(), + id: uuidv4(), type: 'action', }; } @@ -405,7 +405,7 @@ function getMockDataForServiceNow716( secrets: { user: 'test', password: '123' }, ...overwrites, }, - id: uuid.v4(), + id: uuidv4(), type: 'action', }; } diff --git a/x-pack/plugins/alerting/common/index.ts b/x-pack/plugins/alerting/common/index.ts index 795a05dcb802c..9a977213d4446 100644 --- a/x-pack/plugins/alerting/common/index.ts +++ b/x-pack/plugins/alerting/common/index.ts @@ -11,6 +11,7 @@ import { AlertsHealth } from './rule'; export * from './rule'; +export * from './rules_settings'; export * from './rule_type'; export * from './rule_task_instance'; export * from './rule_navigation'; diff --git a/x-pack/plugins/alerting/common/rules_settings.ts b/x-pack/plugins/alerting/common/rules_settings.ts new file mode 100644 index 0000000000000..755becc8a9822 --- /dev/null +++ b/x-pack/plugins/alerting/common/rules_settings.ts @@ -0,0 +1,51 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +export interface RulesSettingsModificationMetadata { + createdBy: string | null; + updatedBy: string | null; + createdAt: string; + updatedAt: string; +} + +export interface RulesSettingsFlappingProperties { + enabled: boolean; + lookBackWindow: number; + statusChangeThreshold: number; +} + +export type RulesSettingsFlapping = RulesSettingsFlappingProperties & + RulesSettingsModificationMetadata; + +export interface RulesSettings { + flapping: RulesSettingsFlapping; +} + +export const MIN_LOOK_BACK_WINDOW = 2; +export const MAX_LOOK_BACK_WINDOW = 20; +export const MIN_STATUS_CHANGE_THRESHOLD = 2; +export const MAX_STATUS_CHANGE_THRESHOLD = 20; + +export const RULES_SETTINGS_FEATURE_ID = 'rulesSettings'; +export const ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID = 'allFlappingSettings'; +export const READ_FLAPPING_SETTINGS_SUB_FEATURE_ID = 'readFlappingSettings'; + +export const API_PRIVILEGES = { + READ_FLAPPING_SETTINGS: 'read-flapping-settings', + WRITE_FLAPPING_SETTINGS: 'write-flapping-settings', +}; + +export const RULES_SETTINGS_SAVED_OBJECT_TYPE = 'rules-settings'; +export const RULES_SETTINGS_SAVED_OBJECT_ID = 'rules-settings'; + +export const DEFAULT_LOOK_BACK_WINDOW = 20; +export const DEFAULT_STATUS_CHANGE_THRESHOLD = 4; + +export const DEFAULT_FLAPPING_SETTINGS = { + enabled: true, + lookBackWindow: 20, + statusChangeThreshold: 4, +}; diff --git a/x-pack/plugins/alerting/docs/openapi/bundled.json b/x-pack/plugins/alerting/docs/openapi/bundled.json index 8adf80f41a836..53b0ad2e75a73 100644 --- a/x-pack/plugins/alerting/docs/openapi/bundled.json +++ b/x-pack/plugins/alerting/docs/openapi/bundled.json @@ -27,7 +27,7 @@ "paths": { "/s/{spaceId}/api/alerting/rule/{ruleId}": { "get": { - "summary": "Retrieve a rule by its identifier.", + "summary": "Retrieves a rule by its identifier.", "operationId": "getRule", "description": "You must have `read` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rules you're seeking. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability** features, or **Security** features. To get rules associated with the **Stack Monitoring** feature, use the `monitoring_user` built-in role.\n", "tags": [ @@ -50,14 +50,39 @@ "$ref": "#/components/schemas/rule_response_properties" }, "examples": { - "updateRuleResponse": { + "getRuleResponse": { "$ref": "#/components/examples/get_rule_response" } } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/404_response" + } + } + } } - } + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] }, "delete": { "summary": "Deletes a rule.", @@ -80,6 +105,26 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/404_response" + } + } + } } }, "servers": [ @@ -136,6 +181,26 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/404_response" + } + } + } } }, "servers": [ @@ -152,7 +217,7 @@ }, "/s/{spaceId}/api/alerting/rule/{ruleId}/_disable": { "post": { - "summary": "Disable a rule.", + "summary": "Disables a rule.", "operationId": "disableRule", "description": "You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features.\n", "tags": [ @@ -172,6 +237,26 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/404_response" + } + } + } } }, "servers": [ @@ -188,7 +273,7 @@ }, "/s/{spaceId}/api/alerting/rule/{ruleId}/_enable": { "post": { - "summary": "Enable a rule.", + "summary": "Enables a rule.", "operationId": "enableRule", "description": "This API supports token-based authentication only. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features.\n", "tags": [ @@ -208,6 +293,26 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + }, + "404": { + "description": "Object is not found.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -380,6 +485,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -394,9 +509,471 @@ } ] }, + "/s/{spaceId}/api/alerting/_health": { + "get": { + "summary": "Retrieves the health status of the alerting framework.", + "operationId": "getAlertingHealth", + "description": "You must have `read` privileges for the **Management > Stack Rules** feature or for at least one of the **Analytics > Discover**, **Analytics > Machine Learning**, **Observability**, or **Security** features.\n", + "tags": [ + "alerting" + ], + "parameters": [ + { + "$ref": "#/components/parameters/space_id" + } + ], + "responses": { + "200": { + "description": "Indicates a successful call.", + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "alerting_framework_heath": { + "type": "object", + "description": "This property has a typo. Use `alerting_framework_health` instead.", + "deprecated": true, + "properties": { + "_deprecated": { + "type": "string", + "example": "This state property has a typo, use \"alerting_framework_health\" instead." + }, + "decryption_health": { + "type": "object", + "properties": { + "status": { + "type": "string", + "example": "ok" + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + }, + "execution_health": { + "type": "object", + "properties": { + "status": { + "type": "string", + "example": "ok" + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + }, + "read_health": { + "type": "object", + "properties": { + "status": { + "type": "string", + "example": "ok" + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + } + } + }, + "alerting_framework_health": { + "type": "object", + "description": "Three substates identify the health of the alerting framework: `decryption_health`, `execution_health`, and `read_health`.\n", + "properties": { + "decryption_health": { + "type": "object", + "description": "The timestamp and status of the rule decryption.", + "properties": { + "status": { + "type": "string", + "example": "ok", + "enum": [ + "error", + "ok", + "warn" + ] + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + }, + "execution_health": { + "type": "object", + "description": "The timestamp and status of the rule run.", + "properties": { + "status": { + "type": "string", + "example": "ok", + "enum": [ + "error", + "ok", + "warn" + ] + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + }, + "read_health": { + "type": "object", + "description": "The timestamp and status of the rule reading events.", + "properties": { + "status": { + "type": "string", + "example": "ok", + "enum": [ + "error", + "ok", + "warn" + ] + }, + "timestamp": { + "type": "string", + "format": "date-time", + "example": "2023-01-13T01:28:00.280Z" + } + } + } + } + }, + "has_permanent_encryption_key": { + "type": "boolean", + "description": "If `false`, the encrypted saved object plugin does not have a permanent encryption key.", + "example": true + }, + "is_sufficiently_secure": { + "type": "boolean", + "description": "If `false`, security is enabled but TLS is not.", + "example": true + } + } + }, + "examples": { + "getAlertingHealthResponse": { + "$ref": "#/components/examples/get_health_response" + } + } + } + } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + } + } + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] + }, + "/s/{spaceId}/api/alerting/rule_types": { + "get": { + "summary": "Retrieves a list of rule types.", + "operationId": "getRuleTypes", + "description": "If you have `read` privileges for one or more Kibana features, the API response contains information about the appropriate rule types. For example, there are rule types associated with the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability** features, and **Security** features. To get rule types associated with the **Stack Monitoring** feature, use the `monitoring_user` built-in role.\n", + "tags": [ + "alerting" + ], + "parameters": [ + { + "$ref": "#/components/parameters/space_id" + } + ], + "responses": { + "200": { + "description": "Indicates a successful call.", + "content": { + "application/json": { + "schema": { + "type": "array", + "items": { + "type": "object", + "properties": { + "action_groups": { + "description": "An explicit list of groups for which the rule type can schedule actions, each with the action group's unique ID and human readable name. Rule actions validation uses this configuration to ensure that groups are valid.\n", + "type": "array", + "items": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string" + } + } + } + }, + "action_variables": { + "description": "A list of action variables that the rule type makes available via context and state in action parameter templates, and a short human readable description. When you create a rule in Kibana, it uses this information to prompt you for these variables in action parameter editors.\n", + "type": "object", + "properties": { + "context": { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "description": { + "type": "string" + }, + "useWithTripleBracesInTemplates": { + "type": "boolean" + } + } + } + }, + "params": { + "type": "array", + "items": { + "type": "object", + "properties": { + "description": { + "type": "string" + }, + "name": { + "type": "string" + } + } + } + }, + "state": { + "type": "array", + "items": { + "type": "object", + "properties": { + "description": { + "type": "string" + }, + "name": { + "type": "string" + } + } + } + } + } + }, + "authorized_consumers": { + "description": "The list of the plugins IDs that have access to the rule type.", + "type": "object", + "properties": { + "alerts": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "apm": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "discover": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "infrastructure": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "logs": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "ml": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "monitoring": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "siem": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "stackAlerts": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + }, + "uptime": { + "type": "object", + "properties": { + "all": { + "type": "boolean" + }, + "read": { + "type": "boolean" + } + } + } + } + }, + "default_action_group_id": { + "description": "The default identifier for the rule type group.", + "type": "string" + }, + "does_set_recovery_context": { + "description": "Indicates whether the rule passes context variables to its recovery action.", + "type": "boolean" + }, + "enabled_in_license": { + "description": "Indicates whether the rule type is enabled or disabled based on the subscription.", + "type": "boolean" + }, + "id": { + "description": "The unique identifier for the rule type.", + "type": "string" + }, + "is_exportable": { + "description": "Indicates whether the rule type is exportable in **Stack Management > Saved Objects**.", + "type": "boolean" + }, + "minimum_license_required": { + "description": "The subscriptions required to use the rule type.", + "type": "string", + "example": "basic" + }, + "name": { + "description": "The descriptive name of the rule type.", + "type": "string" + }, + "producer": { + "description": "An identifier for the application that produces this rule type.", + "type": "string", + "example": "stackAlerts" + }, + "recovery_action_group": { + "description": "An action group to use when an alert goes from an active state to an inactive one.", + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string" + } + } + }, + "rule_task_timeout": { + "type": "string", + "example": "5m" + } + } + } + }, + "examples": { + "getRuleTypesResponse": { + "$ref": "#/components/examples/get_rule_types_response" + } + } + } + } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } + } + } + }, + "servers": [ + { + "url": "https://localhost:5601" + } + ] + }, "/s/{spaceId}/api/alerting/rule/{ruleId}/_mute_all": { "post": { - "summary": "Mute all alerts.", + "summary": "Mutes all alerts.", "operationId": "muteAllAlerts", "description": "This API snoozes the notifications for the rule indefinitely. The rule checks continue to occur but alerts will not trigger any actions. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature.\n", "tags": [ @@ -416,6 +993,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -432,7 +1019,7 @@ }, "/s/{spaceId}/api/alerting/rule/{ruleId}/_unmute_all": { "post": { - "summary": "Unmute all alerts.", + "summary": "Unmutes all alerts.", "operationId": "unmuteAllAlerts", "description": "If the rule has its notifications snoozed indefinitely, this API cancels the snooze. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature.\n", "tags": [ @@ -452,6 +1039,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -468,7 +1065,7 @@ }, "/s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_mute": { "post": { - "summary": "Mute an alert.", + "summary": "Mutes an alert.", "operationId": "muteAlert", "description": "You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. \n", "tags": [ @@ -491,6 +1088,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -507,7 +1114,7 @@ }, "/s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_unmute": { "post": { - "summary": "Unmute an alert.", + "summary": "Unmutes an alert.", "operationId": "unmuteAlert", "description": "You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. \n", "tags": [ @@ -530,6 +1137,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/401_response" + } + } + } } }, "servers": [ @@ -838,6 +1455,52 @@ } } }, + "401_response": { + "type": "object", + "title": "Unsuccessful rule API response", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized", + "enum": [ + "Unauthorized" + ] + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401, + "enum": [ + 401 + ] + } + } + }, + "404_response": { + "type": "object", + "properties": { + "error": { + "type": "string", + "example": "Not Found", + "enum": [ + "Not Found" + ] + }, + "message": { + "type": "string", + "example": "Saved object [alert/caaad6d0-920c-11ed-b36a-874bd1548a00] not found" + }, + "statusCode": { + "type": "integer", + "example": 404, + "enum": [ + 404 + ] + } + } + }, "update_rule_request": { "title": "Update rule request", "description": "The update rule API request body varies depending on the type of rule and actions.", @@ -1115,6 +1778,174 @@ } ] } + }, + "get_health_response": { + "summary": "Retrieve information about the health of the alerting framework.", + "value": { + "is_sufficiently_secure": true, + "has_permanent_encryption_key": true, + "alerting_framework_health": { + "decryption_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + }, + "execution_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + }, + "read_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + } + }, + "alerting_framework_heath": { + "_deprecated": "This state property has a typo, use \"alerting_framework_health\" instead.", + "decryption_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + }, + "execution_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + }, + "read_health": { + "status": "ok", + "timestamp": "2023-01-13T01:28:00.280Z" + } + } + } + }, + "get_rule_types_response": { + "summary": "Retrieve rule types associated with Kibana machine learning features", + "value": [ + { + "id": "xpack.ml.anomaly_detection_alert", + "action_groups": [ + { + "id": "anomaly_score_match", + "name": "Anomaly score matched the condition" + }, + { + "id": "recovered", + "name": "Recovered" + } + ], + "action_variables": { + "context": [ + { + "name": "timestamp", + "description": "The bucket timestamp of the anomaly" + }, + { + "name": "timestampIso8601", + "description": "The bucket time of the anomaly in ISO8601 format" + }, + { + "name": "jobIds", + "description": "List of job IDs that triggered the alert" + }, + { + "name": "message", + "description": "Alert info message" + }, + { + "name": "isInterim", + "description": "Indicate if top hits contain interim results" + }, + { + "name": "score", + "description": "Anomaly score at the time of the notification action" + }, + { + "name": "topRecords", + "description": "Top records" + }, + { + "name": "topInfluencers", + "description": "Top influencers" + }, + { + "name": "anomalyExplorerUrl", + "description": "URL to open in the Anomaly Explorer", + "useWithTripleBracesInTemplates": true + } + ], + "params": [], + "state": [] + }, + "authorized_consumers": { + "alerts": { + "all": true, + "read": true + }, + "ml": { + "all": true, + "read": true + } + }, + "default_action_group_id": "anomaly_score_match", + "does_set_recovery_context": true, + "enabled_in_license": true, + "is_exportable": true, + "minimum_license_required": "platinum", + "name": "Anomaly detection alert", + "producer": "ml", + "recovery_action_group": { + "id": "recovered", + "name": "Recovered" + }, + "rule_task_timeout": "5m" + }, + { + "id": "xpack.ml.anomaly_detection_jobs_health", + "action_groups": [ + { + "id": "anomaly_detection_realtime_issue", + "name": "Issue detected" + }, + { + "id": "recovered", + "name": "Recovered" + } + ], + "action_variables": { + "context": [ + { + "name": "results", + "description": "Results of the rule execution" + }, + { + "name": "message", + "description": "Alert info message" + } + ], + "params": [], + "state": [] + }, + "authorized_consumers": { + "alerts": { + "all": true, + "read": true + }, + "ml": { + "all": true, + "read": true + } + }, + "default_action_group_id": "anomaly_detection_realtime_issue", + "does_set_recovery_context": true, + "enabled_in_license": true, + "is_exportable": true, + "minimum_license_required": "platinum", + "name": "Anomaly detection jobs health", + "producer": "ml", + "recovery_action_group": { + "id": "recovered", + "name": "Recovered" + }, + "rule_task_timeout": "5m" + } + ] } } }, diff --git a/x-pack/plugins/alerting/docs/openapi/bundled.yaml b/x-pack/plugins/alerting/docs/openapi/bundled.yaml index 029c6293557ce..95c0f0c266f1f 100644 --- a/x-pack/plugins/alerting/docs/openapi/bundled.yaml +++ b/x-pack/plugins/alerting/docs/openapi/bundled.yaml @@ -17,7 +17,7 @@ servers: paths: /s/{spaceId}/api/alerting/rule/{ruleId}: get: - summary: Retrieve a rule by its identifier. + summary: Retrieves a rule by its identifier. operationId: getRule description: | You must have `read` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rules you're seeking. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability** features, or **Security** features. To get rules associated with the **Stack Monitoring** feature, use the `monitoring_user` built-in role. @@ -34,8 +34,22 @@ paths: schema: $ref: '#/components/schemas/rule_response_properties' examples: - updateRuleResponse: + getRuleResponse: $ref: '#/components/examples/get_rule_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/404_response' + servers: + - url: https://localhost:5601 delete: summary: Deletes a rule. operationId: deleteRule @@ -50,6 +64,18 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/404_response' servers: - url: https://localhost:5601 put: @@ -82,13 +108,25 @@ paths: examples: updateRuleResponse: $ref: '#/components/examples/update_rule_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/404_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/_disable: post: - summary: Disable a rule. + summary: Disables a rule. operationId: disableRule description: | You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. @@ -101,13 +139,25 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/404_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/_enable: post: - summary: Enable a rule. + summary: Enables a rule. operationId: enableRule description: | This API supports token-based authentication only. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. @@ -120,6 +170,18 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: @@ -229,13 +291,331 @@ paths: examples: findRulesResponse: $ref: '#/components/examples/find_rules_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 + /s/{spaceId}/api/alerting/_health: + get: + summary: Retrieves the health status of the alerting framework. + operationId: getAlertingHealth + description: | + You must have `read` privileges for the **Management > Stack Rules** feature or for at least one of the **Analytics > Discover**, **Analytics > Machine Learning**, **Observability**, or **Security** features. + tags: + - alerting + parameters: + - $ref: '#/components/parameters/space_id' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + type: object + properties: + alerting_framework_heath: + type: object + description: This property has a typo. Use `alerting_framework_health` instead. + deprecated: true + properties: + _deprecated: + type: string + example: This state property has a typo, use "alerting_framework_health" instead. + decryption_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + execution_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + read_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + alerting_framework_health: + type: object + description: | + Three substates identify the health of the alerting framework: `decryption_health`, `execution_health`, and `read_health`. + properties: + decryption_health: + type: object + description: The timestamp and status of the rule decryption. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + execution_health: + type: object + description: The timestamp and status of the rule run. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + read_health: + type: object + description: The timestamp and status of the rule reading events. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: '2023-01-13T01:28:00.280Z' + has_permanent_encryption_key: + type: boolean + description: If `false`, the encrypted saved object plugin does not have a permanent encryption key. + example: true + is_sufficiently_secure: + type: boolean + description: If `false`, security is enabled but TLS is not. + example: true + examples: + getAlertingHealthResponse: + $ref: '#/components/examples/get_health_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + servers: + - url: https://localhost:5601 + /s/{spaceId}/api/alerting/rule_types: + get: + summary: Retrieves a list of rule types. + operationId: getRuleTypes + description: | + If you have `read` privileges for one or more Kibana features, the API response contains information about the appropriate rule types. For example, there are rule types associated with the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability** features, and **Security** features. To get rule types associated with the **Stack Monitoring** feature, use the `monitoring_user` built-in role. + tags: + - alerting + parameters: + - $ref: '#/components/parameters/space_id' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + type: array + items: + type: object + properties: + action_groups: + description: | + An explicit list of groups for which the rule type can schedule actions, each with the action group's unique ID and human readable name. Rule actions validation uses this configuration to ensure that groups are valid. + type: array + items: + type: object + properties: + id: + type: string + name: + type: string + action_variables: + description: | + A list of action variables that the rule type makes available via context and state in action parameter templates, and a short human readable description. When you create a rule in Kibana, it uses this information to prompt you for these variables in action parameter editors. + type: object + properties: + context: + type: array + items: + type: object + properties: + name: + type: string + description: + type: string + useWithTripleBracesInTemplates: + type: boolean + params: + type: array + items: + type: object + properties: + description: + type: string + name: + type: string + state: + type: array + items: + type: object + properties: + description: + type: string + name: + type: string + authorized_consumers: + description: The list of the plugins IDs that have access to the rule type. + type: object + properties: + alerts: + type: object + properties: + all: + type: boolean + read: + type: boolean + apm: + type: object + properties: + all: + type: boolean + read: + type: boolean + discover: + type: object + properties: + all: + type: boolean + read: + type: boolean + infrastructure: + type: object + properties: + all: + type: boolean + read: + type: boolean + logs: + type: object + properties: + all: + type: boolean + read: + type: boolean + ml: + type: object + properties: + all: + type: boolean + read: + type: boolean + monitoring: + type: object + properties: + all: + type: boolean + read: + type: boolean + siem: + type: object + properties: + all: + type: boolean + read: + type: boolean + stackAlerts: + type: object + properties: + all: + type: boolean + read: + type: boolean + uptime: + type: object + properties: + all: + type: boolean + read: + type: boolean + default_action_group_id: + description: The default identifier for the rule type group. + type: string + does_set_recovery_context: + description: Indicates whether the rule passes context variables to its recovery action. + type: boolean + enabled_in_license: + description: Indicates whether the rule type is enabled or disabled based on the subscription. + type: boolean + id: + description: The unique identifier for the rule type. + type: string + is_exportable: + description: Indicates whether the rule type is exportable in **Stack Management > Saved Objects**. + type: boolean + minimum_license_required: + description: The subscriptions required to use the rule type. + type: string + example: basic + name: + description: The descriptive name of the rule type. + type: string + producer: + description: An identifier for the application that produces this rule type. + type: string + example: stackAlerts + recovery_action_group: + description: An action group to use when an alert goes from an active state to an inactive one. + type: object + properties: + id: + type: string + name: + type: string + rule_task_timeout: + type: string + example: 5m + examples: + getRuleTypesResponse: + $ref: '#/components/examples/get_rule_types_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' + servers: + - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/_mute_all: post: - summary: Mute all alerts. + summary: Mutes all alerts. operationId: muteAllAlerts description: | This API snoozes the notifications for the rule indefinitely. The rule checks continue to occur but alerts will not trigger any actions. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. @@ -248,13 +628,19 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/_unmute_all: post: - summary: Unmute all alerts. + summary: Unmutes all alerts. operationId: unmuteAllAlerts description: | If the rule has its notifications snoozed indefinitely, this API cancels the snooze. You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. @@ -267,13 +653,19 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_mute: post: - summary: Mute an alert. + summary: Mutes an alert. operationId: muteAlert description: | You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. @@ -287,13 +679,19 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: - url: https://localhost:5601 /s/{spaceId}/api/alerting/rule/{ruleId}/alert/{alertId}/_unmute: post: - summary: Unmute an alert. + summary: Unmutes an alert. operationId: unmuteAlert description: | You must have `all` privileges for the appropriate Kibana features, depending on the `consumer` and `rule_type_id` of the rule. For example, the **Management > Stack Rules** feature, **Analytics > Discover** and **Machine Learning** features, **Observability**, and **Security** features. If the rule has actions, you must also have `read` privileges for the **Management > Actions and Connectors** feature. @@ -307,6 +705,12 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/401_response' servers: - url: https://localhost:5601 servers: @@ -539,6 +943,38 @@ components: description: The identifier for the user that updated this rule most recently. nullable: true example: elastic + 401_response: + type: object + title: Unsuccessful rule API response + properties: + error: + type: string + example: Unauthorized + enum: + - Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + enum: + - 401 + 404_response: + type: object + properties: + error: + type: string + example: Not Found + enum: + - Not Found + message: + type: string + example: Saved object [alert/caaad6d0-920c-11ed-b36a-874bd1548a00] not found + statusCode: + type: integer + example: 404 + enum: + - 404 update_rule_request: title: Update rule request description: The update rule API request body varies depending on the type of rule and actions. @@ -770,6 +1206,114 @@ components: warning: null outcome: succeeded next_run: '2022-12-06T01:45:23.912Z' + get_health_response: + summary: Retrieve information about the health of the alerting framework. + value: + is_sufficiently_secure: true + has_permanent_encryption_key: true + alerting_framework_health: + decryption_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + execution_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + read_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + alerting_framework_heath: + _deprecated: This state property has a typo, use "alerting_framework_health" instead. + decryption_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + execution_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + read_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + get_rule_types_response: + summary: Retrieve rule types associated with Kibana machine learning features + value: + - id: xpack.ml.anomaly_detection_alert + action_groups: + - id: anomaly_score_match + name: Anomaly score matched the condition + - id: recovered + name: Recovered + action_variables: + context: + - name: timestamp + description: The bucket timestamp of the anomaly + - name: timestampIso8601 + description: The bucket time of the anomaly in ISO8601 format + - name: jobIds + description: List of job IDs that triggered the alert + - name: message + description: Alert info message + - name: isInterim + description: Indicate if top hits contain interim results + - name: score + description: Anomaly score at the time of the notification action + - name: topRecords + description: Top records + - name: topInfluencers + description: Top influencers + - name: anomalyExplorerUrl + description: URL to open in the Anomaly Explorer + useWithTripleBracesInTemplates: true + params: [] + state: [] + authorized_consumers: + alerts: + all: true + read: true + ml: + all: true + read: true + default_action_group_id: anomaly_score_match + does_set_recovery_context: true + enabled_in_license: true + is_exportable: true + minimum_license_required: platinum + name: Anomaly detection alert + producer: ml + recovery_action_group: + id: recovered + name: Recovered + rule_task_timeout: 5m + - id: xpack.ml.anomaly_detection_jobs_health + action_groups: + - id: anomaly_detection_realtime_issue + name: Issue detected + - id: recovered + name: Recovered + action_variables: + context: + - name: results + description: Results of the rule execution + - name: message + description: Alert info message + params: [] + state: [] + authorized_consumers: + alerts: + all: true + read: true + ml: + all: true + read: true + default_action_group_id: anomaly_detection_realtime_issue + does_set_recovery_context: true + enabled_in_license: true + is_exportable: true + minimum_license_required: platinum + name: Anomaly detection jobs health + producer: ml + recovery_action_group: + id: recovered + name: Recovered + rule_task_timeout: 5m security: - basicAuth: [] - apiKeyAuth: [] diff --git a/x-pack/plugins/alerting/docs/openapi/components/examples/get_health_response.yaml b/x-pack/plugins/alerting/docs/openapi/components/examples/get_health_response.yaml new file mode 100644 index 0000000000000..fcd334cc677cf --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/components/examples/get_health_response.yaml @@ -0,0 +1,25 @@ +summary: Retrieve information about the health of the alerting framework. +value: + is_sufficiently_secure: true + has_permanent_encryption_key: true + alerting_framework_health: + decryption_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + execution_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + read_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + alerting_framework_heath: + _deprecated: "This state property has a typo, use \"alerting_framework_health\" instead." + decryption_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + execution_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' + read_health: + status: ok + timestamp: '2023-01-13T01:28:00.280Z' \ No newline at end of file diff --git a/x-pack/plugins/alerting/docs/openapi/components/examples/get_rule_types_response.yaml b/x-pack/plugins/alerting/docs/openapi/components/examples/get_rule_types_response.yaml new file mode 100644 index 0000000000000..8299f7357a217 --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/components/examples/get_rule_types_response.yaml @@ -0,0 +1,81 @@ +summary: Retrieve rule types associated with Kibana machine learning features +value: + - id: xpack.ml.anomaly_detection_alert + action_groups: + - id: anomaly_score_match + name: Anomaly score matched the condition + - id: recovered + name: Recovered + action_variables: + context: + - name: timestamp + description: The bucket timestamp of the anomaly + - name: timestampIso8601 + description: The bucket time of the anomaly in ISO8601 format + - name: jobIds + description: List of job IDs that triggered the alert + - name: message + description: Alert info message + - name: isInterim + description: Indicate if top hits contain interim results + - name: score + description: Anomaly score at the time of the notification action + - name: topRecords + description: Top records + - name: topInfluencers + description: Top influencers + - name: anomalyExplorerUrl + description: URL to open in the Anomaly Explorer + useWithTripleBracesInTemplates: true + params: [] + state: [] + authorized_consumers: + alerts: + all: true + read: true + ml: + all: true + read: true + default_action_group_id: anomaly_score_match + does_set_recovery_context: true + enabled_in_license: true + is_exportable: true + minimum_license_required: platinum + name: Anomaly detection alert + producer: ml + recovery_action_group: + id: recovered + name: Recovered + rule_task_timeout: 5m + - id: xpack.ml.anomaly_detection_jobs_health + action_groups: + - id: anomaly_detection_realtime_issue + name: Issue detected + - id: recovered + name: Recovered + action_variables: + context: + - name: results + description: Results of the rule execution + - name: message + description: Alert info message + params: [] + state: [] + authorized_consumers: + alerts: + all: true + read: true + ml: + all: true + read: true + default_action_group_id: anomaly_detection_realtime_issue + does_set_recovery_context: true + enabled_in_license: true + is_exportable: true + minimum_license_required: platinum + name: Anomaly detection jobs health + producer: ml + recovery_action_group: + id: recovered + name: Recovered + rule_task_timeout: 5m diff --git a/x-pack/plugins/alerting/docs/openapi/components/schemas/401_response.yaml b/x-pack/plugins/alerting/docs/openapi/components/schemas/401_response.yaml new file mode 100644 index 0000000000000..c6044998f8649 --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/components/schemas/401_response.yaml @@ -0,0 +1,15 @@ +type: object +title: Unsuccessful rule API response +properties: + error: + type: string + example: Unauthorized + enum: + - Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 + enum: + - 401 \ No newline at end of file diff --git a/x-pack/plugins/alerting/docs/openapi/components/schemas/404_response.yaml b/x-pack/plugins/alerting/docs/openapi/components/schemas/404_response.yaml new file mode 100644 index 0000000000000..1b8a118703ecb --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/components/schemas/404_response.yaml @@ -0,0 +1,15 @@ +type: object +properties: + error: + type: string + example: Not Found + enum: + - Not Found + message: + type: string + example: "Saved object [alert/caaad6d0-920c-11ed-b36a-874bd1548a00] not found" + statusCode: + type: integer + example: 404 + enum: + - 404 \ No newline at end of file diff --git a/x-pack/plugins/alerting/docs/openapi/entrypoint.yaml b/x-pack/plugins/alerting/docs/openapi/entrypoint.yaml index b26443cfc8dce..3b141954b30da 100644 --- a/x-pack/plugins/alerting/docs/openapi/entrypoint.yaml +++ b/x-pack/plugins/alerting/docs/openapi/entrypoint.yaml @@ -23,10 +23,10 @@ paths: $ref: 'paths/s@{spaceid}@api@alerting@rule@{ruleid}@_enable.yaml' '/s/{spaceId}/api/alerting/rules/_find': $ref: 'paths/s@{spaceid}@api@alerting@rules@_find.yaml' -# '/s/{spaceId}/api/alerting/_health': -# $ref: paths/s@{spaceid}@api@alerting@_health.yaml -# '/s/{spaceId}/api/alerting/rule_types': -# $ref: 'paths/s@{spaceid}@api@alerting@rule_types.yaml' + '/s/{spaceId}/api/alerting/_health': + $ref: paths/s@{spaceid}@api@alerting@_health.yaml + '/s/{spaceId}/api/alerting/rule_types': + $ref: 'paths/s@{spaceid}@api@alerting@rule_types.yaml' '/s/{spaceId}/api/alerting/rule/{ruleId}/_mute_all': $ref: 'paths/s@{spaceid}@api@alerting@rule@{ruleid}@_mute_all.yaml' '/s/{spaceId}/api/alerting/rule/{ruleId}/_unmute_all': diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@_health.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@_health.yaml new file mode 100644 index 0000000000000..6934bddfa9580 --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@_health.yaml @@ -0,0 +1,126 @@ +get: + summary: Retrieves the health status of the alerting framework. + operationId: getAlertingHealth + description: > + You must have `read` privileges for the **Management > Stack Rules** feature + or for at least one of the **Analytics > Discover**, + **Analytics > Machine Learning**, **Observability**, or **Security** features. + tags: + - alerting + parameters: + - $ref: '../components/parameters/space_id.yaml' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + type: object + properties: + alerting_framework_heath: + type: object + description: This property has a typo. Use `alerting_framework_health` instead. + deprecated: true + properties: + _deprecated: + type: string + example: "This state property has a typo, use \"alerting_framework_health\" instead." + decryption_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + execution_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + read_health: + type: object + properties: + status: + type: string + example: ok + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + alerting_framework_health: + type: object + description: > + Three substates identify the health of the alerting framework: `decryption_health`, `execution_health`, and `read_health`. + properties: + decryption_health: + type: object + description: The timestamp and status of the rule decryption. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + execution_health: + type: object + description: The timestamp and status of the rule run. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + read_health: + type: object + description: The timestamp and status of the rule reading events. + properties: + status: + type: string + example: ok + enum: + - error + - ok + - warn + timestamp: + type: string + format: date-time + example: "2023-01-13T01:28:00.280Z" + has_permanent_encryption_key: + type: boolean + description: If `false`, the encrypted saved object plugin does not have a permanent encryption key. + example: true + is_sufficiently_secure: + type: boolean + description: If `false`, security is enabled but TLS is not. + example: true + examples: + getAlertingHealthResponse: + $ref: '../components/examples/get_health_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' +servers: + - url: https://localhost:5601 \ No newline at end of file diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}.yaml index cb6a4a34525d9..91ef40aa0c2e9 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}.yaml @@ -1,5 +1,5 @@ get: - summary: Retrieve a rule by its identifier. + summary: Retrieves a rule by its identifier. operationId: getRule description: > You must have `read` privileges for the appropriate Kibana features, @@ -21,8 +21,22 @@ get: schema: $ref: '../components/schemas/rule_response_properties.yaml' examples: - updateRuleResponse: + getRuleResponse: $ref: '../components/examples/get_rule_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '../components/schemas/404_response.yaml' + servers: + - url: https://localhost:5601 delete: summary: Deletes a rule. @@ -42,6 +56,18 @@ delete: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '../components/schemas/404_response.yaml' servers: - url: https://localhost:5601 @@ -88,6 +114,18 @@ put: examples: updateRuleResponse: $ref: '../components/examples/update_rule_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '../components/schemas/404_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_disable.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_disable.yaml index 8c8a60ae2ce2e..d0d5321a48420 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_disable.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_disable.yaml @@ -1,5 +1,5 @@ post: - summary: Disable a rule. + summary: Disables a rule. operationId: disableRule description: > You must have `all` privileges for the appropriate Kibana features, @@ -15,6 +15,18 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '../components/schemas/404_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_enable.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_enable.yaml index ee4ef54fc43f6..cb7991c2d9185 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_enable.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_enable.yaml @@ -1,5 +1,5 @@ post: - summary: Enable a rule. + summary: Enables a rule. operationId: enableRule description: > This API supports token-based authentication only. @@ -16,6 +16,18 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' + '404': + description: Object is not found. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_mute_all.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_mute_all.yaml index a816ed0b0b7ef..00250d5a754a4 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_mute_all.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_mute_all.yaml @@ -1,5 +1,5 @@ post: - summary: Mute all alerts. + summary: Mutes all alerts. operationId: muteAllAlerts description: > This API snoozes the notifications for the rule indefinitely. The rule @@ -19,6 +19,12 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_unmute_all.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_unmute_all.yaml index 38e8f0807c998..b0a887e7b427e 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_unmute_all.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@_unmute_all.yaml @@ -1,5 +1,5 @@ post: - summary: Unmute all alerts. + summary: Unmutes all alerts. operationId: unmuteAllAlerts description: > If the rule has its notifications snoozed indefinitely, this API cancels the snooze. @@ -18,6 +18,12 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_mute.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_mute.yaml index d120c06e7a6c4..2356bf4a60394 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_mute.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_mute.yaml @@ -1,5 +1,5 @@ post: - summary: Mute an alert. + summary: Mutes an alert. operationId: muteAlert description: > You must have `all` privileges for the appropriate Kibana features, @@ -18,6 +18,12 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_unmute.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_unmute.yaml index bbc92453e236b..c06eccb531b46 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_unmute.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule@{ruleid}@alert@{alertid}@_unmute.yaml @@ -1,5 +1,5 @@ post: - summary: Unmute an alert. + summary: Unmutes an alert. operationId: unmuteAlert description: > You must have `all` privileges for the appropriate Kibana features, @@ -18,6 +18,12 @@ post: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule_types.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule_types.yaml new file mode 100644 index 0000000000000..8b7019ee54539 --- /dev/null +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rule_types.yaml @@ -0,0 +1,198 @@ +get: + summary: Retrieves a list of rule types. + operationId: getRuleTypes + description: > + If you have `read` privileges for one or more Kibana features, the API + response contains information about the appropriate rule types. For example, + there are rule types associated with the **Management > Stack Rules** feature, + **Analytics > Discover** and **Machine Learning** features, **Observability** + features, and **Security** features. To get rule types associated with the + **Stack Monitoring** feature, use the `monitoring_user` built-in role. + tags: + - alerting + parameters: + - $ref: '../components/parameters/space_id.yaml' + responses: + '200': + description: Indicates a successful call. + content: + application/json: + schema: + type: array + items: + type: object + properties: + action_groups: + description: > + An explicit list of groups for which the rule type can + schedule actions, each with the action group's unique ID and + human readable name. Rule actions validation uses this + configuration to ensure that groups are valid. + type: array + items: + type: object + properties: + id: + type: string + name: + type: string + action_variables: + description: > + A list of action variables that the rule type makes available + via context and state in action parameter templates, and a + short human readable description. When you create a rule in + Kibana, it uses this information to prompt you for these + variables in action parameter editors. + type: object + properties: + context: + type: array + items: + type: object + properties: + name: + type: string + description: + type: string + useWithTripleBracesInTemplates: + type: boolean + params: + type: array + items: + type: object + properties: + description: + type: string + name: + type: string + state: + type: array + items: + type: object + properties: + description: + type: string + name: + type: string + authorized_consumers: + description: The list of the plugins IDs that have access to the rule type. + type: object + properties: + alerts: + type: object + properties: + all: + type: boolean + read: + type: boolean + apm: + type: object + properties: + all: + type: boolean + read: + type: boolean + discover: + type: object + properties: + all: + type: boolean + read: + type: boolean + infrastructure: + type: object + properties: + all: + type: boolean + read: + type: boolean + logs: + type: object + properties: + all: + type: boolean + read: + type: boolean + ml: + type: object + properties: + all: + type: boolean + read: + type: boolean + monitoring: + type: object + properties: + all: + type: boolean + read: + type: boolean + siem: + type: object + properties: + all: + type: boolean + read: + type: boolean + stackAlerts: + type: object + properties: + all: + type: boolean + read: + type: boolean + uptime: + type: object + properties: + all: + type: boolean + read: + type: boolean + default_action_group_id: + description: The default identifier for the rule type group. + type: string + does_set_recovery_context: + description: Indicates whether the rule passes context variables to its recovery action. + type: boolean + enabled_in_license: + description: Indicates whether the rule type is enabled or disabled based on the subscription. + type: boolean + id: + description: The unique identifier for the rule type. + type: string + is_exportable: + description: Indicates whether the rule type is exportable in **Stack Management > Saved Objects**. + type: boolean + minimum_license_required: + description: The subscriptions required to use the rule type. + type: string + example: basic + name: + description: The descriptive name of the rule type. + type: string + producer: + description: An identifier for the application that produces this rule type. + type: string + example: stackAlerts + recovery_action_group: + description: An action group to use when an alert goes from an active state to an inactive one. + type: object + properties: + id: + type: string + name: + type: string + rule_task_timeout: + type: string + example: 5m + examples: + getRuleTypesResponse: + $ref: '../components/examples/get_rule_types_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' +servers: + - url: https://localhost:5601 \ No newline at end of file diff --git a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rules@_find.yaml b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rules@_find.yaml index 42c4b817f7968..2f84059aa392d 100644 --- a/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rules@_find.yaml +++ b/x-pack/plugins/alerting/docs/openapi/paths/s@{spaceid}@api@alerting@rules@_find.yaml @@ -113,6 +113,12 @@ get: examples: findRulesResponse: $ref: '../components/examples/find_rules_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/401_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/alerting/public/alert_navigation_registry/alert_navigation_registry.test.ts b/x-pack/plugins/alerting/public/alert_navigation_registry/alert_navigation_registry.test.ts index 204076151614b..bedb17270a477 100644 --- a/x-pack/plugins/alerting/public/alert_navigation_registry/alert_navigation_registry.test.ts +++ b/x-pack/plugins/alerting/public/alert_navigation_registry/alert_navigation_registry.test.ts @@ -7,7 +7,7 @@ import { AlertNavigationRegistry } from './alert_navigation_registry'; import { RuleType, RecoveredActionGroup, SanitizedRule } from '../../common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; beforeEach(() => jest.resetAllMocks()); @@ -37,7 +37,7 @@ describe('AlertNavigationRegistry', () => { describe('has()', () => { test('returns false for unregistered consumer handlers', () => { const registry = new AlertNavigationRegistry(); - expect(registry.has('siem', mockRuleType(uuid.v4()))).toEqual(false); + expect(registry.has('siem', mockRuleType(uuidv4()))).toEqual(false); }); test('returns false for unregistered rule types handlers', () => { diff --git a/x-pack/plugins/alerting/server/alert/create_alert_factory.ts b/x-pack/plugins/alerting/server/alert/create_alert_factory.ts index c7fea46e37e4b..ff8aacd52f5fe 100644 --- a/x-pack/plugins/alerting/server/alert/create_alert_factory.ts +++ b/x-pack/plugins/alerting/server/alert/create_alert_factory.ts @@ -129,7 +129,12 @@ export function createAlertFactory< return []; } - const { currentRecoveredAlerts } = processAlerts({ + const { currentRecoveredAlerts } = processAlerts< + State, + Context, + ActionGroupIds, + ActionGroupIds + >({ alerts, existingAlerts: originalAlerts, previouslyRecoveredAlerts: {}, diff --git a/x-pack/plugins/alerting/server/alerts_client/legacy_alerts_client.ts b/x-pack/plugins/alerting/server/alerts_client/legacy_alerts_client.ts index 95f99a763ad7b..9a8cd78f7fd8f 100644 --- a/x-pack/plugins/alerting/server/alerts_client/legacy_alerts_client.ts +++ b/x-pack/plugins/alerting/server/alerts_client/legacy_alerts_client.ts @@ -17,7 +17,12 @@ import { AlertingEventLogger } from '../lib/alerting_event_logger/alerting_event import { RuleRunMetricsStore } from '../lib/rule_run_metrics_store'; import { UntypedNormalizedRuleType } from '../rule_type_registry'; import { logAlerts } from '../task_runner/log_alerts'; -import { AlertInstanceContext, AlertInstanceState, RawAlertInstance } from '../types'; +import { + AlertInstanceContext, + AlertInstanceState, + RawAlertInstance, + WithoutReservedActionGroups, +} from '../types'; interface ConstructorOpts { logger: Logger; @@ -28,19 +33,24 @@ interface ConstructorOpts { export class LegacyAlertsClient< State extends AlertInstanceState, Context extends AlertInstanceContext, - ActionGroupIds extends string + ActionGroupIds extends string, + RecoveryActionGroupId extends string > { private activeAlertsFromPreviousExecution: Record>; private recoveredAlertsFromPreviousExecution: Record>; private alerts: Record>; private processedAlerts: { - new: Record>; - active: Record>; - recovered: Record>; - recoveredCurrent: Record>; + new: Record>; + active: Record>; + recovered: Record>; + recoveredCurrent: Record>; }; - private alertFactory?: AlertFactory; + private alertFactory?: AlertFactory< + State, + Context, + WithoutReservedActionGroups + >; constructor(private readonly options: ConstructorOpts) { this.alerts = {}; this.activeAlertsFromPreviousExecution = {}; @@ -77,7 +87,11 @@ export class LegacyAlertsClient< this.alerts = cloneDeep(this.activeAlertsFromPreviousExecution); - this.alertFactory = createAlertFactory({ + this.alertFactory = createAlertFactory< + State, + Context, + WithoutReservedActionGroups + >({ alerts: this.alerts, logger: this.options.logger, maxAlerts: this.options.maxAlerts, @@ -101,7 +115,7 @@ export class LegacyAlertsClient< activeAlerts: processedAlertsActive, currentRecoveredAlerts: processedAlertsRecoveredCurrent, recoveredAlerts: processedAlertsRecovered, - } = processAlerts({ + } = processAlerts({ alerts: this.alerts, existingAlerts: this.activeAlertsFromPreviousExecution, previouslyRecoveredAlerts: this.recoveredAlertsFromPreviousExecution, @@ -110,7 +124,10 @@ export class LegacyAlertsClient< setFlapping: true, }); - setFlapping(processedAlertsActive, processedAlertsRecovered); + setFlapping( + processedAlertsActive, + processedAlertsRecovered + ); this.processedAlerts.new = processedAlertsNew; this.processedAlerts.active = processedAlertsActive; @@ -139,7 +156,7 @@ export class LegacyAlertsClient< } public getAlertsToSerialize() { - return determineAlertsToReturn( + return determineAlertsToReturn( this.processedAlerts.active, this.processedAlerts.recovered ); diff --git a/x-pack/plugins/alerting/server/authorization/alerting_authorization.test.ts b/x-pack/plugins/alerting/server/authorization/alerting_authorization.test.ts index 0857c4c18d6ae..4949d958ce4f0 100644 --- a/x-pack/plugins/alerting/server/authorization/alerting_authorization.test.ts +++ b/x-pack/plugins/alerting/server/authorization/alerting_authorization.test.ts @@ -20,7 +20,7 @@ import { ReadOperations, AlertingAuthorizationEntity, } from './alerting_authorization'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { RecoveredActionGroup } from '../../common'; import { RegistryRuleType } from '../rule_type_registry'; import { AlertingAuthorizationFilterType } from './alerting_authorization_kuery'; @@ -210,8 +210,8 @@ describe('AlertingAuthorization', () => { describe('constructor', () => { test(`fetches the user's current space`, async () => { const space = { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), disabledFeatures: [], }; getSpace.mockResolvedValue(space); diff --git a/x-pack/plugins/alerting/server/lib/determine_alerts_to_return.ts b/x-pack/plugins/alerting/server/lib/determine_alerts_to_return.ts index ff9b5ff0b6353..5916bf91efcc0 100644 --- a/x-pack/plugins/alerting/server/lib/determine_alerts_to_return.ts +++ b/x-pack/plugins/alerting/server/lib/determine_alerts_to_return.ts @@ -12,10 +12,12 @@ import { AlertInstanceState, AlertInstanceContext, RawAlertInstance } from '../t // determines which alerts to return in the state export function determineAlertsToReturn< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string >( - activeAlerts: Record> = {}, - recoveredAlerts: Record> = {} + activeAlerts: Record> = {}, + recoveredAlerts: Record> = {} ): { alertsToReturn: Record; recoveredAlertsToReturn: Record; diff --git a/x-pack/plugins/alerting/server/lib/is_alerting_error.test.ts b/x-pack/plugins/alerting/server/lib/is_alerting_error.test.ts index 4413941dfc293..2c4a40efb05f0 100644 --- a/x-pack/plugins/alerting/server/lib/is_alerting_error.test.ts +++ b/x-pack/plugins/alerting/server/lib/is_alerting_error.test.ts @@ -8,11 +8,11 @@ import { isAlertSavedObjectNotFoundError, isEsUnavailableError } from './is_alerting_error'; import { ErrorWithReason } from './error_with_reason'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { RuleExecutionStatusErrorReasons } from '../types'; describe('isAlertSavedObjectNotFoundError', () => { - const id = uuid.v4(); + const id = uuidv4(); const errorSONF = SavedObjectsErrorHelpers.createGenericNotFoundError('alert', id); test('identifies SavedObjects Not Found errors', () => { @@ -33,7 +33,7 @@ describe('isAlertSavedObjectNotFoundError', () => { }); describe('isEsUnavailableError', () => { - const id = uuid.v4(); + const id = uuidv4(); const errorSONF = SavedObjectsErrorHelpers.createGenericNotFoundEsUnavailableError('alert', id); test('identifies es unavailable errors', () => { diff --git a/x-pack/plugins/alerting/server/lib/process_alerts.ts b/x-pack/plugins/alerting/server/lib/process_alerts.ts index 83d375e9b8ac2..40c86dc461ab0 100644 --- a/x-pack/plugins/alerting/server/lib/process_alerts.ts +++ b/x-pack/plugins/alerting/server/lib/process_alerts.ts @@ -25,18 +25,22 @@ interface ProcessAlertsOpts< } interface ProcessAlertsResult< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string > { - newAlerts: Record>; - activeAlerts: Record>; + newAlerts: Record>; + activeAlerts: Record>; // recovered alerts in the current rule run that were previously active - currentRecoveredAlerts: Record>; - recoveredAlerts: Record>; + currentRecoveredAlerts: Record>; + recoveredAlerts: Record>; } export function processAlerts< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string >({ alerts, existingAlerts, @@ -44,7 +48,12 @@ export function processAlerts< hasReachedAlertLimit, alertLimit, setFlapping, -}: ProcessAlertsOpts): ProcessAlertsResult { +}: ProcessAlertsOpts): ProcessAlertsResult< + State, + Context, + ActionGroupIds, + RecoveryActionGroupId +> { return hasReachedAlertLimit ? processAlertsLimitReached( alerts, @@ -58,21 +67,23 @@ export function processAlerts< function processAlertsHelper< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string >( alerts: Record>, existingAlerts: Record>, previouslyRecoveredAlerts: Record>, setFlapping: boolean -): ProcessAlertsResult { +): ProcessAlertsResult { const existingAlertIds = new Set(Object.keys(existingAlerts)); const previouslyRecoveredAlertsIds = new Set(Object.keys(previouslyRecoveredAlerts)); const currentTime = new Date().toISOString(); - const newAlerts: Record> = {}; - const activeAlerts: Record> = {}; - const currentRecoveredAlerts: Record> = {}; - const recoveredAlerts: Record> = {}; + const newAlerts: Record> = {}; + const activeAlerts: Record> = {}; + const currentRecoveredAlerts: Record> = {}; + const recoveredAlerts: Record> = {}; for (const id in alerts) { if (alerts.hasOwnProperty(id)) { @@ -147,14 +158,16 @@ function processAlertsHelper< function processAlertsLimitReached< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string >( alerts: Record>, existingAlerts: Record>, previouslyRecoveredAlerts: Record>, alertLimit: number, setFlapping: boolean -): ProcessAlertsResult { +): ProcessAlertsResult { const existingAlertIds = new Set(Object.keys(existingAlerts)); const previouslyRecoveredAlertsIds = new Set(Object.keys(previouslyRecoveredAlerts)); @@ -164,10 +177,12 @@ function processAlertsLimitReached< // - add any new alerts, up to the max allowed const currentTime = new Date().toISOString(); - const newAlerts: Record> = {}; + const newAlerts: Record> = {}; // all existing alerts stay active - const activeAlerts: Record> = cloneDeep(existingAlerts); + const activeAlerts: Record> = cloneDeep( + existingAlerts + ); // update duration for existing alerts for (const id in activeAlerts) { @@ -231,8 +246,10 @@ function processAlertsLimitReached< export function updateAlertFlappingHistory< State extends AlertInstanceState, - Context extends AlertInstanceContext ->(alert: Alert, state: boolean) { + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string +>(alert: Alert, state: boolean) { const updatedFlappingHistory = updateFlappingHistory(alert.getFlappingHistory() || [], state); alert.setFlappingHistory(updatedFlappingHistory); } diff --git a/x-pack/plugins/alerting/server/lib/set_flapping.test.ts b/x-pack/plugins/alerting/server/lib/set_flapping.test.ts index 93b1cafaca76a..9900d3391861b 100644 --- a/x-pack/plugins/alerting/server/lib/set_flapping.test.ts +++ b/x-pack/plugins/alerting/server/lib/set_flapping.test.ts @@ -7,7 +7,7 @@ import { pick } from 'lodash'; import { Alert } from '../alert'; -import { AlertInstanceState, AlertInstanceContext } from '../../common'; +import { AlertInstanceState, AlertInstanceContext, DefaultActionGroupId } from '../../common'; import { setFlapping, isAlertFlapping } from './set_flapping'; describe('setFlapping', () => { @@ -85,25 +85,34 @@ describe('setFlapping', () => { describe('not currently flapping', () => { test('returns true if the flap count exceeds the threshold', () => { const flappingHistory = [true, true, true, true].concat(new Array(16).fill(false)); - const alert = new Alert('1', { - meta: { flappingHistory }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory }, + } + ); expect(isAlertFlapping(alert)).toEqual(true); }); test("returns false the flap count doesn't exceed the threshold", () => { const flappingHistory = [true, true].concat(new Array(20).fill(false)); - const alert = new Alert('1', { - meta: { flappingHistory }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory }, + } + ); expect(isAlertFlapping(alert)).toEqual(false); }); test('returns true if not at capacity and the flap count exceeds the threshold', () => { const flappingHistory = new Array(5).fill(true); - const alert = new Alert('1', { - meta: { flappingHistory }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory }, + } + ); expect(isAlertFlapping(alert)).toEqual(true); }); }); @@ -111,33 +120,45 @@ describe('setFlapping', () => { describe('currently flapping', () => { test('returns true if at capacity and the flap count exceeds the threshold', () => { const flappingHistory = new Array(16).fill(false).concat([true, true, true, true]); - const alert = new Alert('1', { - meta: { flappingHistory, flapping: true }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory, flapping: true }, + } + ); expect(isAlertFlapping(alert)).toEqual(true); }); test("returns true if not at capacity and the flap count doesn't exceed the threshold", () => { const flappingHistory = new Array(16).fill(false); - const alert = new Alert('1', { - meta: { flappingHistory, flapping: true }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory, flapping: true }, + } + ); expect(isAlertFlapping(alert)).toEqual(true); }); test('returns true if not at capacity and the flap count exceeds the threshold', () => { const flappingHistory = new Array(10).fill(false).concat([true, true, true, true]); - const alert = new Alert('1', { - meta: { flappingHistory, flapping: true }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory, flapping: true }, + } + ); expect(isAlertFlapping(alert)).toEqual(true); }); test("returns false if at capacity and the flap count doesn't exceed the threshold", () => { const flappingHistory = new Array(20).fill(false); - const alert = new Alert('1', { - meta: { flappingHistory, flapping: true }, - }); + const alert = new Alert( + '1', + { + meta: { flappingHistory, flapping: true }, + } + ); expect(isAlertFlapping(alert)).toEqual(false); }); }); diff --git a/x-pack/plugins/alerting/server/lib/set_flapping.ts b/x-pack/plugins/alerting/server/lib/set_flapping.ts index 81e7d0143af6c..2e941cf06e07c 100644 --- a/x-pack/plugins/alerting/server/lib/set_flapping.ts +++ b/x-pack/plugins/alerting/server/lib/set_flapping.ts @@ -10,9 +10,14 @@ import { Alert } from '../alert'; import { AlertInstanceState, AlertInstanceContext } from '../types'; import { isFlapping } from './flapping_utils'; -export function setFlapping( - activeAlerts: Record> = {}, - recoveredAlerts: Record> = {} +export function setFlapping< + State extends AlertInstanceState, + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupIds extends string +>( + activeAlerts: Record> = {}, + recoveredAlerts: Record> = {} ) { for (const id of keys(activeAlerts)) { const alert = activeAlerts[id]; @@ -29,8 +34,10 @@ export function setFlapping(alert: Alert): boolean { + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string +>(alert: Alert): boolean { const flappingHistory: boolean[] = alert.getFlappingHistory() || []; const isCurrentlyFlapping = alert.getFlapping(); return isFlapping(flappingHistory, isCurrentlyFlapping); diff --git a/x-pack/plugins/alerting/server/plugin.test.ts b/x-pack/plugins/alerting/server/plugin.test.ts index 2c057cc4cfc43..7b85bc898fee0 100644 --- a/x-pack/plugins/alerting/server/plugin.test.ts +++ b/x-pack/plugins/alerting/server/plugin.test.ts @@ -78,6 +78,7 @@ describe('Alerting Plugin', () => { statusService: statusServiceMock.createSetupContract(), monitoringCollection: monitoringCollectionMock.createSetup(), data: dataPluginMock.createSetupContract() as unknown as DataPluginSetup, + features: featuresPluginMock.createSetup(), }; let plugin: AlertingPlugin; @@ -221,6 +222,7 @@ describe('Alerting Plugin', () => { statusService: statusServiceMock.createSetupContract(), monitoringCollection: monitoringCollectionMock.createSetup(), data: dataPluginMock.createSetupContract() as unknown as DataPluginSetup, + features: featuresPluginMock.createSetup(), }); const startContract = plugin.start(coreMock.createStart(), { @@ -267,6 +269,7 @@ describe('Alerting Plugin', () => { statusService: statusServiceMock.createSetupContract(), monitoringCollection: monitoringCollectionMock.createSetup(), data: dataPluginMock.createSetupContract() as unknown as DataPluginSetup, + features: featuresPluginMock.createSetup(), }); const startContract = plugin.start(coreMock.createStart(), { @@ -324,6 +327,7 @@ describe('Alerting Plugin', () => { statusService: statusServiceMock.createSetupContract(), monitoringCollection: monitoringCollectionMock.createSetup(), data: dataPluginMock.createSetupContract() as unknown as DataPluginSetup, + features: featuresPluginMock.createSetup(), }); const startContract = plugin.start(coreMock.createStart(), { diff --git a/x-pack/plugins/alerting/server/plugin.ts b/x-pack/plugins/alerting/server/plugin.ts index 13f39504d2781..86d8a7411c16d 100644 --- a/x-pack/plugins/alerting/server/plugin.ts +++ b/x-pack/plugins/alerting/server/plugin.ts @@ -47,13 +47,17 @@ import { IEventLogService, IEventLogClientService, } from '@kbn/event-log-plugin/server'; -import { PluginStartContract as FeaturesPluginStart } from '@kbn/features-plugin/server'; +import { + PluginStartContract as FeaturesPluginStart, + PluginSetupContract as FeaturesPluginSetup, +} from '@kbn/features-plugin/server'; import { PluginStart as DataPluginStart } from '@kbn/data-plugin/server'; import { MonitoringCollectionSetup } from '@kbn/monitoring-collection-plugin/server'; import { SharePluginStart } from '@kbn/share-plugin/server'; import { RuleTypeRegistry } from './rule_type_registry'; import { TaskRunnerFactory } from './task_runner'; import { RulesClientFactory } from './rules_client_factory'; +import { RulesSettingsClientFactory } from './rules_settings_client_factory'; import { ILicenseState, LicenseState } from './lib/license_state'; import { AlertingRequestHandlerContext, ALERTS_FEATURE_ID } from './types'; import { defineRoutes } from './routes'; @@ -82,6 +86,7 @@ import { getSecurityHealth, SecurityHealth } from './lib/get_security_health'; import { registerNodeCollector, registerClusterCollector, InMemoryMetrics } from './monitoring'; import { getRuleTaskTimeout } from './lib/get_rule_task_timeout'; import { getActionsConfigMap } from './lib/get_actions_config_map'; +import { rulesSettingsFeature } from './rules_settings_feature'; export const EVENT_LOG_PROVIDER = 'alerting'; export const EVENT_LOG_ACTIONS = { @@ -146,6 +151,7 @@ export interface AlertingPluginsSetup { statusService: StatusServiceSetup; monitoringCollection: MonitoringCollectionSetup; data: DataPluginSetup; + features: FeaturesPluginSetup; } export interface AlertingPluginsStart { @@ -172,6 +178,7 @@ export class AlertingPlugin { private security?: SecurityPluginSetup; private readonly rulesClientFactory: RulesClientFactory; private readonly alertingAuthorizationClientFactory: AlertingAuthorizationClientFactory; + private readonly rulesSettingsClientFactory: RulesSettingsClientFactory; private readonly telemetryLogger: Logger; private readonly kibanaVersion: PluginInitializerContext['env']['packageInfo']['version']; private eventLogService?: IEventLogService; @@ -186,6 +193,7 @@ export class AlertingPlugin { this.taskRunnerFactory = new TaskRunnerFactory(); this.rulesClientFactory = new RulesClientFactory(); this.alertingAuthorizationClientFactory = new AlertingAuthorizationClientFactory(); + this.rulesSettingsClientFactory = new RulesSettingsClientFactory(); this.telemetryLogger = initializerContext.logger.get('usage'); this.kibanaVersion = initializerContext.env.packageInfo.version; this.inMemoryMetrics = new InMemoryMetrics(initializerContext.logger.get('in_memory_metrics')); @@ -210,6 +218,8 @@ export class AlertingPlugin { }; }); + plugins.features.registerKibanaFeature(rulesSettingsFeature); + this.isESOCanEncrypt = plugins.encryptedSavedObjects.canEncrypt; if (!this.isESOCanEncrypt) { @@ -368,6 +378,7 @@ export class AlertingPlugin { ruleTypeRegistry, rulesClientFactory, alertingAuthorizationClientFactory, + rulesSettingsClientFactory, security, licenseState, } = this; @@ -416,6 +427,12 @@ export class AlertingPlugin { minimumScheduleInterval: this.config.rules.minimumScheduleInterval, }); + rulesSettingsClientFactory.initialize({ + logger: this.logger, + savedObjectsService: core.savedObjects, + securityPluginStart: plugins.security, + }); + const getRulesClientWithRequest = (request: KibanaRequest) => { if (isESOCanEncrypt !== true) { throw new Error( @@ -483,13 +500,16 @@ export class AlertingPlugin { private createRouteHandlerContext = ( core: CoreSetup ): IContextProvider => { - const { ruleTypeRegistry, rulesClientFactory } = this; + const { ruleTypeRegistry, rulesClientFactory, rulesSettingsClientFactory } = this; return async function alertsRouteHandlerContext(context, request) { const [{ savedObjects }] = await core.getStartServices(); return { getRulesClient: () => { return rulesClientFactory!.create(request, savedObjects); }, + getRulesSettingsClient: () => { + return rulesSettingsClientFactory.createWithAuthorization(request); + }, listTypes: ruleTypeRegistry!.list.bind(ruleTypeRegistry!), getFrameworkHealth: async () => await getHealth(savedObjects.createInternalRepository(['alert'])), diff --git a/x-pack/plugins/alerting/server/routes/_mock_handler_arguments.ts b/x-pack/plugins/alerting/server/routes/_mock_handler_arguments.ts index b5fbaa3d0cf86..0df0f371f62b6 100644 --- a/x-pack/plugins/alerting/server/routes/_mock_handler_arguments.ts +++ b/x-pack/plugins/alerting/server/routes/_mock_handler_arguments.ts @@ -10,17 +10,20 @@ import { identity } from 'lodash'; import type { MethodKeysOf } from '@kbn/utility-types'; import { httpServerMock } from '@kbn/core/server/mocks'; import { rulesClientMock, RulesClientMock } from '../rules_client.mock'; +import { rulesSettingsClientMock, RulesSettingsClientMock } from '../rules_settings_client.mock'; import { AlertsHealth, RuleType } from '../../common'; import type { AlertingRequestHandlerContext } from '../types'; export function mockHandlerArguments( { rulesClient = rulesClientMock.create(), + rulesSettingsClient = rulesSettingsClientMock.create(), listTypes: listTypesRes = [], getFrameworkHealth, areApiKeysEnabled, }: { rulesClient?: RulesClientMock; + rulesSettingsClient?: RulesSettingsClientMock; listTypes?: RuleType[]; getFrameworkHealth?: jest.MockInstance, []> & (() => Promise); @@ -41,6 +44,9 @@ export function mockHandlerArguments( getRulesClient() { return rulesClient || rulesClientMock.create(); }, + getRulesSettingsClient() { + return rulesSettingsClient || rulesSettingsClientMock.create(); + }, getFrameworkHealth, areApiKeysEnabled: areApiKeysEnabled ? areApiKeysEnabled : () => Promise.resolve(true), }, diff --git a/x-pack/plugins/alerting/server/routes/get_flapping_settings.test.ts b/x-pack/plugins/alerting/server/routes/get_flapping_settings.test.ts new file mode 100644 index 0000000000000..156ab604fb905 --- /dev/null +++ b/x-pack/plugins/alerting/server/routes/get_flapping_settings.test.ts @@ -0,0 +1,63 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { httpServiceMock } from '@kbn/core/server/mocks'; +import { licenseStateMock } from '../lib/license_state.mock'; +import { mockHandlerArguments } from './_mock_handler_arguments'; +import { rulesSettingsClientMock, RulesSettingsClientMock } from '../rules_settings_client.mock'; +import { getFlappingSettingsRoute } from './get_flapping_settings'; + +let rulesSettingsClient: RulesSettingsClientMock; + +jest.mock('../lib/license_api_access', () => ({ + verifyApiAccess: jest.fn(), +})); + +beforeEach(() => { + jest.resetAllMocks(); + rulesSettingsClient = rulesSettingsClientMock.create(); +}); + +describe('getFlappingSettingsRoute', () => { + test('gets flapping settings', async () => { + const licenseState = licenseStateMock.create(); + const router = httpServiceMock.createRouter(); + + getFlappingSettingsRoute(router, licenseState); + + const [config, handler] = router.get.mock.calls[0]; + + expect(config).toMatchInlineSnapshot(` + Object { + "options": Object { + "tags": Array [ + "access:read-flapping-settings", + ], + }, + "path": "/internal/alerting/rules/settings/_flapping", + "validate": false, + } + `); + + (rulesSettingsClient.flapping().get as jest.Mock).mockResolvedValue({ + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 10, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), + }); + + const [context, req, res] = mockHandlerArguments({ rulesSettingsClient }, {}, ['ok']); + + await handler(context, req, res); + + expect(rulesSettingsClient.flapping().get).toHaveBeenCalledTimes(1); + expect(res.ok).toHaveBeenCalled(); + }); +}); diff --git a/x-pack/plugins/alerting/server/routes/get_flapping_settings.ts b/x-pack/plugins/alerting/server/routes/get_flapping_settings.ts new file mode 100644 index 0000000000000..6ae039032994d --- /dev/null +++ b/x-pack/plugins/alerting/server/routes/get_flapping_settings.ts @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { IRouter } from '@kbn/core/server'; +import { ILicenseState } from '../lib'; +import { AlertingRequestHandlerContext, INTERNAL_BASE_ALERTING_API_PATH } from '../types'; +import { verifyAccessAndContext } from './lib'; +import { API_PRIVILEGES } from '../../common'; + +export const getFlappingSettingsRoute = ( + router: IRouter, + licenseState: ILicenseState +) => { + router.get( + { + path: `${INTERNAL_BASE_ALERTING_API_PATH}/rules/settings/_flapping`, + validate: false, + options: { + tags: [`access:${API_PRIVILEGES.READ_FLAPPING_SETTINGS}`], + }, + }, + router.handleLegacyErrors( + verifyAccessAndContext(licenseState, async function (context, req, res) { + const rulesSettingsClient = (await context.alerting).getRulesSettingsClient(); + const flappingSettings = await rulesSettingsClient.flapping().get(); + return res.ok({ body: flappingSettings }); + }) + ) + ); +}; diff --git a/x-pack/plugins/alerting/server/routes/index.ts b/x-pack/plugins/alerting/server/routes/index.ts index c4c62a92cbede..32deff30edd7c 100644 --- a/x-pack/plugins/alerting/server/routes/index.ts +++ b/x-pack/plugins/alerting/server/routes/index.ts @@ -42,6 +42,8 @@ import { bulkDeleteRulesRoute } from './bulk_delete_rules'; import { bulkEnableRulesRoute } from './bulk_enable_rules'; import { bulkDisableRulesRoute } from './bulk_disable_rules'; import { cloneRuleRoute } from './clone_rule'; +import { getFlappingSettingsRoute } from './get_flapping_settings'; +import { updateFlappingSettingsRoute } from './update_flapping_settings'; export interface RouteOptions { router: IRouter; @@ -87,4 +89,6 @@ export function defineRoutes(opts: RouteOptions) { unsnoozeRuleRoute(router, licenseState); runSoonRoute(router, licenseState); cloneRuleRoute(router, licenseState); + getFlappingSettingsRoute(router, licenseState); + updateFlappingSettingsRoute(router, licenseState); } diff --git a/x-pack/plugins/alerting/server/routes/update_flapping_settings.test.ts b/x-pack/plugins/alerting/server/routes/update_flapping_settings.test.ts new file mode 100644 index 0000000000000..28914e71e7dd3 --- /dev/null +++ b/x-pack/plugins/alerting/server/routes/update_flapping_settings.test.ts @@ -0,0 +1,82 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { httpServiceMock } from '@kbn/core/server/mocks'; +import { licenseStateMock } from '../lib/license_state.mock'; +import { mockHandlerArguments } from './_mock_handler_arguments'; +import { rulesSettingsClientMock, RulesSettingsClientMock } from '../rules_settings_client.mock'; +import { updateFlappingSettingsRoute } from './update_flapping_settings'; + +let rulesSettingsClient: RulesSettingsClientMock; + +jest.mock('../lib/license_api_access', () => ({ + verifyApiAccess: jest.fn(), +})); + +beforeEach(() => { + jest.resetAllMocks(); + rulesSettingsClient = rulesSettingsClientMock.create(); +}); + +describe('updateFlappingSettingsRoute', () => { + test('updates flapping settings', async () => { + const licenseState = licenseStateMock.create(); + const router = httpServiceMock.createRouter(); + + updateFlappingSettingsRoute(router, licenseState); + + const [config, handler] = router.post.mock.calls[0]; + + expect(config.path).toMatchInlineSnapshot(`"/internal/alerting/rules/settings/_flapping"`); + expect(config.options).toMatchInlineSnapshot(` + Object { + "tags": Array [ + "access:write-flapping-settings", + ], + } + `); + + (rulesSettingsClient.flapping().get as jest.Mock).mockResolvedValue({ + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 10, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), + }); + + const updateResult = { + enabled: false, + lookBackWindow: 6, + statusChangeThreshold: 5, + }; + + const [context, req, res] = mockHandlerArguments( + { rulesSettingsClient }, + { + body: updateResult, + }, + ['ok'] + ); + + await handler(context, req, res); + + expect(rulesSettingsClient.flapping().update).toHaveBeenCalledTimes(1); + expect((rulesSettingsClient.flapping().update as jest.Mock).mock.calls[0]) + .toMatchInlineSnapshot(` + Array [ + Object { + "enabled": false, + "lookBackWindow": 6, + "statusChangeThreshold": 5, + }, + ] + `); + expect(res.ok).toHaveBeenCalled(); + }); +}); diff --git a/x-pack/plugins/alerting/server/routes/update_flapping_settings.ts b/x-pack/plugins/alerting/server/routes/update_flapping_settings.ts new file mode 100644 index 0000000000000..ede33a7d36a95 --- /dev/null +++ b/x-pack/plugins/alerting/server/routes/update_flapping_settings.ts @@ -0,0 +1,47 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { IRouter } from '@kbn/core/server'; +import { schema } from '@kbn/config-schema'; +import { ILicenseState } from '../lib'; +import { verifyAccessAndContext } from './lib'; +import { AlertingRequestHandlerContext, INTERNAL_BASE_ALERTING_API_PATH } from '../types'; +import { API_PRIVILEGES } from '../../common'; + +const bodySchema = schema.object({ + enabled: schema.boolean(), + lookBackWindow: schema.number(), + statusChangeThreshold: schema.number(), +}); + +export const updateFlappingSettingsRoute = ( + router: IRouter, + licenseState: ILicenseState +) => { + router.post( + { + path: `${INTERNAL_BASE_ALERTING_API_PATH}/rules/settings/_flapping`, + validate: { + body: bodySchema, + }, + options: { + tags: [`access:${API_PRIVILEGES.WRITE_FLAPPING_SETTINGS}`], + }, + }, + router.handleLegacyErrors( + verifyAccessAndContext(licenseState, async function (context, req, res) { + const rulesSettingsClient = (await context.alerting).getRulesSettingsClient(); + + const updatedFlappingSettings = await rulesSettingsClient.flapping().update(req.body); + + return res.ok({ + body: updatedFlappingSettings, + }); + }) + ) + ); +}; diff --git a/x-pack/plugins/alerting/server/rules_client/tests/bulk_edit.test.ts b/x-pack/plugins/alerting/server/rules_client/tests/bulk_edit.test.ts index 10df25fb2d997..9f302d178b394 100644 --- a/x-pack/plugins/alerting/server/rules_client/tests/bulk_edit.test.ts +++ b/x-pack/plugins/alerting/server/rules_client/tests/bulk_edit.test.ts @@ -6,7 +6,7 @@ */ import { schema } from '@kbn/config-schema'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { RulesClient, ConstructorOptions } from '../rules_client'; import { savedObjectsClientMock, loggingSystemMock } from '@kbn/core/server/mocks'; import { taskManagerMock } from '@kbn/task-manager-plugin/server/mocks'; @@ -591,7 +591,7 @@ describe('bulkEdit()', () => { const getSnoozeSchedule = (useId: boolean = true) => { return { - ...(useId && { id: uuid.v4() }), + ...(useId && { id: uuidv4() }), duration: 28800000, rRule: { dtstart: '2010-09-19T11:49:59.329Z', diff --git a/x-pack/plugins/alerting/server/rules_client/tests/update.test.ts b/x-pack/plugins/alerting/server/rules_client/tests/update.test.ts index 8c18e887c7d03..f28c9d74e5472 100644 --- a/x-pack/plugins/alerting/server/rules_client/tests/update.test.ts +++ b/x-pack/plugins/alerting/server/rules_client/tests/update.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { schema } from '@kbn/config-schema'; import { RulesClient, ConstructorOptions } from '../rules_client'; import { savedObjectsClientMock, loggingSystemMock } from '@kbn/core/server/mocks'; @@ -1649,8 +1649,8 @@ describe('update()', () => { } test('updating the alert schedule should call taskManager.bulkUpdateSchedules', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '60m' }, { interval: '1m' }); @@ -1684,8 +1684,8 @@ describe('update()', () => { }); test('updating the alert without changing the schedule should not call taskManager.bulkUpdateSchedules', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '1m' }, { interval: '1m' }); @@ -1719,8 +1719,8 @@ describe('update()', () => { }); test('throws error when mixing and matching global and per-action frequency values', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '1m' }, { interval: '1m' }); await expect( @@ -1812,8 +1812,8 @@ describe('update()', () => { }); test('throws error when neither global frequency nor action frequency are defined', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '1m' }, { interval: '1m' }); @@ -1848,8 +1848,8 @@ describe('update()', () => { }); test('throws error when when some actions are missing frequency params', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '1m' }, { interval: '1m' }); @@ -1896,8 +1896,8 @@ describe('update()', () => { }); test('logs when update of schedule of an alerts underlying task fails', async () => { - const alertId = uuid.v4(); - const taskId = uuid.v4(); + const alertId = uuidv4(); + const taskId = uuidv4(); mockApiCalls(alertId, taskId, { interval: '1m' }, { interval: '30s' }); diff --git a/x-pack/plugins/alerting/server/rules_settings_client.mock.ts b/x-pack/plugins/alerting/server/rules_settings_client.mock.ts new file mode 100644 index 0000000000000..2c321e54ebf71 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client.mock.ts @@ -0,0 +1,32 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { RulesSettingsClientApi, RulesSettingsFlappingClientApi } from './types'; + +export type RulesSettingsClientMock = jest.Mocked; +export type RulesSettingsFlappingClientMock = jest.Mocked; + +// Warning: Becareful when resetting all mocks in tests as it would clear +// the mock return value on the flapping +const createRulesSettingsClientMock = () => { + const flappingMocked: RulesSettingsFlappingClientMock = { + get: jest.fn(), + update: jest.fn(), + }; + const mocked: RulesSettingsClientMock = { + get: jest.fn(), + create: jest.fn(), + flapping: jest.fn().mockReturnValue(flappingMocked), + }; + return mocked; +}; + +export const rulesSettingsClientMock: { + create: () => RulesSettingsClientMock; +} = { + create: createRulesSettingsClientMock, +}; diff --git a/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.test.ts b/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.test.ts new file mode 100644 index 0000000000000..ca69100fcfaed --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.test.ts @@ -0,0 +1,185 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + RulesSettingsFlappingClient, + RulesSettingsFlappingClientConstructorOptions, +} from './rules_settings_flapping_client'; +import { savedObjectsClientMock, loggingSystemMock } from '@kbn/core/server/mocks'; +import { + RULES_SETTINGS_FEATURE_ID, + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, + DEFAULT_FLAPPING_SETTINGS, + RulesSettings, +} from '../../../common'; + +const mockDateString = '2019-02-12T21:01:22.479Z'; + +const savedObjectsClient = savedObjectsClientMock.create(); + +const getMockRulesSettings = (): RulesSettings => { + return { + flapping: { + enabled: DEFAULT_FLAPPING_SETTINGS.enabled, + lookBackWindow: DEFAULT_FLAPPING_SETTINGS.lookBackWindow, + statusChangeThreshold: DEFAULT_FLAPPING_SETTINGS.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), + }, + }; +}; + +const rulesSettingsFlappingClientParams: jest.Mocked = + { + logger: loggingSystemMock.create().get(), + getOrCreate: jest.fn().mockReturnValue({ + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: getMockRulesSettings(), + references: [], + version: '123', + }), + getModificationMetadata: jest.fn(), + savedObjectsClient, + }; + +describe('RulesSettingsFlappingClient', () => { + beforeAll(() => { + jest.useFakeTimers(); + jest.setSystemTime(new Date(mockDateString)); + }); + + afterAll(() => { + jest.clearAllMocks(); + jest.useRealTimers(); + }); + + test('can get flapping settings', async () => { + const client = new RulesSettingsFlappingClient(rulesSettingsFlappingClientParams); + const result = await client.get(); + + expect(result).toEqual( + expect.objectContaining({ + enabled: DEFAULT_FLAPPING_SETTINGS.enabled, + lookBackWindow: DEFAULT_FLAPPING_SETTINGS.lookBackWindow, + statusChangeThreshold: DEFAULT_FLAPPING_SETTINGS.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }) + ); + }); + + test('can update flapping settings', async () => { + const client = new RulesSettingsFlappingClient(rulesSettingsFlappingClientParams); + + const mockResolve = { + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: getMockRulesSettings(), + references: [], + version: '123', + }; + + savedObjectsClient.update.mockResolvedValueOnce({ + ...mockResolve, + attributes: { + flapping: { + ...mockResolve.attributes.flapping, + enabled: false, + lookBackWindow: 19, + statusChangeThreshold: 3, + }, + }, + }); + + const result = await client.update({ + enabled: false, + lookBackWindow: 19, + statusChangeThreshold: 3, + }); + + expect(savedObjectsClient.update).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, + { + flapping: expect.objectContaining({ + enabled: false, + lookBackWindow: 19, + statusChangeThreshold: 3, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }), + }, + { version: '123' } + ); + + expect(result).toEqual( + expect.objectContaining({ + enabled: false, + lookBackWindow: 19, + statusChangeThreshold: 3, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }) + ); + }); + + test('throws if savedObjectsClient failed to update', async () => { + const client = new RulesSettingsFlappingClient(rulesSettingsFlappingClientParams); + savedObjectsClient.update.mockRejectedValueOnce(new Error('failed!!')); + + await expect( + client.update({ + enabled: false, + lookBackWindow: 19, + statusChangeThreshold: 3, + }) + ).rejects.toThrowError( + 'savedObjectsClient errored trying to update flapping settings: failed!!' + ); + }); + + test('throws if new flapping setting fails verification', async () => { + const client = new RulesSettingsFlappingClient(rulesSettingsFlappingClientParams); + await expect( + client.update({ + enabled: true, + lookBackWindow: 200, + statusChangeThreshold: 500, + }) + ).rejects.toThrowError('Invalid lookBackWindow value, must be between 2 and 20, but got: 200.'); + + await expect( + client.update({ + enabled: true, + lookBackWindow: 20, + statusChangeThreshold: 500, + }) + ).rejects.toThrowError( + 'Invalid statusChangeThreshold value, must be between 2 and 20, but got: 500.' + ); + + await expect( + client.update({ + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 20, + }) + ).rejects.toThrowError( + 'Invalid values,lookBackWindow (10) must be equal to or greater than statusChangeThreshold (20).' + ); + }); +}); diff --git a/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.ts b/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.ts new file mode 100644 index 0000000000000..65db68aaba525 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client/flapping/rules_settings_flapping_client.ts @@ -0,0 +1,109 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import Boom from '@hapi/boom'; +import { Logger, SavedObjectsClientContract, SavedObject } from '@kbn/core/server'; +import { + RulesSettings, + RulesSettingsFlapping, + RulesSettingsFlappingProperties, + RulesSettingsModificationMetadata, + MIN_LOOK_BACK_WINDOW, + MAX_LOOK_BACK_WINDOW, + MIN_STATUS_CHANGE_THRESHOLD, + MAX_STATUS_CHANGE_THRESHOLD, + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, +} from '../../../common'; + +const verifyFlappingSettings = (flappingSettings: RulesSettingsFlappingProperties) => { + const { lookBackWindow, statusChangeThreshold } = flappingSettings; + + if (lookBackWindow < MIN_LOOK_BACK_WINDOW || lookBackWindow > MAX_LOOK_BACK_WINDOW) { + throw Boom.badRequest( + `Invalid lookBackWindow value, must be between ${MIN_LOOK_BACK_WINDOW} and ${MAX_LOOK_BACK_WINDOW}, but got: ${lookBackWindow}.` + ); + } + + if ( + statusChangeThreshold < MIN_STATUS_CHANGE_THRESHOLD || + statusChangeThreshold > MAX_STATUS_CHANGE_THRESHOLD + ) { + throw Boom.badRequest( + `Invalid statusChangeThreshold value, must be between ${MIN_STATUS_CHANGE_THRESHOLD} and ${MAX_STATUS_CHANGE_THRESHOLD}, but got: ${statusChangeThreshold}.` + ); + } + + if (lookBackWindow < statusChangeThreshold) { + throw Boom.badRequest( + `Invalid values,lookBackWindow (${lookBackWindow}) must be equal to or greater than statusChangeThreshold (${statusChangeThreshold}).` + ); + } +}; + +export interface RulesSettingsFlappingClientConstructorOptions { + readonly logger: Logger; + readonly savedObjectsClient: SavedObjectsClientContract; + readonly getOrCreate: () => Promise>; + readonly getModificationMetadata: () => Promise; +} + +export class RulesSettingsFlappingClient { + private readonly logger: Logger; + private readonly savedObjectsClient: SavedObjectsClientContract; + private readonly getOrCreate: () => Promise>; + private readonly getModificationMetadata: () => Promise; + + constructor(options: RulesSettingsFlappingClientConstructorOptions) { + this.logger = options.logger; + this.savedObjectsClient = options.savedObjectsClient; + this.getOrCreate = options.getOrCreate; + this.getModificationMetadata = options.getModificationMetadata; + } + + public async get(): Promise { + const rulesSettings = await this.getOrCreate(); + return rulesSettings.attributes.flapping; + } + + public async update(newFlappingProperties: RulesSettingsFlappingProperties) { + try { + verifyFlappingSettings(newFlappingProperties); + } catch (e) { + this.logger.error( + `Failed to verify new flapping settings properties when updating. Error: ${e}` + ); + throw e; + } + + const { attributes, version } = await this.getOrCreate(); + const modificationMetadata = await this.getModificationMetadata(); + + try { + const result = await this.savedObjectsClient.update( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, + { + ...attributes, + flapping: { + ...attributes.flapping, + ...newFlappingProperties, + ...modificationMetadata, + }, + }, + { + version, + } + ); + return result.attributes.flapping; + } catch (e) { + const errorMessage = 'savedObjectsClient errored trying to update flapping settings'; + this.logger.error(`${errorMessage}: ${e}`); + throw Boom.boomify(e, { message: errorMessage }); + } + } +} diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/schema.ts b/x-pack/plugins/alerting/server/rules_settings_client/index.ts similarity index 57% rename from x-pack/plugins/security_solution/server/lib/sourcerer/routes/schema.ts rename to x-pack/plugins/alerting/server/rules_settings_client/index.ts index 9d7b446e3473f..efbb3f0b3ccfe 100644 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/schema.ts +++ b/x-pack/plugins/alerting/server/rules_settings_client/index.ts @@ -5,12 +5,5 @@ * 2.0. */ -import * as t from 'io-ts'; - -export const sourcererSchema = t.type({ - patternList: t.array(t.string), -}); - -export const sourcererDataViewSchema = t.type({ - dataViewId: t.string, -}); +export * from './rules_settings_client'; +export * from './flapping/rules_settings_flapping_client'; diff --git a/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.test.ts b/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.test.ts new file mode 100644 index 0000000000000..a40c491b9117e --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.test.ts @@ -0,0 +1,285 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + RulesSettingsClient, + RulesSettingsClientConstructorOptions, +} from './rules_settings_client'; +import { RulesSettingsFlappingClient } from './flapping/rules_settings_flapping_client'; +import { savedObjectsClientMock, loggingSystemMock } from '@kbn/core/server/mocks'; +import { SavedObjectsErrorHelpers } from '@kbn/core/server'; +import { + RULES_SETTINGS_FEATURE_ID, + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, + DEFAULT_FLAPPING_SETTINGS, + RulesSettings, +} from '../../common'; + +const mockDateString = '2019-02-12T21:01:22.479Z'; + +const savedObjectsClient = savedObjectsClientMock.create(); + +const rulesSettingsClientParams: jest.Mocked = { + logger: loggingSystemMock.create().get(), + getUserName: jest.fn(), + savedObjectsClient, +}; + +const getMockRulesSettings = (): RulesSettings => { + return { + flapping: { + enabled: DEFAULT_FLAPPING_SETTINGS.enabled, + lookBackWindow: DEFAULT_FLAPPING_SETTINGS.lookBackWindow, + statusChangeThreshold: DEFAULT_FLAPPING_SETTINGS.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), + }, + }; +}; + +describe('RulesSettingsClient', () => { + beforeAll(() => { + jest.useFakeTimers(); + jest.setSystemTime(new Date(mockDateString)); + }); + + afterAll(() => { + jest.useRealTimers(); + }); + + beforeEach(() => { + jest.resetAllMocks(); + rulesSettingsClientParams.getUserName.mockResolvedValue('test name'); + }); + + test('can initialize correctly', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + expect(client.flapping()).toEqual(expect.any(RulesSettingsFlappingClient)); + }); + + test('can create a new rules settings saved object', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + const mockAttributes = getMockRulesSettings(); + + savedObjectsClient.create.mockResolvedValueOnce({ + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: mockAttributes, + references: [], + }); + + const result = await client.create(); + + expect(savedObjectsClient.create).toHaveBeenCalledTimes(1); + expect(savedObjectsClient.create).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + { + flapping: expect.objectContaining({ + enabled: mockAttributes.flapping.enabled, + lookBackWindow: mockAttributes.flapping.lookBackWindow, + statusChangeThreshold: mockAttributes.flapping.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }), + }, + { + id: RULES_SETTINGS_SAVED_OBJECT_ID, + overwrite: true, + } + ); + expect(result.attributes).toEqual(mockAttributes); + }); + + test('can get existing rules settings saved object', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + const mockAttributes = getMockRulesSettings(); + + savedObjectsClient.get.mockResolvedValueOnce({ + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: mockAttributes, + references: [], + }); + const result = await client.get(); + expect(result.attributes).toEqual(mockAttributes); + }); + + test('throws if there is no existing saved object to get', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + + savedObjectsClient.get.mockRejectedValueOnce( + SavedObjectsErrorHelpers.createGenericNotFoundError( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ) + ); + await expect(client.get()).rejects.toThrowError(); + }); + + test('can persist flapping settings when saved object does not exist', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + const mockAttributes = getMockRulesSettings(); + savedObjectsClient.get.mockRejectedValueOnce( + SavedObjectsErrorHelpers.createGenericNotFoundError( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ) + ); + + savedObjectsClient.create.mockResolvedValueOnce({ + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: mockAttributes, + references: [], + }); + + const result = await client.flapping().get(); + + expect(savedObjectsClient.get).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ); + + expect(savedObjectsClient.create).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + { + flapping: expect.objectContaining({ + enabled: mockAttributes.flapping.enabled, + lookBackWindow: mockAttributes.flapping.lookBackWindow, + statusChangeThreshold: mockAttributes.flapping.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }), + }, + { + id: RULES_SETTINGS_SAVED_OBJECT_ID, + overwrite: true, + } + ); + expect(result).toEqual(mockAttributes.flapping); + }); + + test('can persist flapping settings when saved object already exists', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + const mockAttributes = getMockRulesSettings(); + + savedObjectsClient.get.mockResolvedValueOnce({ + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: mockAttributes, + references: [], + }); + + const result = await client.flapping().get(); + + expect(savedObjectsClient.get).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ); + expect(savedObjectsClient.create).not.toHaveBeenCalled(); + expect(result).toEqual(mockAttributes.flapping); + }); + + test('can update flapping settings when saved object does not exist', async () => { + const client = new RulesSettingsClient(rulesSettingsClientParams); + const mockAttributes = getMockRulesSettings(); + + savedObjectsClient.get.mockRejectedValueOnce( + SavedObjectsErrorHelpers.createGenericNotFoundError( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ) + ); + + const mockResolve = { + id: RULES_SETTINGS_FEATURE_ID, + type: RULES_SETTINGS_SAVED_OBJECT_TYPE, + attributes: mockAttributes, + references: [], + version: '123', + }; + + savedObjectsClient.create.mockResolvedValueOnce(mockResolve); + savedObjectsClient.update.mockResolvedValueOnce({ + ...mockResolve, + attributes: { + flapping: { + ...mockResolve.attributes.flapping, + enabled: false, + lookBackWindow: 5, + statusChangeThreshold: 5, + }, + }, + }); + + // Try to update with new values + const result = await client.flapping().update({ + enabled: false, + lookBackWindow: 5, + statusChangeThreshold: 5, + }); + + // Tried to get first, but no results + expect(savedObjectsClient.get).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ); + + // So create a new entry + expect(savedObjectsClient.create).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + { + flapping: expect.objectContaining({ + enabled: mockAttributes.flapping.enabled, + lookBackWindow: mockAttributes.flapping.lookBackWindow, + statusChangeThreshold: mockAttributes.flapping.statusChangeThreshold, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }), + }, + { + id: RULES_SETTINGS_SAVED_OBJECT_ID, + overwrite: true, + } + ); + + // Try to update with version + expect(savedObjectsClient.update).toHaveBeenCalledWith( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, + { + flapping: expect.objectContaining({ + enabled: false, + lookBackWindow: 5, + statusChangeThreshold: 5, + createdBy: 'test name', + updatedBy: 'test name', + createdAt: expect.any(String), + updatedAt: expect.any(String), + }), + }, + { version: '123' } + ); + + expect(result).toEqual( + expect.objectContaining({ + enabled: false, + lookBackWindow: 5, + statusChangeThreshold: 5, + }) + ); + }); +}); diff --git a/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.ts b/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.ts new file mode 100644 index 0000000000000..1a99ab5644246 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client/rules_settings_client.ts @@ -0,0 +1,114 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + Logger, + SavedObjectsClientContract, + SavedObject, + SavedObjectsErrorHelpers, +} from '@kbn/core/server'; +import { RulesSettingsFlappingClient } from './flapping/rules_settings_flapping_client'; +import { + RulesSettings, + DEFAULT_FLAPPING_SETTINGS, + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID, +} from '../../common'; + +export interface RulesSettingsClientConstructorOptions { + readonly logger: Logger; + readonly savedObjectsClient: SavedObjectsClientContract; + readonly getUserName: () => Promise; +} + +export class RulesSettingsClient { + private readonly logger: Logger; + private readonly savedObjectsClient: SavedObjectsClientContract; + private readonly getUserName: () => Promise; + private readonly _flapping: RulesSettingsFlappingClient; + + constructor(options: RulesSettingsClientConstructorOptions) { + this.logger = options.logger; + this.savedObjectsClient = options.savedObjectsClient; + this.getUserName = options.getUserName; + + this._flapping = new RulesSettingsFlappingClient({ + logger: this.logger, + savedObjectsClient: this.savedObjectsClient, + getOrCreate: this.getOrCreate.bind(this), + getModificationMetadata: this.getModificationMetadata.bind(this), + }); + } + + private async getModificationMetadata() { + const createTime = Date.now(); + const userName = await this.getUserName(); + + return { + createdBy: userName, + updatedBy: userName, + createdAt: new Date(createTime).toISOString(), + updatedAt: new Date(createTime).toISOString(), + }; + } + + public async get(): Promise> { + try { + return await this.savedObjectsClient.get( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + RULES_SETTINGS_SAVED_OBJECT_ID + ); + } catch (e) { + this.logger.error(`Failed to get rules setting for current space. Error: ${e}`); + throw e; + } + } + + public async create(): Promise> { + const modificationMetadata = await this.getModificationMetadata(); + + try { + return await this.savedObjectsClient.create( + RULES_SETTINGS_SAVED_OBJECT_TYPE, + { + flapping: { + ...DEFAULT_FLAPPING_SETTINGS, + ...modificationMetadata, + }, + }, + { + id: RULES_SETTINGS_SAVED_OBJECT_ID, + overwrite: true, + } + ); + } catch (e) { + this.logger.error(`Failed to create rules setting for current space. Error: ${e}`); + throw e; + } + } + + /** + * Helper function to ensure that a rules-settings saved object always exists. + * Enabled the creation of the saved object is done lazily during retrieval. + */ + private async getOrCreate(): Promise> { + try { + return await this.get(); + } catch (e) { + if (SavedObjectsErrorHelpers.isNotFoundError(e)) { + this.logger.info('Creating new default rules settings for current space.'); + return await this.create(); + } + this.logger.error(`Failed to persist rules setting for current space. Error: ${e}`); + throw e; + } + } + + public flapping(): RulesSettingsFlappingClient { + return this._flapping; + } +} diff --git a/x-pack/plugins/alerting/server/rules_settings_client_factory.test.ts b/x-pack/plugins/alerting/server/rules_settings_client_factory.test.ts new file mode 100644 index 0000000000000..176082ee02336 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client_factory.test.ts @@ -0,0 +1,161 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { Request } from '@hapi/hapi'; +import { CoreKibanaRequest } from '@kbn/core/server'; +import { + RulesSettingsClientFactory, + RulesSettingsClientFactoryOpts, +} from './rules_settings_client_factory'; +import { + savedObjectsClientMock, + savedObjectsServiceMock, + loggingSystemMock, +} from '@kbn/core/server/mocks'; +import { AuthenticatedUser } from '@kbn/security-plugin/common/model'; +import { securityMock } from '@kbn/security-plugin/server/mocks'; +import { SECURITY_EXTENSION_ID } from '@kbn/core-saved-objects-server'; +import { RULES_SETTINGS_SAVED_OBJECT_TYPE } from '../common'; + +jest.mock('./rules_settings_client'); + +const savedObjectsClient = savedObjectsClientMock.create(); +const savedObjectsService = savedObjectsServiceMock.createInternalStartContract(); + +const securityPluginStart = securityMock.createStart(); + +const rulesSettingsClientFactoryParams: jest.Mocked = { + logger: loggingSystemMock.create().get(), + savedObjectsService, +}; + +const fakeRequest = { + app: {}, + headers: {}, + getBasePath: () => '', + path: '/', + route: { settings: {} }, + url: { + href: '/', + }, + raw: { + req: { + url: '/', + }, + }, + getSavedObjectsClient: () => savedObjectsClient, +} as unknown as Request; + +beforeEach(() => { + jest.resetAllMocks(); +}); + +test('creates a rules settings client with proper constructor arguments when security is enabled', async () => { + const factory = new RulesSettingsClientFactory(); + factory.initialize({ + securityPluginStart, + ...rulesSettingsClientFactoryParams, + }); + const request = CoreKibanaRequest.from(fakeRequest); + + savedObjectsService.getScopedClient.mockReturnValue(savedObjectsClient); + + factory.createWithAuthorization(request); + + expect(savedObjectsService.getScopedClient).toHaveBeenCalledWith(request, { + includedHiddenTypes: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + }); + + const { RulesSettingsClient } = jest.requireMock('./rules_settings_client'); + + expect(RulesSettingsClient).toHaveBeenCalledWith({ + logger: rulesSettingsClientFactoryParams.logger, + savedObjectsClient, + getUserName: expect.any(Function), + }); +}); + +test('creates a rules settings client with proper constructor arguments', async () => { + const factory = new RulesSettingsClientFactory(); + factory.initialize(rulesSettingsClientFactoryParams); + const request = CoreKibanaRequest.from(fakeRequest); + + savedObjectsService.getScopedClient.mockReturnValue(savedObjectsClient); + + factory.createWithAuthorization(request); + + expect(savedObjectsService.getScopedClient).toHaveBeenCalledWith(request, { + includedHiddenTypes: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + }); + + const { RulesSettingsClient } = jest.requireMock('./rules_settings_client'); + + expect(RulesSettingsClient).toHaveBeenCalledWith({ + logger: rulesSettingsClientFactoryParams.logger, + savedObjectsClient, + getUserName: expect.any(Function), + }); +}); + +test('creates an unauthorized rules settings client', async () => { + const factory = new RulesSettingsClientFactory(); + factory.initialize({ + securityPluginStart, + ...rulesSettingsClientFactoryParams, + }); + const request = CoreKibanaRequest.from(fakeRequest); + + savedObjectsService.getScopedClient.mockReturnValue(savedObjectsClient); + + factory.create(request); + + expect(savedObjectsService.getScopedClient).toHaveBeenCalledWith(request, { + excludedExtensions: [SECURITY_EXTENSION_ID], + includedHiddenTypes: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + }); + + const { RulesSettingsClient } = jest.requireMock('./rules_settings_client'); + + expect(RulesSettingsClient).toHaveBeenCalledWith({ + logger: rulesSettingsClientFactoryParams.logger, + savedObjectsClient, + getUserName: expect.any(Function), + }); +}); + +test('getUserName() returns null when security is disabled', async () => { + const factory = new RulesSettingsClientFactory(); + factory.initialize(rulesSettingsClientFactoryParams); + const request = CoreKibanaRequest.from(fakeRequest); + + factory.createWithAuthorization(request); + const constructorCall = + jest.requireMock('./rules_settings_client').RulesSettingsClient.mock.calls[0][0]; + + const userNameResult = await constructorCall.getUserName(); + expect(userNameResult).toEqual(null); +}); + +test('getUserName() returns a name when security is enabled', async () => { + const factory = new RulesSettingsClientFactory(); + factory.initialize({ + securityPluginStart, + ...rulesSettingsClientFactoryParams, + }); + const request = CoreKibanaRequest.from(fakeRequest); + + factory.createWithAuthorization(request); + + const constructorCall = + jest.requireMock('./rules_settings_client').RulesSettingsClient.mock.calls[0][0]; + + securityPluginStart.authc.getCurrentUser.mockReturnValueOnce({ + username: 'testname', + } as unknown as AuthenticatedUser); + const userNameResult = await constructorCall.getUserName(); + expect(userNameResult).toEqual('testname'); +}); diff --git a/x-pack/plugins/alerting/server/rules_settings_client_factory.ts b/x-pack/plugins/alerting/server/rules_settings_client_factory.ts new file mode 100644 index 0000000000000..619e498c6b988 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_client_factory.ts @@ -0,0 +1,67 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + KibanaRequest, + Logger, + SavedObjectsServiceStart, + SECURITY_EXTENSION_ID, +} from '@kbn/core/server'; +import { SecurityPluginStart } from '@kbn/security-plugin/server'; +import { RulesSettingsClient } from './rules_settings_client'; +import { RULES_SETTINGS_SAVED_OBJECT_TYPE } from '../common'; + +export interface RulesSettingsClientFactoryOpts { + logger: Logger; + savedObjectsService: SavedObjectsServiceStart; + securityPluginStart?: SecurityPluginStart; +} + +export class RulesSettingsClientFactory { + private isInitialized = false; + private logger!: Logger; + private savedObjectsService!: SavedObjectsServiceStart; + private securityPluginStart?: SecurityPluginStart; + + public initialize(options: RulesSettingsClientFactoryOpts) { + if (this.isInitialized) { + throw new Error('RulesSettingsClientFactory already initialized'); + } + this.isInitialized = true; + this.logger = options.logger; + this.savedObjectsService = options.savedObjectsService; + this.securityPluginStart = options.securityPluginStart; + } + + private createRulesSettingsClient(request: KibanaRequest, withAuth: boolean) { + const { securityPluginStart } = this; + const savedObjectsClient = this.savedObjectsService.getScopedClient(request, { + includedHiddenTypes: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + ...(withAuth ? {} : { excludedExtensions: [SECURITY_EXTENSION_ID] }), + }); + + return new RulesSettingsClient({ + logger: this.logger, + savedObjectsClient, + async getUserName() { + if (!securityPluginStart || !request) { + return null; + } + const user = securityPluginStart.authc.getCurrentUser(request); + return user ? user.username : null; + }, + }); + } + + public createWithAuthorization(request: KibanaRequest) { + return this.createRulesSettingsClient(request, true); + } + + public create(request: KibanaRequest) { + return this.createRulesSettingsClient(request, false); + } +} diff --git a/x-pack/plugins/alerting/server/rules_settings_feature.ts b/x-pack/plugins/alerting/server/rules_settings_feature.ts new file mode 100644 index 0000000000000..c207d337a2b20 --- /dev/null +++ b/x-pack/plugins/alerting/server/rules_settings_feature.ts @@ -0,0 +1,91 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; +import { KibanaFeatureConfig } from '@kbn/features-plugin/common'; +import { DEFAULT_APP_CATEGORIES } from '@kbn/core/server'; +import { + RULES_SETTINGS_FEATURE_ID, + READ_FLAPPING_SETTINGS_SUB_FEATURE_ID, + ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID, + API_PRIVILEGES, + RULES_SETTINGS_SAVED_OBJECT_TYPE, +} from '../common'; + +export const rulesSettingsFeature: KibanaFeatureConfig = { + id: RULES_SETTINGS_FEATURE_ID, + name: i18n.translate('xpack.alerting.feature.rulesSettingsFeatureName', { + defaultMessage: 'Rules Settings', + }), + category: DEFAULT_APP_CATEGORIES.management, + app: [], + management: { + insightsAndAlerting: ['triggersActions'], + }, + privileges: { + all: { + app: [], + api: [], + management: { + insightsAndAlerting: ['triggersActions'], + }, + savedObject: { + all: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + read: [], + }, + ui: ['show', 'save'], + }, + read: { + app: [], + api: [], + management: { + insightsAndAlerting: ['triggersActions'], + }, + savedObject: { + all: [], + read: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + }, + ui: ['show'], + }, + }, + subFeatures: [ + { + name: i18n.translate('xpack.alerting.feature.flappingSettingsSubFeatureName', { + defaultMessage: 'Flapping Detection', + }), + privilegeGroups: [ + { + groupType: 'mutually_exclusive', + privileges: [ + { + api: [API_PRIVILEGES.READ_FLAPPING_SETTINGS, API_PRIVILEGES.WRITE_FLAPPING_SETTINGS], + name: 'All', + id: ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID, + includeIn: 'all', + savedObject: { + all: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + read: [], + }, + ui: ['writeFlappingSettingsUI', 'readFlappingSettingsUI'], + }, + { + api: [API_PRIVILEGES.READ_FLAPPING_SETTINGS], + name: 'Read', + id: READ_FLAPPING_SETTINGS_SUB_FEATURE_ID, + includeIn: 'read', + savedObject: { + all: [], + read: [RULES_SETTINGS_SAVED_OBJECT_TYPE], + }, + ui: ['readFlappingSettingsUI'], + }, + ], + }, + ], + }, + ], +}; diff --git a/x-pack/plugins/alerting/server/saved_objects/index.ts b/x-pack/plugins/alerting/server/saved_objects/index.ts index d8d53f4978d55..cd69efaf3e875 100644 --- a/x-pack/plugins/alerting/server/saved_objects/index.ts +++ b/x-pack/plugins/alerting/server/saved_objects/index.ts @@ -14,6 +14,7 @@ import type { import { EncryptedSavedObjectsPluginSetup } from '@kbn/encrypted-saved-objects-plugin/server'; import { MigrateFunctionsObject } from '@kbn/kibana-utils-plugin/common'; import { alertMappings } from './mappings'; +import { rulesSettingsMappings } from './rules_settings_mappings'; import { getMigrations } from './migrations'; import { transformRulesForExport } from './transform_rule_for_export'; import { RawRule } from '../types'; @@ -21,6 +22,7 @@ import { getImportWarnings } from './get_import_warnings'; import { isRuleExportable } from './is_rule_exportable'; import { RuleTypeRegistry } from '../rule_type_registry'; export { partiallyUpdateAlert } from './partially_update_alert'; +import { RULES_SETTINGS_SAVED_OBJECT_TYPE } from '../../common'; // Use caution when removing items from this array! Any field which has // ever existed in the rule SO must be included in this array to prevent @@ -114,6 +116,13 @@ export function setupSavedObjects( }, }); + savedObjects.registerType({ + name: RULES_SETTINGS_SAVED_OBJECT_TYPE, + hidden: true, + namespaceType: 'single', + mappings: rulesSettingsMappings, + }); + // Encrypted attributes encryptedSavedObjects.registerType({ type: 'alert', diff --git a/x-pack/plugins/alerting/server/saved_objects/migrations/index.test.ts b/x-pack/plugins/alerting/server/saved_objects/migrations/index.test.ts index 59bbb99b9d549..8e04f7dcdcb5c 100644 --- a/x-pack/plugins/alerting/server/saved_objects/migrations/index.test.ts +++ b/x-pack/plugins/alerting/server/saved_objects/migrations/index.test.ts @@ -6,7 +6,7 @@ */ import sinon from 'sinon'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getMigrations } from '.'; import { RawRule } from '../../types'; import { SavedObjectMigrationContext, SavedObjectUnsanitizedDoc } from '@kbn/core/server'; @@ -2892,7 +2892,7 @@ function getMockData( ...overwrites, }, updated_at: withSavedObjectUpdatedAt ? getUpdatedAt() : undefined, - id: uuid.v4(), + id: uuidv4(), type: 'alert', }; } diff --git a/x-pack/plugins/alerting/server/saved_objects/rules_settings_mappings.ts b/x-pack/plugins/alerting/server/saved_objects/rules_settings_mappings.ts new file mode 100644 index 0000000000000..d20567edc2832 --- /dev/null +++ b/x-pack/plugins/alerting/server/saved_objects/rules_settings_mappings.ts @@ -0,0 +1,45 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { SavedObjectsTypeMappingDefinition } from '@kbn/core/server'; + +export const rulesSettingsMappings: SavedObjectsTypeMappingDefinition = { + properties: { + flapping: { + properties: { + enabled: { + type: 'boolean', + index: false, + }, + lookBackWindow: { + type: 'long', + index: false, + }, + statusChangeThreshold: { + type: 'long', + index: false, + }, + createdBy: { + type: 'keyword', + index: false, + }, + updatedBy: { + type: 'keyword', + index: false, + }, + createdAt: { + type: 'date', + index: false, + }, + updatedAt: { + type: 'date', + index: false, + }, + }, + }, + }, +}; diff --git a/x-pack/plugins/alerting/server/task_runner/alert_task_instance.test.ts b/x-pack/plugins/alerting/server/task_runner/alert_task_instance.test.ts index 3faea1a4d2261..b78c06eaff7b6 100644 --- a/x-pack/plugins/alerting/server/task_runner/alert_task_instance.test.ts +++ b/x-pack/plugins/alerting/server/task_runner/alert_task_instance.test.ts @@ -7,7 +7,7 @@ import { ConcreteTaskInstance, TaskStatus } from '@kbn/task-manager-plugin/server'; import { AlertTaskInstance, taskInstanceToAlertTaskInstance } from './alert_task_instance'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SanitizedRule } from '../types'; const alert: SanitizedRule<{ @@ -43,7 +43,7 @@ describe('Alert Task Instance', () => { test(`validates that a TaskInstance has valid Alert Task State`, () => { const lastScheduledActionsDate = new Date(); const taskInstance: ConcreteTaskInstance = { - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', @@ -165,7 +165,7 @@ describe('Alert Task Instance', () => { test(`allows an initial empty state`, () => { const taskInstance: ConcreteTaskInstance = { - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', @@ -188,7 +188,7 @@ describe('Alert Task Instance', () => { test(`validates that a TaskInstance has valid Params`, () => { const taskInstance: ConcreteTaskInstance = { - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', diff --git a/x-pack/plugins/alerting/server/task_runner/log_alerts.test.ts b/x-pack/plugins/alerting/server/task_runner/log_alerts.test.ts index b903e638e06aa..163cadf1d084b 100644 --- a/x-pack/plugins/alerting/server/task_runner/log_alerts.test.ts +++ b/x-pack/plugins/alerting/server/task_runner/log_alerts.test.ts @@ -9,6 +9,7 @@ import { loggingSystemMock } from '@kbn/core-logging-server-mocks'; import { Alert } from '../alert'; import { alertingEventLoggerMock } from '../lib/alerting_event_logger/alerting_event_logger.mock'; import { RuleRunMetricsStore } from '../lib/rule_run_metrics_store'; +import { DefaultActionGroupId } from '../types'; import { logAlerts } from './log_alerts'; const logger: ReturnType = loggingSystemMock.createLogger(); @@ -28,8 +29,8 @@ describe('logAlerts', () => { alertingEventLogger, newAlerts: {}, activeAlerts: { - '1': new Alert<{}, {}>('1'), - '2': new Alert<{}, {}>('2'), + '1': new Alert<{}, {}, DefaultActionGroupId>('1'), + '2': new Alert<{}, {}, DefaultActionGroupId>('2'), }, recoveredAlerts: {}, ruleLogPrefix: `test-rule-type-id:123: 'test rule'`, @@ -51,11 +52,11 @@ describe('logAlerts', () => { alertingEventLogger, newAlerts: {}, activeAlerts: { - '1': new Alert<{}, {}>('1'), - '2': new Alert<{}, {}>('2'), + '1': new Alert<{}, {}, DefaultActionGroupId>('1'), + '2': new Alert<{}, {}, DefaultActionGroupId>('2'), }, recoveredAlerts: { - '8': new Alert<{}, {}>('8'), + '8': new Alert<{}, {}, DefaultActionGroupId>('8'), }, ruleLogPrefix: `test-rule-type-id:123: 'test rule'`, ruleRunMetricsStore, @@ -75,8 +76,8 @@ describe('logAlerts', () => { }); test('should correctly debug log recovered alerts if canSetRecoveryContext is true', () => { - const recoveredAlert1 = new Alert<{ value: string }, {}>('8'); - const recoveredAlert2 = new Alert<{ value: string }, {}>('9'); + const recoveredAlert1 = new Alert<{ value: string }, {}, DefaultActionGroupId>('8'); + const recoveredAlert2 = new Alert<{ value: string }, {}, DefaultActionGroupId>('9'); const recoveredAlerts = { '8': recoveredAlert1, '9': recoveredAlert2, @@ -127,18 +128,18 @@ describe('logAlerts', () => { logger, alertingEventLogger, newAlerts: { - '4': new Alert<{}, {}>('4'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, activeAlerts: { - '1': new Alert<{}, {}>('1'), - '2': new Alert<{}, {}>('2'), - '4': new Alert<{}, {}>('4'), + '1': new Alert<{}, {}, DefaultActionGroupId>('1'), + '2': new Alert<{}, {}, DefaultActionGroupId>('2'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, recoveredAlerts: { - '7': new Alert<{}, {}>('7'), - '8': new Alert<{}, {}>('8'), - '9': new Alert<{}, {}>('9'), - '10': new Alert<{}, {}>('10'), + '7': new Alert<{}, {}, DefaultActionGroupId>('7'), + '8': new Alert<{}, {}, DefaultActionGroupId>('8'), + '9': new Alert<{}, {}, DefaultActionGroupId>('9'), + '10': new Alert<{}, {}, DefaultActionGroupId>('10'), }, ruleLogPrefix: `test-rule-type-id:123: 'test rule'`, ruleRunMetricsStore, @@ -215,18 +216,18 @@ describe('logAlerts', () => { logger, alertingEventLogger, newAlerts: { - '4': new Alert<{}, {}>('4'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, activeAlerts: { - '1': new Alert<{}, {}>('1'), - '2': new Alert<{}, {}>('2'), - '4': new Alert<{}, {}>('4'), + '1': new Alert<{}, {}, DefaultActionGroupId>('1'), + '2': new Alert<{}, {}, DefaultActionGroupId>('2'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, recoveredAlerts: { - '7': new Alert<{}, {}>('7'), - '8': new Alert<{}, {}>('8'), - '9': new Alert<{}, {}>('9'), - '10': new Alert<{}, {}>('10'), + '7': new Alert<{}, {}, DefaultActionGroupId>('7'), + '8': new Alert<{}, {}, DefaultActionGroupId>('8'), + '9': new Alert<{}, {}, DefaultActionGroupId>('9'), + '10': new Alert<{}, {}, DefaultActionGroupId>('10'), }, ruleLogPrefix: `test-rule-type-id:123: 'test rule'`, ruleRunMetricsStore, @@ -246,18 +247,18 @@ describe('logAlerts', () => { logger, alertingEventLogger, newAlerts: { - '4': new Alert<{}, {}>('4'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, activeAlerts: { - '1': new Alert<{}, {}>('1', { meta: { flapping: true } }), - '2': new Alert<{}, {}>('2'), - '4': new Alert<{}, {}>('4'), + '1': new Alert<{}, {}, DefaultActionGroupId>('1', { meta: { flapping: true } }), + '2': new Alert<{}, {}, DefaultActionGroupId>('2'), + '4': new Alert<{}, {}, DefaultActionGroupId>('4'), }, recoveredAlerts: { - '7': new Alert<{}, {}>('7'), - '8': new Alert<{}, {}>('8', { meta: { flapping: true } }), - '9': new Alert<{}, {}>('9'), - '10': new Alert<{}, {}>('10'), + '7': new Alert<{}, {}, DefaultActionGroupId>('7'), + '8': new Alert<{}, {}, DefaultActionGroupId>('8', { meta: { flapping: true } }), + '9': new Alert<{}, {}, DefaultActionGroupId>('9'), + '10': new Alert<{}, {}, DefaultActionGroupId>('10'), }, ruleLogPrefix: `test-rule-type-id:123: 'test rule'`, ruleRunMetricsStore, diff --git a/x-pack/plugins/alerting/server/task_runner/log_alerts.ts b/x-pack/plugins/alerting/server/task_runner/log_alerts.ts index 4b673b44864dd..7f8f5d93a5d9f 100644 --- a/x-pack/plugins/alerting/server/task_runner/log_alerts.ts +++ b/x-pack/plugins/alerting/server/task_runner/log_alerts.ts @@ -15,20 +15,27 @@ import { RuleRunMetricsStore } from '../lib/rule_run_metrics_store'; export interface LogAlertsParams< State extends AlertInstanceState, - Context extends AlertInstanceContext + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string > { logger: Logger; alertingEventLogger: AlertingEventLogger; - newAlerts: Record>; - activeAlerts: Record>; - recoveredAlerts: Record>; + newAlerts: Record>; + activeAlerts: Record>; + recoveredAlerts: Record>; ruleLogPrefix: string; ruleRunMetricsStore: RuleRunMetricsStore; canSetRecoveryContext: boolean; shouldPersistAlerts: boolean; } -export function logAlerts({ +export function logAlerts< + State extends AlertInstanceState, + Context extends AlertInstanceContext, + ActionGroupIds extends string, + RecoveryActionGroupId extends string +>({ logger, alertingEventLogger, newAlerts, @@ -38,7 +45,7 @@ export function logAlerts) { +}: LogAlertsParams) { const newAlertIds = Object.keys(newAlerts); const activeAlertIds = Object.keys(activeAlerts); const recoveredAlertIds = Object.keys(recoveredAlerts); diff --git a/x-pack/plugins/alerting/server/task_runner/task_runner.ts b/x-pack/plugins/alerting/server/task_runner/task_runner.ts index 27977dd3bf6f5..347c330361092 100644 --- a/x-pack/plugins/alerting/server/task_runner/task_runner.ts +++ b/x-pack/plugins/alerting/server/task_runner/task_runner.ts @@ -8,7 +8,7 @@ import apm from 'elastic-apm-node'; import { omit } from 'lodash'; import { UsageCounter } from '@kbn/usage-collection-plugin/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Logger } from '@kbn/core/server'; import { ConcreteTaskInstance, throwUnrecoverableError } from '@kbn/task-manager-plugin/server'; import { nanosToMillis } from '@kbn/event-log-plugin/server'; @@ -44,7 +44,6 @@ import { RuleTypeParams, RuleTypeState, parseDuration, - WithoutReservedActionGroups, } from '../../common'; import { NormalizedRuleType, UntypedNormalizedRuleType } from '../rule_type_registry'; import { getEsErrorMessage } from '../lib/errors'; @@ -114,7 +113,8 @@ export class TaskRunner< private legacyAlertsClient: LegacyAlertsClient< State, Context, - WithoutReservedActionGroups + ActionGroupIds, + RecoveryActionGroupId >; constructor( @@ -141,7 +141,7 @@ export class TaskRunner< this.ruleTypeRegistry = context.ruleTypeRegistry; this.searchAbortController = new AbortController(); this.cancelled = false; - this.executionId = uuid.v4(); + this.executionId = uuidv4(); this.inMemoryMetrics = inMemoryMetrics; this.maxAlerts = context.maxAlerts; this.timer = new TaskRunnerTimer({ logger: this.logger }); diff --git a/x-pack/plugins/alerting/server/types.ts b/x-pack/plugins/alerting/server/types.ts index c0399779a62df..f2a368c062d05 100644 --- a/x-pack/plugins/alerting/server/types.ts +++ b/x-pack/plugins/alerting/server/types.ts @@ -25,6 +25,7 @@ import { SharePluginStart } from '@kbn/share-plugin/server'; import { RuleTypeRegistry as OrigruleTypeRegistry } from './rule_type_registry'; import { PluginSetupContract, PluginStartContract } from './plugin'; import { RulesClient } from './rules_client'; +import { RulesSettingsClient, RulesSettingsFlappingClient } from './rules_settings_client'; export * from '../common'; import { Rule, @@ -57,6 +58,7 @@ export type { RuleTypeParams }; */ export interface AlertingApiRequestHandlerContext { getRulesClient: () => RulesClient; + getRulesSettingsClient: () => RulesSettingsClient; listTypes: RuleTypeRegistry['list']; getFrameworkHealth: () => Promise; areApiKeysEnabled: () => Promise; @@ -320,6 +322,9 @@ export type RuleTypeRegistry = PublicMethodsOf; export type RulesClientApi = PublicMethodsOf; +export type RulesSettingsClientApi = PublicMethodsOf; +export type RulesSettingsFlappingClientApi = PublicMethodsOf; + export interface PublicMetricsSetters { setLastRunMetricsTotalSearchDurationMs: (totalSearchDurationMs: number) => void; setLastRunMetricsTotalIndexingDurationMs: (totalIndexingDurationMs: number) => void; diff --git a/x-pack/plugins/apm/common/anomaly_detection/get_preferred_service_anomaly_timeseries.test.ts b/x-pack/plugins/apm/common/anomaly_detection/get_preferred_service_anomaly_timeseries.test.ts index f3bc60d67905e..da4951129dd18 100644 --- a/x-pack/plugins/apm/common/anomaly_detection/get_preferred_service_anomaly_timeseries.test.ts +++ b/x-pack/plugins/apm/common/anomaly_detection/get_preferred_service_anomaly_timeseries.test.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ENVIRONMENT_ALL } from '../environment_filter_values'; import { Environment } from '../environment_rt'; import { ApmMlDetectorType } from './apm_ml_detectors'; @@ -27,7 +27,7 @@ function createMockAnomalyTimeseries({ anomalies: [], bounds: [], environment, - jobId: uuid(), + jobId: uuidv4(), type, serviceName: 'opbeans-java', transactionType: 'request', diff --git a/x-pack/plugins/apm/common/critical_path/get_critical_path.test.ts b/x-pack/plugins/apm/common/critical_path/get_critical_path.test.ts index de6be848b4660..284147303ced0 100644 --- a/x-pack/plugins/apm/common/critical_path/get_critical_path.test.ts +++ b/x-pack/plugins/apm/common/critical_path/get_critical_path.test.ts @@ -24,7 +24,7 @@ describe('getCriticalPath', () => { exceedsMax: false, spanLinksCountById: {}, traceItemCount: events.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }, entryTransaction, }); diff --git a/x-pack/plugins/apm/common/es_fields/__snapshots__/es_fields.test.ts.snap b/x-pack/plugins/apm/common/es_fields/__snapshots__/es_fields.test.ts.snap index 224b0b3b78ab3..10c8daa6e8565 100644 --- a/x-pack/plugins/apm/common/es_fields/__snapshots__/es_fields.test.ts.snap +++ b/x-pack/plugins/apm/common/es_fields/__snapshots__/es_fields.test.ts.snap @@ -49,7 +49,7 @@ exports[`Error CONTAINER_IMAGE 1`] = `undefined`; exports[`Error DESTINATION_ADDRESS 1`] = `undefined`; -exports[`Error DEVICE_MODEL_NAME 1`] = `undefined`; +exports[`Error DEVICE_MODEL_IDENTIFIER 1`] = `undefined`; exports[`Error ERROR_CULPRIT 1`] = `"handleOopsie"`; @@ -212,6 +212,8 @@ exports[`Error SERVICE_RUNTIME_NAME 1`] = `undefined`; exports[`Error SERVICE_RUNTIME_VERSION 1`] = `undefined`; +exports[`Error SERVICE_TARGET_TYPE 1`] = `undefined`; + exports[`Error SERVICE_VERSION 1`] = `undefined`; exports[`Error SESSION_ID 1`] = `undefined`; @@ -337,7 +339,7 @@ exports[`Span CONTAINER_IMAGE 1`] = `undefined`; exports[`Span DESTINATION_ADDRESS 1`] = `undefined`; -exports[`Span DEVICE_MODEL_NAME 1`] = `undefined`; +exports[`Span DEVICE_MODEL_IDENTIFIER 1`] = `undefined`; exports[`Span ERROR_CULPRIT 1`] = `undefined`; @@ -483,6 +485,8 @@ exports[`Span SERVICE_RUNTIME_NAME 1`] = `undefined`; exports[`Span SERVICE_RUNTIME_VERSION 1`] = `undefined`; +exports[`Span SERVICE_TARGET_TYPE 1`] = `undefined`; + exports[`Span SERVICE_VERSION 1`] = `undefined`; exports[`Span SESSION_ID 1`] = `undefined`; @@ -612,7 +616,7 @@ exports[`Transaction CONTAINER_IMAGE 1`] = `undefined`; exports[`Transaction DESTINATION_ADDRESS 1`] = `undefined`; -exports[`Transaction DEVICE_MODEL_NAME 1`] = `undefined`; +exports[`Transaction DEVICE_MODEL_IDENTIFIER 1`] = `undefined`; exports[`Transaction ERROR_CULPRIT 1`] = `undefined`; @@ -772,6 +776,8 @@ exports[`Transaction SERVICE_RUNTIME_NAME 1`] = `undefined`; exports[`Transaction SERVICE_RUNTIME_VERSION 1`] = `undefined`; +exports[`Transaction SERVICE_TARGET_TYPE 1`] = `undefined`; + exports[`Transaction SERVICE_VERSION 1`] = `undefined`; exports[`Transaction SESSION_ID 1`] = `undefined`; diff --git a/x-pack/plugins/apm/common/es_fields/apm.ts b/x-pack/plugins/apm/common/es_fields/apm.ts index 3bf8c1919946f..c20b70e0add76 100644 --- a/x-pack/plugins/apm/common/es_fields/apm.ts +++ b/x-pack/plugins/apm/common/es_fields/apm.ts @@ -32,6 +32,7 @@ export const SERVICE_RUNTIME_NAME = 'service.runtime.name'; export const SERVICE_RUNTIME_VERSION = 'service.runtime.version'; export const SERVICE_NODE_NAME = 'service.node.name'; export const SERVICE_VERSION = 'service.version'; +export const SERVICE_TARGET_TYPE = 'service.target.type'; export const URL_FULL = 'url.full'; export const HTTP_REQUEST_METHOD = 'http.request.method'; @@ -158,7 +159,7 @@ export const INDEX = '_index'; // Mobile export const NETWORK_CONNECTION_TYPE = 'network.connection.type'; -export const DEVICE_MODEL_NAME = 'device.model.name'; +export const DEVICE_MODEL_IDENTIFIER = 'device.model.identifier'; export const SESSION_ID = 'session.id'; export const APP_LAUNCH_TIME = 'application.launch.time'; export const EVENT_NAME = 'event.name'; diff --git a/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.test.ts b/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.test.ts index b6ad94d3cc0bb..cacc544a3afe8 100644 --- a/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.test.ts +++ b/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.test.ts @@ -15,7 +15,7 @@ describe('getKueryWithMobileFilters', () => { appVersion: '', netConnectionType: undefined, }); - expect(result).toBe('device.model.name: foo'); + expect(result).toBe('device.model.identifier: foo'); }); it('should return only kuery when mobile filters are missing ', () => { @@ -38,7 +38,7 @@ describe('getKueryWithMobileFilters', () => { kuery: '', }); expect(result).toBe( - 'device.model.name: foo and host.os.version: bar and service.version: 1.0 and network.connection.type: fooBar' + 'device.model.identifier: foo and host.os.version: bar and service.version: 1.0 and network.connection.type: fooBar' ); }); @@ -52,7 +52,7 @@ describe('getKueryWithMobileFilters', () => { }); expect(result).toBe( - 'foo.bar.test: test and device.model.name: foo and host.os.version: bar and service.version: 1.0 and network.connection.type: fooBar' + 'foo.bar.test: test and device.model.identifier: foo and host.os.version: bar and service.version: 1.0 and network.connection.type: fooBar' ); }); @@ -66,7 +66,7 @@ describe('getKueryWithMobileFilters', () => { }); expect(result).toBe( - 'foo.bar.test: test and device.model.name: foo\\>. and host.os.version: bar\\*\\* and service.version: 1.0\\(\\)\\: and network.connection.type: fooBar\\)45' + 'foo.bar.test: test and device.model.identifier: foo\\>. and host.os.version: bar\\*\\* and service.version: 1.0\\(\\)\\: and network.connection.type: fooBar\\)45' ); }); }); diff --git a/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.ts b/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.ts index 6244b5a72f1f4..19970a0b24b93 100644 --- a/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.ts +++ b/x-pack/plugins/apm/common/utils/get_kuery_with_mobile_filters.ts @@ -7,7 +7,7 @@ import { HOST_OS_VERSION, - DEVICE_MODEL_NAME, + DEVICE_MODEL_IDENTIFIER, NETWORK_CONNECTION_TYPE, SERVICE_VERSION, } from '../es_fields/apm'; @@ -28,7 +28,7 @@ export function getKueryWithMobileFilters({ }) { const kueryWithFilters = [ kuery, - ...fieldValuePairToKql(DEVICE_MODEL_NAME, device), + ...fieldValuePairToKql(DEVICE_MODEL_IDENTIFIER, device), ...fieldValuePairToKql(HOST_OS_VERSION, osVersion), ...fieldValuePairToKql(SERVICE_VERSION, appVersion), ...fieldValuePairToKql(NETWORK_CONNECTION_TYPE, netConnectionType), diff --git a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/alert_details_app_section.tsx b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/alert_details_app_section.tsx index 3bf792840ab71..73690e8b0a00e 100644 --- a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/alert_details_app_section.tsx +++ b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/alert_details_app_section.tsx @@ -15,13 +15,11 @@ import { EuiIconTip } from '@elastic/eui'; import { ALERT_DURATION, ALERT_END, + ALERT_RULE_UUID, ALERT_EVALUATION_THRESHOLD, ALERT_RULE_TYPE_ID, } from '@kbn/rule-data-utils'; import moment from 'moment'; -import { getTransactionType } from '../../../../context/apm_service/apm_service_context'; -import { useServiceAgentFetcher } from '../../../../context/apm_service/use_service_agent_fetcher'; -import { useServiceTransactionTypesFetcher } from '../../../../context/apm_service/use_service_transaction_types_fetcher'; import { asPercent } from '../../../../../common/utils/formatters'; import { APIReturnType } from '../../../../services/rest/create_call_apm_api'; import { getDurationFormatter } from '../../../../../common/utils/formatters/duration'; @@ -48,6 +46,7 @@ import { import { getAggsTypeFromRule, isLatencyThresholdRuleType } from './helpers'; import { filterNil } from '../../../shared/charts/latency_chart'; import { errorRateI18n } from '../../../shared/charts/failed_transaction_rate_chart'; +import { LatencyAlertsHistoryChart } from './latency_alerts_history_chart'; import { AlertActiveRect, AlertAnnotation, @@ -100,23 +99,7 @@ export function AlertDetailsAppSection({ .toISOString(); const { start, end } = useTimeRange({ rangeFrom, rangeTo }); - const { agentName } = useServiceAgentFetcher({ - serviceName, - start, - end, - }); - const transactionTypes = useServiceTransactionTypesFetcher({ - serviceName, - start, - end, - }); - - const transactionType = getTransactionType({ - transactionType: alert.fields[TRANSACTION_TYPE], - transactionTypes, - agentName, - }); - + const transactionType = alert.fields[TRANSACTION_TYPE]; const comparisonChartTheme = getComparisonChartTheme(); const INITIAL_STATE = { currentPeriod: [], @@ -443,6 +426,18 @@ export function AlertDetailsAppSection({ + + + ); diff --git a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/constants.ts b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/constants.ts index 45fe209d8111a..497b779d24e7d 100644 --- a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/constants.ts +++ b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/constants.ts @@ -5,3 +5,4 @@ * 2.0. */ export const DEFAULT_DATE_FORMAT = 'HH:mm:ss'; +export const CHART_ANNOTATION_RED_COLOR = '#BD271E'; diff --git a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_alerts_history_chart.tsx b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_alerts_history_chart.tsx new file mode 100644 index 0000000000000..4927782b722d9 --- /dev/null +++ b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_alerts_history_chart.tsx @@ -0,0 +1,241 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useMemo } from 'react'; +import moment from 'moment'; +import { EuiPanel, EuiSpacer } from '@elastic/eui'; +import { EuiFlexGroup } from '@elastic/eui'; +import { EuiFlexItem } from '@elastic/eui'; +import { EuiTitle } from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import { EuiText } from '@elastic/eui'; +import { + AnnotationDomainType, + LineAnnotation, + Position, +} from '@elastic/charts'; +import { EuiIcon } from '@elastic/eui'; +import { EuiBadge } from '@elastic/eui'; +import { convertTo } from '@kbn/observability-plugin/public'; +import { useFetchTriggeredAlertsHistory } from '../../../../hooks/use_fetch_triggered_alert_history'; +import { getDurationFormatter } from '../../../../../common/utils/formatters'; +import { getLatencyChartSelector } from '../../../../selectors/latency_chart_selectors'; +import { LatencyAggregationType } from '../../../../../common/latency_aggregation_types'; +import { useFetcher } from '../../../../hooks/use_fetcher'; +import { TimeseriesChart } from '../../../shared/charts/timeseries_chart'; +import { filterNil } from '../../../shared/charts/latency_chart'; +import { + getMaxY, + getResponseTimeTickFormatter, +} from '../../../shared/charts/transaction_charts/helper'; +import { CHART_ANNOTATION_RED_COLOR } from './constants'; + +interface LatencyAlertsHistoryChartProps { + serviceName: string; + start: string; + end: string; + transactionType?: string; + latencyAggregationType: LatencyAggregationType; + environment: string; + timeZone: string; + ruleId: string; +} +export function LatencyAlertsHistoryChart({ + serviceName, + start, + end, + transactionType, + latencyAggregationType, + environment, + timeZone, + ruleId, +}: LatencyAlertsHistoryChartProps) { + const { data, status } = useFetcher( + (callApmApi) => { + if ( + serviceName && + start && + end && + transactionType && + latencyAggregationType + ) { + return callApmApi( + `GET /internal/apm/services/{serviceName}/transactions/charts/latency`, + { + params: { + path: { serviceName }, + query: { + environment, + kuery: '', + start: moment().subtract(30, 'days').toISOString(), + end: moment().toISOString(), + transactionType, + transactionName: undefined, + latencyAggregationType, + }, + }, + } + ); + } + }, + [ + end, + environment, + latencyAggregationType, + serviceName, + start, + transactionType, + ] + ); + const memoizedData = useMemo( + () => + getLatencyChartSelector({ + latencyChart: data, + latencyAggregationType, + previousPeriodLabel: '', + }), + // It should only update when the data has changed + // eslint-disable-next-line react-hooks/exhaustive-deps + [data] + ); + + const { currentPeriod, previousPeriod } = memoizedData; + const timeseriesLatency = [currentPeriod, previousPeriod].filter(filterNil); + const latencyMaxY = getMaxY(timeseriesLatency); + const latencyFormatter = getDurationFormatter(latencyMaxY); + const { triggeredAlertsData } = useFetchTriggeredAlertsHistory({ + features: 'apm', + ruleId, + }); + + return ( + + + + +

    + {serviceName} + {i18n.translate('xpack.apm.latencyChartHistory.chartTitle', { + defaultMessage: ' latency alerts history', + })} +

    +
    +
    + + + {i18n.translate('xpack.apm.latencyChartHistory.last30days', { + defaultMessage: 'Last 30 days', + })} + + +
    + + + + + + + + +

    {triggeredAlertsData?.totalTriggeredAlerts || '-'}

    +
    +
    +
    + + + {i18n.translate( + 'xpack.apm.latencyChartHistory.alertsTriggered', + { + defaultMessage: 'Alerts triggered', + } + )} + + +
    +
    + + + + +

    + {triggeredAlertsData?.avgTimeToRecoverUS + ? convertTo({ + unit: 'minutes', + microseconds: triggeredAlertsData?.avgTimeToRecoverUS, + extended: true, + }).formatted + : '-'} +

    +
    +
    +
    + + + {i18n.translate( + 'xpack.apm.latencyChartHistory.avgTimeToRecover', + { + defaultMessage: 'Avg time to recover', + } + )} + + +
    +
    + + + annotation.doc_count > 0) + .map((annotation) => { + return { + dataValue: annotation.key, + header: String(annotation.doc_count), + details: moment(annotation.key_as_string).format( + 'yyyy-MM-DD' + ), + }; + }) || [] + } + style={{ + line: { + strokeWidth: 3, + stroke: CHART_ANNOTATION_RED_COLOR, + opacity: 1, + }, + }} + marker={} + markerBody={(annotationData) => ( + <> + + + {annotationData.header} + + + + + )} + markerPosition={Position.Top} + />, + ]} + height={200} + comparisonEnabled={false} + offset={''} + fetchStatus={status} + timeseries={timeseriesLatency} + yLabelFormat={getResponseTimeTickFormatter(latencyFormatter)} + timeZone={timeZone} + /> +
    + ); +} diff --git a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_annotation.tsx b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_annotation.tsx index 27354ea2ac3b8..d4496e6512434 100644 --- a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_annotation.tsx +++ b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_annotation.tsx @@ -14,7 +14,7 @@ import { import moment from 'moment'; import { EuiIcon } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { DEFAULT_DATE_FORMAT } from '../constants'; +import { CHART_ANNOTATION_RED_COLOR, DEFAULT_DATE_FORMAT } from '../constants'; export function AlertAnnotation({ alertStarted }: { alertStarted: number }) { return ( @@ -36,11 +36,11 @@ export function AlertAnnotation({ alertStarted }: { alertStarted: number }) { style={{ line: { strokeWidth: 3, - stroke: '#f00', + stroke: CHART_ANNOTATION_RED_COLOR, opacity: 1, }, }} - marker={} + marker={} markerPosition={Position.Top} /> ); diff --git a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_threshold_annotation.tsx b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_threshold_annotation.tsx index c1c6ddefd32f1..0304d298d195e 100644 --- a/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_threshold_annotation.tsx +++ b/x-pack/plugins/apm/public/components/alerting/ui_components/alert_details_app_section/latency_chart_components/alert_threshold_annotation.tsx @@ -7,6 +7,7 @@ import React from 'react'; import { AnnotationDomainType, LineAnnotation } from '@elastic/charts'; +import { CHART_ANNOTATION_RED_COLOR } from '../constants'; export function AlertThresholdAnnotation({ threshold, @@ -29,7 +30,7 @@ export function AlertThresholdAnnotation({ line: { opacity: 0.5, strokeWidth: 1, - stroke: 'red', + stroke: CHART_ANNOTATION_RED_COLOR, }, }} /> diff --git a/x-pack/plugins/apm/public/components/app/error_group_overview/index.tsx b/x-pack/plugins/apm/public/components/app/error_group_overview/index.tsx index 514759c2b3dfe..452e4009a470e 100644 --- a/x-pack/plugins/apm/public/components/app/error_group_overview/index.tsx +++ b/x-pack/plugins/apm/public/components/app/error_group_overview/index.tsx @@ -14,7 +14,7 @@ import { } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { orderBy } from 'lodash'; import { isTimeComparison } from '../../shared/time_comparison/get_comparison_options'; import { useApmServiceContext } from '../../../context/apm_service/use_apm_service_context'; @@ -110,7 +110,7 @@ export function ErrorGroupOverview() { return { // Everytime the main statistics is refetched, updates the requestId making the comparison API to be refetched. - requestId: uuid(), + requestId: uuidv4(), errorGroupMainStatistics: response.errorGroups, currentPageGroupIds, }; diff --git a/x-pack/plugins/apm/public/components/app/mobile/charts/http_requests_chart.tsx b/x-pack/plugins/apm/public/components/app/mobile/charts/http_requests_chart.tsx new file mode 100644 index 0000000000000..0b530a6cc4e2c --- /dev/null +++ b/x-pack/plugins/apm/public/components/app/mobile/charts/http_requests_chart.tsx @@ -0,0 +1,146 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { + EuiPanel, + EuiTitle, + EuiIconTip, + EuiFlexItem, + EuiFlexGroup, +} from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import React from 'react'; +import { useFetcher } from '../../../../hooks/use_fetcher'; +import { TimeseriesChartWithContext } from '../../../shared/charts/timeseries_chart_with_context'; +import { getComparisonChartTheme } from '../../../shared/time_comparison/get_comparison_chart_theme'; +import { + getTimeSeriesColor, + ChartType, +} from '../../../shared/charts/helper/get_timeseries_color'; +import { usePreviousPeriodLabel } from '../../../../hooks/use_previous_period_text'; + +const INITIAL_STATE = { + currentPeriod: [], + previousPeriod: [], +}; + +export function HttpRequestsChart({ + kuery, + serviceName, + start, + end, + transactionName, + environment, + offset, + comparisonEnabled, +}: { + kuery: string; + serviceName: string; + start: string; + end: string; + transactionType?: string; + transactionName?: string; + environment: string; + offset?: string; + comparisonEnabled: boolean; +}) { + const comparisonChartTheme = getComparisonChartTheme(); + const { currentPeriodColor, previousPeriodColor } = getTimeSeriesColor( + ChartType.HTTP_REQUESTS + ); + + const previousPeriodLabel = usePreviousPeriodLabel(); + + const { data = INITIAL_STATE, status } = useFetcher( + (callApmApi) => { + return callApmApi( + 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests', + { + params: { + path: { + serviceName, + }, + query: { + environment, + kuery, + start, + end, + transactionName, + offset: comparisonEnabled ? offset : undefined, + }, + }, + } + ); + }, + [ + environment, + kuery, + serviceName, + start, + end, + transactionName, + offset, + comparisonEnabled, + ] + ); + + const timeseries = [ + { + data: data.currentPeriod, + type: 'linemark', + color: currentPeriodColor, + title: i18n.translate('xpack.apm.transactions.httpRequestsTitle', { + defaultMessage: 'HTTP Requests', + }), + }, + ...(comparisonEnabled + ? [ + { + data: data.previousPeriod, + type: 'area', + color: previousPeriodColor, + title: previousPeriodLabel, + }, + ] + : []), + ]; + return ( + + + + +

    + {i18n.translate('xpack.apm.transactions.httpRequestsTitle', { + defaultMessage: 'HTTP Requests', + })} +

    +
    +
    + + + + +
    + + `${y}`} + /> +
    + ); +} diff --git a/x-pack/plugins/apm/public/components/app/mobile/charts/sessions_chart.tsx b/x-pack/plugins/apm/public/components/app/mobile/charts/sessions_chart.tsx new file mode 100644 index 0000000000000..8c0b806cce6be --- /dev/null +++ b/x-pack/plugins/apm/public/components/app/mobile/charts/sessions_chart.tsx @@ -0,0 +1,152 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { + EuiPanel, + EuiTitle, + EuiIconTip, + EuiFlexItem, + EuiFlexGroup, +} from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import React from 'react'; +import { useFetcher } from '../../../../hooks/use_fetcher'; +import { APIReturnType } from '../../../../services/rest/create_call_apm_api'; +import { TimeseriesChartWithContext } from '../../../shared/charts/timeseries_chart_with_context'; +import { getComparisonChartTheme } from '../../../shared/time_comparison/get_comparison_chart_theme'; +import { + getTimeSeriesColor, + ChartType, +} from '../../../shared/charts/helper/get_timeseries_color'; +import { usePreviousPeriodLabel } from '../../../../hooks/use_previous_period_text'; + +const INITIAL_STATE = { + currentPeriod: [], + previousPeriod: [], +}; + +type SessionsChart = + APIReturnType<'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions'>; + +export function SessionsChart({ + kuery, + serviceName, + start, + end, + transactionType, + transactionName, + environment, + offset, + comparisonEnabled, +}: { + kuery: string; + serviceName: string; + start: string; + end: string; + transactionType?: string; + transactionName?: string; + environment: string; + offset?: string; + comparisonEnabled: boolean; +}) { + const comparisonChartTheme = getComparisonChartTheme(); + const { currentPeriodColor, previousPeriodColor } = getTimeSeriesColor( + ChartType.SESSIONS + ); + + const { data = INITIAL_STATE, status } = useFetcher( + (callApmApi) => { + return callApmApi( + 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions', + { + params: { + path: { + serviceName, + }, + query: { + environment, + kuery, + start, + end, + transactionType, + transactionName, + offset: comparisonEnabled ? offset : undefined, + }, + }, + } + ); + }, + [ + environment, + kuery, + serviceName, + start, + end, + transactionType, + transactionName, + offset, + comparisonEnabled, + ] + ); + const previousPeriodLabel = usePreviousPeriodLabel(); + + const timeseries = [ + { + data: data.currentPeriod, + type: 'linemark', + color: currentPeriodColor, + title: i18n.translate('xpack.apm.transactions.sessionsChartTitle', { + defaultMessage: 'Sessions', + }), + }, + ...(comparisonEnabled + ? [ + { + data: data.previousPeriod, + type: 'area', + color: previousPeriodColor, + title: previousPeriodLabel, + }, + ] + : []), + ]; + return ( + + + + +

    + {i18n.translate('xpack.apm.transactions.sessionsChartTitle', { + defaultMessage: 'Sessions', + })} +

    +
    +
    + + + + +
    + + `${y}`} + /> +
    + ); +} diff --git a/x-pack/plugins/apm/public/components/app/mobile/service_overview/index.tsx b/x-pack/plugins/apm/public/components/app/mobile/service_overview/index.tsx index c8ac865fc3a40..847df33534455 100644 --- a/x-pack/plugins/apm/public/components/app/mobile/service_overview/index.tsx +++ b/x-pack/plugins/apm/public/components/app/mobile/service_overview/index.tsx @@ -29,7 +29,7 @@ import { useApmRouter } from '../../../../hooks/use_apm_router'; import { ServiceOverviewThroughputChart } from '../../service_overview/service_overview_throughput_chart'; import { TransactionsTable } from '../../../shared/transactions_table'; import { - DEVICE_MODEL_NAME, + DEVICE_MODEL_IDENTIFIER, HOST_OS_VERSION, NETWORK_CONNECTION_TYPE, SERVICE_VERSION, @@ -191,7 +191,7 @@ export function MobileServiceOverview() { defaultMessage: 'Devices', } )} - metric={DEVICE_MODEL_NAME} + metric={DEVICE_MODEL_IDENTIFIER} start={start} end={end} kuery={kueryWithMobileFilters} diff --git a/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/embedded_map.tsx b/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/embedded_map.tsx index 6cabc18e2aa62..e8f80d8fbdf26 100644 --- a/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/embedded_map.tsx +++ b/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/embedded_map.tsx @@ -6,7 +6,7 @@ */ import React, { useEffect, useState, useRef } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { MapEmbeddable, MapEmbeddableInput, @@ -83,7 +83,7 @@ function EmbeddedMapComponent({ const input: MapEmbeddableInput = { attributes: { title: '' }, - id: uuid.v4(), + id: uuidv4(), title: i18n.translate( 'xpack.apm.serviceOverview.embeddedMap.input.title', { diff --git a/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/get_layer_list.ts b/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/get_layer_list.ts index e17d5d4b5663c..d6f544cdd1d21 100644 --- a/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/get_layer_list.ts +++ b/x-pack/plugins/apm/public/components/app/mobile/service_overview/latency_map/get_layer_list.ts @@ -20,7 +20,7 @@ import { STYLE_TYPE, SYMBOLIZE_AS_TYPES, } from '@kbn/maps-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { MapsStartApi } from '@kbn/maps-plugin/public'; import { i18n } from '@kbn/i18n'; import { @@ -141,7 +141,7 @@ export async function getLayerList(maps?: MapsStartApi) { tooltipProperties: [COUNTRY_NAME], }, style: getLayerStyle(), - id: uuid.v4(), + id: uuidv4(), label: null, minZoom: 0, maxZoom: 24, diff --git a/x-pack/plugins/apm/public/components/app/mobile/service_overview/most_used_chart/index.tsx b/x-pack/plugins/apm/public/components/app/mobile/service_overview/most_used_chart/index.tsx index 101ae1592e5f1..53f9d41cd15b1 100644 --- a/x-pack/plugins/apm/public/components/app/mobile/service_overview/most_used_chart/index.tsx +++ b/x-pack/plugins/apm/public/components/app/mobile/service_overview/most_used_chart/index.tsx @@ -13,14 +13,14 @@ import { useKibana } from '@kbn/kibana-react-plugin/public'; import { ApmPluginStartDeps } from '../../../../../plugin'; import { getLensAttributes } from './get_lens_attributes'; import { - DEVICE_MODEL_NAME, + DEVICE_MODEL_IDENTIFIER, HOST_OS_VERSION, NETWORK_CONNECTION_TYPE, SERVICE_VERSION, } from '../../../../../../common/es_fields/apm'; export type MostUsedMetricTypes = - | typeof DEVICE_MODEL_NAME + | typeof DEVICE_MODEL_IDENTIFIER | typeof SERVICE_VERSION | typeof HOST_OS_VERSION | typeof NETWORK_CONNECTION_TYPE; diff --git a/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/index.tsx b/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/index.tsx index e361066264668..3194a21c5d14a 100644 --- a/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/index.tsx +++ b/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/index.tsx @@ -18,13 +18,14 @@ import { useApmServiceContext } from '../../../../context/apm_service/use_apm_se import { useApmParams } from '../../../../hooks/use_apm_params'; import { useTimeRange } from '../../../../hooks/use_time_range'; import { AggregatedTransactionsBadge } from '../../../shared/aggregated_transactions_badge'; -import { MobileTransactionCharts } from '../../../shared/charts/transaction_charts/mobile_transaction_charts'; import { TransactionsTable } from '../../../shared/transactions_table'; import { replace } from '../../../shared/links/url_helpers'; import { getKueryWithMobileFilters } from '../../../../../common/utils/get_kuery_with_mobile_filters'; +import { MobileTransactionCharts } from './transaction_charts'; export function MobileTransactionOverview() { const { + path: { serviceName }, query: { environment, rangeFrom, @@ -35,10 +36,12 @@ export function MobileTransactionOverview() { appVersion, netConnectionType, kuery, + offset, + comparisonEnabled, }, } = useApmParams('/mobile-services/{serviceName}/transactions'); - const kueryWithFilters = getKueryWithMobileFilters({ + const kueryWithMobileFilters = getKueryWithMobileFilters({ device, osVersion, appVersion, @@ -73,10 +76,14 @@ export function MobileTransactionOverview() { )} @@ -85,7 +92,7 @@ export function MobileTransactionOverview() { numberOfTransactionsPerPage={25} showAggregationAccurateCallout environment={environment} - kuery={kueryWithFilters} + kuery={kueryWithMobileFilters} start={start} end={end} saveTableOptionsToUrl diff --git a/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/transaction_charts.tsx b/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/transaction_charts.tsx new file mode 100644 index 0000000000000..a80f0ebfbced3 --- /dev/null +++ b/x-pack/plugins/apm/public/components/app/mobile/transaction_overview/transaction_charts.tsx @@ -0,0 +1,89 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { EuiFlexGrid, EuiFlexItem, EuiPanel, EuiSpacer } from '@elastic/eui'; +import React from 'react'; +import { AnnotationsContextProvider } from '../../../../context/annotations/annotations_context'; +import { ChartPointerEventContextProvider } from '../../../../context/chart_pointer_event/chart_pointer_event_context'; +import { ServiceOverviewThroughputChart } from '../../service_overview/service_overview_throughput_chart'; +import { SessionsChart } from '../charts/sessions_chart'; +import { HttpRequestsChart } from '../charts/http_requests_chart'; +import { LatencyChart } from '../../../shared/charts/latency_chart'; +import { FailedTransactionRateChart } from '../../../shared/charts/failed_transaction_rate_chart'; + +export function MobileTransactionCharts({ + serviceName, + kuery, + environment, + start, + end, + transactionType, + offset, + comparisonEnabled, +}: { + serviceName: string; + kuery: string; + environment: string; + start: string; + end: string; + transactionType?: string; + offset?: string; + comparisonEnabled: boolean; +}) { + return ( + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ); +} diff --git a/x-pack/plugins/apm/public/components/app/service_inventory/index.tsx b/x-pack/plugins/apm/public/components/app/service_inventory/index.tsx index b6c490b32e7a4..67d2cc520218c 100644 --- a/x-pack/plugins/apm/public/components/app/service_inventory/index.tsx +++ b/x-pack/plugins/apm/public/components/app/service_inventory/index.tsx @@ -8,7 +8,7 @@ import { EuiFlexGroup, EuiFlexItem, EuiEmptyPrompt } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { useKibana } from '@kbn/kibana-react-plugin/public'; import { apmServiceInventoryOptimizedSorting } from '@kbn/observability-plugin/common'; import { isTimeComparison } from '../../shared/time_comparison/get_comparison_options'; @@ -83,7 +83,7 @@ function useServicesMainStatisticsFetcher() { }, }).then((mainStatisticsData) => { return { - requestId: uuid(), + requestId: uuidv4(), ...mainStatisticsData, }; }); diff --git a/x-pack/plugins/apm/public/components/app/service_overview/service_overview_errors_table/index.tsx b/x-pack/plugins/apm/public/components/app/service_overview/service_overview_errors_table/index.tsx index 340dc4f80da84..81e5509ca6239 100644 --- a/x-pack/plugins/apm/public/components/app/service_overview/service_overview_errors_table/index.tsx +++ b/x-pack/plugins/apm/public/components/app/service_overview/service_overview_errors_table/index.tsx @@ -14,7 +14,7 @@ import { import { i18n } from '@kbn/i18n'; import { orderBy } from 'lodash'; import React, { useState } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isTimeComparison } from '../../../shared/time_comparison/get_comparison_options'; import { FETCH_STATUS, useFetcher } from '../../../../hooks/use_fetcher'; import { APIReturnType } from '../../../../services/rest/create_call_apm_api'; @@ -105,7 +105,7 @@ export function ServiceOverviewErrorsTable({ serviceName }: Props) { return { // Everytime the main statistics is refetched, updates the requestId making the comparison API to be refetched. - requestId: uuid(), + requestId: uuidv4(), items: currentPageErrorGroups, totalItems: response.errorGroups.length, }; diff --git a/x-pack/plugins/apm/public/components/app/service_overview/service_overview_instances_chart_and_table.tsx b/x-pack/plugins/apm/public/components/app/service_overview/service_overview_instances_chart_and_table.tsx index e426899c7390f..13bd5324f6444 100644 --- a/x-pack/plugins/apm/public/components/app/service_overview/service_overview_instances_chart_and_table.tsx +++ b/x-pack/plugins/apm/public/components/app/service_overview/service_overview_instances_chart_and_table.tsx @@ -8,7 +8,7 @@ import { EuiFlexItem, EuiPanel } from '@elastic/eui'; import { orderBy } from 'lodash'; import React, { useState } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isTimeComparison } from '../../shared/time_comparison/get_comparison_options'; import { useApmServiceContext } from '../../../context/apm_service/use_apm_service_context'; import { useApmParams } from '../../../hooks/use_apm_params'; @@ -124,7 +124,7 @@ export function ServiceOverviewInstancesChartAndTable({ ).then((response) => { return { // Everytime the main statistics is refetched, updates the requestId making the detailed API to be refetched. - requestId: uuid(), + requestId: uuidv4(), currentPeriodItems: response.currentPeriod, currentPeriodItemsCount: response.currentPeriod.length, previousPeriodItems: response.previousPeriod, diff --git a/x-pack/plugins/apm/public/components/app/settings/general_settings/index.tsx b/x-pack/plugins/apm/public/components/app/settings/general_settings/index.tsx index a2a4b756d4c5b..e250f1e09276b 100644 --- a/x-pack/plugins/apm/public/components/app/settings/general_settings/index.tsx +++ b/x-pack/plugins/apm/public/components/app/settings/general_settings/index.tsx @@ -11,7 +11,6 @@ import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import { apmLabsButton, - apmProgressiveLoading, apmServiceGroupMaxNumberOfServices, defaultApmServiceEnvironment, enableComparisonByDefault, @@ -28,7 +27,6 @@ import { BottomBarActions } from '../bottom_bar_actions'; const apmSettingsKeys = [ enableComparisonByDefault, defaultApmServiceEnvironment, - apmProgressiveLoading, apmServiceGroupMaxNumberOfServices, enableInspectEsQueries, apmLabsButton, diff --git a/x-pack/plugins/apm/public/components/app/transaction_details/top_errors/index.tsx b/x-pack/plugins/apm/public/components/app/transaction_details/top_errors/index.tsx index 237580e253949..926a672ce818e 100644 --- a/x-pack/plugins/apm/public/components/app/transaction_details/top_errors/index.tsx +++ b/x-pack/plugins/apm/public/components/app/transaction_details/top_errors/index.tsx @@ -13,7 +13,7 @@ import { } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isTimeComparison } from '../../../shared/time_comparison/get_comparison_options'; import { FETCH_STATUS, useFetcher } from '../../../../hooks/use_fetcher'; import { APIReturnType } from '../../../../services/rest/create_call_apm_api'; @@ -84,7 +84,7 @@ export function TopErrors() { ).then((response) => { return { // Everytime the main statistics is refetched, updates the requestId making the comparison API to be refetched. - requestId: uuid(), + requestId: uuidv4(), items: response.errorGroups, }; }); diff --git a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/index.tsx b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/index.tsx index 191b38f73754a..2536c6f59d0ff 100644 --- a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/index.tsx +++ b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/index.tsx @@ -159,7 +159,11 @@ export function Waterfall({ flyoutDetailTab: string ) => toggleFlyout({ history, item, flyoutDetailTab })} showCriticalPath={showCriticalPath} - maxLevelOpen={maxLevelOpen} + maxLevelOpen={ + waterfall.traceItemCount > 500 + ? maxLevelOpen + : waterfall.traceItemCount + } /> )} diff --git a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/waterfall_helpers/waterfall_helpers.test.ts b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/waterfall_helpers/waterfall_helpers.test.ts index 393851a0f4aa2..91d674386fabc 100644 --- a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/waterfall_helpers/waterfall_helpers.test.ts +++ b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall/waterfall_helpers/waterfall_helpers.test.ts @@ -139,7 +139,7 @@ describe('waterfall_helpers', () => { exceedsMax: false, spanLinksCountById: {}, traceItemCount: hits.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }, entryTransaction: { processor: { event: 'transaction' }, @@ -169,7 +169,7 @@ describe('waterfall_helpers', () => { exceedsMax: false, spanLinksCountById: {}, traceItemCount: hits.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }, entryTransaction: { parent: { id: 'mySpanIdD' }, @@ -272,7 +272,7 @@ describe('waterfall_helpers', () => { exceedsMax: false, spanLinksCountById: {}, traceItemCount: traceItems.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }, entryTransaction: { processor: { event: 'transaction' }, @@ -391,7 +391,7 @@ describe('waterfall_helpers', () => { exceedsMax: false, spanLinksCountById: {}, traceItemCount: traceItems.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }, entryTransaction: { processor: { event: 'transaction' }, diff --git a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall_container.stories.tsx b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall_container.stories.tsx index eb2d4ec9369dd..e0f48f9bed781 100644 --- a/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall_container.stories.tsx +++ b/x-pack/plugins/apm/public/components/app/transaction_details/waterfall_with_summary/waterfall_container/waterfall_container.stories.tsx @@ -82,7 +82,7 @@ export const Example: Story = () => { errorDocs: errorDocs.map((error) => dedot(error, {}) as WaterfallError), spanLinksCountById: {}, traceItemCount: traceDocs.length, - maxTraceItems: 1000, + maxTraceItems: 5000, }; const entryTransaction = dedot(traceDocs[0]!, {}) as Transaction; diff --git a/x-pack/plugins/apm/public/components/shared/charts/helper/get_timeseries_color.ts b/x-pack/plugins/apm/public/components/shared/charts/helper/get_timeseries_color.ts index ba5ff5fec0801..0ab27b607f099 100644 --- a/x-pack/plugins/apm/public/components/shared/charts/helper/get_timeseries_color.ts +++ b/x-pack/plugins/apm/public/components/shared/charts/helper/get_timeseries_color.ts @@ -15,6 +15,8 @@ export enum ChartType { FAILED_TRANSACTION_RATE, CPU_USAGE, MEMORY_USAGE, + SESSIONS, + HTTP_REQUESTS, ERROR_OCCURRENCES, } @@ -52,6 +54,14 @@ const timeSeriesColorMap: Record< currentPeriodColor: palette[8], previousPeriodColor: palette[18], }, + [ChartType.SESSIONS]: { + currentPeriodColor: palette[3], + previousPeriodColor: palette[13], + }, + [ChartType.HTTP_REQUESTS]: { + currentPeriodColor: palette[2], + previousPeriodColor: palette[12], + }, [ChartType.ERROR_OCCURRENCES]: { currentPeriodColor: palette[3], previousPeriodColor: palette[13], diff --git a/x-pack/plugins/apm/public/components/shared/charts/transaction_charts/mobile_transaction_charts.tsx b/x-pack/plugins/apm/public/components/shared/charts/transaction_charts/mobile_transaction_charts.tsx deleted file mode 100644 index 67d713eea2b0a..0000000000000 --- a/x-pack/plugins/apm/public/components/shared/charts/transaction_charts/mobile_transaction_charts.tsx +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { EuiFlexGrid, EuiFlexItem, EuiPanel } from '@elastic/eui'; -import React from 'react'; -import { AnnotationsContextProvider } from '../../../../context/annotations/annotations_context'; -import { ChartPointerEventContextProvider } from '../../../../context/chart_pointer_event/chart_pointer_event_context'; -import { ServiceOverviewThroughputChart } from '../../../app/service_overview/service_overview_throughput_chart'; -import { LatencyChart } from '../latency_chart'; -import { FailedTransactionRateChart } from '../failed_transaction_rate_chart'; - -export function MobileTransactionCharts({ - kuery, - environment, - start, - end, - transactionName, -}: { - kuery: string; - environment: string; - start: string; - end: string; - transactionName?: string; -}) { - return ( - - - - - - - - - - - - - - - - - - ); -} diff --git a/x-pack/plugins/apm/public/components/shared/transactions_table/index.tsx b/x-pack/plugins/apm/public/components/shared/transactions_table/index.tsx index 4b4ce0f784243..686842de935c9 100644 --- a/x-pack/plugins/apm/public/components/shared/transactions_table/index.tsx +++ b/x-pack/plugins/apm/public/components/shared/transactions_table/index.tsx @@ -14,7 +14,7 @@ import { import { i18n } from '@kbn/i18n'; import { orderBy } from 'lodash'; import React, { useMemo, useState } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { EuiCallOut } from '@elastic/eui'; import { FormattedMessage } from '@kbn/i18n-react'; import { EuiCode } from '@elastic/eui'; @@ -160,7 +160,7 @@ export function TransactionsTable({ return { // Everytime the main statistics is refetched, updates the requestId making the detailed API to be refetched. - requestId: uuid(), + requestId: uuidv4(), mainStatisticsData: { ...response, transactionGroups: currentPageTransactionGroups, diff --git a/x-pack/plugins/apm/public/hooks/use_fetch_triggered_alert_history.ts b/x-pack/plugins/apm/public/hooks/use_fetch_triggered_alert_history.ts new file mode 100644 index 0000000000000..4c457f135bf01 --- /dev/null +++ b/x-pack/plugins/apm/public/hooks/use_fetch_triggered_alert_history.ts @@ -0,0 +1,217 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { AsApiContract } from '@kbn/actions-plugin/common'; +import { HttpSetup } from '@kbn/core/public'; +import { + ALERT_DURATION, + ALERT_RULE_UUID, + ALERT_START, + ALERT_STATUS, + ALERT_TIME_RANGE, +} from '@kbn/rule-data-utils'; +import { BASE_RAC_ALERTS_API_PATH } from '@kbn/rule-registry-plugin/common'; +import { useCallback, useEffect, useRef, useState } from 'react'; +import { useKibana } from '@kbn/kibana-react-plugin/public'; + +interface UseFetchTriggeredAlertsHistoryProps { + features: string; + ruleId: string; +} +interface FetchTriggeredAlertsHistory { + totalTriggeredAlerts: number; + histogramTriggeredAlerts: Array<{ + key_as_string: string; + key: number; + doc_count: number; + }>; + error?: string; + avgTimeToRecoverUS: number; +} + +interface TriggeredAlertsHistory { + isLoadingTriggeredAlertHistory: boolean; + errorTriggeredAlertHistory?: string; + triggeredAlertsData?: FetchTriggeredAlertsHistory; +} +export function useFetchTriggeredAlertsHistory({ + features, + ruleId, +}: UseFetchTriggeredAlertsHistoryProps) { + const { http } = useKibana().services; + const [triggeredAlertsHistory, setTriggeredAlertsHistory] = + useState({ + isLoadingTriggeredAlertHistory: true, + }); + const isCancelledRef = useRef(false); + const abortCtrlRef = useRef(new AbortController()); + const loadRuleAlertsAgg = useCallback(async () => { + isCancelledRef.current = false; + abortCtrlRef.current.abort(); + abortCtrlRef.current = new AbortController(); + + try { + if (!http) throw new Error('No http client'); + if (!features) return; + const { index } = await fetchIndexNameAPI({ + http, + features, + }); + + const { + totalTriggeredAlerts, + histogramTriggeredAlerts, + error, + avgTimeToRecoverUS, + } = await fetchTriggeredAlertsHistory({ + http, + index, + ruleId, + signal: abortCtrlRef.current.signal, + }); + + if (error) throw error; + if (!isCancelledRef.current) { + setTriggeredAlertsHistory((oldState: TriggeredAlertsHistory) => ({ + ...oldState, + triggeredAlertsData: { + totalTriggeredAlerts, + histogramTriggeredAlerts, + avgTimeToRecoverUS, + }, + isLoadingRuleAlertsAggs: false, + })); + } + } catch (error) { + if (!isCancelledRef.current) { + if (error.name !== 'AbortError') { + setTriggeredAlertsHistory((oldState: TriggeredAlertsHistory) => ({ + ...oldState, + isLoadingRuleAlertsAggs: false, + errorTriggeredAlertHistory: error, + triggeredAlertsData: undefined, + })); + } + } + } + }, [features, http, ruleId]); + useEffect(() => { + loadRuleAlertsAgg(); + }, [loadRuleAlertsAgg]); + + return triggeredAlertsHistory; +} + +interface IndexName { + index: string; +} + +export async function fetchIndexNameAPI({ + http, + features, +}: { + http: HttpSetup; + features: string; +}): Promise { + const res = await http.get<{ index_name: string[] }>( + `${BASE_RAC_ALERTS_API_PATH}/index`, + { + query: { features }, + } + ); + return { + index: res.index_name[0], + }; +} + +export async function fetchTriggeredAlertsHistory({ + http, + index, + ruleId, + signal, +}: { + http: HttpSetup; + index: string; + ruleId: string; + signal: AbortSignal; +}): Promise { + try { + const res = await http.post>( + `${BASE_RAC_ALERTS_API_PATH}/find`, + { + signal, + body: JSON.stringify({ + index, + size: 0, + query: { + bool: { + must: [ + { + term: { + [ALERT_RULE_UUID]: ruleId, + }, + }, + { + range: { + [ALERT_TIME_RANGE]: { + gte: 'now-30d', + lt: 'now', + }, + }, + }, + ], + }, + }, + aggs: { + histogramTriggeredAlerts: { + date_histogram: { + field: ALERT_START, + fixed_interval: '1d', + extended_bounds: { + min: 'now-30d', + max: 'now', + }, + }, + }, + avgTimeToRecoverUS: { + filter: { + term: { + [ALERT_STATUS]: 'recovered', + }, + }, + aggs: { + recoveryTime: { + avg: { + field: ALERT_DURATION, + }, + }, + }, + }, + }, + }), + } + ); + const totalTriggeredAlerts = res?.hits.total.value; + const histogramTriggeredAlerts = + res?.aggregations?.histogramTriggeredAlerts.buckets; + const avgTimeToRecoverUS = + res?.aggregations?.avgTimeToRecoverUS.recoveryTime.value; + return { + totalTriggeredAlerts, + histogramTriggeredAlerts, + avgTimeToRecoverUS, + }; + } catch (error) { + console.error(error); + return { + error, + totalTriggeredAlerts: 0, + histogramTriggeredAlerts: [], + avgTimeToRecoverUS: 0, + }; + } +} diff --git a/x-pack/plugins/apm/public/hooks/use_previous_period_text.ts b/x-pack/plugins/apm/public/hooks/use_previous_period_text.ts index 822fa8d630230..544c3a6e28208 100644 --- a/x-pack/plugins/apm/public/hooks/use_previous_period_text.ts +++ b/x-pack/plugins/apm/public/hooks/use_previous_period_text.ts @@ -22,7 +22,8 @@ export const usePreviousPeriodLabel = () => { } = useAnyOfApmParams( '/services', '/dependencies/*', - '/services/{serviceName}' + '/services/{serviceName}', + '/mobile-services/{serviceName}/*' ); const { start, end } = useTimeRange({ rangeFrom, rangeTo }); diff --git a/x-pack/plugins/apm/server/index.ts b/x-pack/plugins/apm/server/index.ts index d04d10a1cccad..9d630a75ea24b 100644 --- a/x-pack/plugins/apm/server/index.ts +++ b/x-pack/plugins/apm/server/index.ts @@ -29,7 +29,7 @@ const configSchema = schema.object({ ui: schema.object({ enabled: schema.boolean({ defaultValue: true }), transactionGroupBucketSize: schema.number({ defaultValue: 1000 }), - maxTraceItems: schema.number({ defaultValue: 1000 }), + maxTraceItems: schema.number({ defaultValue: 5000 }), }), searchAggregatedTransactions: schema.oneOf( [ diff --git a/x-pack/plugins/apm/server/lib/anomaly_detection/create_anomaly_detection_jobs.ts b/x-pack/plugins/apm/server/lib/anomaly_detection/create_anomaly_detection_jobs.ts index 3e38b86853bd0..85c9550fd230d 100644 --- a/x-pack/plugins/apm/server/lib/anomaly_detection/create_anomaly_detection_jobs.ts +++ b/x-pack/plugins/apm/server/lib/anomaly_detection/create_anomaly_detection_jobs.ts @@ -9,7 +9,7 @@ import Boom from '@hapi/boom'; import { ElasticsearchClient, Logger } from '@kbn/core/server'; import { snakeCase } from 'lodash'; import moment from 'moment'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { ProcessorEvent } from '@kbn/observability-plugin/common'; import { waitForIndexStatus } from '@kbn/core-saved-objects-migration-server-internal'; import { ML_ERRORS } from '../../../common/anomaly_detection'; @@ -104,7 +104,7 @@ async function createAnomalyDetectionJob({ apmMetricIndex: string; }) { return withApmSpan('create_anomaly_detection_job', async () => { - const randomToken = uuid().substr(-4); + const randomToken = uuidv4().substr(-4); const anomalyDetectionJob = mlClient.modules.setup({ moduleId: ML_MODULE_ID_APM_TRANSACTION, diff --git a/x-pack/plugins/apm/server/routes/mobile/get_http_requests_chart.ts b/x-pack/plugins/apm/server/routes/mobile/get_http_requests_chart.ts new file mode 100644 index 0000000000000..e1e9ef59c94e8 --- /dev/null +++ b/x-pack/plugins/apm/server/routes/mobile/get_http_requests_chart.ts @@ -0,0 +1,153 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { ProcessorEvent } from '@kbn/observability-plugin/common'; +import { + kqlQuery, + rangeQuery, + termQuery, +} from '@kbn/observability-plugin/server'; +import { + SERVICE_NAME, + TRANSACTION_NAME, + SERVICE_TARGET_TYPE, +} from '../../../common/es_fields/apm'; +import { environmentQuery } from '../../../common/utils/environment_query'; +import { getOffsetInMs } from '../../../common/utils/get_offset_in_ms'; +import { offsetPreviousPeriodCoordinates } from '../../../common/utils/offset_previous_period_coordinate'; +import { APMEventClient } from '../../lib/helpers/create_es_client/create_apm_event_client'; +import { getBucketSize } from '../../lib/helpers/get_bucket_size'; +import { Coordinate } from '../../../typings/timeseries'; + +export interface HttpRequestsTimeseries { + currentPeriod: Coordinate[]; + previousPeriod: Coordinate[]; +} +interface Props { + apmEventClient: APMEventClient; + serviceName: string; + transactionName?: string; + environment: string; + start: number; + end: number; + kuery: string; + offset?: string; +} + +async function getHttpRequestsTimeseries({ + kuery, + apmEventClient, + serviceName, + transactionName, + environment, + start, + end, + offset, +}: Props) { + const { startWithOffset, endWithOffset } = getOffsetInMs({ + start, + end, + offset, + }); + + const { intervalString } = getBucketSize({ + start: startWithOffset, + end: endWithOffset, + minBucketSize: 60, + }); + + const response = await apmEventClient.search('get_http_requests_chart', { + apm: { events: [ProcessorEvent.metric] }, + body: { + track_total_hits: false, + size: 0, + query: { + bool: { + filter: [ + { exists: { field: SERVICE_TARGET_TYPE } }, + ...termQuery(SERVICE_NAME, serviceName), + ...termQuery(TRANSACTION_NAME, transactionName), + ...rangeQuery(startWithOffset, endWithOffset), + ...environmentQuery(environment), + ...kqlQuery(kuery), + ], + }, + }, + aggs: { + timeseries: { + date_histogram: { + field: '@timestamp', + fixed_interval: intervalString, + min_doc_count: 0, + extended_bounds: { min: startWithOffset, max: endWithOffset }, + }, + aggs: { + requests: { + filter: { term: { [SERVICE_TARGET_TYPE]: 'http' } }, + }, + }, + }, + }, + }, + }); + + return ( + response?.aggregations?.timeseries.buckets.map((bucket) => { + return { + x: bucket.key, + y: bucket.doc_count ?? 0, + }; + }) ?? [] + ); +} + +export async function getHttpRequestsChart({ + kuery, + apmEventClient, + serviceName, + transactionName, + environment, + start, + end, + offset, +}: Props): Promise { + const options = { + serviceName, + transactionName, + apmEventClient, + kuery, + environment, + }; + + const currentPeriodPromise = getHttpRequestsTimeseries({ + ...options, + start, + end, + }); + + const previousPeriodPromise = offset + ? getHttpRequestsTimeseries({ + ...options, + start, + end, + offset, + }) + : []; + + const [currentPeriod, previousPeriod] = await Promise.all([ + currentPeriodPromise, + previousPeriodPromise, + ]); + + return { + currentPeriod, + previousPeriod: offsetPreviousPeriodCoordinates({ + currentPeriodTimeseries: currentPeriod, + previousPeriodTimeseries: previousPeriod, + }), + }; +} diff --git a/x-pack/plugins/apm/server/routes/mobile/get_mobile_filters.ts b/x-pack/plugins/apm/server/routes/mobile/get_mobile_filters.ts index 1b1553fa3be8c..cc648513a896a 100644 --- a/x-pack/plugins/apm/server/routes/mobile/get_mobile_filters.ts +++ b/x-pack/plugins/apm/server/routes/mobile/get_mobile_filters.ts @@ -12,7 +12,7 @@ import { } from '@kbn/observability-plugin/server'; import { ProcessorEvent } from '@kbn/observability-plugin/common'; import { - DEVICE_MODEL_NAME, + DEVICE_MODEL_IDENTIFIER, HOST_OS_VERSION, NETWORK_CONNECTION_TYPE, SERVICE_NAME, @@ -76,7 +76,7 @@ export async function getMobileFilters({ aggs: { devices: { terms: { - field: DEVICE_MODEL_NAME, + field: DEVICE_MODEL_IDENTIFIER, size: 10, }, }, diff --git a/x-pack/plugins/apm/server/routes/mobile/get_mobile_stats.ts b/x-pack/plugins/apm/server/routes/mobile/get_mobile_stats.ts index 1102c728ce8db..e37f4ec9616c8 100644 --- a/x-pack/plugins/apm/server/routes/mobile/get_mobile_stats.ts +++ b/x-pack/plugins/apm/server/routes/mobile/get_mobile_stats.ts @@ -13,9 +13,8 @@ import { import { ProcessorEvent } from '@kbn/observability-plugin/common'; import { SERVICE_NAME, - TRANSACTION_TYPE, SESSION_ID, - SPAN_SUBTYPE, + SERVICE_TARGET_TYPE, APP_LAUNCH_TIME, EVENT_NAME, } from '../../../common/es_fields/apm'; @@ -59,7 +58,7 @@ export async function getMobileStats({ cardinality: { field: SESSION_ID }, }, requests: { - filter: { term: { [SPAN_SUBTYPE]: 'http' } }, + filter: { term: { [SERVICE_TARGET_TYPE]: 'http' } }, }, maxLoadTime: { max: { field: APP_LAUNCH_TIME }, @@ -85,7 +84,6 @@ export async function getMobileStats({ bool: { filter: [ ...termQuery(SERVICE_NAME, serviceName), - ...termQuery(TRANSACTION_TYPE, transactionType), ...rangeQuery(start, end), ...environmentQuery(environment), ...kqlQuery(kuery), diff --git a/x-pack/plugins/apm/server/routes/mobile/get_sessions_chart.ts b/x-pack/plugins/apm/server/routes/mobile/get_sessions_chart.ts new file mode 100644 index 0000000000000..874743af63342 --- /dev/null +++ b/x-pack/plugins/apm/server/routes/mobile/get_sessions_chart.ts @@ -0,0 +1,160 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { ProcessorEvent } from '@kbn/observability-plugin/common'; +import { + kqlQuery, + rangeQuery, + termQuery, +} from '@kbn/observability-plugin/server'; +import { offsetPreviousPeriodCoordinates } from '../../../common/utils/offset_previous_period_coordinate'; +import { + SERVICE_NAME, + SESSION_ID, + TRANSACTION_NAME, +} from '../../../common/es_fields/apm'; +import { environmentQuery } from '../../../common/utils/environment_query'; +import { getOffsetInMs } from '../../../common/utils/get_offset_in_ms'; +import { APMEventClient } from '../../lib/helpers/create_es_client/create_apm_event_client'; +import { getBucketSize } from '../../lib/helpers/get_bucket_size'; +import { Coordinate } from '../../../typings/timeseries'; + +export interface SessionsTimeseries { + currentPeriod: Coordinate[]; + previousPeriod: Coordinate[]; +} + +interface Props { + apmEventClient: APMEventClient; + serviceName: string; + transactionName?: string; + environment: string; + start: number; + end: number; + kuery: string; + offset?: string; +} + +async function getSessionTimeseries({ + apmEventClient, + serviceName, + transactionName, + environment, + start, + end, + kuery, + offset, +}: Props) { + const { startWithOffset, endWithOffset } = getOffsetInMs({ + start, + end, + offset, + }); + + const { intervalString } = getBucketSize({ + start: startWithOffset, + end: endWithOffset, + minBucketSize: 60, + }); + + const response = await apmEventClient.search('get_sessions_chart', { + apm: { + events: [ + ProcessorEvent.transaction, + ProcessorEvent.error, + ProcessorEvent.span, + ], + }, + body: { + track_total_hits: false, + size: 0, + query: { + bool: { + filter: [ + { exists: { field: SESSION_ID } }, + ...termQuery(SERVICE_NAME, serviceName), + ...termQuery(TRANSACTION_NAME, transactionName), + ...rangeQuery(startWithOffset, endWithOffset), + ...environmentQuery(environment), + ...kqlQuery(kuery), + ], + }, + }, + aggs: { + timeseries: { + date_histogram: { + field: '@timestamp', + fixed_interval: intervalString, + min_doc_count: 0, + extended_bounds: { min: startWithOffset, max: endWithOffset }, + }, + aggs: { + sessions: { + cardinality: { field: SESSION_ID }, + }, + }, + }, + }, + }, + }); + + return ( + response?.aggregations?.timeseries.buckets.map((bucket) => { + return { + x: bucket.key, + y: bucket.doc_count ?? 0, + }; + }) ?? [] + ); +} + +export async function getSessionsChart({ + kuery, + apmEventClient, + serviceName, + transactionName, + environment, + start, + end, + offset, +}: Props): Promise { + const options = { + serviceName, + transactionName, + apmEventClient, + kuery, + environment, + }; + + const currentPeriodPromise = getSessionTimeseries({ + ...options, + start, + end, + }); + + const previousPeriodPromise = offset + ? getSessionTimeseries({ + ...options, + start, + end, + offset, + }) + : []; + + const [currentPeriod, previousPeriod] = await Promise.all([ + currentPeriodPromise, + previousPeriodPromise, + ]); + + return { + currentPeriod, + previousPeriod: offsetPreviousPeriodCoordinates({ + currentPeriodTimeseries: currentPeriod, + previousPeriodTimeseries: previousPeriod, + }), + }; +} diff --git a/x-pack/plugins/apm/server/routes/mobile/route.ts b/x-pack/plugins/apm/server/routes/mobile/route.ts index 966a12ab776ed..e18e7cae75c87 100644 --- a/x-pack/plugins/apm/server/routes/mobile/route.ts +++ b/x-pack/plugins/apm/server/routes/mobile/route.ts @@ -9,10 +9,16 @@ import * as t from 'io-ts'; import { getApmEventClient } from '../../lib/helpers/get_apm_event_client'; import { createApmServerRoute } from '../apm_routes/create_apm_server_route'; import { environmentRt, kueryRt, rangeRt } from '../default_api_types'; +import { offsetRt } from '../../../common/comparison_rt'; +import { + getHttpRequestsChart, + HttpRequestsTimeseries, +} from './get_http_requests_chart'; import { getMobileFilters } from './get_mobile_filters'; +import { getSessionsChart, SessionsTimeseries } from './get_sessions_chart'; import { getMobileStats, MobileStats } from './get_mobile_stats'; -const mobileFilters = createApmServerRoute({ +const mobileFiltersRoute = createApmServerRoute({ endpoint: 'GET /internal/apm/services/{serviceName}/mobile/filters', params: t.type({ path: t.type({ @@ -51,7 +57,7 @@ const mobileFilters = createApmServerRoute({ }, }); -const mobileStats = createApmServerRoute({ +const mobileStatsRoute = createApmServerRoute({ endpoint: 'GET /internal/apm/mobile-services/{serviceName}/stats', params: t.type({ path: t.type({ @@ -71,12 +77,11 @@ const mobileStats = createApmServerRoute({ const apmEventClient = await getApmEventClient(resources); const { params } = resources; const { serviceName } = params.path; - const { kuery, environment, start, end, transactionType } = params.query; + const { kuery, environment, start, end } = params.query; const stats = await getMobileStats({ kuery, environment, - transactionType, start, end, serviceName, @@ -87,7 +92,91 @@ const mobileStats = createApmServerRoute({ }, }); +const sessionsChartRoute = createApmServerRoute({ + endpoint: + 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions', + params: t.type({ + path: t.type({ + serviceName: t.string, + }), + query: t.intersection([ + kueryRt, + rangeRt, + environmentRt, + offsetRt, + t.partial({ + transactionType: t.string, + transactionName: t.string, + }), + ]), + }), + options: { tags: ['access:apm'] }, + handler: async (resources): Promise => { + const apmEventClient = await getApmEventClient(resources); + const { params } = resources; + const { serviceName } = params.path; + const { kuery, environment, start, end, transactionName, offset } = + params.query; + + const { currentPeriod, previousPeriod } = await getSessionsChart({ + kuery, + environment, + transactionName, + start, + end, + serviceName, + apmEventClient, + offset, + }); + + return { currentPeriod, previousPeriod }; + }, +}); + +const httpRequestsChartRoute = createApmServerRoute({ + endpoint: + 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests', + params: t.type({ + path: t.type({ + serviceName: t.string, + }), + query: t.intersection([ + kueryRt, + rangeRt, + environmentRt, + offsetRt, + t.partial({ + transactionType: t.string, + transactionName: t.string, + }), + ]), + }), + options: { tags: ['access:apm'] }, + handler: async (resources): Promise => { + const apmEventClient = await getApmEventClient(resources); + const { params } = resources; + const { serviceName } = params.path; + const { kuery, environment, start, end, transactionName, offset } = + params.query; + + const { currentPeriod, previousPeriod } = await getHttpRequestsChart({ + kuery, + environment, + transactionName, + start, + end, + serviceName, + apmEventClient, + offset, + }); + + return { currentPeriod, previousPeriod }; + }, +}); + export const mobileRouteRepository = { - ...mobileFilters, - ...mobileStats, + ...mobileFiltersRoute, + ...sessionsChartRoute, + ...httpRequestsChartRoute, + ...mobileStatsRoute, }; diff --git a/x-pack/plugins/apm/server/routes/traces/__snapshots__/queries.test.ts.snap b/x-pack/plugins/apm/server/routes/traces/__snapshots__/queries.test.ts.snap index a490aec44a366..e44b52a5b1f6b 100644 --- a/x-pack/plugins/apm/server/routes/traces/__snapshots__/queries.test.ts.snap +++ b/x-pack/plugins/apm/server/routes/traces/__snapshots__/queries.test.ts.snap @@ -48,7 +48,7 @@ Object { }, }, }, - "size": 1000, + "size": 5000, "track_total_hits": false, }, } diff --git a/x-pack/plugins/apm/server/utils/test_helpers.tsx b/x-pack/plugins/apm/server/utils/test_helpers.tsx index 22ca4783497ca..ab1b63e058d04 100644 --- a/x-pack/plugins/apm/server/utils/test_helpers.tsx +++ b/x-pack/plugins/apm/server/utils/test_helpers.tsx @@ -79,7 +79,7 @@ export async function inspectSearchParams( return { enabled: true, transactionGroupBucketSize: 1000, - maxTraceItems: 1000, + maxTraceItems: 5000, }; case 'metricsInterval': return 30; diff --git a/x-pack/plugins/canvas/common/lib/get_id.ts b/x-pack/plugins/canvas/common/lib/get_id.ts index 56f7e69d82539..6b808a21500a3 100644 --- a/x-pack/plugins/canvas/common/lib/get_id.ts +++ b/x-pack/plugins/canvas/common/lib/get_id.ts @@ -5,8 +5,8 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export function getId(type: string): string { - return `${type}-${uuid()}`; + return `${type}-${uuidv4()}`; } diff --git a/x-pack/plugins/canvas/public/lib/get_id.ts b/x-pack/plugins/canvas/public/lib/get_id.ts index 56f7e69d82539..6b808a21500a3 100644 --- a/x-pack/plugins/canvas/public/lib/get_id.ts +++ b/x-pack/plugins/canvas/public/lib/get_id.ts @@ -5,8 +5,8 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export function getId(type: string): string { - return `${type}-${uuid()}`; + return `${type}-${uuidv4()}`; } diff --git a/x-pack/plugins/canvas/scripts/shareable_runtime.js b/x-pack/plugins/canvas/scripts/shareable_runtime.js index a0b8421f8da01..f3e1e66c1744a 100644 --- a/x-pack/plugins/canvas/scripts/shareable_runtime.js +++ b/x-pack/plugins/canvas/scripts/shareable_runtime.js @@ -55,6 +55,7 @@ run( execa.sync( process.execPath, [ + '--openssl-legacy-provider', require.resolve('webpack-dev-server/bin/webpack-dev-server'), '--config', webpackConfig, @@ -88,6 +89,7 @@ run( execa.sync( process.execPath, [ + '--openssl-legacy-provider', require.resolve('webpack/bin/webpack'), '--config', webpackConfig, diff --git a/x-pack/plugins/canvas/server/routes/custom_elements/create.test.ts b/x-pack/plugins/canvas/server/routes/custom_elements/create.test.ts index 5c255c35f305f..72f449098de98 100644 --- a/x-pack/plugins/canvas/server/routes/custom_elements/create.test.ts +++ b/x-pack/plugins/canvas/server/routes/custom_elements/create.test.ts @@ -30,7 +30,9 @@ const mockedUUID = '123abc'; const now = new Date(); const nowIso = now.toISOString(); -jest.mock('uuid/v4', () => jest.fn().mockReturnValue('123abc')); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('123abc'), +})); describe('POST custom element', () => { let routeHandler: RequestHandler; diff --git a/x-pack/plugins/canvas/server/routes/custom_elements/update.test.ts b/x-pack/plugins/canvas/server/routes/custom_elements/update.test.ts index 92dbf35bcf8aa..1eb2d3ddee6ee 100644 --- a/x-pack/plugins/canvas/server/routes/custom_elements/update.test.ts +++ b/x-pack/plugins/canvas/server/routes/custom_elements/update.test.ts @@ -31,7 +31,9 @@ const mockRouteContext = { const now = new Date(); const nowIso = now.toISOString(); -jest.mock('uuid/v4', () => jest.fn().mockReturnValue('123abc')); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('123abc'), +})); type CustomElementPayload = CustomElement & { '@timestamp': string; diff --git a/x-pack/plugins/canvas/server/routes/workpad/create.test.ts b/x-pack/plugins/canvas/server/routes/workpad/create.test.ts index e409e342fe16e..7e9e32e1c4184 100644 --- a/x-pack/plugins/canvas/server/routes/workpad/create.test.ts +++ b/x-pack/plugins/canvas/server/routes/workpad/create.test.ts @@ -21,7 +21,9 @@ let mockRouteContext = { canvas: workpadRouteContextMock.create(), } as unknown as AwaitedProperties; -jest.mock('uuid/v4', () => jest.fn().mockReturnValue('123abc')); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('123abc'), +})); describe('POST workpad', () => { let routeHandler: RequestHandler; diff --git a/x-pack/plugins/canvas/server/routes/workpad/update.test.ts b/x-pack/plugins/canvas/server/routes/workpad/update.test.ts index 2383e7d4beab2..fcf24f68743dd 100644 --- a/x-pack/plugins/canvas/server/routes/workpad/update.test.ts +++ b/x-pack/plugins/canvas/server/routes/workpad/update.test.ts @@ -28,7 +28,9 @@ const mockRouteContext = { const workpad = workpads[0]; const now = new Date(); -jest.mock('uuid/v4', () => jest.fn().mockReturnValue('123abc')); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('123abc'), +})); describe('PUT workpad', () => { let routeHandler: RequestHandler; diff --git a/x-pack/plugins/canvas/storybook/addon/components/action_list.tsx b/x-pack/plugins/canvas/storybook/addon/components/action_list.tsx index 7318158b9363d..734fbe87e831f 100644 --- a/x-pack/plugins/canvas/storybook/addon/components/action_list.tsx +++ b/x-pack/plugins/canvas/storybook/addon/components/action_list.tsx @@ -8,7 +8,7 @@ import React, { FC, useEffect, useState } from 'react'; import { EuiSelectable, EuiSelectableOption } from '@elastic/eui'; import addons from '@storybook/addons'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { EVENTS } from '../constants'; import { RecordedAction, RecordedPayload } from '../types'; @@ -25,7 +25,7 @@ export const ActionList: FC<{ useEffect(() => { const actionListener = (newAction: RecordedPayload) => { - const id = uuid(); + const id = uuidv4(); setRecordedActions({ ...recordedActions, [id]: { ...newAction, id } }); }; diff --git a/x-pack/plugins/canvas/storybook/addon/components/action_tree.tsx b/x-pack/plugins/canvas/storybook/addon/components/action_tree.tsx index caac16ee034ed..6fac4a42e0d17 100644 --- a/x-pack/plugins/canvas/storybook/addon/components/action_tree.tsx +++ b/x-pack/plugins/canvas/storybook/addon/components/action_tree.tsx @@ -7,7 +7,7 @@ import React, { FC } from 'react'; import { isObject, isDate } from 'lodash'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { EuiTreeView } from '@elastic/eui'; import { Node } from '@elastic/eui/src/components/tree_view/tree_view'; @@ -20,17 +20,17 @@ const actionToTree = (recordedAction: RecordedAction) => { return [ { label: 'Action', - id: uuid(), + id: uuidv4(), children: jsonToTree(action), }, { label: 'Previous State', - id: uuid(), + id: uuidv4(), children: jsonToTree(previousState), }, { label: 'Current State', - id: uuid(), + id: uuidv4(), children: jsonToTree(newState), }, ]; @@ -46,7 +46,7 @@ const jsonToTree: (obj: Record) => Node[] = (obj) => { return null; } - const id = uuid(); + const id = uuidv4(); if (isDate(value)) { return { label: `${label}: ${(value as Date).toDateString()}` }; diff --git a/x-pack/plugins/cases/common/api/connectors/index.ts b/x-pack/plugins/cases/common/api/connectors/index.ts index 5f73f3ae493ac..8aac471c634b8 100644 --- a/x-pack/plugins/cases/common/api/connectors/index.ts +++ b/x-pack/plugins/cases/common/api/connectors/index.ts @@ -116,6 +116,15 @@ export const CaseConnectorRt = rt.intersection([ CaseUserActionConnectorRt, ]); +export const GetCaseConnectorsResponseRt = rt.record( + rt.string, + rt.intersection([ + rt.type({ needsToBePushed: rt.boolean, hasBeenPushed: rt.boolean }), + rt.partial(rt.type({ latestPushDate: rt.string }).props), + CaseConnectorRt, + ]) +); + export type CaseUserActionConnector = rt.TypeOf; export type CaseConnector = rt.TypeOf; export type ConnectorTypeFields = rt.TypeOf; @@ -130,3 +139,5 @@ export type ConnectorServiceNowSIRTypeFields = rt.TypeOf; + +export type GetCaseConnectorsResponse = rt.TypeOf; diff --git a/x-pack/plugins/cases/common/api/connectors/mappings.ts b/x-pack/plugins/cases/common/api/connectors/mappings.ts index 8737a6c5a6462..33d7441c0c71f 100644 --- a/x-pack/plugins/cases/common/api/connectors/mappings.ts +++ b/x-pack/plugins/cases/common/api/connectors/mappings.ts @@ -16,6 +16,7 @@ const CaseFieldRT = rt.union([ rt.literal('title'), rt.literal('description'), rt.literal('comments'), + rt.literal('tags'), ]); const ThirdPartyFieldRT = rt.union([rt.string, rt.literal('not_mapped')]); diff --git a/x-pack/plugins/cases/common/constants.ts b/x-pack/plugins/cases/common/constants.ts index af50c851a1979..1f8d6031a1c56 100644 --- a/x-pack/plugins/cases/common/constants.ts +++ b/x-pack/plugins/cases/common/constants.ts @@ -89,6 +89,7 @@ export const INTERNAL_BULK_CREATE_ATTACHMENTS_URL = `${CASES_INTERNAL_URL}/{case_id}/attachments/_bulk_create` as const; export const INTERNAL_SUGGEST_USER_PROFILES_URL = `${CASES_INTERNAL_URL}/_suggest_user_profiles` as const; +export const INTERNAL_CONNECTORS_URL = `${CASES_INTERNAL_URL}/{case_id}/_connectors` as const; export const INTERNAL_BULK_GET_CASES_URL = `${CASES_INTERNAL_URL}/_bulk_get` as const; /** diff --git a/x-pack/plugins/cases/common/ui/types.ts b/x-pack/plugins/cases/common/ui/types.ts index 1723ae33385e5..f1193a2a49112 100644 --- a/x-pack/plugins/cases/common/ui/types.ts +++ b/x-pack/plugins/cases/common/ui/types.ts @@ -137,6 +137,7 @@ export type SingleCaseMetricsFeature = export enum SortFieldCase { closedAt = 'closedAt', createdAt = 'createdAt', + updatedAt = 'updatedAt', severity = 'severity', status = 'status', title = 'title', diff --git a/x-pack/plugins/cases/docs/openapi/bundled.json b/x-pack/plugins/cases/docs/openapi/bundled.json index 226d5578e8521..3fad9872c07bf 100644 --- a/x-pack/plugins/cases/docs/openapi/bundled.json +++ b/x-pack/plugins/cases/docs/openapi/bundled.json @@ -71,6 +71,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -107,6 +117,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -162,6 +182,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -419,6 +449,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -482,6 +522,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -649,6 +699,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -882,6 +942,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1104,6 +1174,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1184,6 +1264,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1253,6 +1343,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1310,6 +1410,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1373,6 +1483,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1428,6 +1548,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1477,6 +1607,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1540,6 +1680,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1569,6 +1719,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1625,6 +1785,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1659,6 +1829,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1698,6 +1878,16 @@ "responses": { "204": { "description": "Indicates a successful call." + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1746,6 +1936,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1807,6 +2007,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -1856,6 +2066,16 @@ } } } + }, + "401": { + "description": "Authorization information is missing or invalid.", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/4xx_response" + } + } + } } }, "servers": [ @@ -3008,6 +3228,23 @@ } } }, + "4xx_response": { + "type": "object", + "title": "Unsuccessful cases API response", + "properties": { + "error": { + "type": "string", + "example": "Unauthorized" + }, + "message": { + "type": "string" + }, + "statusCode": { + "type": "integer", + "example": 401 + } + } + }, "update_case_request": { "title": "Update case request", "description": "The update case API request body varies depending on the type of connector.", diff --git a/x-pack/plugins/cases/docs/openapi/bundled.yaml b/x-pack/plugins/cases/docs/openapi/bundled.yaml index e01bf8c4fea10..129bf13a79b48 100644 --- a/x-pack/plugins/cases/docs/openapi/bundled.yaml +++ b/x-pack/plugins/cases/docs/openapi/bundled.yaml @@ -45,6 +45,12 @@ paths: examples: createCaseResponse: $ref: '#/components/examples/create_case_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 delete: @@ -67,6 +73,12 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 patch: @@ -99,6 +111,12 @@ paths: examples: updateCaseResponse: $ref: '#/components/examples/update_case_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -257,6 +275,12 @@ paths: examples: findCaseResponse: $ref: '#/components/examples/find_case_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -293,6 +317,12 @@ paths: example: - id: 06116b80-e1c3-11ec-be9b-9b1838238ee6 title: security_case + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -409,6 +439,12 @@ paths: version: type: string example: WzIwNzMsMV0= + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 post: @@ -573,6 +609,12 @@ paths: examples: setCaseConfigResponse: $ref: '#/components/examples/set_case_configuration_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -728,6 +770,12 @@ paths: version: type: string example: WzIwNzMsMV0= + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -777,6 +825,12 @@ paths: examples: findConnectorResponse: $ref: '#/components/examples/find_connector_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -820,6 +874,12 @@ paths: examples: getReportersResponse: $ref: '#/components/examples/get_reporters_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -853,6 +913,12 @@ paths: examples: getStatusResponse: $ref: '#/components/examples/get_status_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -888,6 +954,12 @@ paths: examples: getTagsResponse: $ref: '#/components/examples/get_tags_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -920,6 +992,12 @@ paths: examples: getCaseResponse: $ref: '#/components/examples/get_case_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -948,6 +1026,12 @@ paths: examples: getCaseAlertsResponse: $ref: '#/components/examples/get_case_alerts_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -983,6 +1067,12 @@ paths: examples: createCaseCommentResponse: $ref: '#/components/examples/add_comment_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 delete: @@ -999,6 +1089,12 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 patch: @@ -1031,6 +1127,12 @@ paths: examples: updateCaseCommentResponse: $ref: '#/components/examples/update_comment_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 get: @@ -1051,6 +1153,12 @@ paths: application/json: schema: $ref: '#/components/schemas/case_response_properties' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -1071,6 +1179,12 @@ paths: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 get: @@ -1096,6 +1210,12 @@ paths: examples: getCaseCommentResponse: $ref: '#/components/examples/get_comment_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -1129,6 +1249,12 @@ paths: examples: pushCaseResponse: $ref: '#/components/examples/push_case_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -1157,6 +1283,12 @@ paths: examples: getCaseActivityResponse: $ref: '#/components/examples/get_case_activity_response' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '#/components/schemas/4xx_response' servers: - url: https://localhost:5601 servers: @@ -2004,6 +2136,18 @@ components: version: type: string example: WzUzMiwxXQ== + 4xx_response: + type: object + title: Unsuccessful cases API response + properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 update_case_request: title: Update case request description: The update case API request body varies depending on the type of connector. diff --git a/x-pack/plugins/cases/docs/openapi/components/schemas/4xx_response.yaml b/x-pack/plugins/cases/docs/openapi/components/schemas/4xx_response.yaml new file mode 100644 index 0000000000000..75d0ac39903bf --- /dev/null +++ b/x-pack/plugins/cases/docs/openapi/components/schemas/4xx_response.yaml @@ -0,0 +1,11 @@ +type: object +title: Unsuccessful cases API response +properties: + error: + type: string + example: Unauthorized + message: + type: string + statusCode: + type: integer + example: 401 \ No newline at end of file diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases.yaml index 98e36898e9685..ba4b852d96405 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases.yaml @@ -29,6 +29,12 @@ post: examples: createCaseResponse: $ref: '../components/examples/create_case_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -55,6 +61,12 @@ delete: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -90,6 +102,12 @@ patch: examples: updateCaseResponse: $ref: '../components/examples/update_case_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@_find.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@_find.yaml index 65fbc2e1e2e40..e4eb42e73f0b2 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@_find.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@_find.yaml @@ -163,6 +163,12 @@ get: examples: findCaseResponse: $ref: '../components/examples/find_case_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@alerts@{alertid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@alerts@{alertid}.yaml index f12e48f4bb6b9..940f343c89386 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@alerts@{alertid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@alerts@{alertid}.yaml @@ -30,7 +30,13 @@ get: description: The case title. example: - id: 06116b80-e1c3-11ec-be9b-9b1838238ee6 - title: security_case + title: security_case + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure.yaml index e95a6f5410149..cc17f044d437c 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure.yaml @@ -21,6 +21,12 @@ get: type: object properties: $ref: '../components/schemas/case_configure_response_properties.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -90,8 +96,13 @@ post: examples: setCaseConfigResponse: $ref: '../components/examples/set_case_configuration_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 - servers: - url: https://localhost:5601 \ No newline at end of file diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@connectors@_find.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@connectors@_find.yaml index d6328b4426f7b..7cdd1bf63ae61 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@connectors@_find.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@connectors@_find.yaml @@ -23,6 +23,12 @@ get: examples: findConnectorResponse: $ref: '../components/examples/find_connector_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@{configurationid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@{configurationid}.yaml index c15c3ff5dc1d7..5f8dae09abf55 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@{configurationid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@configure@{configurationid}.yaml @@ -50,6 +50,12 @@ patch: type: object properties: $ref: '../components/schemas/case_configure_response_properties.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@reporters.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@reporters.yaml index 171af68a417ba..51e57615f1216 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@reporters.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@reporters.yaml @@ -28,6 +28,12 @@ get: examples: getReportersResponse: $ref: '../components/examples/get_reporters_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@status.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@status.yaml index c3f4875e07ffd..a9db413e2eaef 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@status.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@status.yaml @@ -28,6 +28,12 @@ get: examples: getStatusResponse: $ref: '../components/examples/get_status_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@tags.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@tags.yaml index a4ce739c52b04..5e70cff6640e1 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@tags.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@tags.yaml @@ -30,7 +30,12 @@ get: examples: getTagsResponse: $ref: '../components/examples/get_tags_response.yaml' - + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml index d32d24b9fa01b..aca09f4a74420 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml @@ -27,6 +27,12 @@ get: examples: getCaseResponse: $ref: '../components/examples/get_case_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@alerts.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@alerts.yaml index abf2f26ce357b..aca587fe4886c 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@alerts.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@alerts.yaml @@ -23,6 +23,12 @@ get: examples: getCaseAlertsResponse: $ref: '../components/examples/get_case_alerts_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments.yaml index 25d119bd613c7..1b69926377ffb 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments.yaml @@ -31,6 +31,12 @@ post: examples: createCaseCommentResponse: $ref: '../components/examples/add_comment_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -50,6 +56,12 @@ delete: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -86,6 +98,12 @@ patch: examples: updateCaseCommentResponse: $ref: '../components/examples/update_comment_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -109,9 +127,13 @@ get: application/json: schema: $ref: '../components/schemas/case_response_properties.yaml' - + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 - servers: - url: https://localhost:5601 \ No newline at end of file diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments@{commentid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments@{commentid}.yaml index f12e43158a99a..e43a2b2d81d65 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments@{commentid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@comments@{commentid}.yaml @@ -15,6 +15,12 @@ delete: responses: '204': description: Indicates a successful call. + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 @@ -43,8 +49,13 @@ get: examples: getCaseCommentResponse: $ref: '../components/examples/get_comment_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 - servers: - url: https://localhost:5601 \ No newline at end of file diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@connector@{connectorid}@_push.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@connector@{connectorid}@_push.yaml index 7c4ba981edd07..c378192592ce9 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@connector@{connectorid}@_push.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@connector@{connectorid}@_push.yaml @@ -30,6 +30,12 @@ post: examples: pushCaseResponse: $ref: '../components/examples/push_case_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@user_actions.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@user_actions.yaml index 43a6ec096dfaa..a21988cd5434f 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@user_actions.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}@user_actions.yaml @@ -23,6 +23,12 @@ get: examples: getCaseActivityResponse: $ref: '../components/examples/get_case_activity_response.yaml' + '401': + description: Authorization information is missing or invalid. + content: + application/json: + schema: + $ref: '../components/schemas/4xx_response.yaml' servers: - url: https://localhost:5601 servers: diff --git a/x-pack/plugins/cases/public/common/translations.ts b/x-pack/plugins/cases/public/common/translations.ts index b7ef1d80f3afa..e691e712becd9 100644 --- a/x-pack/plugins/cases/public/common/translations.ts +++ b/x-pack/plugins/cases/public/common/translations.ts @@ -21,6 +21,14 @@ export const DELETE_CASE = (quantity: number = 1) => defaultMessage: `Delete {quantity, plural, =1 {case} other {{quantity} cases}}`, }); +export const COPY_ID_ACTION_LABEL = i18n.translate('xpack.cases.caseView.copyID', { + defaultMessage: 'Copy Case ID', +}); + +export const COPY_ID_ACTION_SUCCESS = i18n.translate('xpack.cases.caseView.copyIDSuccess', { + defaultMessage: 'Copied Case ID to clipboard', +}); + export const NAME = i18n.translate('xpack.cases.caseView.name', { defaultMessage: 'Name', }); @@ -29,6 +37,10 @@ export const CREATED_ON = i18n.translate('xpack.cases.caseView.createdOn', { defaultMessage: 'Created on', }); +export const UPDATED_ON = i18n.translate('xpack.cases.caseView.updatedOn', { + defaultMessage: 'Updated on', +}); + export const CLOSED_ON = i18n.translate('xpack.cases.caseView.closedOn', { defaultMessage: 'Closed on', }); @@ -158,7 +170,7 @@ export const NO_TAGS = i18n.translate('xpack.cases.caseView.noTags', { }); export const TITLE_REQUIRED = i18n.translate('xpack.cases.createCase.titleFieldRequiredError', { - defaultMessage: 'A title is required.', + defaultMessage: 'A name is required.', }); export const CONFIGURE_CASES_PAGE_TITLE = i18n.translate('xpack.cases.configureCases.headerTitle', { diff --git a/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.test.tsx b/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.test.tsx new file mode 100644 index 0000000000000..7cc4f7677286b --- /dev/null +++ b/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.test.tsx @@ -0,0 +1,91 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { AppMockRenderer } from '../../../common/mock'; +import { createAppMockRenderer } from '../../../common/mock'; +import { renderHook } from '@testing-library/react-hooks'; +import { useCopyIDAction } from './use_copy_id_action'; + +import { basicCase } from '../../../containers/mock'; + +jest.mock('../../../containers/api'); + +describe('useCopyIDAction', () => { + let appMockRender: AppMockRenderer; + const onActionSuccess = jest.fn(); + const originalClipboard = global.window.navigator.clipboard; + + beforeEach(() => { + appMockRender = createAppMockRenderer(); + jest.clearAllMocks(); + Object.defineProperty(navigator, 'clipboard', { + value: { + writeText: jest.fn().mockImplementation(() => Promise.resolve()), + }, + writable: true, + }); + }); + + afterEach(() => { + Object.defineProperty(navigator, 'clipboard', { + value: originalClipboard, + }); + }); + + it('renders a copy ID action with one case', async () => { + const { result } = renderHook(() => useCopyIDAction({ onActionSuccess }), { + wrapper: appMockRender.AppWrapper, + }); + + expect(result.current.getAction(basicCase)).toMatchInlineSnapshot(` + Object { + "data-test-subj": "cases-action-copy-id", + "icon": , + "key": "cases-action-copy-id", + "name": + Copy Case ID + , + "onClick": [Function], + } + `); + }); + + it('copies the id of the selected case to the clipboard', async () => { + const { result, waitFor } = renderHook(() => useCopyIDAction({ onActionSuccess }), { + wrapper: appMockRender.AppWrapper, + }); + + const action = result.current.getAction(basicCase); + + action.onClick(); + + await waitFor(() => { + expect(onActionSuccess).toHaveBeenCalled(); + expect(navigator.clipboard.writeText).toHaveBeenCalledWith(basicCase.id); + }); + }); + + it('shows the success toaster correctly when copying the case id', async () => { + const { result, waitFor } = renderHook(() => useCopyIDAction({ onActionSuccess }), { + wrapper: appMockRender.AppWrapper, + }); + + const action = result.current.getAction(basicCase); + + action.onClick(); + + await waitFor(() => { + expect(onActionSuccess).toHaveBeenCalled(); + expect(appMockRender.coreStart.notifications.toasts.addSuccess).toHaveBeenCalledWith( + 'Copied Case ID to clipboard' + ); + }); + }); +}); diff --git a/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.tsx b/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.tsx new file mode 100644 index 0000000000000..be2166ba5b250 --- /dev/null +++ b/x-pack/plugins/cases/public/components/actions/copy_id/use_copy_id_action.tsx @@ -0,0 +1,37 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { EuiIcon, EuiTextColor } from '@elastic/eui'; +import * as i18n from '../../../common/translations'; +import { useCasesToast } from '../../../common/use_cases_toast'; + +import type { Case } from '../../../../common'; +import type { UseCopyIDActionProps } from '../types'; + +export const useCopyIDAction = ({ onActionSuccess }: UseCopyIDActionProps) => { + const { showSuccessToast } = useCasesToast(); + + const getAction = (selectedCase: Case) => { + return { + name: {i18n.COPY_ID_ACTION_LABEL}, + onClick: () => { + navigator.clipboard.writeText(selectedCase.id).then(() => { + onActionSuccess(); + showSuccessToast(i18n.COPY_ID_ACTION_SUCCESS); + }); + }, + 'data-test-subj': 'cases-action-copy-id', + icon: , + key: 'cases-action-copy-id', + }; + }; + + return { getAction }; +}; + +export type UseCopyIDAction = ReturnType; diff --git a/x-pack/plugins/cases/public/components/actions/types.ts b/x-pack/plugins/cases/public/components/actions/types.ts index a906a0ff38269..7d477a09eed52 100644 --- a/x-pack/plugins/cases/public/components/actions/types.ts +++ b/x-pack/plugins/cases/public/components/actions/types.ts @@ -13,6 +13,8 @@ export interface UseActionProps { isDisabled: boolean; } +export type UseCopyIDActionProps = Pick; + export interface ItemsSelectionState { selectedItems: string[]; unSelectedItems: string[]; diff --git a/x-pack/plugins/cases/public/components/all_cases/all_cases_list.test.tsx b/x-pack/plugins/cases/public/components/all_cases/all_cases_list.test.tsx index 6c65308bc9a94..65156c39202b4 100644 --- a/x-pack/plugins/cases/public/components/all_cases/all_cases_list.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/all_cases_list.test.tsx @@ -208,6 +208,7 @@ describe.skip('AllCasesListGeneric', () => { id: null, createdAt: null, createdBy: null, + updatedAt: null, status: null, severity: null, tags: null, @@ -270,16 +271,22 @@ describe.skip('AllCasesListGeneric', () => { expect(res.getByTestId('tableHeaderCell_title_0')).toBeInTheDocument(); }); + it('renders the updated on column', async () => { + const res = appMockRenderer.render(); + + expect(res.getByTestId('tableHeaderCell_updatedAt_5')).toBeInTheDocument(); + }); + it('renders the status column', async () => { const res = appMockRenderer.render(); - expect(res.getByTestId('tableHeaderCell_status_6')).toBeInTheDocument(); + expect(res.getByTestId('tableHeaderCell_status_7')).toBeInTheDocument(); }); it('renders the severity column', async () => { const res = appMockRenderer.render(); - expect(res.getByTestId('tableHeaderCell_severity_7')).toBeInTheDocument(); + expect(res.getByTestId('tableHeaderCell_severity_8')).toBeInTheDocument(); }); it('should render the case stats', () => { @@ -403,7 +410,7 @@ describe.skip('AllCasesListGeneric', () => { const result = appMockRenderer.render(); userEvent.click( - within(result.getByTestId('tableHeaderCell_status_6')).getByTestId('tableHeaderSortButton') + within(result.getByTestId('tableHeaderCell_status_7')).getByTestId('tableHeaderSortButton') ); await waitFor(() => { @@ -423,7 +430,7 @@ describe.skip('AllCasesListGeneric', () => { const result = appMockRenderer.render(); userEvent.click( - within(result.getByTestId('tableHeaderCell_severity_7')).getByTestId('tableHeaderSortButton') + within(result.getByTestId('tableHeaderCell_severity_8')).getByTestId('tableHeaderSortButton') ); await waitFor(() => { @@ -459,6 +466,26 @@ describe.skip('AllCasesListGeneric', () => { }); }); + it('should sort by updatedOn', async () => { + const result = appMockRenderer.render(); + + userEvent.click( + within(result.getByTestId('tableHeaderCell_updatedAt_5')).getByTestId('tableHeaderSortButton') + ); + + await waitFor(() => { + expect(useGetCasesMock).toHaveBeenLastCalledWith( + expect.objectContaining({ + queryParams: { + ...DEFAULT_QUERY_PARAMS, + sortField: SortFieldCase.updatedAt, + sortOrder: 'asc', + }, + }) + ); + }); + }); + it('should filter by status: closed', async () => { const result = appMockRenderer.render(); userEvent.click(result.getByTestId('case-status-filter')); diff --git a/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx b/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx index ac60ccbc6c0bf..ab719466bbb25 100644 --- a/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx @@ -73,6 +73,7 @@ describe('useActions', () => { expect(res.getByText('Actions')).toBeInTheDocument(); expect(res.getByTestId(`case-action-status-panel-${basicCase.id}`)).toBeInTheDocument(); expect(res.getByTestId('cases-bulk-action-delete')).toBeInTheDocument(); + expect(res.getByTestId('cases-action-copy-id')).toBeInTheDocument(); }); }); @@ -143,6 +144,40 @@ describe('useActions', () => { }); }); + it('copies the case id to the clipboard', async () => { + const originalClipboard = global.window.navigator.clipboard; + + Object.defineProperty(navigator, 'clipboard', { + value: { + writeText: jest.fn().mockImplementation(() => Promise.resolve()), + }, + writable: true, + }); + + const { result } = renderHook(() => useActions({ disableActions: false }), { + wrapper: appMockRender.AppWrapper, + }); + + const comp = result.current.actions!.render(basicCase) as React.ReactElement; + const res = appMockRender.render(comp); + + userEvent.click(res.getByTestId(`case-action-popover-button-${basicCase.id}`)); + + await waitFor(() => { + expect(res.getByTestId('cases-action-copy-id')).toBeInTheDocument(); + }); + + userEvent.click(res.getByTestId('cases-action-copy-id'), undefined, { + skipPointerEventsCheck: true, + }); + + expect(navigator.clipboard.writeText).toHaveBeenCalledWith(basicCase.id); + + Object.defineProperty(navigator, 'clipboard', { + value: originalClipboard, + }); + }); + describe('Modals', () => { it('delete a case', async () => { const deleteSpy = jest.spyOn(api, 'deleteCases'); @@ -304,6 +339,7 @@ describe('useActions', () => { expect(res.getByTestId(`case-action-severity-panel-${basicCase.id}`)).toBeInTheDocument(); expect(res.getByTestId('cases-bulk-action-delete')).toBeInTheDocument(); expect(res.getByTestId(`actions-separator-${basicCase.id}`)).toBeInTheDocument(); + expect(res.getByTestId('cases-action-copy-id')).toBeInTheDocument(); }); }); @@ -321,6 +357,7 @@ describe('useActions', () => { await waitFor(() => { expect(res.getByTestId(`case-action-status-panel-${basicCase.id}`)).toBeInTheDocument(); expect(res.getByTestId(`case-action-severity-panel-${basicCase.id}`)).toBeInTheDocument(); + expect(res.getByTestId('cases-action-copy-id')).toBeInTheDocument(); expect(res.queryByTestId('cases-bulk-action-delete')).toBeFalsy(); expect(res.queryByTestId(`actions-separator-${basicCase.id}`)).toBeFalsy(); }); @@ -340,6 +377,7 @@ describe('useActions', () => { await waitFor(() => { expect(res.queryByTestId(`case-action-status-panel-${basicCase.id}`)).toBeFalsy(); expect(res.queryByTestId(`case-action-severity-panel-${basicCase.id}`)).toBeFalsy(); + expect(res.getByTestId('cases-action-copy-id')).toBeInTheDocument(); expect(res.getByTestId('cases-bulk-action-delete')).toBeInTheDocument(); expect(res.queryByTestId(`actions-separator-${basicCase.id}`)).toBeFalsy(); }); diff --git a/x-pack/plugins/cases/public/components/all_cases/use_actions.tsx b/x-pack/plugins/cases/public/components/all_cases/use_actions.tsx index d793233f9cca6..a06235d144a50 100644 --- a/x-pack/plugins/cases/public/components/all_cases/use_actions.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/use_actions.tsx @@ -27,6 +27,7 @@ import { useTagsAction } from '../actions/tags/use_tags_action'; import { EditTagsFlyout } from '../actions/tags/edit_tags_flyout'; import { useAssigneesAction } from '../actions/assignees/use_assignees_action'; import { EditAssigneesFlyout } from '../actions/assignees/edit_assignees_flyout'; +import { useCopyIDAction } from '../actions/copy_id/use_copy_id_action'; const ActionColumnComponent: React.FC<{ theCase: Case; disableActions: boolean }> = ({ theCase, @@ -43,6 +44,10 @@ const ActionColumnComponent: React.FC<{ theCase: Case; disableActions: boolean } onActionSuccess: refreshCases, }); + const copyIDAction = useCopyIDAction({ + onActionSuccess: closePopover, + }); + const statusAction = useStatusAction({ isDisabled: false, onAction: closePopover, @@ -126,6 +131,8 @@ const ActionColumnComponent: React.FC<{ theCase: Case; disableActions: boolean } mainPanelItems.push(assigneesAction.getAction([theCase])); } + mainPanelItems.push(copyIDAction.getAction(theCase)); + if (canDelete) { mainPanelItems.push(deleteAction.getAction([theCase])); } @@ -146,13 +153,14 @@ const ActionColumnComponent: React.FC<{ theCase: Case; disableActions: boolean } return panelsToBuild; }, [ + assigneesAction, canDelete, canUpdate, + copyIDAction, deleteAction, severityAction, statusAction, tagsAction, - assigneesAction, theCase, ]); diff --git a/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.test.tsx b/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.test.tsx index 0b8777465ff2d..f11794bcf13e2 100644 --- a/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.test.tsx @@ -92,9 +92,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", @@ -140,7 +148,7 @@ describe('useCasesColumns ', () => { "name": "Name", "render": [Function], "sortable": true, - "width": "20%", + "width": undefined, }, Object { "field": "assignees", @@ -152,14 +160,14 @@ describe('useCasesColumns ', () => { "field": "tags", "name": "Tags", "render": [Function], - "width": "15%", + "width": undefined, }, Object { "align": "right", "field": "totalAlerts", "name": "Alerts", "render": [Function], - "width": "80px", + "width": "55px", }, Object { "align": "right", @@ -179,9 +187,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": "80px", + }, Object { "name": "External Incident", "render": [Function], + "width": "80px", }, Object { "field": "status", @@ -259,9 +275,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", @@ -336,9 +360,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", @@ -408,9 +440,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", @@ -485,9 +525,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", @@ -527,20 +575,20 @@ describe('useCasesColumns ', () => { "name": "Name", "render": [Function], "sortable": true, - "width": "20%", + "width": undefined, }, Object { "field": "tags", "name": "Tags", "render": [Function], - "width": "15%", + "width": undefined, }, Object { "align": "right", "field": "totalAlerts", "name": "Alerts", "render": [Function], - "width": "80px", + "width": "55px", }, Object { "align": "right", @@ -560,9 +608,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": "80px", + }, Object { "name": "External Incident", "render": [Function], + "width": "80px", }, Object { "field": "status", @@ -601,20 +657,20 @@ describe('useCasesColumns ', () => { "name": "Name", "render": [Function], "sortable": true, - "width": "20%", + "width": undefined, }, Object { "field": "tags", "name": "Tags", "render": [Function], - "width": "15%", + "width": undefined, }, Object { "align": "right", "field": "totalAlerts", "name": "Alerts", "render": [Function], - "width": "80px", + "width": "55px", }, Object { "align": "right", @@ -634,9 +690,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": "80px", + }, Object { "name": "External Incident", "render": [Function], + "width": "80px", }, Object { "field": "status", @@ -707,9 +771,17 @@ describe('useCasesColumns ', () => { "render": [Function], "sortable": true, }, + Object { + "field": "updatedAt", + "name": "Updated on", + "render": [Function], + "sortable": true, + "width": undefined, + }, Object { "name": "External Incident", "render": [Function], + "width": undefined, }, Object { "field": "status", diff --git a/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.tsx b/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.tsx index 601e60ae9a5c5..a2760c71a8ef5 100644 --- a/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/use_cases_columns.tsx @@ -137,7 +137,7 @@ export const useCasesColumns = ({ } return getEmptyTagValue(); }, - width: '20%', + width: !isSelectorView ? '20%' : undefined, }, ]; @@ -197,7 +197,7 @@ export const useCasesColumns = ({ } return getEmptyTagValue(); }, - width: '15%', + width: !isSelectorView ? '15%' : undefined, }); if (isAlertsEnabled) { @@ -209,7 +209,7 @@ export const useCasesColumns = ({ totalAlerts != null ? renderStringField(`${totalAlerts}`, `case-table-column-alertsCount`) : getEmptyTagValue(), - width: '80px', + width: !isSelectorView ? '80px' : '55px', }); } @@ -278,6 +278,23 @@ export const useCasesColumns = ({ }); } + columns.push({ + field: 'updatedAt', + name: i18n.UPDATED_ON, + sortable: true, + render: (updatedAt: Case['updatedAt']) => { + if (updatedAt != null) { + return ( + + + + ); + } + return getEmptyTagValue(); + }, + width: isSelectorView ? '80px' : undefined, + }); + columns.push( { name: i18n.EXTERNAL_INCIDENT, @@ -287,6 +304,7 @@ export const useCasesColumns = ({ } return getEmptyTagValue(); }, + width: isSelectorView ? '80px' : undefined, }, { field: 'status', diff --git a/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx b/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx index cf15d546415be..16bef4b933d6e 100644 --- a/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx +++ b/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx @@ -55,6 +55,32 @@ describe('CaseView actions', () => { expect(wrapper.find('[data-test-subj="confirm-delete-case-modal"]').exists()).toBeTruthy(); }); + it('clicking copyClipboard icon copies case id', () => { + const originalClipboard = global.window.navigator.clipboard; + + Object.defineProperty(navigator, 'clipboard', { + value: { + writeText: jest.fn().mockImplementation(() => Promise.resolve()), + }, + writable: true, + }); + + const wrapper = mount( + + + + ); + + wrapper.find('button[data-test-subj="property-actions-ellipses"]').first().simulate('click'); + wrapper.find('button[data-test-subj="property-actions-copyClipboard"]').simulate('click'); + + expect(navigator.clipboard.writeText).toHaveBeenCalledWith(basicCase.id); + + Object.defineProperty(navigator, 'clipboard', { + value: originalClipboard, + }); + }); + it('does not show trash icon when user does not have deletion privileges', () => { const wrapper = mount( @@ -63,7 +89,9 @@ describe('CaseView actions', () => { ); expect(wrapper.find('[data-test-subj="confirm-delete-case-modal"]').exists()).toBeFalsy(); - expect(wrapper.find('button[data-test-subj="property-actions-ellipses"]').exists()).toBeFalsy(); + wrapper.find('button[data-test-subj="property-actions-ellipses"]').first().simulate('click'); + expect(wrapper.find('[data-test-subj="property-actions-trash"]').exists()).toBeFalsy(); + expect(wrapper.find('[data-test-subj="property-actions-copyClipboard"]').exists()).toBeTruthy(); }); it('toggle delete modal and confirm', async () => { diff --git a/x-pack/plugins/cases/public/components/case_action_bar/actions.tsx b/x-pack/plugins/cases/public/components/case_action_bar/actions.tsx index 414ac6326ef5d..bb6e323d433a0 100644 --- a/x-pack/plugins/cases/public/components/case_action_bar/actions.tsx +++ b/x-pack/plugins/cases/public/components/case_action_bar/actions.tsx @@ -16,6 +16,7 @@ import type { Case } from '../../../common/ui/types'; import type { CaseService } from '../../containers/use_get_case_user_actions'; import { useAllCasesNavigation } from '../../common/navigation'; import { useCasesContext } from '../cases_context/use_cases_context'; +import { useCasesToast } from '../../common/use_cases_toast'; interface CaseViewActions { caseData: Case; @@ -26,6 +27,7 @@ const ActionsComponent: React.FC = ({ caseData, currentExternal const { mutate: deleteCases } = useDeleteCases(); const { navigateToAllCases } = useAllCasesNavigation(); const { permissions } = useCasesContext(); + const { showSuccessToast } = useCasesToast(); const [isModalVisible, setIsModalVisible] = useState(false); const openModal = useCallback(() => { @@ -38,11 +40,20 @@ const ActionsComponent: React.FC = ({ caseData, currentExternal const propertyActions = useMemo( () => [ + { + iconType: 'copyClipboard', + label: i18n.COPY_ID_ACTION_LABEL, + onClick: () => { + navigator.clipboard.writeText(caseData.id); + showSuccessToast(i18n.COPY_ID_ACTION_SUCCESS); + }, + }, ...(permissions.delete ? [ { iconType: 'trash', label: i18n.DELETE_CASE(), + color: 'danger' as const, onClick: openModal, }, ] @@ -57,7 +68,7 @@ const ActionsComponent: React.FC = ({ caseData, currentExternal ] : []), ], - [permissions.delete, openModal, currentExternalIncident] + [permissions.delete, openModal, currentExternalIncident, caseData.id, showSuccessToast] ); const onConfirmDeletion = useCallback(() => { diff --git a/x-pack/plugins/cases/public/components/case_action_bar/index.test.tsx b/x-pack/plugins/cases/public/components/case_action_bar/index.test.tsx index dc2cbccc229c2..e458961db3424 100644 --- a/x-pack/plugins/cases/public/components/case_action_bar/index.test.tsx +++ b/x-pack/plugins/cases/public/components/case_action_bar/index.test.tsx @@ -233,8 +233,10 @@ describe('CaseActionBar', () => { ); - expect(queryByTestId('property-actions-ellipses')).not.toBeInTheDocument(); + userEvent.click(screen.getByTestId('property-actions-ellipses')); expect(queryByText('Delete case')).not.toBeInTheDocument(); + expect(queryByTestId('property-actions-trash')).not.toBeInTheDocument(); + expect(queryByTestId('property-actions-copyClipboard')).toBeInTheDocument(); }); it('should show the the delete item in the menu when the user does have delete privileges', () => { diff --git a/x-pack/plugins/cases/public/components/create/form_context.test.tsx b/x-pack/plugins/cases/public/components/create/form_context.test.tsx index 1f7551b466b8a..37971667da37b 100644 --- a/x-pack/plugins/cases/public/components/create/form_context.test.tsx +++ b/x-pack/plugins/cases/public/components/create/form_context.test.tsx @@ -282,7 +282,7 @@ describe('Create case', () => { await waitFor(() => { expect( - screen.getByText('The length of the title is too long. The maximum length is 160.') + screen.getByText('The length of the name is too long. The maximum length is 160.') ).toBeInTheDocument(); }); diff --git a/x-pack/plugins/cases/public/components/create/schema.tsx b/x-pack/plugins/cases/public/components/create/schema.tsx index f80c4e52945bb..10f414109852d 100644 --- a/x-pack/plugins/cases/public/components/create/schema.tsx +++ b/x-pack/plugins/cases/public/components/create/schema.tsx @@ -58,7 +58,7 @@ export const schema: FormSchema = { { validator: maxLengthField({ length: MAX_TITLE_LENGTH, - message: i18n.MAX_LENGTH_ERROR('title', MAX_TITLE_LENGTH), + message: i18n.MAX_LENGTH_ERROR('name', MAX_TITLE_LENGTH), }), }, ], diff --git a/x-pack/plugins/cases/public/components/property_actions/index.tsx b/x-pack/plugins/cases/public/components/property_actions/index.tsx index 8f67611097a80..61f4c4b6f2cfe 100644 --- a/x-pack/plugins/cases/public/components/property_actions/index.tsx +++ b/x-pack/plugins/cases/public/components/property_actions/index.tsx @@ -6,6 +6,7 @@ */ import React, { useCallback, useState } from 'react'; +import type { EuiButtonProps } from '@elastic/eui'; import { EuiFlexGroup, EuiFlexItem, EuiPopover, EuiButtonIcon, EuiButtonEmpty } from '@elastic/eui'; import * as i18n from './translations'; @@ -15,15 +16,16 @@ export interface PropertyActionButtonProps { onClick: () => void; iconType: string; label: string; + color?: EuiButtonProps['color']; } const ComponentId = 'property-actions'; const PropertyActionButton = React.memo( - ({ disabled = false, onClick, iconType, label }) => ( + ({ disabled = false, onClick, iconType, label, color }) => ( (({ propertyActio disabled={action.disabled} iconType={action.iconType} label={action.label} + color={action.color} onClick={() => onClosePopover(action.onClick)} /> diff --git a/x-pack/plugins/cases/public/components/user_actions/property_actions/alert_property_actions.tsx b/x-pack/plugins/cases/public/components/user_actions/property_actions/alert_property_actions.tsx index 0acafdcfa8d60..9885de69bb551 100644 --- a/x-pack/plugins/cases/public/components/user_actions/property_actions/alert_property_actions.tsx +++ b/x-pack/plugins/cases/public/components/user_actions/property_actions/alert_property_actions.tsx @@ -32,6 +32,7 @@ const AlertPropertyActionsComponent: React.FC = ({ isLoading, totalAlerts ? [ { iconType: 'minusInCircle', + color: 'danger' as const, label: i18n.REMOVE_ALERTS(totalAlerts), onClick: onModalOpen, }, diff --git a/x-pack/plugins/cases/public/components/user_actions/property_actions/registered_attachments_property_actions.tsx b/x-pack/plugins/cases/public/components/user_actions/property_actions/registered_attachments_property_actions.tsx index 28d82525246f5..8859d61c99ea5 100644 --- a/x-pack/plugins/cases/public/components/user_actions/property_actions/registered_attachments_property_actions.tsx +++ b/x-pack/plugins/cases/public/components/user_actions/property_actions/registered_attachments_property_actions.tsx @@ -34,6 +34,7 @@ const RegisteredAttachmentsPropertyActionsComponent: React.FC = ({ ? [ { iconType: 'trash', + color: 'danger' as const, label: i18n.DELETE_ATTACHMENT, onClick: onModalOpen, }, diff --git a/x-pack/plugins/cases/public/components/user_actions/property_actions/user_comment_property_actions.tsx b/x-pack/plugins/cases/public/components/user_actions/property_actions/user_comment_property_actions.tsx index 90d16dfc2bf61..a791ef534e5dd 100644 --- a/x-pack/plugins/cases/public/components/user_actions/property_actions/user_comment_property_actions.tsx +++ b/x-pack/plugins/cases/public/components/user_actions/property_actions/user_comment_property_actions.tsx @@ -54,21 +54,22 @@ const UserCommentPropertyActionsComponent: React.FC = ({ }, ] : []), - ...(showTrashIcon + ...(showQuoteIcon ? [ { - iconType: 'trash', - label: i18n.DELETE_COMMENT, - onClick: onModalOpen, + iconType: 'quote', + label: i18n.QUOTE, + onClick: onQuote, }, ] : []), - ...(showQuoteIcon + ...(showTrashIcon ? [ { - iconType: 'quote', - label: i18n.QUOTE, - onClick: onQuote, + iconType: 'trash', + color: 'danger' as const, + label: i18n.DELETE_COMMENT, + onClick: onModalOpen, }, ] : []), diff --git a/x-pack/plugins/cases/server/authorization/__snapshots__/audit_logger.test.ts.snap b/x-pack/plugins/cases/server/authorization/__snapshots__/audit_logger.test.ts.snap index ee6bc6e4a3681..6e824f460a722 100644 --- a/x-pack/plugins/cases/server/authorization/__snapshots__/audit_logger.test.ts.snap +++ b/x-pack/plugins/cases/server/authorization/__snapshots__/audit_logger.test.ts.snap @@ -1596,6 +1596,90 @@ Object { } `; +exports[`audit_logger log function event structure creates the correct audit event for operation: "getConnectors" with an error and entity 1`] = ` +Object { + "error": Object { + "code": "Error", + "message": "an error", + }, + "event": Object { + "action": "case_connectors_get", + "category": Array [ + "database", + ], + "outcome": "failure", + "type": Array [ + "access", + ], + }, + "kibana": Object { + "saved_object": Object { + "id": "1", + "type": "cases-user-actions", + }, + }, + "message": "Failed attempt to access cases-user-actions [id=1] as owner \\"awesome\\"", +} +`; + +exports[`audit_logger log function event structure creates the correct audit event for operation: "getConnectors" with an error but no entity 1`] = ` +Object { + "error": Object { + "code": "Error", + "message": "an error", + }, + "event": Object { + "action": "case_connectors_get", + "category": Array [ + "database", + ], + "outcome": "failure", + "type": Array [ + "access", + ], + }, + "message": "Failed attempt to access a user actions as any owners", +} +`; + +exports[`audit_logger log function event structure creates the correct audit event for operation: "getConnectors" without an error but with an entity 1`] = ` +Object { + "event": Object { + "action": "case_connectors_get", + "category": Array [ + "database", + ], + "outcome": "success", + "type": Array [ + "access", + ], + }, + "kibana": Object { + "saved_object": Object { + "id": "5", + "type": "cases-user-actions", + }, + }, + "message": "User has accessed cases-user-actions [id=5] as owner \\"super\\"", +} +`; + +exports[`audit_logger log function event structure creates the correct audit event for operation: "getConnectors" without an error or entity 1`] = ` +Object { + "event": Object { + "action": "case_connectors_get", + "category": Array [ + "database", + ], + "outcome": "success", + "type": Array [ + "access", + ], + }, + "message": "User has accessed a user actions as any owners", +} +`; + exports[`audit_logger log function event structure creates the correct audit event for operation: "getReporters" with an error and entity 1`] = ` Object { "error": Object { diff --git a/x-pack/plugins/cases/server/authorization/index.ts b/x-pack/plugins/cases/server/authorization/index.ts index 723221d361d82..0c301f372ba5d 100644 --- a/x-pack/plugins/cases/server/authorization/index.ts +++ b/x-pack/plugins/cases/server/authorization/index.ts @@ -318,6 +318,14 @@ export const Operations: Record ({ id: comment.id, @@ -150,7 +150,7 @@ export async function deleteComment( refresh: false, }); - await userActionService.createUserAction({ + await userActionService.creator.createUserAction({ type: ActionTypes.comment, action: Actions.delete, caseId: id, diff --git a/x-pack/plugins/cases/server/client/cases/create.ts b/x-pack/plugins/cases/server/client/cases/create.ts index 0da0f42b93f2f..a8f9975fee39f 100644 --- a/x-pack/plugins/cases/server/client/cases/create.ts +++ b/x-pack/plugins/cases/server/client/cases/create.ts @@ -102,7 +102,7 @@ export const create = async ( refresh: false, }); - await userActionService.createUserAction({ + await userActionService.creator.createUserAction({ type: ActionTypes.create_case, caseId: newCase.id, user, diff --git a/x-pack/plugins/cases/server/client/cases/delete.ts b/x-pack/plugins/cases/server/client/cases/delete.ts index 0b7a6a6839e5c..81f5df0d2d2b3 100644 --- a/x-pack/plugins/cases/server/client/cases/delete.ts +++ b/x-pack/plugins/cases/server/client/cases/delete.ts @@ -68,7 +68,7 @@ export async function deleteCases(ids: string[], clientArgs: CasesClientArgs): P options: { refresh: 'wait_for' }, }); - await userActionService.bulkAuditLogCaseDeletion( + await userActionService.creator.bulkAuditLogCaseDeletion( cases.saved_objects.map((caseInfo) => caseInfo.id) ); } catch (error) { diff --git a/x-pack/plugins/cases/server/client/cases/push.ts b/x-pack/plugins/cases/server/client/cases/push.ts index 9f5e9adbb4815..340a93dee2d4f 100644 --- a/x-pack/plugins/cases/server/client/cases/push.ts +++ b/x-pack/plugins/cases/server/client/cases/push.ts @@ -257,7 +257,7 @@ export const push = async ( ]); if (shouldMarkAsClosed) { - await userActionService.createUserAction({ + await userActionService.creator.createUserAction({ type: ActionTypes.status, payload: { status: CaseStatuses.closed }, user, @@ -271,7 +271,7 @@ export const push = async ( } } - await userActionService.createUserAction({ + await userActionService.creator.createUserAction({ type: ActionTypes.pushed, payload: { externalService }, user, diff --git a/x-pack/plugins/cases/server/client/cases/update.ts b/x-pack/plugins/cases/server/client/cases/update.ts index 6a304bf12e3e6..622665f139ad2 100644 --- a/x-pack/plugins/cases/server/client/cases/update.ts +++ b/x-pack/plugins/cases/server/client/cases/update.ts @@ -444,7 +444,7 @@ export const update = async ( ]; }, [] as CaseResponse[]); - await userActionService.bulkCreateUpdateCase({ + await userActionService.creator.bulkCreateUpdateCase({ originalCases: myCases.saved_objects, updatedCases: updatedCases.saved_objects, user, diff --git a/x-pack/plugins/cases/server/client/cases/utils.test.ts b/x-pack/plugins/cases/server/client/cases/utils.test.ts index 9f34a52dae6a4..1e26a5783e8d9 100644 --- a/x-pack/plugins/cases/server/client/cases/utils.test.ts +++ b/x-pack/plugins/cases/server/client/cases/utils.test.ts @@ -88,7 +88,7 @@ describe('utils', () => { isDeprecated: false, }; - it('creates an external incident', async () => { + it('creates an external incident correctly for Jira', async () => { const res = await createIncident({ theCase, userActions: [], @@ -113,6 +113,155 @@ describe('utils', () => { }); }); + it('creates an external incident correctly for SN', async () => { + const snConnector = { + ...connector, + actionTypeId: '.servicenow', + }; + + const res = await createIncident({ + theCase, + userActions: [], + connector: snConnector, + alerts: [], + casesConnectors, + spaceId: 'default', + }); + + expect(res).toEqual({ + incident: { + category: null, + subcategory: null, + correlation_display: 'Elastic Case', + correlation_id: 'mock-id-1', + impact: null, + severity: null, + urgency: null, + short_description: 'Super Bad Security Issue', + description: + 'This is a brand new case of a bad meanie defacing data\n\nAdded by elastic.', + externalId: null, + }, + comments: [], + }); + }); + + it('creates an external incident correctly for SIR', async () => { + const snConnector = { + ...connector, + actionTypeId: '.servicenow-sir', + }; + + const res = await createIncident({ + theCase, + userActions: [], + connector: snConnector, + alerts: [], + casesConnectors, + spaceId: 'default', + }); + + expect(res).toEqual({ + incident: { + category: null, + subcategory: null, + correlation_display: 'Elastic Case', + correlation_id: 'mock-id-1', + dest_ip: [], + source_ip: [], + malware_hash: [], + malware_url: [], + priority: null, + short_description: 'Super Bad Security Issue', + description: + 'This is a brand new case of a bad meanie defacing data\n\nAdded by elastic.', + externalId: null, + }, + comments: [], + }); + }); + + it('creates an external incident correctly for IBM Resilient', async () => { + const resilientConnector = { + ...connector, + actionTypeId: '.resilient', + }; + + const res = await createIncident({ + theCase, + userActions: [], + connector: resilientConnector, + alerts: [], + casesConnectors, + spaceId: 'default', + }); + + expect(res).toEqual({ + incident: { + incidentTypes: null, + severityCode: null, + name: 'Super Bad Security Issue', + description: + 'This is a brand new case of a bad meanie defacing data\n\nAdded by elastic.', + externalId: null, + }, + comments: [], + }); + }); + + it('creates an external incident correctly for Swimlane', async () => { + const swimlaneConnector = { + ...connector, + actionTypeId: '.swimlane', + }; + + const res = await createIncident({ + theCase, + userActions: [], + connector: swimlaneConnector, + alerts: [], + casesConnectors, + spaceId: 'default', + }); + + expect(res).toEqual({ + incident: { + caseId: 'mock-id-1', + caseName: 'Super Bad Security Issue', + description: + 'This is a brand new case of a bad meanie defacing data\n\nAdded by elastic.', + externalId: null, + }, + comments: [], + }); + }); + + it('creates an external incident correctly for Cases webhook', async () => { + const webhookConnector = { + ...connector, + actionTypeId: '.cases-webhook', + }; + + const res = await createIncident({ + theCase, + userActions: [], + connector: webhookConnector, + alerts: [], + casesConnectors, + spaceId: 'default', + }); + + expect(res).toEqual({ + incident: { + externalId: null, + description: 'This is a brand new case of a bad meanie defacing data', + tags: ['defacement'], + title: 'Super Bad Security Issue', + }, + comments: [], + }); + }); + it('formats the connector fields correctly', async () => { const caseWithConnector = { ...flattenCaseSavedObject({ diff --git a/x-pack/plugins/cases/server/client/cases/utils.ts b/x-pack/plugins/cases/server/client/cases/utils.ts index e142493dff130..954b48cb2d1da 100644 --- a/x-pack/plugins/cases/server/client/cases/utils.ts +++ b/x-pack/plugins/cases/server/client/cases/utils.ts @@ -208,12 +208,14 @@ export const createIncident = async ({ }; export const mapCaseFieldsToExternalSystemFields = ( - caseFields: Record, unknown>, + caseFields: Record, unknown>, mapping: ConnectorMappingsAttributes[] ): Record => { const mappedCaseFields: Record = {}; - for (const caseFieldKey of Object.keys(caseFields) as Array>) { + for (const caseFieldKey of Object.keys(caseFields) as Array< + Exclude + >) { const mapDefinition = mapping.find( (mappingEntry) => mappingEntry.source === caseFieldKey && mappingEntry.target !== 'not_mapped' ); diff --git a/x-pack/plugins/cases/server/client/factory.ts b/x-pack/plugins/cases/server/client/factory.ts index 9816f8444e399..63f0fdcb5a12b 100644 --- a/x-pack/plugins/cases/server/client/factory.ts +++ b/x-pack/plugins/cases/server/client/factory.ts @@ -13,6 +13,7 @@ import type { SavedObjectsClientContract, IBasePath, } from '@kbn/core/server'; +import type { ISavedObjectsSerializer } from '@kbn/core-saved-objects-server'; import { SECURITY_EXTENSION_ID } from '@kbn/core-saved-objects-server'; import type { AuditLogger, @@ -119,8 +120,11 @@ export class CasesClientFactory { excludedExtensions: [SECURITY_EXTENSION_ID], }); + const savedObjectsSerializer = savedObjectsService.createSerializer(); + const services = this.createServices({ unsecuredSavedObjectsClient, + savedObjectsSerializer, esClient: scopedClusterClient, request, auditLogger, @@ -152,11 +156,13 @@ export class CasesClientFactory { private createServices({ unsecuredSavedObjectsClient, + savedObjectsSerializer, esClient, request, auditLogger, }: { unsecuredSavedObjectsClient: SavedObjectsClientContract; + savedObjectsSerializer: ISavedObjectsSerializer; esClient: ElasticsearchClient; request: KibanaRequest; auditLogger: AuditLogger; @@ -201,6 +207,7 @@ export class CasesClientFactory { log: this.logger, persistableStateAttachmentTypeRegistry: this.options.persistableStateAttachmentTypeRegistry, unsecuredSavedObjectsClient, + savedObjectsSerializer, auditLogger, }), attachmentService, diff --git a/x-pack/plugins/cases/server/client/mocks.ts b/x-pack/plugins/cases/server/client/mocks.ts index 3281cd7764240..0ca2578d107a2 100644 --- a/x-pack/plugins/cases/server/client/mocks.ts +++ b/x-pack/plugins/cases/server/client/mocks.ts @@ -83,6 +83,7 @@ type UserActionsSubClientMock = jest.Mocked; const createUserActionsSubClientMock = (): UserActionsSubClientMock => { return { getAll: jest.fn(), + getConnectors: jest.fn(), }; }; diff --git a/x-pack/plugins/cases/server/client/user_actions/client.ts b/x-pack/plugins/cases/server/client/user_actions/client.ts index 3f14a313cd8f2..bb529ae3b2c2f 100644 --- a/x-pack/plugins/cases/server/client/user_actions/client.ts +++ b/x-pack/plugins/cases/server/client/user_actions/client.ts @@ -5,19 +5,12 @@ * 2.0. */ +import type { GetCaseConnectorsResponse } from '../../../common/api'; import type { ICaseUserActionsResponse } from '../typedoc_interfaces'; import type { CasesClientArgs } from '../types'; import { get } from './get'; - -/** - * Parameters for retrieving user actions for a particular case - */ -export interface UserActionGet { - /** - * The ID of the case - */ - caseId: string; -} +import { getConnectors } from './connectors'; +import type { GetConnectorsRequest, UserActionGet } from './types'; /** * API for interacting the actions performed by a user when interacting with the cases entities. @@ -27,16 +20,19 @@ export interface UserActionsSubClient { * Retrieves all user actions for a particular case. */ getAll(clientArgs: UserActionGet): Promise; + /** + * Retrieves all the connectors used within a given case + */ + getConnectors(clientArgs: GetConnectorsRequest): Promise; } /** * Creates an API object for interacting with the user action entities - * - * @ignore */ export const createUserActionsSubClient = (clientArgs: CasesClientArgs): UserActionsSubClient => { const attachmentSubClient: UserActionsSubClient = { getAll: (params: UserActionGet) => get(params, clientArgs), + getConnectors: (params: GetConnectorsRequest) => getConnectors(params, clientArgs), }; return Object.freeze(attachmentSubClient); diff --git a/x-pack/plugins/cases/server/client/user_actions/connectors.ts b/x-pack/plugins/cases/server/client/user_actions/connectors.ts new file mode 100644 index 0000000000000..18cba75d79948 --- /dev/null +++ b/x-pack/plugins/cases/server/client/user_actions/connectors.ts @@ -0,0 +1,265 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { isEqual } from 'lodash'; + +import type { SavedObject } from '@kbn/core/server'; +import type { PublicMethodsOf } from '@kbn/utility-types'; +import type { ActionResult, ActionsClient } from '@kbn/actions-plugin/server'; +import type { + CaseUserActionResponse, + GetCaseConnectorsResponse, + CaseConnector, +} from '../../../common/api'; +import { GetCaseConnectorsResponseRt } from '../../../common/api'; +import { isConnectorUserAction, isCreateCaseUserAction } from '../../../common/utils/user_actions'; +import { createCaseError } from '../../common/error'; +import type { CasesClientArgs } from '..'; +import type { Authorization, OwnerEntity } from '../../authorization'; +import { Operations } from '../../authorization'; +import type { GetConnectorsRequest } from './types'; +import type { CaseConnectorActivity, PushInfo } from '../../services/user_actions/types'; +import type { CaseUserActionService } from '../../services'; + +export const getConnectors = async ( + { caseId }: GetConnectorsRequest, + clientArgs: CasesClientArgs +): Promise => { + const { + services: { userActionService }, + logger, + authorization, + actionsClient, + } = clientArgs; + + try { + const [connectors, latestUserAction] = await Promise.all([ + userActionService.getCaseConnectorInformation(caseId), + userActionService.getMostRecentUserAction(caseId), + ]); + + await checkConnectorsAuthorization({ authorization, connectors, latestUserAction }); + + const results = await getConnectorsInfo({ + caseId, + actionsClient, + connectors, + latestUserAction, + userActionService, + }); + + return GetCaseConnectorsResponseRt.encode(results); + } catch (error) { + throw createCaseError({ + message: `Failed to retrieve the case connectors case id: ${caseId}: ${error}`, + error, + logger, + }); + } +}; + +const checkConnectorsAuthorization = async ({ + connectors, + latestUserAction, + authorization, +}: { + connectors: CaseConnectorActivity[]; + latestUserAction?: SavedObject; + authorization: PublicMethodsOf; +}) => { + const entities: OwnerEntity[] = latestUserAction + ? [{ owner: latestUserAction.attributes.owner, id: latestUserAction.id }] + : []; + + for (const connector of connectors) { + entities.push({ + owner: connector.fields.attributes.owner, + id: connector.connectorId, + }); + + if (connector.push) { + entities.push({ + owner: connector.push.attributes.owner, + id: connector.connectorId, + }); + } + } + + await authorization.ensureAuthorized({ + entities, + operation: Operations.getConnectors, + }); +}; + +interface EnrichedPushInfo { + pushDate: Date; + connectorFieldsUsedInPush: CaseConnector; +} + +const getConnectorsInfo = async ({ + caseId, + connectors, + latestUserAction, + actionsClient, + userActionService, +}: { + caseId: string; + connectors: CaseConnectorActivity[]; + latestUserAction?: SavedObject; + actionsClient: PublicMethodsOf; + userActionService: CaseUserActionService; +}): Promise => { + const connectorIds = connectors.map((connector) => connector.connectorId); + + const [pushInfo, actionConnectors] = await Promise.all([ + getPushInfo({ caseId, activity: connectors, userActionService }), + actionsClient.getBulk(connectorIds), + ]); + + return createConnectorInfoResult({ actionConnectors, connectors, pushInfo, latestUserAction }); +}; + +const getPushInfo = async ({ + caseId, + activity, + userActionService, +}: { + caseId: string; + activity: CaseConnectorActivity[]; + userActionService: CaseUserActionService; +}): Promise> => { + const pushRequest: PushInfo[] = []; + + for (const connectorInfo of activity) { + const pushCreatedAt = getDate(connectorInfo.push?.attributes.created_at); + + if (connectorInfo.push != null && pushCreatedAt != null) { + pushRequest.push({ connectorId: connectorInfo.connectorId, date: pushCreatedAt }); + } + } + + const connectorFieldsForPushes = await userActionService.getConnectorFieldsBeforeLatestPush( + caseId, + pushRequest + ); + + const enrichedPushInfo = new Map(); + for (const request of pushRequest) { + const connectorFieldsSO = connectorFieldsForPushes.get(request.connectorId); + const connectorFields = getConnectorInfoFromSavedObject(connectorFieldsSO); + + if (connectorFields != null) { + enrichedPushInfo.set(request.connectorId, { + pushDate: request.date, + connectorFieldsUsedInPush: connectorFields, + }); + } + } + + return enrichedPushInfo; +}; + +const getDate = (timestamp: string | undefined): Date | undefined => { + if (timestamp == null) { + return; + } + + const date = new Date(timestamp); + + if (isDateValid(date)) { + return date; + } +}; + +const isDateValid = (date: Date): boolean => { + return !isNaN(date.getTime()); +}; + +const getConnectorInfoFromSavedObject = ( + savedObject: SavedObject | undefined +): CaseConnector | undefined => { + if ( + savedObject != null && + (isConnectorUserAction(savedObject.attributes) || + isCreateCaseUserAction(savedObject.attributes)) + ) { + return savedObject.attributes.payload.connector; + } +}; + +const createConnectorInfoResult = ({ + actionConnectors, + connectors, + pushInfo, + latestUserAction, +}: { + actionConnectors: ActionResult[]; + connectors: CaseConnectorActivity[]; + pushInfo: Map; + latestUserAction?: SavedObject; +}) => { + const results: GetCaseConnectorsResponse = {}; + + for (let i = 0; i < connectors.length; i++) { + const connectorDetails = actionConnectors[i]; + const aggregationConnector = connectors[i]; + const connector = getConnectorInfoFromSavedObject(aggregationConnector.fields); + + const latestUserActionCreatedAt = getDate(latestUserAction?.attributes.created_at); + + if (connector != null) { + const enrichedPushInfo = pushInfo.get(aggregationConnector.connectorId); + const needsToBePushed = hasDataToPush({ + connector, + pushInfo: enrichedPushInfo, + latestUserActionDate: latestUserActionCreatedAt, + }); + + results[connector.id] = { + ...connector, + name: connectorDetails.name, + needsToBePushed, + latestPushDate: enrichedPushInfo?.pushDate.toISOString(), + hasBeenPushed: hasBeenPushed(enrichedPushInfo), + }; + } + } + + return results; +}; + +/** + * The algorithm to determine if a specific connector within a case needs to be pushed is as follows: + * 1. Check to see if the connector has been used to push, if it hasn't then we need to push + * 2. Check to see if the most recent connector fields are different than the connector fields used in the most recent push, + * if they are different then we need to push + * 3. Check to see if the most recent valid user action (a valid user action is one that changes the title, description, + * tags, or creation of a comment) was created after the most recent push (aka did the user do something new that needs + * to be pushed) + */ +const hasDataToPush = ({ + connector, + pushInfo, + latestUserActionDate, +}: { + connector: CaseConnector; + pushInfo?: EnrichedPushInfo; + latestUserActionDate?: Date; +}): boolean => { + return ( + /** + * This isEqual call satisfies the first two steps of the algorithm above because if a push never occurred then the + * push fields will be undefined which will not equal the latest connector fields anyway. + */ + !isEqual(connector, pushInfo?.connectorFieldsUsedInPush) || + (pushInfo != null && latestUserActionDate != null && latestUserActionDate > pushInfo.pushDate) + ); +}; + +const hasBeenPushed = (pushInfo: EnrichedPushInfo | undefined): boolean => { + return pushInfo != null; +}; diff --git a/x-pack/plugins/cases/server/client/user_actions/get.ts b/x-pack/plugins/cases/server/client/user_actions/get.ts index 3b1addfe7c6c5..63711419ad3b9 100644 --- a/x-pack/plugins/cases/server/client/user_actions/get.ts +++ b/x-pack/plugins/cases/server/client/user_actions/get.ts @@ -11,7 +11,7 @@ import { CaseUserActionsResponseRt } from '../../../common/api'; import { createCaseError } from '../../common/error'; import type { CasesClientArgs } from '..'; import { Operations } from '../../authorization'; -import type { UserActionGet } from './client'; +import type { UserActionGet } from './types'; export const get = async ( { caseId }: UserActionGet, diff --git a/x-pack/plugins/cases/server/client/user_actions/types.ts b/x-pack/plugins/cases/server/client/user_actions/types.ts new file mode 100644 index 0000000000000..a974c5136047c --- /dev/null +++ b/x-pack/plugins/cases/server/client/user_actions/types.ts @@ -0,0 +1,18 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +/** + * Parameters for retrieving user actions for a particular case + */ +export interface UserActionGet { + /** + * The ID of the case + */ + caseId: string; +} + +export type GetConnectorsRequest = UserActionGet; diff --git a/x-pack/plugins/cases/server/client/utils.test.ts b/x-pack/plugins/cases/server/client/utils.test.ts index 94f973683f567..12cbc1bb60358 100644 --- a/x-pack/plugins/cases/server/client/utils.test.ts +++ b/x-pack/plugins/cases/server/client/utils.test.ts @@ -31,6 +31,14 @@ describe('utils', () => { expect(convertSortField('created_at')).toBe('created_at'); }); + it('transforms updated_at correctly', () => { + expect(convertSortField('updated_at')).toBe('updated_at'); + }); + + it('transforms updatedAt correctly', () => { + expect(convertSortField('updatedAt')).toBe('updated_at'); + }); + it('transforms closedAt correctly', () => { expect(convertSortField('closedAt')).toBe('closed_at'); }); diff --git a/x-pack/plugins/cases/server/client/utils.ts b/x-pack/plugins/cases/server/client/utils.ts index fffc704d37d98..b2a151f6d9957 100644 --- a/x-pack/plugins/cases/server/client/utils.ts +++ b/x-pack/plugins/cases/server/client/utils.ts @@ -503,6 +503,7 @@ enum SortFieldCase { status = 'status', title = 'title.keyword', severity = 'severity', + updatedAt = 'updated_at', } export const convertSortField = (sortField: string | undefined): SortFieldCase => { @@ -519,6 +520,9 @@ export const convertSortField = (sortField: string | undefined): SortFieldCase = return SortFieldCase.title; case 'severity': return SortFieldCase.severity; + case 'updatedAt': + case 'updated_at': + return SortFieldCase.updatedAt; default: return SortFieldCase.createdAt; } diff --git a/x-pack/plugins/cases/server/common/models/case_with_comments.ts b/x-pack/plugins/cases/server/common/models/case_with_comments.ts index 1cc40b48d51e6..62d6b44b613f8 100644 --- a/x-pack/plugins/cases/server/common/models/case_with_comments.ts +++ b/x-pack/plugins/cases/server/common/models/case_with_comments.ts @@ -182,7 +182,7 @@ export class CaseCommentModel { ) { const { id, version, ...queryRestAttributes } = updateRequest; - await this.params.services.userActionService.createUserAction({ + await this.params.services.userActionService.creator.createUserAction({ type: ActionTypes.comment, action: Actions.update, caseId: this.caseInfo.id, @@ -335,7 +335,7 @@ export class CaseCommentModel { comment: SavedObject, req: CommentRequest ) { - await this.params.services.userActionService.createUserAction({ + await this.params.services.userActionService.creator.createUserAction({ type: ActionTypes.comment, action: Actions.create, caseId: this.caseInfo.id, @@ -349,7 +349,7 @@ export class CaseCommentModel { } private async bulkCreateCommentUserAction(attachments: Array<{ id: string } & CommentRequest>) { - await this.params.services.userActionService.bulkCreateAttachmentCreation({ + await this.params.services.userActionService.creator.bulkCreateAttachmentCreation({ caseId: this.caseInfo.id, attachments: attachments.map(({ id, ...attachment }) => ({ id, diff --git a/x-pack/plugins/cases/server/connectors/jira/mapping.ts b/x-pack/plugins/cases/server/connectors/jira/mapping.ts index 716a2694bdf1a..c3be1cc14fc45 100644 --- a/x-pack/plugins/cases/server/connectors/jira/mapping.ts +++ b/x-pack/plugins/cases/server/connectors/jira/mapping.ts @@ -19,6 +19,11 @@ export const getMapping: GetMapping = () => { target: 'description', action_type: 'overwrite', }, + { + source: 'tags', + target: 'labels', + action_type: 'overwrite', + }, { source: 'comments', target: 'comments', diff --git a/x-pack/plugins/cases/server/routes/api/get_internal_routes.ts b/x-pack/plugins/cases/server/routes/api/get_internal_routes.ts index 096a57af6b8ca..ca1f44706caf9 100644 --- a/x-pack/plugins/cases/server/routes/api/get_internal_routes.ts +++ b/x-pack/plugins/cases/server/routes/api/get_internal_routes.ts @@ -6,6 +6,7 @@ */ import type { UserProfileService } from '../../services'; +import { getConnectorsRoute } from './internal/get_connectors'; import { bulkCreateAttachmentsRoute } from './internal/bulk_create_attachments'; import { bulkGetCasesRoute } from './internal/bulk_get_cases'; import { suggestUserProfilesRoute } from './internal/suggest_user_profiles'; @@ -15,5 +16,6 @@ export const getInternalRoutes = (userProfileService: UserProfileService) => [ bulkCreateAttachmentsRoute, suggestUserProfilesRoute(userProfileService), + getConnectorsRoute, bulkGetCasesRoute, ] as CaseRoute[]; diff --git a/x-pack/plugins/cases/server/routes/api/internal/get_connectors.ts b/x-pack/plugins/cases/server/routes/api/internal/get_connectors.ts new file mode 100644 index 0000000000000..ac48e17461fad --- /dev/null +++ b/x-pack/plugins/cases/server/routes/api/internal/get_connectors.ts @@ -0,0 +1,37 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { schema } from '@kbn/config-schema'; +import { INTERNAL_CONNECTORS_URL } from '../../../../common/constants'; +import { createCaseError } from '../../../common/error'; +import { createCasesRoute } from '../create_cases_route'; + +export const getConnectorsRoute = createCasesRoute({ + method: 'get', + path: INTERNAL_CONNECTORS_URL, + params: { + params: schema.object({ + case_id: schema.string(), + }), + }, + handler: async ({ context, request, response }) => { + try { + const casesContext = await context.cases; + const casesClient = await casesContext.getCasesClient(); + const caseId = request.params.case_id; + + return response.ok({ + body: await casesClient.userActions.getConnectors({ caseId }), + }); + } catch (error) { + throw createCaseError({ + message: `Failed to retrieve connectors in route case id: ${request.params.case_id}: ${error}`, + error, + }); + } + }, +}); diff --git a/x-pack/plugins/cases/server/saved_object_types/user_actions.ts b/x-pack/plugins/cases/server/saved_object_types/user_actions.ts index 1862e180acc22..3060ca219ca42 100644 --- a/x-pack/plugins/cases/server/saved_object_types/user_actions.ts +++ b/x-pack/plugins/cases/server/saved_object_types/user_actions.ts @@ -50,6 +50,16 @@ export const createCaseUserActionSavedObjectType = ( type: { type: 'keyword' }, }, }, + comment: { + properties: { + // comment.type + type: { type: 'keyword' }, + // comment.externalReferenceAttachmentTypeId + externalReferenceAttachmentTypeId: { type: 'keyword' }, + // comment.persistableStateAttachmentTypeId + persistableStateAttachmentTypeId: { type: 'keyword' }, + }, + }, }, }, owner: { diff --git a/x-pack/plugins/cases/server/services/mocks.ts b/x-pack/plugins/cases/server/services/mocks.ts index 125fbc7ec9650..11ce2711bbbae 100644 --- a/x-pack/plugins/cases/server/services/mocks.ts +++ b/x-pack/plugins/cases/server/services/mocks.ts @@ -16,11 +16,13 @@ import type { } from '.'; import type { LicensingService } from './licensing'; import type { EmailNotificationService } from './notifications/email_notification_service'; +import type { UserActionPersister } from './user_actions/operations/create'; export type CaseServiceMock = jest.Mocked; export type CaseConfigureServiceMock = jest.Mocked; export type ConnectorMappingsServiceMock = jest.Mocked; export type CaseUserActionServiceMock = jest.Mocked; +export type CaseUserActionPersisterServiceMock = jest.Mocked; export type AlertServiceMock = jest.Mocked; export type AttachmentServiceMock = jest.Mocked; export type LicensingServiceMock = jest.Mocked; @@ -73,13 +75,28 @@ export const connectorMappingsServiceMock = (): ConnectorMappingsServiceMock => return service as unknown as ConnectorMappingsServiceMock; }; -export const createUserActionServiceMock = (): CaseUserActionServiceMock => { - const service: PublicMethodsOf = { +const createUserActionPersisterServiceMock = (): CaseUserActionPersisterServiceMock => { + const service: PublicMethodsOf = { bulkAuditLogCaseDeletion: jest.fn(), bulkCreateUpdateCase: jest.fn(), bulkCreateAttachmentDeletion: jest.fn(), bulkCreateAttachmentCreation: jest.fn(), createUserAction: jest.fn(), + }; + + return service as unknown as CaseUserActionPersisterServiceMock; +}; + +type FakeUserActionService = PublicMethodsOf & { + creator: CaseUserActionPersisterServiceMock; +}; + +export const createUserActionServiceMock = (): CaseUserActionServiceMock => { + const service: FakeUserActionService = { + creator: createUserActionPersisterServiceMock(), + getConnectorFieldsBeforeLatestPush: jest.fn(), + getMostRecentUserAction: jest.fn(), + getCaseConnectorInformation: jest.fn(), getAll: jest.fn(), findStatusChanges: jest.fn(), getUniqueConnectors: jest.fn(), diff --git a/x-pack/plugins/cases/server/services/user_actions/index.test.ts b/x-pack/plugins/cases/server/services/user_actions/index.test.ts index e2aa6192cdccf..f5fefebfc41b7 100644 --- a/x-pack/plugins/cases/server/services/user_actions/index.test.ts +++ b/x-pack/plugins/cases/server/services/user_actions/index.test.ts @@ -64,6 +64,7 @@ import { createPersistableStateAttachmentTypeRegistryMock, persistableStateAttachment, } from '../../attachment_framework/mocks'; +import { serializerMock } from '@kbn/core-saved-objects-base-server-mocks'; const createConnectorUserAction = ( overrides?: Partial @@ -661,6 +662,8 @@ describe('CaseUserActionService', () => { }; const mockAuditLogger = auditLoggerMock.create(); + const soSerializerMock = serializerMock.create(); + beforeEach(() => { jest.clearAllMocks(); service = new CaseUserActionService({ @@ -668,13 +671,14 @@ describe('CaseUserActionService', () => { log: mockLogger, persistableStateAttachmentTypeRegistry, auditLogger: mockAuditLogger, + savedObjectsSerializer: soSerializerMock, }); }); describe('createUserAction', () => { describe('create case', () => { it('creates a create case user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: casePayload, type: ActionTypes.create_case, @@ -726,7 +730,7 @@ describe('CaseUserActionService', () => { }); it('logs a create case user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: casePayload, type: ActionTypes.create_case, @@ -760,7 +764,7 @@ describe('CaseUserActionService', () => { describe('status', () => { it('creates an update status user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { status: CaseStatuses.closed }, type: ActionTypes.status, @@ -785,7 +789,7 @@ describe('CaseUserActionService', () => { }); it('logs an update status user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { status: CaseStatuses.closed }, type: ActionTypes.status, @@ -820,7 +824,7 @@ describe('CaseUserActionService', () => { describe('severity', () => { it('creates an update severity user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { severity: CaseSeverity.MEDIUM }, type: ActionTypes.severity, @@ -845,7 +849,7 @@ describe('CaseUserActionService', () => { }); it('logs an update severity user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { severity: CaseSeverity.MEDIUM }, type: ActionTypes.severity, @@ -880,7 +884,7 @@ describe('CaseUserActionService', () => { describe('push', () => { it('creates a push user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { externalService }, type: ActionTypes.pushed, @@ -924,7 +928,7 @@ describe('CaseUserActionService', () => { }); it('logs a push user action', async () => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, payload: { externalService }, type: ActionTypes.pushed, @@ -961,7 +965,7 @@ describe('CaseUserActionService', () => { it.each([[Actions.create], [Actions.delete], [Actions.update]])( 'creates a comment user action of action: %s', async (action) => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, type: ActionTypes.comment, action, @@ -1002,7 +1006,7 @@ describe('CaseUserActionService', () => { it.each([[Actions.create], [Actions.delete], [Actions.update]])( 'logs a comment user action of action: %s', async (action) => { - await service.createUserAction({ + await service.creator.createUserAction({ ...commonArgs, type: ActionTypes.comment, action, @@ -1020,7 +1024,7 @@ describe('CaseUserActionService', () => { describe('bulkAuditLogCaseDeletion', () => { it('logs a delete case audit log message', async () => { - await service.bulkAuditLogCaseDeletion(['1', '2']); + await service.creator.bulkAuditLogCaseDeletion(['1', '2']); expect(unsecuredSavedObjectsClient.bulkCreate).not.toHaveBeenCalled(); @@ -1076,7 +1080,7 @@ describe('CaseUserActionService', () => { describe('bulkCreateUpdateCase', () => { it('creates the correct user actions when bulk updating cases', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases, @@ -1244,7 +1248,7 @@ describe('CaseUserActionService', () => { }); it('logs the correct user actions when bulk updating cases', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases, @@ -1427,7 +1431,7 @@ describe('CaseUserActionService', () => { }); it('creates the correct user actions when an assignee is added', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases: updatedAssigneesCases, @@ -1474,7 +1478,7 @@ describe('CaseUserActionService', () => { }); it('logs the correct user actions when an assignee is added', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases: updatedAssigneesCases, @@ -1520,7 +1524,7 @@ describe('CaseUserActionService', () => { }, ]; - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases: originalCasesWithAssignee, updatedCases: casesWithAssigneeRemoved, @@ -1577,7 +1581,7 @@ describe('CaseUserActionService', () => { }, ]; - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases: originalCasesWithAssignee, updatedCases: casesWithAssigneeRemoved, @@ -1623,7 +1627,7 @@ describe('CaseUserActionService', () => { }, ]; - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases: originalCasesWithAssignee, updatedCases: caseAssignees, @@ -1708,7 +1712,7 @@ describe('CaseUserActionService', () => { }, ]; - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases: originalCasesWithAssignee, updatedCases: caseAssignees, @@ -1765,7 +1769,7 @@ describe('CaseUserActionService', () => { }); it('creates the correct user actions when tags are added and removed', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases: updatedTagsCases, @@ -1837,7 +1841,7 @@ describe('CaseUserActionService', () => { }); it('logs the correct user actions when tags are added and removed', async () => { - await service.bulkCreateUpdateCase({ + await service.creator.bulkCreateUpdateCase({ ...commonArgs, originalCases, updatedCases: updatedTagsCases, @@ -1896,7 +1900,7 @@ describe('CaseUserActionService', () => { describe('bulkCreateAttachmentDeletion', () => { it('creates delete comment user action', async () => { - await service.bulkCreateAttachmentDeletion({ + await service.creator.bulkCreateAttachmentDeletion({ ...commonArgs, attachments, }); @@ -1956,7 +1960,7 @@ describe('CaseUserActionService', () => { }); it('logs delete comment user action', async () => { - await service.bulkCreateAttachmentDeletion({ + await service.creator.bulkCreateAttachmentDeletion({ ...commonArgs, attachments, }); diff --git a/x-pack/plugins/cases/server/services/user_actions/index.ts b/x-pack/plugins/cases/server/services/user_actions/index.ts index 9cf0095019c97..31060ebb86d28 100644 --- a/x-pack/plugins/cases/server/services/user_actions/index.ts +++ b/x-pack/plugins/cases/server/services/user_actions/index.ts @@ -5,40 +5,26 @@ * 2.0. */ -import { get, isEmpty } from 'lodash'; - import type { - Logger, SavedObject, SavedObjectReference, - SavedObjectsBulkResponse, - SavedObjectsClientContract, SavedObjectsFindResponse, - SavedObjectsUpdateResponse, + SavedObjectsRawDoc, } from '@kbn/core/server'; import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; import type { KueryNode } from '@kbn/es-query'; -import type { AuditLogger } from '@kbn/security-plugin/server'; import { isCommentRequestTypePersistableState } from '../../../common/utils/attachments'; import { isConnectorUserAction, isPushedUserAction, - isUserActionType, isCreateCaseUserAction, isCommentUserAction, } from '../../../common/utils/user_actions'; import type { - ActionTypeValues, - CaseAttributes, CaseUserActionAttributes, CaseUserActionAttributesWithoutConnectorId, CaseUserActionResponse, - CaseUserProfile, - CaseAssignees, - CommentRequest, - User, - UserAction as Action, } from '../../../common/api'; import { Actions, ActionTypes, NONE_CONNECTOR_ID } from '../../../common/api'; import { @@ -55,364 +41,466 @@ import { PUSH_CONNECTOR_ID_REFERENCE_NAME, } from '../../common/constants'; import { findConnectorIdReference } from '../transform'; -import { buildFilter, combineFilters, arraysDifference } from '../../client/utils'; -import type { - Attributes, - BuilderParameters, - CommonArguments, - CreateUserAction, - UserActionEvent, - UserActionParameters, -} from './types'; -import { BuilderFactory } from './builder_factory'; +import { buildFilter, combineFilters } from '../../client/utils'; +import type { CaseConnectorActivity, CaseConnectorFields, PushInfo, ServiceContext } from './types'; import { defaultSortField, isCommentRequestTypeExternalReferenceSO } from '../../common/utils'; import type { PersistableStateAttachmentTypeRegistry } from '../../attachment_framework/persistable_state_registry'; import { injectPersistableReferencesToSO } from '../../attachment_framework/so_references'; -import type { IndexRefresh } from '../types'; -import { isAssigneesArray, isStringArray } from './type_guards'; -import type { CaseSavedObject } from '../../common/types'; -import { UserActionAuditLogger } from './audit_logger'; +import { UserActionPersister } from './operations/create'; export interface UserActionItem { attributes: CaseUserActionAttributesWithoutConnectorId; references: SavedObjectReference[]; } -interface PostCaseUserActionArgs extends IndexRefresh { - actions: UserActionEvent[]; +interface MostRecentResults { + mostRecent: { + hits: { + total: number; + hits: SavedObjectsRawDoc[]; + }; + }; } -interface CreateUserActionES extends IndexRefresh { - attributes: T; - references: SavedObjectReference[]; +interface ConnectorActivityAggsResult { + references: { + connectors: { + ids: { + buckets: Array<{ + key: string; + reverse: { + connectorActivity: { + buckets: { + changeConnector: MostRecentResults; + createCase: MostRecentResults; + pushInfo: MostRecentResults; + }; + }; + }; + }>; + }; + }; + }; } -type CommonUserActionArgs = CommonArguments; - -interface GetUserActionItemByDifference extends CommonUserActionArgs { - field: string; - originalValue: unknown; - newValue: unknown; +interface ConnectorFieldsBeforePushAggsResult { + references: { + connectors: { + reverse: { + ids: { + buckets: Record; + }; + }; + }; + }; } -interface TypedUserActionDiffedItems extends GetUserActionItemByDifference { - originalValue: T[]; - newValue: T[]; -} +export class CaseUserActionService { + private readonly _creator: UserActionPersister; -interface BulkCreateBulkUpdateCaseUserActions extends IndexRefresh { - originalCases: CaseSavedObject[]; - updatedCases: Array>; - user: User; -} + constructor(private readonly context: ServiceContext) { + this._creator = new UserActionPersister(context); + } -interface BulkCreateAttachmentUserAction extends Omit, IndexRefresh { - attachments: Array<{ id: string; owner: string; attachment: CommentRequest }>; -} + public get creator() { + return this._creator; + } -type CreateUserActionClient = CreateUserAction & - CommonUserActionArgs & - IndexRefresh; + public async getConnectorFieldsBeforeLatestPush( + caseId: string, + pushes: PushInfo[] + ): Promise { + try { + this.context.log.debug( + `Attempting to retrieve the connector fields before the last push for case id: ${caseId}` + ); -type CreatePayloadFunction = ( - items: Item[] -) => UserActionParameters['payload']; + if (pushes.length <= 0) { + return new Map(); + } -export class CaseUserActionService { - private static readonly userActionFieldsAllowed: Set = new Set(Object.keys(ActionTypes)); - - private readonly unsecuredSavedObjectsClient: SavedObjectsClientContract; - private readonly builderFactory: BuilderFactory; - private readonly persistableStateAttachmentTypeRegistry: PersistableStateAttachmentTypeRegistry; - private readonly log: Logger; - private readonly auditLogger: UserActionAuditLogger; - - constructor({ - log, - persistableStateAttachmentTypeRegistry, - unsecuredSavedObjectsClient, - auditLogger, - }: { - log: Logger; - persistableStateAttachmentTypeRegistry: PersistableStateAttachmentTypeRegistry; - unsecuredSavedObjectsClient: SavedObjectsClientContract; - auditLogger: AuditLogger; - }) { - this.log = log; - this.unsecuredSavedObjectsClient = unsecuredSavedObjectsClient; - this.persistableStateAttachmentTypeRegistry = persistableStateAttachmentTypeRegistry; - - this.builderFactory = new BuilderFactory({ - persistableStateAttachmentTypeRegistry: this.persistableStateAttachmentTypeRegistry, - }); - - this.auditLogger = new UserActionAuditLogger(auditLogger); - } + const connectorsFilter = buildFilter({ + filters: [ActionTypes.connector, ActionTypes.create_case], + field: 'type', + operator: 'or', + type: CASE_USER_ACTION_SAVED_OBJECT, + }); - private getUserActionItemByDifference(params: GetUserActionItemByDifference): UserActionEvent[] { - const { field, originalValue, newValue, caseId, owner, user } = params; - - if (!CaseUserActionService.userActionFieldsAllowed.has(field)) { - return []; - } else if ( - field === ActionTypes.assignees && - isAssigneesArray(originalValue) && - isAssigneesArray(newValue) - ) { - return this.buildAssigneesUserActions({ ...params, originalValue, newValue }); - } else if ( - field === ActionTypes.tags && - isStringArray(originalValue) && - isStringArray(newValue) - ) { - return this.buildTagsUserActions({ ...params, originalValue, newValue }); - } else if (isUserActionType(field) && newValue != null) { - const userActionBuilder = this.builderFactory.getBuilder(ActionTypes[field]); - const fieldUserAction = userActionBuilder?.build({ - caseId, - owner, - user, - payload: { [field]: newValue }, + const response = await this.context.unsecuredSavedObjectsClient.find< + CaseUserActionAttributesWithoutConnectorId, + ConnectorFieldsBeforePushAggsResult + >({ + type: CASE_USER_ACTION_SAVED_OBJECT, + hasReference: { type: CASE_SAVED_OBJECT, id: caseId }, + page: 1, + perPage: 1, + sortField: defaultSortField, + aggs: CaseUserActionService.buildConnectorFieldsUsedInPushAggs(pushes), + filter: connectorsFilter, }); - return fieldUserAction ? [fieldUserAction] : []; + return this.createCaseConnectorFieldsUsedInPushes(response.aggregations); + } catch (error) { + this.context.log.error( + `Error while retrieving the connector fields before the last push: ${caseId}: ${error}` + ); + throw error; } - - return []; } - private buildAssigneesUserActions(params: TypedUserActionDiffedItems) { - const createPayload: CreatePayloadFunction = ( - items: CaseAssignees - ) => ({ assignees: items }); - - return this.buildAddDeleteUserActions(params, createPayload, ActionTypes.assignees); - } + private static buildConnectorFieldsUsedInPushAggs( + pushes: PushInfo[] + ): Record { + const filters: estypes.AggregationsBuckets = {}; - private buildTagsUserActions(params: TypedUserActionDiffedItems) { - const createPayload: CreatePayloadFunction = ( - items: string[] - ) => ({ - tags: items, - }); + /** + * Group the user actions by the unique connector ids and bound the time range + * for that connector's push event. We want to search for the fields before the push timestamp. + */ + for (const push of pushes) { + filters[push.connectorId] = { + bool: { + filter: [ + { + // Search for connector field user action prior to the push occurrence + range: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.created_at`]: { + lt: push.date.toISOString(), + }, + }, + }, + { + nested: { + path: `${CASE_USER_ACTION_SAVED_OBJECT}.references`, + query: { + bool: { + filter: [ + { + // We only want to search a time frame for a specific connector id + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.references.id`]: { + value: push.connectorId, + }, + }, + }, + ], + }, + }, + }, + }, + ], + }, + }; + } - return this.buildAddDeleteUserActions(params, createPayload, ActionTypes.tags); + return { + references: { + nested: { + path: `${CASE_USER_ACTION_SAVED_OBJECT}.references`, + }, + aggregations: { + connectors: { + filter: { + // Only search for user actions that have a connector reference aka a reference with type action + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.references.type`]: 'action', + }, + }, + aggregations: { + reverse: { + reverse_nested: {}, + aggregations: { + ids: { + filters: { + filters, + }, + aggregations: { + mostRecent: { + top_hits: { + sort: [ + { + [`${CASE_USER_ACTION_SAVED_OBJECT}.created_at`]: { + order: 'desc', + }, + }, + ], + size: 1, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }; } - private buildAddDeleteUserActions( - params: TypedUserActionDiffedItems, - createPayload: CreatePayloadFunction, - actionType: ActionType - ) { - const { originalValue, newValue } = params; - const compareValues = arraysDifference(originalValue, newValue); - - const addUserAction = this.buildUserAction({ - commonArgs: params, - actionType, - action: Actions.add, - createPayload, - modifiedItems: compareValues?.addedItems, - }); - const deleteUserAction = this.buildUserAction({ - commonArgs: params, - actionType, - action: Actions.delete, - createPayload, - modifiedItems: compareValues?.deletedItems, - }); - - return [ - ...(addUserAction ? [addUserAction] : []), - ...(deleteUserAction ? [deleteUserAction] : []), - ]; - } + private createCaseConnectorFieldsUsedInPushes( + aggsResults?: ConnectorFieldsBeforePushAggsResult + ): CaseConnectorFields { + const connectorFields: CaseConnectorFields = new Map(); - private buildUserAction({ - commonArgs, - actionType, - action, - createPayload, - modifiedItems, - }: { - commonArgs: CommonUserActionArgs; - actionType: ActionType; - action: Action; - createPayload: CreatePayloadFunction; - modifiedItems?: Item[] | null; - }) { - const userActionBuilder = this.builderFactory.getBuilder(actionType); - - if (!userActionBuilder || !modifiedItems || modifiedItems.length <= 0) { - return; + if (!aggsResults) { + return connectorFields; } - const { caseId, owner, user } = commonArgs; + for (const connectorId of Object.keys(aggsResults.references.connectors.reverse.ids.buckets)) { + const fields = aggsResults.references.connectors.reverse.ids.buckets[connectorId]; + + if (fields.mostRecent.hits.hits.length > 0) { + const rawFieldsDoc = fields.mostRecent.hits.hits[0]; + const doc = + this.context.savedObjectsSerializer.rawToSavedObject( + rawFieldsDoc + ); + + const fieldsDoc = transformToExternalModel( + doc, + this.context.persistableStateAttachmentTypeRegistry + ); - const userAction = userActionBuilder.build({ - action, - caseId, - user, - owner, - payload: createPayload(modifiedItems), - }); + connectorFields.set(connectorId, fieldsDoc); + } + } - return userAction; + return connectorFields; } - public async bulkAuditLogCaseDeletion(caseIds: string[]) { - this.log.debug(`Attempting to log bulk case deletion`); + public async getMostRecentUserAction( + caseId: string + ): Promise | undefined> { + try { + this.context.log.debug( + `Attempting to retrieve the most recent user action for case id: ${caseId}` + ); + + const id = caseId; + const type = CASE_SAVED_OBJECT; - for (const id of caseIds) { - this.auditLogger.log({ - getMessage: () => `User deleted case id: ${id}`, - action: Actions.delete, - descriptiveAction: 'case_user_action_delete_case', - savedObjectId: id, - savedObjectType: CASE_SAVED_OBJECT, + const connectorsFilter = buildFilter({ + filters: [ + ActionTypes.comment, + ActionTypes.description, + ActionTypes.tags, + ActionTypes.title, + ], + field: 'type', + operator: 'or', + type: CASE_USER_ACTION_SAVED_OBJECT, }); + + const userActions = + await this.context.unsecuredSavedObjectsClient.find( + { + type: CASE_USER_ACTION_SAVED_OBJECT, + hasReference: { type, id }, + page: 1, + perPage: 1, + sortField: 'created_at', + sortOrder: 'desc', + filter: connectorsFilter, + } + ); + + if (userActions.saved_objects.length <= 0) { + return; + } + + return transformToExternalModel( + userActions.saved_objects[0], + this.context.persistableStateAttachmentTypeRegistry + ); + } catch (error) { + this.context.log.error( + `Error while retrieving the most recent user action for case id: ${caseId}: ${error}` + ); + throw error; } } - public async bulkCreateUpdateCase({ - originalCases, - updatedCases, - user, - refresh, - }: BulkCreateBulkUpdateCaseUserActions): Promise { - const builtUserActions = updatedCases.reduce((acc, updatedCase) => { - const originalCase = originalCases.find(({ id }) => id === updatedCase.id); - - if (originalCase == null) { - return acc; - } + public async getCaseConnectorInformation(caseId: string): Promise { + try { + this.context.log.debug(`Attempting to find connector information for case id: ${caseId}`); - const caseId = updatedCase.id; - const owner = originalCase.attributes.owner; - - const userActions: UserActionEvent[] = []; - const updatedFields = Object.keys(updatedCase.attributes); - - updatedFields - .filter((field) => CaseUserActionService.userActionFieldsAllowed.has(field)) - .forEach((field) => { - const originalValue = get(originalCase, ['attributes', field]); - const newValue = get(updatedCase, ['attributes', field]); - userActions.push( - ...this.getUserActionItemByDifference({ - field, - originalValue, - newValue, - user, - owner, - caseId, - }) - ); - }); + const connectorsFilter = buildFilter({ + filters: [ActionTypes.connector, ActionTypes.create_case, ActionTypes.pushed], + field: 'type', + operator: 'or', + type: CASE_USER_ACTION_SAVED_OBJECT, + }); - return [...acc, ...userActions]; - }, []); + const response = await this.context.unsecuredSavedObjectsClient.find< + CaseUserActionAttributesWithoutConnectorId, + ConnectorActivityAggsResult + >({ + type: CASE_USER_ACTION_SAVED_OBJECT, + hasReference: { type: CASE_SAVED_OBJECT, id: caseId }, + page: 1, + perPage: 1, + sortField: defaultSortField, + aggs: CaseUserActionService.buildConnectorInfoAggs(), + filter: connectorsFilter, + }); - await this.bulkCreateAndLog({ - userActions: builtUserActions, - refresh, - }); + return this.createCaseConnectorInformation(response.aggregations); + } catch (error) { + this.context.log.error( + `Error while retrieving the connector information for case id: ${caseId} ${error}` + ); + throw error; + } } - private async bulkCreateAttachment({ - caseId, - attachments, - user, - action = Actions.create, - refresh, - }: BulkCreateAttachmentUserAction): Promise { - this.log.debug(`Attempting to create a bulk create case user action`); - const userActions = attachments.reduce((acc, attachment) => { - const userActionBuilder = this.builderFactory.getBuilder(ActionTypes.comment); - const commentUserAction = userActionBuilder?.build({ - action, - caseId, - user, - owner: attachment.owner, - attachmentId: attachment.id, - payload: { attachment: attachment.attachment }, - }); + private createCaseConnectorInformation( + aggsResults?: ConnectorActivityAggsResult + ): CaseConnectorActivity[] { + const caseConnectorInfo: CaseConnectorActivity[] = []; - if (commentUserAction == null) { - return acc; + if (!aggsResults) { + return caseConnectorInfo; + } + + for (const connectorInfo of aggsResults.references.connectors.ids.buckets) { + const changeConnector = connectorInfo.reverse.connectorActivity.buckets.changeConnector; + const createCase = connectorInfo.reverse.connectorActivity.buckets.createCase; + let rawFieldsDoc: SavedObjectsRawDoc | undefined; + + if (changeConnector.mostRecent.hits.hits.length > 0) { + rawFieldsDoc = changeConnector.mostRecent.hits.hits[0]; + } else if (createCase.mostRecent.hits.hits.length > 0) { + /** + * If there is ever a connector update user action that takes precedence over the information stored + * in the create case user action because it indicates that the connector's fields were changed + */ + rawFieldsDoc = createCase.mostRecent.hits.hits[0]; } - return [...acc, commentUserAction]; - }, []); + let fieldsDoc: SavedObject | undefined; + if (rawFieldsDoc != null) { + const doc = + this.context.savedObjectsSerializer.rawToSavedObject( + rawFieldsDoc + ); + + fieldsDoc = transformToExternalModel( + doc, + this.context.persistableStateAttachmentTypeRegistry + ); + } - await this.bulkCreateAndLog({ - userActions, - refresh, - }); - } + const pushInfo = connectorInfo.reverse.connectorActivity.buckets.pushInfo; + let pushDoc: SavedObject | undefined; - public async bulkCreateAttachmentDeletion({ - caseId, - attachments, - user, - refresh, - }: BulkCreateAttachmentUserAction): Promise { - await this.bulkCreateAttachment({ - caseId, - attachments, - user, - action: Actions.delete, - refresh, - }); - } + if (pushInfo.mostRecent.hits.hits.length > 0) { + const rawPushDoc = pushInfo.mostRecent.hits.hits[0]; - public async bulkCreateAttachmentCreation({ - caseId, - attachments, - user, - refresh, - }: BulkCreateAttachmentUserAction): Promise { - await this.bulkCreateAttachment({ - caseId, - attachments, - user, - action: Actions.create, - refresh, - }); - } + const doc = + this.context.savedObjectsSerializer.rawToSavedObject( + rawPushDoc + ); - public async createUserAction({ - action, - type, - caseId, - user, - owner, - payload, - connectorId, - attachmentId, - refresh, - }: CreateUserActionClient) { - try { - this.log.debug(`Attempting to create a user action of type: ${type}`); - const userActionBuilder = this.builderFactory.getBuilder(type); - - const userAction = userActionBuilder?.build({ - action, - caseId, - user, - owner, - connectorId, - attachmentId, - payload, - }); + pushDoc = transformToExternalModel( + doc, + this.context.persistableStateAttachmentTypeRegistry + ); + } - if (userAction) { - await this.createAndLog({ userAction, refresh }); + if (fieldsDoc != null) { + caseConnectorInfo.push({ + connectorId: connectorInfo.key, + fields: fieldsDoc, + push: pushDoc, + }); + } else { + this.context.log.warn(`Unable to find fields for connector id: ${connectorInfo.key}`); } - } catch (error) { - this.log.error(`Error on creating user action of type: ${type}. Error: ${error}`); - throw error; } + + return caseConnectorInfo; + } + + private static buildConnectorInfoAggs(): Record< + string, + estypes.AggregationsAggregationContainer + > { + return { + references: { + nested: { + path: `${CASE_USER_ACTION_SAVED_OBJECT}.references`, + }, + aggregations: { + connectors: { + filter: { + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.references.type`]: 'action', + }, + }, + aggregations: { + ids: { + // Bucket by connector id + terms: { + field: `${CASE_USER_ACTION_SAVED_OBJECT}.references.id`, + // We're assuming that a case will not have more than 1000 connectors + size: 1000, + }, + aggregations: { + reverse: { + reverse_nested: {}, + aggregations: { + connectorActivity: { + filters: { + filters: { + // look for connector fields user actions from "change connector" occurrence + changeConnector: { + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.attributes.type`]: + ActionTypes.connector, + }, + }, + // If the case was initialized with a connector, the fields could exist in the create_case + // user action + createCase: { + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.attributes.type`]: + ActionTypes.create_case, + }, + }, + // Also grab the most recent push occurrence for the connector + pushInfo: { + term: { + [`${CASE_USER_ACTION_SAVED_OBJECT}.attributes.type`]: + ActionTypes.pushed, + }, + }, + }, + }, + aggregations: { + mostRecent: { + top_hits: { + sort: [ + { + [`${CASE_USER_ACTION_SAVED_OBJECT}.created_at`]: { + order: 'desc', + }, + }, + ], + size: 1, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }, + }; } public async getAll(caseId: string): Promise> { @@ -421,30 +509,34 @@ export class CaseUserActionService { const type = CASE_SAVED_OBJECT; const userActions = - await this.unsecuredSavedObjectsClient.find({ - type: CASE_USER_ACTION_SAVED_OBJECT, - hasReference: { type, id }, - page: 1, - perPage: MAX_DOCS_PER_PAGE, - sortField: 'created_at', - sortOrder: 'asc', - }); + await this.context.unsecuredSavedObjectsClient.find( + { + type: CASE_USER_ACTION_SAVED_OBJECT, + hasReference: { type, id }, + page: 1, + perPage: MAX_DOCS_PER_PAGE, + sortField: 'created_at', + sortOrder: 'asc', + } + ); return transformFindResponseToExternalModel( userActions, - this.persistableStateAttachmentTypeRegistry + this.context.persistableStateAttachmentTypeRegistry ); } catch (error) { - this.log.error(`Error on GET case user action case id: ${caseId}: ${error}`); + this.context.log.error(`Error on GET case user action case id: ${caseId}: ${error}`); throw error; } } public async getUserActionIdsForCases(caseIds: string[]) { try { - this.log.debug(`Attempting to retrieve user actions associated with cases: [${caseIds}]`); + this.context.log.debug( + `Attempting to retrieve user actions associated with cases: [${caseIds}]` + ); - const finder = this.unsecuredSavedObjectsClient.createPointInTimeFinder({ + const finder = this.context.unsecuredSavedObjectsClient.createPointInTimeFinder({ type: CASE_USER_ACTION_SAVED_OBJECT, hasReference: caseIds.map((id) => ({ id, type: CASE_SAVED_OBJECT })), sortField: 'created_at', @@ -465,78 +557,7 @@ export class CaseUserActionService { return ids; } catch (error) { - this.log.error(`Error retrieving user action ids for cases: [${caseIds}]: ${error}`); - throw error; - } - } - - private async createAndLog({ - userAction, - refresh, - }: { - userAction: UserActionEvent; - } & IndexRefresh): Promise { - const createdUserAction = await this.create({ ...userAction.parameters, refresh }); - this.auditLogger.log(userAction.eventDetails, createdUserAction.id); - } - - private async create({ - attributes, - references, - refresh, - }: CreateUserActionES): Promise> { - try { - this.log.debug(`Attempting to POST a new case user action`); - - return await this.unsecuredSavedObjectsClient.create( - CASE_USER_ACTION_SAVED_OBJECT, - attributes, - { - references: references ?? [], - refresh, - } - ); - } catch (error) { - this.log.error(`Error on POST a new case user action: ${error}`); - throw error; - } - } - - private async bulkCreateAndLog({ - userActions, - refresh, - }: { userActions: UserActionEvent[] } & IndexRefresh) { - const createdUserActions = await this.bulkCreate({ actions: userActions, refresh }); - - if (!createdUserActions) { - return; - } - - for (let i = 0; i < userActions.length; i++) { - this.auditLogger.log(userActions[i].eventDetails, createdUserActions.saved_objects[i].id); - } - } - - private async bulkCreate({ - actions, - refresh, - }: PostCaseUserActionArgs): Promise | undefined> { - if (isEmpty(actions)) { - return; - } - - try { - this.log.debug(`Attempting to POST a new case user action`); - - return await this.unsecuredSavedObjectsClient.bulkCreate( - actions.map((action) => ({ - type: CASE_USER_ACTION_SAVED_OBJECT, - ...action.parameters, - })), - { refresh } - ); - } catch (error) { - this.log.error(`Error on POST a new case user action: ${error}`); + this.context.log.error(`Error retrieving user action ids for cases: [${caseIds}]: ${error}`); throw error; } } @@ -549,7 +570,7 @@ export class CaseUserActionService { filter?: KueryNode; }): Promise>> { try { - this.log.debug('Attempting to find status changes'); + this.context.log.debug('Attempting to find status changes'); const updateActionFilter = buildFilter({ filters: Actions.update, @@ -568,7 +589,7 @@ export class CaseUserActionService { const combinedFilters = combineFilters([updateActionFilter, statusChangeFilter, filter]); const finder = - this.unsecuredSavedObjectsClient.createPointInTimeFinder( + this.context.unsecuredSavedObjectsClient.createPointInTimeFinder( { type: CASE_USER_ACTION_SAVED_OBJECT, hasReference: { type: CASE_SAVED_OBJECT, id: caseId }, @@ -583,14 +604,14 @@ export class CaseUserActionService { for await (const findResults of finder.find()) { userActions = userActions.concat( findResults.saved_objects.map((so) => - transformToExternalModel(so, this.persistableStateAttachmentTypeRegistry) + transformToExternalModel(so, this.context.persistableStateAttachmentTypeRegistry) ) ); } return userActions; } catch (error) { - this.log.error(`Error finding status changes: ${error}`); + this.context.log.error(`Error finding status changes: ${error}`); throw error; } } @@ -603,7 +624,7 @@ export class CaseUserActionService { filter?: KueryNode; }): Promise> { try { - this.log.debug(`Attempting to count connectors for case id ${caseId}`); + this.context.log.debug(`Attempting to count connectors for case id ${caseId}`); const connectorsFilter = buildFilter({ filters: [ActionTypes.connector, ActionTypes.create_case], field: 'type', @@ -613,7 +634,7 @@ export class CaseUserActionService { const combinedFilter = combineFilters([connectorsFilter, filter]); - const response = await this.unsecuredSavedObjectsClient.find< + const response = await this.context.unsecuredSavedObjectsClient.find< CaseUserActionAttributesWithoutConnectorId, { references: { connectors: { ids: { buckets: Array<{ key: string }> } } } } >({ @@ -632,7 +653,7 @@ export class CaseUserActionService { })) ?? [] ); } catch (error) { - this.log.error(`Error while counting connectors for case id ${caseId}: ${error}`); + this.context.log.error(`Error while counting connectors for case id ${caseId}: ${error}`); throw error; } } diff --git a/x-pack/plugins/cases/server/services/user_actions/operations/create.ts b/x-pack/plugins/cases/server/services/user_actions/operations/create.ts new file mode 100644 index 0000000000000..9160445ec2474 --- /dev/null +++ b/x-pack/plugins/cases/server/services/user_actions/operations/create.ts @@ -0,0 +1,433 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { + SavedObject, + SavedObjectReference, + SavedObjectsBulkResponse, + SavedObjectsUpdateResponse, +} from '@kbn/core/server'; +import { get, isEmpty } from 'lodash'; +import { CASE_SAVED_OBJECT, CASE_USER_ACTION_SAVED_OBJECT } from '../../../../common/constants'; +import type { CaseSavedObject } from '../../../common/types'; +import { arraysDifference } from '../../../client/utils'; +import { isUserActionType } from '../../../../common/utils/user_actions'; +import type { + ActionTypeValues, + CaseAssignees, + CaseAttributes, + CaseUserProfile, + CommentRequest, + User, + UserAction as Action, +} from '../../../../common/api'; +import { Actions, ActionTypes } from '../../../../common/api'; +import { BuilderFactory } from '../builder_factory'; +import type { + Attributes, + BuilderParameters, + CommonArguments, + CreateUserAction, + ServiceContext, + UserActionEvent, + UserActionParameters, +} from '../types'; +import { isAssigneesArray, isStringArray } from '../type_guards'; +import type { IndexRefresh } from '../../types'; +import { UserActionAuditLogger } from '../audit_logger'; + +type CommonUserActionArgs = CommonArguments; + +interface GetUserActionItemByDifference extends CommonUserActionArgs { + field: string; + originalValue: unknown; + newValue: unknown; +} + +interface TypedUserActionDiffedItems extends GetUserActionItemByDifference { + originalValue: T[]; + newValue: T[]; +} + +type CreatePayloadFunction = ( + items: Item[] +) => UserActionParameters['payload']; + +interface BulkCreateBulkUpdateCaseUserActions extends IndexRefresh { + originalCases: CaseSavedObject[]; + updatedCases: Array>; + user: User; +} + +interface BulkCreateAttachmentUserAction extends Omit, IndexRefresh { + attachments: Array<{ id: string; owner: string; attachment: CommentRequest }>; +} + +type CreateUserActionClient = CreateUserAction & + CommonUserActionArgs & + IndexRefresh; + +interface CreateUserActionES extends IndexRefresh { + attributes: T; + references: SavedObjectReference[]; +} + +interface PostCaseUserActionArgs extends IndexRefresh { + actions: UserActionEvent[]; +} + +export class UserActionPersister { + private static readonly userActionFieldsAllowed: Set = new Set(Object.keys(ActionTypes)); + + private readonly builderFactory: BuilderFactory; + private readonly auditLogger: UserActionAuditLogger; + + constructor(private readonly context: ServiceContext) { + this.builderFactory = new BuilderFactory({ + persistableStateAttachmentTypeRegistry: this.context.persistableStateAttachmentTypeRegistry, + }); + + this.auditLogger = new UserActionAuditLogger(this.context.auditLogger); + } + + public async bulkCreateUpdateCase({ + originalCases, + updatedCases, + user, + refresh, + }: BulkCreateBulkUpdateCaseUserActions): Promise { + const builtUserActions = updatedCases.reduce((acc, updatedCase) => { + const originalCase = originalCases.find(({ id }) => id === updatedCase.id); + + if (originalCase == null) { + return acc; + } + + const caseId = updatedCase.id; + const owner = originalCase.attributes.owner; + + const userActions: UserActionEvent[] = []; + const updatedFields = Object.keys(updatedCase.attributes); + + updatedFields + .filter((field) => UserActionPersister.userActionFieldsAllowed.has(field)) + .forEach((field) => { + const originalValue = get(originalCase, ['attributes', field]); + const newValue = get(updatedCase, ['attributes', field]); + userActions.push( + ...this.getUserActionItemByDifference({ + field, + originalValue, + newValue, + user, + owner, + caseId, + }) + ); + }); + + return [...acc, ...userActions]; + }, []); + + await this.bulkCreateAndLog({ + userActions: builtUserActions, + refresh, + }); + } + + private getUserActionItemByDifference(params: GetUserActionItemByDifference): UserActionEvent[] { + const { field, originalValue, newValue, caseId, owner, user } = params; + + if (!UserActionPersister.userActionFieldsAllowed.has(field)) { + return []; + } else if ( + field === ActionTypes.assignees && + isAssigneesArray(originalValue) && + isAssigneesArray(newValue) + ) { + return this.buildAssigneesUserActions({ ...params, originalValue, newValue }); + } else if ( + field === ActionTypes.tags && + isStringArray(originalValue) && + isStringArray(newValue) + ) { + return this.buildTagsUserActions({ ...params, originalValue, newValue }); + } else if (isUserActionType(field) && newValue != null) { + const userActionBuilder = this.builderFactory.getBuilder(ActionTypes[field]); + const fieldUserAction = userActionBuilder?.build({ + caseId, + owner, + user, + payload: { [field]: newValue }, + }); + + return fieldUserAction ? [fieldUserAction] : []; + } + + return []; + } + + private buildAssigneesUserActions(params: TypedUserActionDiffedItems) { + const createPayload: CreatePayloadFunction = ( + items: CaseAssignees + ) => ({ assignees: items }); + + return this.buildAddDeleteUserActions(params, createPayload, ActionTypes.assignees); + } + + private buildTagsUserActions(params: TypedUserActionDiffedItems) { + const createPayload: CreatePayloadFunction = ( + items: string[] + ) => ({ + tags: items, + }); + + return this.buildAddDeleteUserActions(params, createPayload, ActionTypes.tags); + } + + private buildAddDeleteUserActions( + params: TypedUserActionDiffedItems, + createPayload: CreatePayloadFunction, + actionType: ActionType + ) { + const { originalValue, newValue } = params; + const compareValues = arraysDifference(originalValue, newValue); + + const addUserAction = this.buildUserAction({ + commonArgs: params, + actionType, + action: Actions.add, + createPayload, + modifiedItems: compareValues?.addedItems, + }); + const deleteUserAction = this.buildUserAction({ + commonArgs: params, + actionType, + action: Actions.delete, + createPayload, + modifiedItems: compareValues?.deletedItems, + }); + + return [ + ...(addUserAction ? [addUserAction] : []), + ...(deleteUserAction ? [deleteUserAction] : []), + ]; + } + + private buildUserAction({ + commonArgs, + actionType, + action, + createPayload, + modifiedItems, + }: { + commonArgs: CommonUserActionArgs; + actionType: ActionType; + action: Action; + createPayload: CreatePayloadFunction; + modifiedItems?: Item[] | null; + }) { + const userActionBuilder = this.builderFactory.getBuilder(actionType); + + if (!userActionBuilder || !modifiedItems || modifiedItems.length <= 0) { + return; + } + + const { caseId, owner, user } = commonArgs; + + const userAction = userActionBuilder.build({ + action, + caseId, + user, + owner, + payload: createPayload(modifiedItems), + }); + + return userAction; + } + + public async bulkCreateAttachmentDeletion({ + caseId, + attachments, + user, + refresh, + }: BulkCreateAttachmentUserAction): Promise { + await this.bulkCreateAttachment({ + caseId, + attachments, + user, + action: Actions.delete, + refresh, + }); + } + + public async bulkCreateAttachmentCreation({ + caseId, + attachments, + user, + refresh, + }: BulkCreateAttachmentUserAction): Promise { + await this.bulkCreateAttachment({ + caseId, + attachments, + user, + action: Actions.create, + refresh, + }); + } + + private async bulkCreateAttachment({ + caseId, + attachments, + user, + action = Actions.create, + refresh, + }: BulkCreateAttachmentUserAction): Promise { + this.context.log.debug(`Attempting to create a bulk create case user action`); + const userActions = attachments.reduce((acc, attachment) => { + const userActionBuilder = this.builderFactory.getBuilder(ActionTypes.comment); + const commentUserAction = userActionBuilder?.build({ + action, + caseId, + user, + owner: attachment.owner, + attachmentId: attachment.id, + payload: { attachment: attachment.attachment }, + }); + + if (commentUserAction == null) { + return acc; + } + + return [...acc, commentUserAction]; + }, []); + + await this.bulkCreateAndLog({ + userActions, + refresh, + }); + } + + private async bulkCreateAndLog({ + userActions, + refresh, + }: { userActions: UserActionEvent[] } & IndexRefresh) { + const createdUserActions = await this.bulkCreate({ actions: userActions, refresh }); + + if (!createdUserActions) { + return; + } + + for (let i = 0; i < userActions.length; i++) { + this.auditLogger.log(userActions[i].eventDetails, createdUserActions.saved_objects[i].id); + } + } + + private async bulkCreate({ + actions, + refresh, + }: PostCaseUserActionArgs): Promise | undefined> { + if (isEmpty(actions)) { + return; + } + + try { + this.context.log.debug(`Attempting to POST a new case user action`); + + return await this.context.unsecuredSavedObjectsClient.bulkCreate( + actions.map((action) => ({ + type: CASE_USER_ACTION_SAVED_OBJECT, + ...action.parameters, + })), + { refresh } + ); + } catch (error) { + this.context.log.error(`Error on POST a new case user action: ${error}`); + throw error; + } + } + + public async createUserAction({ + action, + type, + caseId, + user, + owner, + payload, + connectorId, + attachmentId, + refresh, + }: CreateUserActionClient) { + try { + this.context.log.debug(`Attempting to create a user action of type: ${type}`); + const userActionBuilder = this.builderFactory.getBuilder(type); + + const userAction = userActionBuilder?.build({ + action, + caseId, + user, + owner, + connectorId, + attachmentId, + payload, + }); + + if (userAction) { + await this.createAndLog({ userAction, refresh }); + } + } catch (error) { + this.context.log.error(`Error on creating user action of type: ${type}. Error: ${error}`); + throw error; + } + } + + private async createAndLog({ + userAction, + refresh, + }: { + userAction: UserActionEvent; + } & IndexRefresh): Promise { + const createdUserAction = await this.create({ ...userAction.parameters, refresh }); + this.auditLogger.log(userAction.eventDetails, createdUserAction.id); + } + + private async create({ + attributes, + references, + refresh, + }: CreateUserActionES): Promise> { + try { + this.context.log.debug(`Attempting to POST a new case user action`); + + return await this.context.unsecuredSavedObjectsClient.create( + CASE_USER_ACTION_SAVED_OBJECT, + attributes, + { + references: references ?? [], + refresh, + } + ); + } catch (error) { + this.context.log.error(`Error on POST a new case user action: ${error}`); + throw error; + } + } + + public async bulkAuditLogCaseDeletion(caseIds: string[]) { + this.context.log.debug(`Attempting to log bulk case deletion`); + + for (const id of caseIds) { + this.auditLogger.log({ + getMessage: () => `User deleted case id: ${id}`, + action: Actions.delete, + descriptiveAction: 'case_user_action_delete_case', + savedObjectId: id, + savedObjectType: CASE_SAVED_OBJECT, + }); + } + } +} diff --git a/x-pack/plugins/cases/server/services/user_actions/types.ts b/x-pack/plugins/cases/server/services/user_actions/types.ts index be3fc602c132a..377a7217cdd02 100644 --- a/x-pack/plugins/cases/server/services/user_actions/types.ts +++ b/x-pack/plugins/cases/server/services/user_actions/types.ts @@ -5,13 +5,21 @@ * 2.0. */ -import type { SavedObjectReference } from '@kbn/core/server'; +import type { + SavedObjectReference, + SavedObjectsClientContract, + Logger, + ISavedObjectsSerializer, + SavedObject, +} from '@kbn/core/server'; +import type { AuditLogger } from '@kbn/security-plugin/server'; import type { CaseAssignees } from '../../../common/api/cases/assignee'; import type { CasePostRequest, CaseSettings, CaseSeverity, CaseStatuses, + CaseUserActionResponse, CommentUserAction, ConnectorUserAction, PushedUserAction, @@ -126,3 +134,24 @@ export type CommonBuilderArguments = CommonArguments & { export interface BuilderDeps { persistableStateAttachmentTypeRegistry: PersistableStateAttachmentTypeRegistry; } + +export interface ServiceContext { + log: Logger; + persistableStateAttachmentTypeRegistry: PersistableStateAttachmentTypeRegistry; + unsecuredSavedObjectsClient: SavedObjectsClientContract; + savedObjectsSerializer: ISavedObjectsSerializer; + auditLogger: AuditLogger; +} + +export interface CaseConnectorActivity { + connectorId: string; + fields: SavedObject; + push?: SavedObject; +} + +export type CaseConnectorFields = Map>; + +export interface PushInfo { + date: Date; + connectorId: string; +} diff --git a/x-pack/plugins/cases/tsconfig.json b/x-pack/plugins/cases/tsconfig.json index cb1039e1eff7b..bb4cc5f9e59c7 100644 --- a/x-pack/plugins/cases/tsconfig.json +++ b/x-pack/plugins/cases/tsconfig.json @@ -52,6 +52,7 @@ "@kbn/safer-lodash-set", "@kbn/logging-mocks", "@kbn/ecs", + "@kbn/core-saved-objects-base-server-mocks", ], "exclude": [ "target/**/*", diff --git a/x-pack/plugins/cloud/server/index.ts b/x-pack/plugins/cloud/server/index.ts index 4381ddaa0c3cc..0328ebe89e1cf 100644 --- a/x-pack/plugins/cloud/server/index.ts +++ b/x-pack/plugins/cloud/server/index.ts @@ -8,7 +8,7 @@ import { PluginInitializerContext } from '@kbn/core/server'; import { CloudPlugin } from './plugin'; -export type { CloudSetup } from './plugin'; +export type { CloudSetup, CloudStart } from './plugin'; export { config } from './config'; export const plugin = (initializerContext: PluginInitializerContext) => { return new CloudPlugin(initializerContext); diff --git a/x-pack/plugins/cloud/server/plugin.test.ts b/x-pack/plugins/cloud/server/plugin.test.ts index 55be923e98cf8..e3095e97e6a4c 100644 --- a/x-pack/plugins/cloud/server/plugin.test.ts +++ b/x-pack/plugins/cloud/server/plugin.test.ts @@ -16,22 +16,23 @@ const baseConfig = { }; describe('Cloud Plugin', () => { - describe('#setup', () => { - describe('interface', () => { - const setupPlugin = () => { - const initContext = coreMock.createPluginInitializerContext({ - ...baseConfig, - id: 'cloudId', - cname: 'cloud.elastic.co', - }); - const plugin = new CloudPlugin(initContext); + const setupPlugin = () => { + const initContext = coreMock.createPluginInitializerContext({ + ...baseConfig, + id: 'cloudId', + cname: 'cloud.elastic.co', + }); + const plugin = new CloudPlugin(initContext); - const coreSetup = coreMock.createSetup(); - const setup = plugin.setup(coreSetup, {}); + const coreSetup = coreMock.createSetup(); + const setup = plugin.setup(coreSetup, {}); + const start = plugin.start(); - return { setup }; - }; + return { setup, start }; + }; + describe('#setup', () => { + describe('interface', () => { it('exposes isCloudEnabled', () => { const { setup } = setupPlugin(); expect(setup.isCloudEnabled).toBe(true); @@ -58,4 +59,13 @@ describe('Cloud Plugin', () => { }); }); }); + + describe('#start', () => { + describe('interface', () => { + it('exposes isCloudEnabled', () => { + const { start } = setupPlugin(); + expect(start.isCloudEnabled).toBe(true); + }); + }); + }); }); diff --git a/x-pack/plugins/cloud/server/plugin.ts b/x-pack/plugins/cloud/server/plugin.ts index 4e54c2b9b7f40..c0f52645521fe 100644 --- a/x-pack/plugins/cloud/server/plugin.ts +++ b/x-pack/plugins/cloud/server/plugin.ts @@ -55,7 +55,17 @@ export interface CloudSetup { }; } -export class CloudPlugin implements Plugin { +/** + * Start contract + */ +export interface CloudStart { + /** + * `true` when running on Elastic Cloud. + */ + isCloudEnabled: boolean; +} + +export class CloudPlugin implements Plugin { private readonly config: CloudConfigType; constructor(private readonly context: PluginInitializerContext) { @@ -85,5 +95,9 @@ export class CloudPlugin implements Plugin { }; } - public start() {} + public start() { + return { + isCloudEnabled: getIsCloudEnabled(this.config.id), + }; + } } diff --git a/x-pack/plugins/cloud_defend/public/common/constants.ts b/x-pack/plugins/cloud_defend/public/common/constants.ts new file mode 100644 index 0000000000000..d0baec8804ff7 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/common/constants.ts @@ -0,0 +1,13 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +export const VALID_SELECTOR_NAME_REGEX = /^[a-z0-9][a-z0-9_\-]+$/i; // alphanumberic (no - or _ allowed on first char) +export const MAX_SELECTOR_NAME_LENGTH = 128; // chars +export const MAX_CONDITION_VALUE_LENGTH_BYTES = 511; +export const MAX_FILE_PATH_VALUE_LENGTH_BYTES = 255; + +// TODO: temporary until I change condition value length checks in the yaml editor view to be byte based. +export const MAX_CONDITION_VALUE_LENGTH = 64; diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.test.tsx deleted file mode 100644 index 78429546b31f3..0000000000000 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.test.tsx +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ -import React from 'react'; -import { render } from '@testing-library/react'; -import '@kbn/kibana-react-plugin/public/code_editor/code_editor.test.helpers'; -import { TestProvider } from '../../test/test_provider'; -import { getCloudDefendNewPolicyMock } from './mocks'; -import { ConfigYamlView } from '.'; -import './__mocks__/worker'; -import './__mocks__/resizeobserver'; - -// @ts-ignore-next -window.Worker = Worker; - -describe('', () => { - beforeAll(() => { - Object.defineProperty(window, 'matchMedia', { - writable: true, - value: jest.fn().mockImplementation((query) => ({ - matches: false, - media: query, - onchange: null, - addListener: jest.fn(), // Deprecated - removeListener: jest.fn(), // Deprecated - addEventListener: jest.fn(), - removeEventListener: jest.fn(), - dispatchEvent: jest.fn(), - })), - }); - }); - - const onChange = jest.fn(); - - const WrappedComponent = ({ policy = getCloudDefendNewPolicyMock() }) => { - return ( - - ; - - ); - }; - - beforeEach(() => { - onChange.mockClear(); - }); - - it('renders a checkbox to toggle BPF/LSM control mechanism', () => { - const { getByTestId } = render(); - const input = getByTestId('cloud-defend-control-toggle') as HTMLInputElement; - expect(input).toBeInTheDocument(); - expect(input).toBeEnabled(); - }); - - it('renders a yaml editor', () => { - const { getByTestId } = render(); - const el = getByTestId('monacoEditorTextarea') as HTMLTextAreaElement; - expect(el).toBeInTheDocument(); - }); -}); diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.tsx b/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.tsx deleted file mode 100644 index 21bee7282b17a..0000000000000 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/index.tsx +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ -import React, { useCallback, useEffect, useState } from 'react'; -import { EuiSwitch, EuiSpacer, EuiText, EuiFlexGroup, EuiFlexItem, EuiTitle } from '@elastic/eui'; -import { CodeEditor, YamlLang } from '@kbn/kibana-react-plugin/public'; -import { NewPackagePolicy } from '@kbn/fleet-plugin/public'; -import { monaco } from '@kbn/monaco'; -import { INPUT_CONTROL } from '../../../common/constants'; -import { useStyles } from './styles'; -import { useConfigModel } from './hooks/use_config_model'; -import { getInputFromPolicy } from '../../common/utils'; -import * as i18n from './translations'; - -const { editor } = monaco; - -interface OnChangeDeps { - isValid: boolean; - updatedPolicy: NewPackagePolicy; -} - -interface ConfigYamlViewDeps { - policy: NewPackagePolicy; - onChange(opts: OnChangeDeps): void; -} - -interface ConfigError { - line: number; - message: string; -} - -export const ConfigYamlView = ({ policy, onChange }: ConfigYamlViewDeps) => { - const styles = useStyles(); - const [errors, setErrors] = useState([]); - const input = getInputFromPolicy(policy, INPUT_CONTROL); - const configuration = input?.vars?.configuration?.value || ''; - const currentModel = useConfigModel(configuration); - const controlEnabled = !!input?.enabled; - - useEffect(() => { - const listener = editor.onDidChangeMarkers(([resource]) => { - const markers = editor.getModelMarkers({ resource }); - const errs = markers.map((marker) => { - const error: ConfigError = { - line: marker.startLineNumber, - message: marker.message, - }; - - return error; - }); - - onChange({ isValid: errs.length === 0, updatedPolicy: policy }); - setErrors(errs); - }); - - return () => { - listener.dispose(); - }; - }, [onChange, policy]); - - const onYamlChange = useCallback( - (value) => { - if (input?.vars) { - input.vars.configuration.value = value; - onChange({ isValid: errors.length === 0, updatedPolicy: policy }); - } - }, - [errors.length, input, onChange, policy] - ); - - const onToggleEnabled = useCallback( - (e) => { - if (input) { - input.enabled = e.target.checked; - onChange({ isValid: errors.length === 0, updatedPolicy: policy }); - } - }, - [errors.length, input, onChange, policy] - ); - - return ( - - - - - - {i18n.enableControlHelp} - - - {controlEnabled && ( - - -

    {i18n.controlYaml}

    -
    - - - {i18n.controlYamlHelp} - - -
    - -
    - -
    - )} -
    - ); -}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view/index.test.tsx new file mode 100644 index 0000000000000..0a0b05d35b32b --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view/index.test.tsx @@ -0,0 +1,109 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import yaml from 'js-yaml'; +import { render, waitFor } from '@testing-library/react'; +import { coreMock } from '@kbn/core/public/mocks'; +import userEvent from '@testing-library/user-event'; +import { TestProvider } from '../../test/test_provider'; +import { getCloudDefendNewPolicyMock } from '../../test/mocks'; +import { ControlGeneralView } from '.'; +import { getInputFromPolicy } from '../../common/utils'; +import { INPUT_CONTROL } from '../../../common/constants'; + +describe('', () => { + const onChange = jest.fn(); + + // defining this here to avoid a warning in testprovider with params.history changing on rerender. + const params = coreMock.createAppMountParameters(); + + const WrappedComponent = ({ policy = getCloudDefendNewPolicyMock() }) => { + return ( + + ; + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + }); + + it('renders a list of selectors and responses', () => { + const { getAllByTestId } = render(); + + const input = getInputFromPolicy(getCloudDefendNewPolicyMock(), INPUT_CONTROL); + const configuration = input?.vars?.configuration?.value; + + try { + const json = yaml.load(configuration); + + expect(json.selectors.length).toBe(getAllByTestId('cloud-defend-selector').length); + expect(json.responses.length).toBe(getAllByTestId('cloud-defend-response').length); + expect(json.selectors.length).toBe(3); + expect(json.responses.length).toBe(2); + } catch (err) { + throw err; + } + }); + + it('allows a user to add a new selector and new response', async () => { + const { getAllByTestId, getByTestId, rerender } = render(); + + userEvent.click(getByTestId('cloud-defend-btnaddselector')); + userEvent.click(getByTestId('cloud-defend-btnaddresponse')); + + const policy = onChange.mock.calls[0][0].updatedPolicy; + + rerender(); + + const input = getInputFromPolicy(policy, INPUT_CONTROL); + const configuration = input?.vars?.configuration?.value; + + try { + const json = yaml.load(configuration); + + expect(json.selectors.length).toBe(getAllByTestId('cloud-defend-selector').length); + expect(json.responses.length).toBe(getAllByTestId('cloud-defend-response').length); + expect(json.selectors.length).toBe(4); + expect(json.responses.length).toBe(3); + } catch (err) { + throw err; + } + }); + + it('updates selector name used in response.match, if its name is changed', async () => { + const { getByTitle, getAllByTestId, rerender } = render(); + + const input = await waitFor( + () => getAllByTestId('cloud-defend-selectorcondition-name')[1] as HTMLInputElement + ); + + userEvent.type(input, '2'); + + const policy = onChange.mock.calls[0][0].updatedPolicy; + rerender(); + + expect(getByTitle('Remove nginxOnly2 from selection in this group')).toBeTruthy(); // would be 'nginxOnly' had the update not worked + }); + + it('updates selector name used in response.exclude, if its name is changed', async () => { + const { getByTitle, getAllByTestId, rerender } = render(); + + const input = await waitFor( + () => getAllByTestId('cloud-defend-selectorcondition-name')[2] as HTMLInputElement + ); + + userEvent.type(input, '3'); + + const policy = onChange.mock.calls[0][0].updatedPolicy; + + rerender(); + + expect(getByTitle('Remove excludeCustomNginxBuild3 from selection in this group')).toBeTruthy(); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view/index.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view/index.tsx new file mode 100644 index 0000000000000..9fc8add9640ce --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view/index.tsx @@ -0,0 +1,338 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useMemo, useCallback } from 'react'; +import { + EuiIcon, + EuiFlexGroup, + EuiFlexItem, + EuiText, + EuiTitle, + EuiButton, + EuiPanel, + EuiDragDropContext, + EuiDraggable, + EuiDroppable, + euiDragDropReorder, + EuiSpacer, +} from '@elastic/eui'; +import yaml from 'js-yaml'; +import { INPUT_CONTROL } from '../../../common/constants'; +import { useStyles } from './styles'; +import { getInputFromPolicy } from '../../common/utils'; +import { + ControlSelector, + ControlResponse, + DefaultSelector, + DefaultResponse, + ViewDeps, +} from '../../types'; +import * as i18n from './translations'; +import { ControlGeneralViewSelector } from '../control_general_view_selector'; +import { ControlGeneralViewResponse } from '../control_general_view_response'; + +export const ControlGeneralView = ({ policy, onChange, show }: ViewDeps) => { + const styles = useStyles(); + const input = getInputFromPolicy(policy, INPUT_CONTROL); + const configuration = input?.vars?.configuration?.value || ''; + const json = useMemo<{ selectors: ControlSelector[]; responses: ControlResponse[] }>(() => { + try { + const result = yaml.load(configuration); + + if (result) { + return result; + } + } catch { + // noop + } + + return { selectors: [], responses: [] }; + }, [configuration]); + + const { selectors, responses } = json; + + const onUpdateYaml = useCallback( + (newSelectors: ControlSelector[], newResponses: ControlResponse[]) => { + if (input?.vars?.configuration) { + const isValid = + !newSelectors.find((selector) => selector.hasErrors) && + !newResponses.find((response) => response.hasErrors); + + // remove hasErrors prop prior to yaml conversion + newSelectors.forEach((selector) => delete selector.hasErrors); + newResponses.forEach((response) => delete response.hasErrors); + + const yml = yaml.dump({ selectors: newSelectors, responses: newResponses }); + input.vars.configuration.value = yml; + + onChange({ isValid, updatedPolicy: { ...policy } }); + } + }, + [input?.vars?.configuration, onChange, policy] + ); + + const incrementName = useCallback( + (name: string): string => { + // increment name using ints + const lastChar = parseInt(name.slice(-1), 10); + const newName = isNaN(lastChar) ? name + '1' : name.slice(0, -1) + (lastChar + 1); + const dupe = selectors.find((selector) => selector.name === newName); + + if (dupe) { + return incrementName(dupe.name); + } + + return newName; + }, + [selectors] + ); + + const onAddSelector = useCallback(() => { + const newSelector = { ...DefaultSelector }; + const dupe = selectors.find((selector) => selector.name === newSelector.name); + + if (dupe) { + newSelector.name = incrementName(dupe.name); + } + + selectors.push(newSelector); + onUpdateYaml(selectors, responses); + }, [incrementName, onUpdateYaml, responses, selectors]); + + const onAddResponse = useCallback(() => { + const newResponse = { ...DefaultResponse }; + responses.push(newResponse); + onUpdateYaml(selectors, responses); + }, [onUpdateYaml, responses, selectors]); + + const onDuplicateSelector = useCallback( + (selector: ControlSelector) => { + const duplicate = JSON.parse(JSON.stringify(selector)); + + duplicate.name = incrementName(duplicate.name); + + selectors.push(duplicate); + + onUpdateYaml(selectors, responses); + }, + [incrementName, onUpdateYaml, responses, selectors] + ); + + const onRemoveSelector = useCallback( + (index: number) => { + const oldName = selectors[index].name; + const newSelectors = [...selectors]; + newSelectors.splice(index, 1); + + // remove reference from all responses + const updatedResponses = responses.map((r) => { + const response = { ...r }; + const matchIndex = response.match.indexOf(oldName); + + if (matchIndex !== -1) { + response.match.splice(matchIndex, 1); + } + + if (response.exclude) { + const excludeIndex = response.exclude.indexOf(oldName); + + if (excludeIndex !== -1) { + response.exclude.splice(excludeIndex, 1); + } + } + + return response; + }); + + onUpdateYaml(newSelectors, updatedResponses); + }, + [onUpdateYaml, responses, selectors] + ); + + const onDuplicateResponse = useCallback( + (response: ControlResponse) => { + const duplicate = { ...response }; + responses.push(duplicate); + onUpdateYaml(selectors, responses); + }, + [onUpdateYaml, responses, selectors] + ); + + const onRemoveResponse = useCallback( + (index: number) => { + const newResponses = [...responses]; + newResponses.splice(index, 1); + onUpdateYaml(selectors, newResponses); + }, + [onUpdateYaml, responses, selectors] + ); + + const onSelectorChange = useCallback( + (updatedSelector: ControlSelector, index: number) => { + const old = selectors[index]; + + const updatedSelectors: ControlSelector[] = [...selectors]; + let updatedResponses: ControlResponse[] = [...responses]; + + if (old.name !== updatedSelector.name) { + // update all references to this selector in responses + updatedResponses = responses.map((response) => { + let oldNameIndex = response.match.indexOf(old.name); + + if (oldNameIndex !== -1) { + response.match[oldNameIndex] = updatedSelector.name; + } + + if (response.exclude) { + oldNameIndex = response.exclude.indexOf(old.name); + + if (oldNameIndex !== -1) { + response.exclude[oldNameIndex] = updatedSelector.name; + } + } + + return response; + }); + } + + updatedSelectors[index] = updatedSelector; + onUpdateYaml(updatedSelectors, updatedResponses); + }, + [onUpdateYaml, responses, selectors] + ); + + const onResponseChange = useCallback( + (updatedResponse: ControlResponse, index: number) => { + const updatedResponses: ControlResponse[] = [...responses]; + + updatedResponses[index] = updatedResponse; + onUpdateYaml(selectors, updatedResponses); + }, + [onUpdateYaml, responses, selectors] + ); + + const onResponseDragEnd = useCallback( + ({ source, destination }) => { + if (source && destination) { + const reorderedResponses = euiDragDropReorder(responses, source.index, destination.index); + onUpdateYaml(selectors, reorderedResponses); + } + }, + [onUpdateYaml, responses, selectors] + ); + + return ( + + + +

    {i18n.selectors}

    +
    + + {i18n.selectorsHelp} + +
    + + {selectors.map((selector, i) => { + return ( + + + + ); + })} + + + {i18n.addSelector} + + + + + + +

    {i18n.responses}

    +
    + + {i18n.responsesHelp} + +
    + + + + + {responses.map((response, i) => { + return ( + + {(provided) => ( + + + + + + + + + + + + + )} + + ); + })} + + + + {i18n.addResponse} + + + +
    + ); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view/styles.ts b/x-pack/plugins/cloud_defend/public/components/control_general_view/styles.ts new file mode 100644 index 0000000000000..f35bd4207f164 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view/styles.ts @@ -0,0 +1,29 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useMemo } from 'react'; +import { CSSObject } from '@emotion/react'; + +export const useStyles = () => { + return useMemo(() => { + const panel: CSSObject = { + position: 'relative', + }; + + const draggable: CSSObject = { + // setting manually as the spacing of selectors doesn't match with built in sizes + padding: 0, + paddingBottom: '12px', + }; + + const hide: CSSObject = { + display: 'none', + }; + + return { panel, draggable, hide }; + }, []); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view/translations.ts b/x-pack/plugins/cloud_defend/public/components/control_general_view/translations.ts new file mode 100644 index 0000000000000..d97789e8f9e9a --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view/translations.ts @@ -0,0 +1,141 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; +import { ControlSelectorCondition } from '../../types'; + +export const duplicate = i18n.translate('xpack.cloudDefend.controlDuplicate', { + defaultMessage: 'Duplicate', +}); + +export const remove = i18n.translate('xpack.cloudDefend.controlRemove', { + defaultMessage: 'Remove', +}); + +export const selectors = i18n.translate('xpack.cloudDefend.controlSelectors', { + defaultMessage: 'Selectors', +}); + +export const selectorsHelp = i18n.translate('xpack.cloudDefend.controlSelectorsHelp', { + defaultMessage: 'Create selectors to match on activities that should be blocked or alerted.', +}); + +export const responses = i18n.translate('xpack.cloudDefend.controlResponses', { + defaultMessage: 'Responses', +}); + +export const responsesHelp = i18n.translate('xpack.cloudDefend.controlResponsesHelp', { + defaultMessage: + 'Responses are evaluated from top to bottom. At most, one set of actions will be performed.', +}); + +export const matchSelectors = i18n.translate('xpack.cloudDefend.controlMatchSelectors', { + defaultMessage: 'Match selectors', +}); + +export const excludeSelectors = i18n.translate('xpack.cloudDefend.controlExcludeSelectors', { + defaultMessage: 'Exclude selectors', +}); + +export const actions = i18n.translate('xpack.cloudDefend.controlResponseActions', { + defaultMessage: 'Actions', +}); + +export const actionAlert = i18n.translate('xpack.cloudDefend.controlResponseActionAlert', { + defaultMessage: 'Alert', +}); + +export const actionBlock = i18n.translate('xpack.cloudDefend.controlResponseActionBlock', { + defaultMessage: 'Block', +}); + +export const actionAlertAndBlock = i18n.translate( + 'xpack.cloudDefend.controlResponseActionAlertAndBlock', + { + defaultMessage: 'Alert and block', + } +); + +export const addResponse = i18n.translate('xpack.cloudDefend.addResponse', { + defaultMessage: 'Add response', +}); + +export const addSelector = i18n.translate('xpack.cloudDefend.addSelector', { + defaultMessage: 'Add selector', +}); + +export const addSelectorCondition = i18n.translate('xpack.cloudDefend.addSelectorCondition', { + defaultMessage: 'Add condition', +}); + +export const name = i18n.translate('xpack.cloudDefend.name', { + defaultMessage: 'Name', +}); + +export const errorDuplicateName = i18n.translate('xpack.cloudDefend.errorDuplicateName', { + defaultMessage: 'This name is already used by another selector.', +}); + +export const errorInvalidName = i18n.translate('xpack.cloudDefend.errorInvalidName', { + defaultMessage: 'Selector names must be alphanumeric and contain no spaces.', +}); + +export const errorValueRequired = i18n.translate('xpack.cloudDefend.errorValueRequired', { + defaultMessage: 'At least one value is required.', +}); + +export const errorValueLengthExceeded = i18n.translate( + 'xpack.cloudDefend.errorValueLengthExceeded', + { + defaultMessage: 'Values must not exceed 32 characters.', + } +); + +export const getConditionLabel = (prop: string) => { + switch (prop) { + case ControlSelectorCondition.operation: + return i18n.translate('xpack.cloudDefend.operation', { + defaultMessage: 'Operation', + }); + case ControlSelectorCondition.containerImageName: + return i18n.translate('xpack.cloudDefend.containerImageName', { + defaultMessage: 'Container image name', + }); + case ControlSelectorCondition.containerImageTag: + return i18n.translate('xpack.cloudDefend.containerImageTag', { + defaultMessage: 'Container image tag', + }); + case ControlSelectorCondition.targetFilePath: + return i18n.translate('xpack.cloudDefend.targetFilePath', { + defaultMessage: 'Target file path', + }); + case ControlSelectorCondition.orchestratorClusterId: + return i18n.translate('xpack.cloudDefend.orchestratorClusterId', { + defaultMessage: 'Orchestrator cluster ID', + }); + case ControlSelectorCondition.orchestratorClusterName: + return i18n.translate('xpack.cloudDefend.orchestratorClusterName', { + defaultMessage: 'Orchestrator cluster name', + }); + case ControlSelectorCondition.orchestratorNamespace: + return i18n.translate('xpack.cloudDefend.orchestratorNamespace', { + defaultMessage: 'Orchestrator namespace', + }); + case ControlSelectorCondition.orchestratorResourceLabel: + return i18n.translate('xpack.cloudDefend.orchestratorResourceLabel', { + defaultMessage: 'Orchestrator resource label', + }); + case ControlSelectorCondition.orchestratorResourceName: + return i18n.translate('xpack.cloudDefend.orchestratorResourceName', { + defaultMessage: 'Orchestrator resource name', + }); + case ControlSelectorCondition.orchestratorResourceType: + return i18n.translate('xpack.cloudDefend.orchestratorResourceType', { + defaultMessage: 'Orchestrator resource type', + }); + } +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.test.tsx new file mode 100644 index 0000000000000..2912b8ecac5e4 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.test.tsx @@ -0,0 +1,212 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render, waitFor } from '@testing-library/react'; +import { coreMock } from '@kbn/core/public/mocks'; +import userEvent from '@testing-library/user-event'; +import { TestProvider } from '../../test/test_provider'; +import { ControlGeneralViewResponse } from '.'; +import { + ControlResponse, + ControlResponseAction, + ControlSelector, + ControlSelectorOperation, +} from '../../types'; +import * as i18n from '../control_general_view/translations'; + +describe('', () => { + const onChange = jest.fn(); + const onRemove = jest.fn(); + const onDuplicate = jest.fn(); + + // defining this here to avoid a warning in testprovider with params.history changing on rerender. + const params = coreMock.createAppMountParameters(); + + const mockSelector: ControlSelector = { + name: 'mock', + operation: [ControlSelectorOperation.createExecutable], + }; + + const mockSelector2: ControlSelector = { + name: 'mock2', + operation: [ControlSelectorOperation.modifyExecutable], + }; + + const mockExclude: ControlSelector = { + name: 'mockExclude', + containerImageName: ['nginx'], + }; + + const mockResponse: ControlResponse = { + match: [mockSelector.name], + actions: [ControlResponseAction.alert], + }; + + const mockResponse2: ControlResponse = { + match: [mockSelector.name], + actions: [ControlResponseAction.alert, ControlResponseAction.block], + }; + + const WrappedComponent = ({ + response = { ...mockResponse }, + responses, + }: { + response?: ControlResponse; + responses?: ControlResponse[]; + }) => { + return ( + + + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + onRemove.mockClear(); + onDuplicate.mockClear(); + }); + + it('renders a response that matches a selector and has alert action enabled', () => { + const { getByTestId, queryByTestId } = render(); + expect(getByTestId('cloud-defend-responsematch').querySelector('.euiBadge__text')).toBeTruthy(); + expect(queryByTestId('cloud-defend-responseexclude')).toBeFalsy(); + expect( + getByTestId('cloud-defend-chkalertaction').querySelector('.euiRadio__input') + ).toBeChecked(); + expect( + getByTestId('cloud-defend-chkblockaction').querySelector('.euiRadio__input') + ).not.toBeChecked(); + }); + + it('allows the user to add more selectors to match on', () => { + const { getByTestId, rerender } = render(); + getByTestId('comboBoxSearchInput').focus(); + + const options = getByTestId( + 'comboBoxOptionsList cloud-defend-responsematch-optionsList' + ).querySelectorAll('.euiComboBoxOption__content'); + expect(options).toHaveLength(2); + expect(options[0].textContent).toBe('mock2'); + + userEvent.click(options[0]); + + const updatedResponse: ControlResponse = onChange.mock.calls[0][0]; + + rerender(); + + expect(updatedResponse.match).toContain('mock'); + expect(updatedResponse.match).toContain('mock2'); + + // test that 1 option remains + const updatedOptions = getByTestId( + 'comboBoxOptionsList cloud-defend-responsematch-optionsList' + ).querySelectorAll('.euiComboBoxOption__content'); + expect(updatedOptions).toHaveLength(1); + expect(updatedOptions[0].textContent).toContain('mockExclude'); + }); + + it('ensures there is at least 1 selector to match', () => { + const { getByText, getByTitle, rerender } = render(); + + userEvent.click(getByTitle('Remove mock from selection in this group')); + + const updatedResponse: ControlResponse = onChange.mock.calls[0][0]; + rerender(); + + expect(getByText(i18n.errorValueRequired)).toBeTruthy(); + }); + + it('allows the user to exclude selectors', async () => { + const { getByTestId, getAllByTestId, rerender } = render(); + + // first must click button to show combobox + userEvent.click(getByTestId('cloud-defend-btnshowexclude')); + + let updatedResponse: ControlResponse = onChange.mock.calls[0][0]; + rerender(); + + getAllByTestId('comboBoxSearchInput')[1].focus(); + + let options = await waitFor(() => + getByTestId('comboBoxOptionsList cloud-defend-responseexclude-optionsList').querySelectorAll( + '.euiComboBoxOption__content' + ) + ); + expect(options).toHaveLength(2); + expect(options[0].textContent).toBe('mock2'); + expect(options[1].textContent).toBe('mockExclude'); + + userEvent.click(options[1]); + + updatedResponse = onChange.mock.calls[0][0]; + rerender(); + + expect(updatedResponse.exclude).toContain('mockExclude'); + + // focus 'match' input box, lets ensure selectors can't be re-used across 'match' and 'exclude' fields + getAllByTestId('comboBoxSearchInput')[0].focus(); + + options = getByTestId( + 'comboBoxOptionsList cloud-defend-responsematch-optionsList' + ).querySelectorAll('.euiComboBoxOption__content'); + expect(options).toHaveLength(1); + expect(options[0].textContent).toBe('mock2'); + }); + + it('allows the user to enable block action (which should force alert action on)', () => { + const { getByTestId } = render(); + const radioBtn = getByTestId('cloud-defend-chkblockaction').querySelector('.euiRadio__input'); + if (radioBtn) { + userEvent.click(radioBtn); + } + + const response: ControlResponse = onChange.mock.calls[0][0]; + expect(response.actions).toContain(ControlResponseAction.alert); + expect(response.actions).toContain(ControlResponseAction.block); + }); + + it('allows the user to remove the response', async () => { + const { getByTestId } = render(); + const btnPopover = getByTestId('cloud-defend-btnresponsepopover'); + userEvent.click(btnPopover); + + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btndeleteresponse'))); + + expect(onRemove.mock.calls).toHaveLength(1); + expect(onRemove.mock.calls[0][0]).toEqual(0); + }); + + it('prevents the last response from being removed', async () => { + const { getByTestId } = render(); + const btnPopover = getByTestId('cloud-defend-btnresponsepopover'); + userEvent.click(btnPopover); + + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btndeleteresponse'))); + + expect(onRemove.mock.calls).toHaveLength(0); + }); + + it('allows the user to duplicate the response', async () => { + const { getByTestId } = render(); + const btnPopover = getByTestId('cloud-defend-btnresponsepopover'); + userEvent.click(btnPopover); + + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btnduplicateresponse'))); + + expect(onDuplicate.mock.calls).toHaveLength(1); + expect(onDuplicate.mock.calls[0][0]).toEqual(mockResponse); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.tsx new file mode 100644 index 0000000000000..e98259acf7c55 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/index.tsx @@ -0,0 +1,255 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useMemo, useState, useCallback } from 'react'; +import { + EuiFlexGroup, + EuiFlexItem, + EuiButtonIcon, + EuiButtonEmpty, + EuiPopover, + EuiContextMenuPanel, + EuiContextMenuItem, + EuiForm, + EuiFormRow, + EuiComboBox, + EuiRadio, + EuiComboBoxOptionOption, + EuiSpacer, + euiPaletteColorBlindBehindText, +} from '@elastic/eui'; +import { useStyles } from './styles'; +import { ControlGeneralViewResponseDeps, ControlResponseAction } from '../../types'; +import * as i18n from '../control_general_view/translations'; + +export const ControlGeneralViewResponse = ({ + response, + selectors, + responses, + index, + onRemove, + onDuplicate, + onChange, +}: ControlGeneralViewResponseDeps) => { + const [isPopoverOpen, setPopoverOpen] = useState(false); + const styles = useStyles(); + const visColorsBehindText = euiPaletteColorBlindBehindText(); + + const onTogglePopover = useCallback(() => { + setPopoverOpen(!isPopoverOpen); + }, [isPopoverOpen]); + + const closePopover = useCallback(() => { + setPopoverOpen(false); + }, []); + + const onRemoveClicked = useCallback(() => { + onRemove(index); + closePopover(); + }, [closePopover, index, onRemove]); + + const onDuplicateClicked = useCallback(() => { + onDuplicate(response); + closePopover(); + }, [closePopover, onDuplicate, response]); + + const onChangeMatches = useCallback( + (options) => { + response.match = options.map((option: EuiComboBoxOptionOption) => option.value); + response.hasErrors = response.match.length === 0; + + onChange(response, index); + }, + [index, onChange, response] + ); + + const onChangeExcludes = useCallback( + (options) => { + response.exclude = options.map((option: EuiComboBoxOptionOption) => option.value); + + if (response.exclude?.length === 0) { + delete response.exclude; + } + + onChange(response, index); + }, + [index, onChange, response] + ); + + const selectorOptions = useMemo(() => { + return selectors + .filter( + (selector) => + !(response.match.includes(selector.name) || response.exclude?.includes(selector.name)) + ) + .map((selector) => ({ label: selector.name, value: selector.name })); + }, [response.exclude, response.match, selectors]); + + const selectedMatches = useMemo( + () => + response.match.map((selector) => ({ + label: selector as unknown as string, + value: selector as unknown as string, + color: visColorsBehindText[0], + })), + [response.match, visColorsBehindText] + ); + + const selectedExcludes = useMemo( + () => + response.exclude && + response.exclude.map((selector) => ({ + label: selector as unknown as string, + value: selector as unknown as string, + color: visColorsBehindText[5], + })), + [response.exclude, visColorsBehindText] + ); + + const onShowExclude = useCallback(() => { + const updatedResponse = { ...response }; + updatedResponse.exclude = []; + onChange(updatedResponse, index); + }, [index, onChange, response]); + + const alertSelected = !response.actions.includes(ControlResponseAction.block); + const blockSelected = response.actions.includes(ControlResponseAction.block); + + const onSelectAlertAction = useCallback(() => { + const updatedResponse = { ...response }; + + updatedResponse.actions = [ControlResponseAction.alert]; + + onChange(updatedResponse, index); + }, [index, onChange, response]); + + const onSelectAlertAndBlockAction = useCallback(() => { + const updatedResponse = { ...response }; + + updatedResponse.actions = [ControlResponseAction.alert, ControlResponseAction.block]; + + onChange(updatedResponse, index); + }, [index, onChange, response]); + + const errors = useMemo(() => { + const errs: string[] = []; + + if (response.match.length === 0) { + errs.push(i18n.errorValueRequired); + } + + return errs; + }, [response.match.length]); + + return ( + + + 0}> + 0}> + + + {response.exclude && ( + + + + )} + + {!response.exclude && ( + + {i18n.excludeSelectors} + + )} + + + + + + + + + + + + + + + + + + } + isOpen={isPopoverOpen} + closePopover={closePopover} + panelPaddingSize="none" + anchorPosition="downLeft" + > + + {i18n.duplicate} + , + + {i18n.remove} + , + ]} + /> + + + + ); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/styles.ts b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/styles.ts similarity index 61% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/styles.ts rename to x-pack/plugins/cloud_defend/public/components/control_general_view_response/styles.ts index 0d49630b95d66..a54cae7ae9ce5 100644 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/styles.ts +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_response/styles.ts @@ -7,13 +7,19 @@ import { useMemo } from 'react'; import { CSSObject } from '@emotion/react'; +import { useEuiTheme } from '@elastic/eui'; export const useStyles = () => { + const { euiTheme } = useEuiTheme(); + const { size } = euiTheme; + return useMemo(() => { - const yamlEditor: CSSObject = { - height: '400px', + const options: CSSObject = { + position: 'absolute', + top: size.m, + right: size.m, }; - return { yamlEditor }; - }, []); + return { options }; + }, [size.m]); }; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.test.tsx new file mode 100644 index 0000000000000..71e33c7005af1 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.test.tsx @@ -0,0 +1,230 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render, waitFor } from '@testing-library/react'; +import { coreMock } from '@kbn/core/public/mocks'; +import userEvent from '@testing-library/user-event'; +import { TestProvider } from '../../test/test_provider'; +import { ControlGeneralViewSelector } from '.'; +import { ControlSelector, ControlSelectorCondition, ControlSelectorOperation } from '../../types'; +import * as i18n from '../control_general_view/translations'; + +describe('', () => { + const onChange = jest.fn(); + const onRemove = jest.fn(); + const onDuplicate = jest.fn(); + + // defining this here to avoid a warning in testprovider with params.history changing on rerender. + const params = coreMock.createAppMountParameters(); + + const mockSelector: ControlSelector = { + name: 'mock', + operation: [ControlSelectorOperation.createExecutable], + }; + + const mockSelector2: ControlSelector = { + name: 'mock2', + operation: [ControlSelectorOperation.modifyExecutable], + }; + + const WrappedComponent = ({ + selector = { ...mockSelector }, + selectors, + }: { + selector?: ControlSelector; + selectors?: ControlSelector[]; + }) => { + return ( + + + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + onRemove.mockClear(); + onDuplicate.mockClear(); + }); + + it('by default has name and operation fields added', () => { + const { getByTestId } = render(); + + expect(getByTestId('cloud-defend-selectorcondition-name')).toBeTruthy(); + expect(getByTestId('cloud-defend-selectorcondition-operation')).toBeTruthy(); + }); + + it('allows the user to add a limited set of operations', () => { + const { getByTestId, rerender } = render(); + + userEvent.click(getByTestId('cloud-defend-selectorcondition-operation')); + + getByTestId('comboBoxSearchInput').focus(); + + const options = getByTestId( + 'comboBoxOptionsList cloud-defend-selectorcondition-operation-optionsList' + ).querySelectorAll('.euiComboBoxOption__content'); + expect(options).toHaveLength(2); + expect(options[0].textContent).toBe(ControlSelectorOperation.modifyExecutable); + expect(options[1].textContent).toBe(ControlSelectorOperation.execMemFd); + + userEvent.click(options[1]); // select execMemFd + + const updatedSelector: ControlSelector = onChange.mock.calls[0][0]; + + rerender(); + + expect(updatedSelector.operation).toContain(ControlSelectorOperation.execMemFd); + + // test that only 1 option is remaining + const updatedOptions = getByTestId( + 'comboBoxOptionsList cloud-defend-selectorcondition-operation-optionsList' + ).querySelectorAll('.euiComboBoxOption__content'); + expect(updatedOptions).toHaveLength(1); + expect(updatedOptions[0].textContent).toBe(ControlSelectorOperation.modifyExecutable); + }); + + it('allows the user add additional conditions', async () => { + const { getByTestId, rerender } = render(); + const addConditionBtn = getByTestId('cloud-defend-btnaddselectorcondition'); + + userEvent.click(addConditionBtn); + + const options = document.querySelectorAll('.euiContextMenuItem'); + expect(options).toHaveLength(Object.values(ControlSelectorCondition).length - 1); // since operation is already present + + await waitFor(() => userEvent.click(options[0])); // add first option "containerImageName" + + // rerender and check that containerImageName is not in the list anymore + const updatedSelector: ControlSelector = { ...onChange.mock.calls[0][0] }; + rerender(); + expect(updatedSelector.containerImageName).toHaveLength(0); + + userEvent.click(addConditionBtn); + + const updatedOptions = document.querySelectorAll('.euiContextMenuItem'); + expect(updatedOptions).toHaveLength(Object.values(ControlSelectorCondition).length - 2); // since operation and containerImageName are already selected + expect(updatedOptions[0]).not.toHaveTextContent('containerImageName'); + }); + + it('ensures at least one condition is provided, and a value specified', async () => { + const { getByText, getByTestId } = render(); + + userEvent.click(getByTestId('cloud-defend-btnremovecondition-operation')); + + expect(onChange.mock.calls).toHaveLength(0); // because operation is the only condition, it should not have been removed. + + const addConditionBtn = getByTestId('cloud-defend-btnaddselectorcondition'); + userEvent.click(addConditionBtn); + + await waitFor(() => userEvent.click(getByText('Container image name'))); // add containerImageName + + expect(onChange.mock.calls).toHaveLength(1); + expect(onChange.mock.calls[0][0]).toHaveProperty('containerImageName'); + expect(onChange.mock.calls[0][0]).toHaveProperty('hasErrors'); + }); + + it('prevents conditions from having values that exceed MAX_CONDITION_VALUE_LENGTH_BYTES', async () => { + const { getByText, getByTestId, rerender } = render(); + + const addConditionBtn = getByTestId('cloud-defend-btnaddselectorcondition'); + userEvent.click(addConditionBtn); + + await waitFor(() => userEvent.click(getByText('Container image name'))); // add containerImageName + + const updatedSelector: ControlSelector = onChange.mock.calls[0][0]; + + rerender(); + + const el = getByTestId('cloud-defend-selectorcondition-containerImageName').querySelector( + 'input' + ); + + if (el) { + userEvent.type(el, new Array(513).join('a') + '{enter}'); + } else { + throw new Error("Can't find input"); + } + + expect(getByText(i18n.errorValueLengthExceeded)).toBeTruthy(); + }); + + it('prevents targetFilePath conditions from having values that exceed MAX_FILE_PATH_VALUE_LENGTH_BYTES', async () => { + const { getByText, getByTestId, rerender } = render(); + + const addConditionBtn = getByTestId('cloud-defend-btnaddselectorcondition'); + userEvent.click(addConditionBtn); + + await waitFor(() => userEvent.click(getByText('Target file path'))); + + const updatedSelector: ControlSelector = onChange.mock.calls[0][0]; + + rerender(); + + const el = getByTestId('cloud-defend-selectorcondition-targetFilePath').querySelector('input'); + + if (el) { + userEvent.type(el, new Array(257).join('a') + '{enter}'); + } else { + throw new Error("Can't find input"); + } + + expect(getByText(i18n.errorValueLengthExceeded)).toBeTruthy(); + }); + + it('allows the user to remove conditions', async () => { + const selector: ControlSelector = { + name: 'mock3', + operation: [ControlSelectorOperation.createExecutable], + containerImageTag: ['test'], + }; + + const { getByTestId } = render(); + + userEvent.click(getByTestId('cloud-defend-btnremovecondition-operation')); + expect(onChange.mock.calls).toHaveLength(1); + expect(onChange.mock.calls[0][0]).not.toHaveProperty('operation'); + }); + + it('allows the user to remove the selector (unless its the last one)', async () => { + const { getByTestId, rerender } = render(); + const btnSelectorPopover = getByTestId('cloud-defend-btnselectorpopover'); + userEvent.click(btnSelectorPopover); + + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btndeleteselector'))); + + expect(onRemove.mock.calls).toHaveLength(1); + expect(onRemove.mock.calls[0][0]).toEqual(0); + + onRemove.mockClear(); + + rerender(); + + // try and delete again, and ensure the last selector can't be deleted. + userEvent.click(btnSelectorPopover); + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btndeleteselector'))); + expect(onRemove.mock.calls).toHaveLength(0); + }); + + it('allows the user to duplicate the selector', async () => { + const { getByTestId } = render(); + const btnSelectorPopover = getByTestId('cloud-defend-btnselectorpopover'); + userEvent.click(btnSelectorPopover); + + await waitFor(() => userEvent.click(getByTestId('cloud-defend-btnduplicateselector'))); + + expect(onDuplicate.mock.calls).toHaveLength(1); + expect(onDuplicate.mock.calls[0][0]).toEqual(mockSelector); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.tsx b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.tsx new file mode 100644 index 0000000000000..509c0e1b3069f --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/index.tsx @@ -0,0 +1,352 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useState, useMemo, useCallback, FormEvent } from 'react'; +import { + EuiAccordion, + EuiButtonIcon, + EuiPopover, + EuiContextMenuPanel, + EuiContextMenuItem, + EuiForm, + EuiFormRow, + EuiFieldText, + EuiComboBox, + EuiButtonEmpty, + EuiSpacer, + EuiFlexGroup, + EuiFlexItem, +} from '@elastic/eui'; +import { useStyles } from './styles'; +import { + ControlGeneralViewSelectorDeps, + ControlFormErrorMap, + ControlSelectorCondition, + ControlSelectorConditionUIOptionsMap, + ControlSelector, +} from '../../types'; +import * as i18n from '../control_general_view/translations'; +import { + VALID_SELECTOR_NAME_REGEX, + MAX_SELECTOR_NAME_LENGTH, + MAX_CONDITION_VALUE_LENGTH_BYTES, + MAX_FILE_PATH_VALUE_LENGTH_BYTES, +} from '../../common/constants'; + +export const ControlGeneralViewSelector = ({ + selector, + selectors, + index, + onRemove, + onDuplicate, + onChange, +}: ControlGeneralViewSelectorDeps) => { + const [isPopoverOpen, setPopoverOpen] = useState(false); + const [isAddConditionOpen, setAddConditionOpen] = useState(false); + const [errorMap, setErrorMap] = useState({}); + const styles = useStyles(); + const onTogglePopover = useCallback(() => { + setPopoverOpen(!isPopoverOpen); + }, [isPopoverOpen]); + + const closePopover = useCallback(() => { + setPopoverOpen(false); + }, []); + + const onToggleAddCondition = useCallback(() => { + setAddConditionOpen(!isAddConditionOpen); + }, [isAddConditionOpen]); + + const closeAddCondition = useCallback(() => { + setAddConditionOpen(false); + }, []); + + const onRemoveClicked = useCallback(() => { + // we prevent the removal of the last selector to avoid an empty state + if (selectors.length > 1) { + onRemove(index); + } + + closePopover(); + }, [closePopover, index, onRemove, selectors.length]); + + const onDuplicateClicked = useCallback(() => { + onDuplicate(selector); + closePopover(); + }, [closePopover, onDuplicate, selector]); + + const onNameChange = useCallback( + (event: FormEvent) => { + const errors: string[] = []; + const value = event.currentTarget.value; + + // look for duplicate names (selector names should be unique) + const found = selectors.find((sel) => sel.name === value); + + if (found) { + errors.push(i18n.errorDuplicateName); + } + + // ensure name is valid + if (!VALID_SELECTOR_NAME_REGEX.test(value)) { + errors.push(i18n.errorInvalidName); + } + + if (errors.length) { + errorMap.name = errors; + } else { + delete errorMap.name; + } + + setErrorMap({ ...errorMap }); + + const updatedSelector = { ...selector }; + + updatedSelector.name = value; + updatedSelector.hasErrors = Object.keys(errorMap).length > 0; + + onChange(updatedSelector, index); + }, + [errorMap, index, onChange, selector, selectors] + ); + + const onChangeCondition = useCallback( + (prop: string, values: string[]) => { + const updatedSelector = { ...selector, [prop]: values }; + const errors = []; + + if (values.length === 0) { + errors.push(i18n.errorValueRequired); + } + + values.forEach((value) => { + const bytes = new Blob([value]).size; + + if (prop === ControlSelectorCondition.targetFilePath) { + if (bytes > MAX_FILE_PATH_VALUE_LENGTH_BYTES) { + errors.push(i18n.errorValueLengthExceeded); + } + } else if (bytes > MAX_CONDITION_VALUE_LENGTH_BYTES) { + errors.push(i18n.errorValueLengthExceeded); + } + }); + + if (errors.length) { + errorMap[prop] = errors; + } else { + delete errorMap[prop]; + } + + updatedSelector.hasErrors = Object.keys(errorMap).length > 0; + setErrorMap({ ...errorMap }); + + onChange(updatedSelector, index); + }, + [errorMap, index, onChange, selector] + ); + + const onAddCondition = useCallback( + (prop: string) => { + onChangeCondition(prop, []); + closeAddCondition(); + }, + [closeAddCondition, onChangeCondition] + ); + + const onRemoveCondition = useCallback( + (prop: string) => { + const updatedSelector = { ...selector }; + delete (updatedSelector as any)[prop]; + + delete errorMap[prop]; + setErrorMap({ ...errorMap }); + updatedSelector.hasErrors = Object.keys(errorMap).length > 0; + + onChange(updatedSelector, index); + closeAddCondition(); + }, + [closeAddCondition, errorMap, index, onChange, selector] + ); + + const onAddValueToCondition = useCallback( + (prop: string, searchValue: string) => { + const value = searchValue.trim(); + const values = selector[prop as keyof ControlSelector] as string[]; + + if (values && values.indexOf(value) === -1) { + onChangeCondition(prop, [...values, value]); + } + }, + [onChangeCondition, selector] + ); + + const errors = useMemo(() => { + return Object.keys(errorMap).reduce((prev, current) => { + return prev.concat(errorMap[current]); + }, []); + }, [errorMap]); + + const remainingProps = useMemo(() => { + return Object.keys(ControlSelectorCondition).filter( + (condition) => !selector.hasOwnProperty(condition) + ); + }, [selector]); + + const conditionsAdded = Object.keys(ControlSelectorCondition).length - remainingProps.length; + + return ( + + } + isOpen={isPopoverOpen} + closePopover={closePopover} + panelPaddingSize="none" + anchorPosition="downLeft" + > + + {i18n.duplicate} + , + + {i18n.remove} + , + ]} + /> + + } + > + 0}> + + + + {Object.keys(selector).map((prop: string) => { + if (['name', 'hasErrors'].indexOf(prop) === -1) { + const values = selector[prop as keyof ControlSelector] as string[]; + const selectedOptions = + values?.map((option) => { + return { label: option, value: option }; + }) || []; + + const label = i18n.getConditionLabel(prop); + const restrictedValues = ControlSelectorConditionUIOptionsMap[prop]?.values; + + return ( + + + + onAddValueToCondition(prop, searchValue) + : undefined + } + selectedOptions={selectedOptions} + options={ + restrictedValues + ? restrictedValues.map((value: string) => ({ label: value, value })) + : selectedOptions + } + onChange={(options) => + onChangeCondition(prop, options.map((option) => option.value) as string[]) + } + isClearable + data-test-subj={'cloud-defend-selectorcondition-' + prop} + /> + + + onRemoveCondition(prop)} + aria-label="Remove condition" + data-test-subj={'cloud-defend-btnremovecondition-' + prop} + /> + + + + ); + } + })} + + + + {i18n.addSelectorCondition} +
    + } + isOpen={isAddConditionOpen} + closePopover={closeAddCondition} + panelPaddingSize="none" + anchorPosition="downLeft" + > + { + return ( + onAddCondition(prop)}> + {i18n.getConditionLabel(prop)} + + ); + })} + /> + + + ); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/styles.ts b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/styles.ts new file mode 100644 index 0000000000000..ca060c3fac8be --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_general_view_selector/styles.ts @@ -0,0 +1,27 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useMemo } from 'react'; +import { CSSObject } from '@emotion/react'; +import { useEuiTheme } from '@elastic/eui'; + +export const useStyles = () => { + const { euiTheme } = useEuiTheme(); + const { colors, size, border } = euiTheme; + + return useMemo(() => { + const accordion: CSSObject = { + borderRadius: border.radius.small, + backgroundColor: colors.lightestShade, + '> .euiAccordion__triggerWrapper': { + padding: size.m, + }, + }; + + return { accordion }; + }, [border.radius.small, colors.lightestShade, size.m]); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_settings/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/control_settings/index.test.tsx new file mode 100644 index 0000000000000..400000a87890e --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_settings/index.test.tsx @@ -0,0 +1,69 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render, screen, waitFor } from '@testing-library/react'; +import userEvent from '@testing-library/user-event'; +import { TestProvider } from '../../test/test_provider'; +import { getCloudDefendNewPolicyMock } from '../../test/mocks'; +import { ControlSettings } from '.'; +import { coreMock } from '@kbn/core/public/mocks'; + +describe('', () => { + const onChange = jest.fn(); + + // defining this here to avoid a warning in testprovider with params.history changing on rerender. + const params = coreMock.createAppMountParameters(); + + const WrappedComponent = ({ policy = getCloudDefendNewPolicyMock() }) => { + return ( + + ; + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + }); + + it('renders a toggle to switch between yaml and general views', () => { + const { getByTestId } = render(); + let el = getByTestId('cloud-defend-btngeneralview'); + expect(el).toBeInTheDocument(); + el = getByTestId('cloud-defend-btnyamlview'); + expect(el).toBeInTheDocument(); + }); + + it('renders a yaml editor when the user switches to yaml view', async () => { + render(); + userEvent.click(screen.getByText('YAML view')); + + await waitFor(() => expect(screen.getByTestId('monacoEditorTextarea')).toBeTruthy()); + }); + + it('renders a friendly UI when the user switches to general view', async () => { + render(); + userEvent.click(screen.getByText('General view')); + + await waitFor(() => expect(screen.findByTestId('cloud-defend-generalview')).toBeTruthy()); + }); + + it('should prevent ability to switch views if there are errors', async () => { + const { rerender, getAllByTestId } = render(); + + const btnClear = await waitFor(() => getAllByTestId('comboBoxClearButton')[0]); + + userEvent.click(btnClear); + + const updated = onChange.mock.calls[0][0].updatedPolicy; + + rerender(); + + expect(screen.getByTestId('cloud-defend-btngeneralview')).toBeDisabled(); + expect(screen.getByTestId('cloud-defend-btnyamlview')).toBeDisabled(); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/control_settings/index.tsx b/x-pack/plugins/cloud_defend/public/components/control_settings/index.tsx new file mode 100644 index 0000000000000..56fc053308218 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_settings/index.tsx @@ -0,0 +1,71 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useState, useCallback } from 'react'; +import { EuiFlexGroup, EuiFlexItem, EuiTabs, EuiTab } from '@elastic/eui'; +import * as i18n from './translations'; +import { ControlGeneralView } from '../control_general_view'; +import { ControlYamlView } from '../control_yaml_view'; +import { SettingsDeps, OnChangeDeps } from '../../types'; + +const VIEW_MODE_GENERAL = 'general'; +const VIEW_MODE_YAML = 'yaml'; + +export const ControlSettings = ({ policy, onChange }: SettingsDeps) => { + const [viewMode, setViewMode] = useState(VIEW_MODE_GENERAL); + const [isValid, setIsValid] = useState(true); + + const onViewModeGeneral = useCallback(() => { + setViewMode(VIEW_MODE_GENERAL); + }, []); + + const onViewModeYaml = useCallback(() => { + setViewMode(VIEW_MODE_YAML); + }, []); + + const isGeneralViewSelected = viewMode === VIEW_MODE_GENERAL; + const isYamlViewSelected = viewMode === VIEW_MODE_YAML; + + const onChanges = useCallback( + (opts: OnChangeDeps) => { + opts.updatedPolicy = policy; + onChange(opts); + setIsValid(opts.isValid); + }, + [onChange, policy] + ); + + return ( + + + + + {i18n.viewModeGeneral} + + + {i18n.viewModeYaml} + + + + + + + + + ); +}; diff --git a/x-pack/plugins/observability/public/pages/slos/translations.ts b/x-pack/plugins/cloud_defend/public/components/control_settings/translations.ts similarity index 55% rename from x-pack/plugins/observability/public/pages/slos/translations.ts rename to x-pack/plugins/cloud_defend/public/components/control_settings/translations.ts index 3c50b11f1888b..0f6c9fd5921ed 100644 --- a/x-pack/plugins/observability/public/pages/slos/translations.ts +++ b/x-pack/plugins/cloud_defend/public/components/control_settings/translations.ts @@ -7,10 +7,10 @@ import { i18n } from '@kbn/i18n'; -export const SLOS_PAGE_TITLE = i18n.translate('xpack.observability.slosPageTitle', { - defaultMessage: 'SLOs', +export const viewModeGeneral = i18n.translate('xpack.cloudDefend.controlGeneralView', { + defaultMessage: 'General view', }); -export const SLOS_BREADCRUMB_TEXT = i18n.translate('xpack.observability.breadcrumbs.slosLinkText', { - defaultMessage: 'SLOs', +export const viewModeYaml = i18n.translate('xpack.cloudDefend.controlYamlView', { + defaultMessage: 'YAML view', }); diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/hooks/use_config_model.ts b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/hooks/use_config_model.ts similarity index 80% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/hooks/use_config_model.ts rename to x-pack/plugins/cloud_defend/public/components/control_yaml_view/hooks/use_config_model.ts index 58d9a8c9a46c2..36d9628214fbe 100644 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/hooks/use_config_model.ts +++ b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/hooks/use_config_model.ts @@ -8,6 +8,7 @@ import { useMemo } from 'react'; import yaml from 'js-yaml'; import { setDiagnosticsOptions } from 'monaco-yaml'; import { monaco } from '@kbn/monaco'; +import { MAX_CONDITION_VALUE_LENGTH } from '../../../common/constants'; const { Uri, editor } = monaco; @@ -19,7 +20,7 @@ export const useConfigModel = (configuration: string) => { try { return yaml.load(configuration); } catch { - return { selectors: [] }; + return { selectors: [], responses: [] }; } }, [configuration]); @@ -70,6 +71,7 @@ export const useConfigModel = (configuration: string) => { properties: { name: { type: 'string', + maxLength: MAX_CONDITION_VALUE_LENGTH, }, operation: { type: 'array', @@ -79,42 +81,42 @@ export const useConfigModel = (configuration: string) => { containerImageName: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, containerImageTag: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, targetFilePath: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorClusterId: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorClusterName: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorNamespace: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorResourceLabel: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorResourceName: { type: 'array', minItems: 1, - items: { type: 'string' }, + items: { type: 'string', maxLength: MAX_CONDITION_VALUE_LENGTH }, }, orchestratorType: { type: 'array', @@ -130,7 +132,11 @@ export const useConfigModel = (configuration: string) => { properties: { match: { type: 'array', minItems: 1, items: { enum: selectorNames } }, exclude: { type: 'array', items: { enum: selectorNames } }, - actions: { type: 'array', minItems: 1, items: { enum: ['alert', 'block'] } }, + actions: { + type: 'array', + minItems: 1, + items: { enum: ['alert', 'block'] }, + }, }, }, }, @@ -146,5 +152,5 @@ export const useConfigModel = (configuration: string) => { } return model; - }, [configuration, json.selectors]); + }, [configuration, json?.selectors]); }; diff --git a/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.test.tsx new file mode 100644 index 0000000000000..7f48eafe2bc43 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.test.tsx @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render } from '@testing-library/react'; +import '@kbn/kibana-react-plugin/public/code_editor/code_editor.test.helpers'; +import { TestProvider } from '../../test/test_provider'; +import { getCloudDefendNewPolicyMock, MOCK_YAML_INVALID_CONFIGURATION } from '../../test/mocks'; +import { ControlYamlView } from '.'; + +describe('', () => { + const onChange = jest.fn(); + + const WrappedComponent = ({ policy = getCloudDefendNewPolicyMock() }) => { + return ( + + ; + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + }); + + it('handles invalid yaml', async () => { + render( + + ); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.tsx b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.tsx new file mode 100644 index 0000000000000..eb58560d60881 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/index.tsx @@ -0,0 +1,117 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useCallback, useEffect, useState } from 'react'; +import { EuiSpacer, EuiText, EuiFlexGroup, EuiFlexItem, EuiForm } from '@elastic/eui'; +import { CodeEditor, YamlLang } from '@kbn/kibana-react-plugin/public'; +import { monaco } from '@kbn/monaco'; +import yaml from 'js-yaml'; +import { INPUT_CONTROL } from '../../../common/constants'; +import { useStyles } from './styles'; +import { useConfigModel } from './hooks/use_config_model'; +import { getInputFromPolicy } from '../../common/utils'; +import * as i18n from './translations'; +import { ControlResponseAction, ViewDeps } from '../../types'; + +const { editor } = monaco; + +const TEXT_EDITOR_PADDING = 10; + +interface ConfigError { + line: number; + message: string; +} + +export const ControlYamlView = ({ policy, onChange, show }: ViewDeps) => { + const styles = useStyles(); + const [errors, setErrors] = useState([]); + const [actionsValid, setActionsValid] = useState(true); + const input = getInputFromPolicy(policy, INPUT_CONTROL); + const configuration = input?.vars?.configuration?.value || ''; + const currentModel = useConfigModel(configuration); + + useEffect(() => { + const listener = editor.onDidChangeMarkers(([resource]) => { + const markers = editor.getModelMarkers({ resource }); + const errs = markers.map((marker) => { + const error: ConfigError = { + line: marker.startLineNumber, + message: marker.message, + }; + + return error; + }); + + onChange({ isValid: actionsValid && errs.length === 0, updatedPolicy: policy }); + setErrors(errs); + }); + + return () => { + listener.dispose(); + }; + }, [actionsValid, onChange, policy]); + + // for now we force 'alert' action on all responses. This restriction may be removed in future when we have a plan to record all responses. e.g. audit + const validateActions = useCallback((value) => { + try { + const json = yaml.load(value); + + for (let i = 0; i < json.responses.length; i++) { + const response = json.responses[i]; + + if (!response.actions.includes(ControlResponseAction.alert)) { + return false; + } + } + } catch { + // noop + } + + return true; + }, []); + + const onYamlChange = useCallback( + (value) => { + if (input?.vars) { + input.vars.configuration.value = value; + + const areActionsValid = validateActions(value); + + setActionsValid(areActionsValid); + + onChange({ isValid: areActionsValid && errors.length === 0, updatedPolicy: policy }); + } + }, + [errors.length, input?.vars, onChange, policy, validateActions] + ); + + return ( + + + + {i18n.controlYamlHelp} + + + {!actionsValid && } +
    + +
    + +
    +
    + ); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_yaml_view/styles.ts b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/styles.ts new file mode 100644 index 0000000000000..2a7f470f530d3 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/styles.ts @@ -0,0 +1,32 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useMemo } from 'react'; +import { CSSObject } from '@emotion/react'; +import { useEuiTheme } from '@elastic/eui'; + +export const useStyles = () => { + const { euiTheme } = useEuiTheme(); + const { border } = euiTheme; + + return useMemo(() => { + const yamlEditor: CSSObject = { + height: '500px', + border: border.thin, + }; + + // for some reason, switching back to monaco (by virtue of including the editor when yaml view selector, causes the editor not not update properly when switching views. + // instead I just hide it visually, and show when we switch back which seems + // to fix the issue. + const hide: CSSObject = { + visibility: 'hidden', + position: 'absolute', + }; + + return { yamlEditor, hide }; + }, [border.thin]); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/control_yaml_view/translations.ts b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/translations.ts new file mode 100644 index 0000000000000..f183a02e1fb3f --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/control_yaml_view/translations.ts @@ -0,0 +1,18 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; + +export const errorAlertActionRequired = i18n.translate('xpack.cloudDefend.alertActionRequired', { + defaultMessage: + '[Technical Preview] The "alert" action is required on all responses. This restriction will be removed once all responses become auditable.', +}); + +export const controlYamlHelp = i18n.translate('xpack.cloudDefend.controlYamlHelp', { + defaultMessage: + 'Configure BPF/LSM controls by creating selectors, and responses below. To learn more click ', +}); diff --git a/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_create.tsx b/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_create.tsx index 4d46204d40eff..1de04cf513b73 100644 --- a/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_create.tsx +++ b/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_create.tsx @@ -6,11 +6,11 @@ */ import React, { memo } from 'react'; import type { PackagePolicyCreateExtensionComponentProps } from '@kbn/fleet-plugin/public'; -import { ConfigYamlView } from '../config_yaml_view'; +import { PolicySettings } from '../policy_settings'; export const CloudDefendCreatePolicyExtension = memo( ({ newPolicy, onChange }) => { - return ; + return ; } ); diff --git a/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_edit.tsx b/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_edit.tsx index c1e1b6c755d53..8de06ae9255a5 100644 --- a/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_edit.tsx +++ b/x-pack/plugins/cloud_defend/public/components/fleet_extensions/policy_extension_edit.tsx @@ -6,11 +6,11 @@ */ import React, { memo } from 'react'; import type { PackagePolicyEditExtensionComponentProps } from '@kbn/fleet-plugin/public'; -import { ConfigYamlView } from '../config_yaml_view'; +import { PolicySettings } from '../policy_settings'; export const CloudDefendEditPolicyExtension = memo( ({ newPolicy, onChange }) => { - return ; + return ; } ); diff --git a/x-pack/plugins/cloud_defend/public/components/policy_settings/index.test.tsx b/x-pack/plugins/cloud_defend/public/components/policy_settings/index.test.tsx new file mode 100644 index 0000000000000..f7a10a3ec99d0 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/policy_settings/index.test.tsx @@ -0,0 +1,48 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render } from '@testing-library/react'; +import userEvent from '@testing-library/user-event'; +import { TestProvider } from '../../test/test_provider'; +import { getCloudDefendNewPolicyMock } from '../../test/mocks'; +import { PolicySettings } from '.'; +import { getInputFromPolicy } from '../../common/utils'; +import { INPUT_CONTROL } from '../../../common/constants'; + +describe('', () => { + const onChange = jest.fn(); + + const WrappedComponent = ({ policy = getCloudDefendNewPolicyMock() }) => { + return ( + + ; + + ); + }; + + beforeEach(() => { + onChange.mockClear(); + }); + + it('renders a checkbox to toggle BPF/LSM control mechanism', () => { + const { getByTestId } = render(); + const input = getByTestId('cloud-defend-controltoggle'); + expect(input).toBeInTheDocument(); + expect(input).toBeEnabled(); + }); + + it('User can disable control features', async () => { + const { getByTestId } = render(); + + userEvent.click(getByTestId('cloud-defend-controltoggle')); + + const policy = onChange.mock.calls[0][0].updatedPolicy; + const controlInput = getInputFromPolicy(policy, INPUT_CONTROL); + + expect(controlInput?.enabled).toBeFalsy(); + }); +}); diff --git a/x-pack/plugins/cloud_defend/public/components/policy_settings/index.tsx b/x-pack/plugins/cloud_defend/public/components/policy_settings/index.tsx new file mode 100644 index 0000000000000..5b47bf12e87d7 --- /dev/null +++ b/x-pack/plugins/cloud_defend/public/components/policy_settings/index.tsx @@ -0,0 +1,54 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useCallback, useMemo } from 'react'; +import { EuiSwitch, EuiSpacer, EuiText, EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; +import { INPUT_CONTROL } from '../../../common/constants'; +import { getInputFromPolicy } from '../../common/utils'; +import * as i18n from './translations'; +import { ControlSettings } from '../control_settings'; +import type { SettingsDeps } from '../../types'; + +export const PolicySettings = ({ policy, onChange }: SettingsDeps) => { + const controlInput = getInputFromPolicy(policy, INPUT_CONTROL); + const controlEnabled = !!controlInput?.enabled; + const policyCopy = useMemo(() => JSON.parse(JSON.stringify(policy)), [policy]); + + const onToggleEnabled = useCallback( + (e) => { + if (controlInput) { + controlInput.enabled = e.target.checked; + + onChange({ isValid: true, updatedPolicy: policy }); + } + }, + [controlInput, onChange, policy] + ); + + return ( + + + + + + {i18n.enableControlHelp} + + + {controlEnabled && ( + + )} + + ); +}; diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/translations.ts b/x-pack/plugins/cloud_defend/public/components/policy_settings/translations.ts similarity index 64% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/translations.ts rename to x-pack/plugins/cloud_defend/public/components/policy_settings/translations.ts index f7765910d38a5..84fb74351e213 100644 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/translations.ts +++ b/x-pack/plugins/cloud_defend/public/components/policy_settings/translations.ts @@ -15,12 +15,3 @@ export const enableControlHelp = i18n.translate('xpack.cloudDefend.enableControl defaultMessage: 'Enables BPF/LSM control mechanism, for use with FIM and container drift prevention.', }); - -export const controlYaml = i18n.translate('xpack.cloudDefend.controlYaml', { - defaultMessage: 'Configuration yaml', -}); - -export const controlYamlHelp = i18n.translate('xpack.cloudDefend.controlYamlHelp', { - defaultMessage: - 'Configure BPF/LSM controls by creating selectors, and responses below. To learn more click ', -}); diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/__mocks__/resizeobserver.js b/x-pack/plugins/cloud_defend/public/test/__mocks__/resizeobserver.js similarity index 100% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/__mocks__/resizeobserver.js rename to x-pack/plugins/cloud_defend/public/test/__mocks__/resizeobserver.js diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/__mocks__/worker.js b/x-pack/plugins/cloud_defend/public/test/__mocks__/worker.js similarity index 100% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/__mocks__/worker.js rename to x-pack/plugins/cloud_defend/public/test/__mocks__/worker.js diff --git a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/mocks.ts b/x-pack/plugins/cloud_defend/public/test/mocks.ts similarity index 88% rename from x-pack/plugins/cloud_defend/public/components/config_yaml_view/mocks.ts rename to x-pack/plugins/cloud_defend/public/test/mocks.ts index 7e1d30d6dba22..9a9f707cf2354 100644 --- a/x-pack/plugins/cloud_defend/public/components/config_yaml_view/mocks.ts +++ b/x-pack/plugins/cloud_defend/public/test/mocks.ts @@ -6,7 +6,7 @@ */ import type { NewPackagePolicy } from '@kbn/fleet-plugin/public'; import type { PackagePolicy } from '@kbn/fleet-plugin/common'; -import { INTEGRATION_PACKAGE_NAME, INPUT_CONTROL, ALERTS_DATASET } from '../../../common/constants'; +import { INTEGRATION_PACKAGE_NAME, INPUT_CONTROL, ALERTS_DATASET } from '../../common/constants'; const MOCK_YAML_CONFIGURATION = ` selectors: @@ -37,7 +37,12 @@ responses: actions: [alert] `; -export const getCloudDefendNewPolicyMock = (): NewPackagePolicy => ({ +export const MOCK_YAML_INVALID_CONFIGURATION = ` +selectrs: +reeesponses: +`; + +export const getCloudDefendNewPolicyMock = (yaml = MOCK_YAML_CONFIGURATION): NewPackagePolicy => ({ name: 'some-cloud_defend-policy', description: '', namespace: 'default', @@ -51,7 +56,7 @@ export const getCloudDefendNewPolicyMock = (): NewPackagePolicy => ({ vars: { configuration: { type: 'yaml', - value: MOCK_YAML_CONFIGURATION, + value: yaml, }, }, streams: [ @@ -72,7 +77,7 @@ export const getCloudDefendNewPolicyMock = (): NewPackagePolicy => ({ }, }); -export const getCloudDefendPolicyMock = (): PackagePolicy => ({ +export const getCloudDefendPolicyMock = (yaml = MOCK_YAML_CONFIGURATION): PackagePolicy => ({ id: 'c6d16e42-c32d-4dce-8a88-113cfe276ad1', version: 'abcd', revision: 1, @@ -93,7 +98,7 @@ export const getCloudDefendPolicyMock = (): PackagePolicy => ({ vars: { configuration: { type: 'yaml', - value: MOCK_YAML_CONFIGURATION, + value: yaml, }, }, streams: [ diff --git a/x-pack/plugins/cloud_defend/public/test/test_provider.tsx b/x-pack/plugins/cloud_defend/public/test/test_provider.tsx index 8f692a7f381ec..c384e6dbe0054 100755 --- a/x-pack/plugins/cloud_defend/public/test/test_provider.tsx +++ b/x-pack/plugins/cloud_defend/public/test/test_provider.tsx @@ -15,6 +15,26 @@ import { dataPluginMock } from '@kbn/data-plugin/public/mocks'; import { KibanaContextProvider } from '@kbn/kibana-react-plugin/public'; import { fleetMock } from '@kbn/fleet-plugin/public/mocks'; import type { CloudDefendPluginStartDeps } from '../types'; +import './__mocks__/worker'; +import './__mocks__/resizeobserver'; +import '@kbn/kibana-react-plugin/public/code_editor/code_editor.test.helpers'; + +// @ts-ignore-next +window.Worker = Worker; + +Object.defineProperty(window, 'matchMedia', { + writable: true, + value: jest.fn().mockImplementation((query) => ({ + matches: false, + media: query, + onchange: null, + addListener: jest.fn(), // Deprecated + removeListener: jest.fn(), // Deprecated + addEventListener: jest.fn(), + removeEventListener: jest.fn(), + dispatchEvent: jest.fn(), + })), +}); interface CspAppDeps { core: CoreStart; diff --git a/x-pack/plugins/cloud_defend/public/types.ts b/x-pack/plugins/cloud_defend/public/types.ts index afdc76cb852c9..3f1704b2cd07e 100755 --- a/x-pack/plugins/cloud_defend/public/types.ts +++ b/x-pack/plugins/cloud_defend/public/types.ts @@ -6,6 +6,7 @@ */ import type { FleetSetup, FleetStart } from '@kbn/fleet-plugin/public'; +import { NewPackagePolicy } from '@kbn/fleet-plugin/public'; // eslint-disable-next-line @typescript-eslint/no-empty-interface export interface CloudDefendPluginSetup {} @@ -18,3 +19,117 @@ export interface CloudDefendPluginSetupDeps { export interface CloudDefendPluginStartDeps { fleet: FleetStart; } + +export enum ControlResponseAction { + alert = 'alert', + block = 'block', +} + +export enum ControlSelectorCondition { + operation = 'operation', + containerImageName = 'containerImageName', + containerImageTag = 'containerImageTag', + targetFilePath = 'targetFilePath', + orchestratorClusterId = 'orchestratorClusterId', + orchestratorClusterName = 'orchestratorClusterName', + orchestratorNamespace = 'orchestratorNamespace', + orchestratorResourceLabel = 'orchestratorResourceLabel', + orchestratorResourceName = 'orchestratorResourceName', + orchestratorResourceType = 'orchestratorResourceType', + orchestratorType = 'orchestratorType', +} + +export enum ControlSelectorOperation { + createExecutable = 'createExecutable', + modifyExecutable = 'modifyExecutable', + execMemFd = 'execMemFd', +} + +export enum ControlSelectorOrchestratorType { + kubernetes = 'kubernetes', +} + +export interface ControlSelectorConditionUIOptions { + [key: string]: { + values: string[]; + }; +} + +export const ControlSelectorConditionUIOptionsMap: ControlSelectorConditionUIOptions = { + operation: { values: Object.values(ControlSelectorOperation) }, + orchestratorType: { values: Object.values(ControlSelectorOrchestratorType) }, +}; + +export interface ControlSelector { + name: string; + operation?: string[]; + containerImageName?: string[]; + containerImageTag?: string[]; + targetFilePath?: string[]; + orchestratorClusterId?: string[]; + orchestratorClusterName?: string[]; + orchestratorNamespace?: string[]; + orchestratorResourceLabel?: string[]; + orchestratorResourceName?: string[]; + orchestratorResourceType?: string[]; + orchestratorType?: string[]; + + // ephemeral, used to track selector error state in UI + hasErrors?: boolean; +} + +export interface ControlResponse { + match: string[]; + exclude?: string[]; + actions: ControlResponseAction[]; + + // ephemeral, used to track response error state in UI + hasErrors?: boolean; +} + +export const DefaultSelector: ControlSelector = { + name: 'Untitled', + operation: ControlSelectorConditionUIOptionsMap.operation.values, +}; + +export const DefaultResponse: ControlResponse = { + match: [], + actions: [ControlResponseAction.alert], +}; + +export interface OnChangeDeps { + isValid: boolean; + updatedPolicy: NewPackagePolicy; +} + +export interface SettingsDeps { + policy: NewPackagePolicy; + onChange(opts: OnChangeDeps): void; +} + +export interface ViewDeps extends SettingsDeps { + show: boolean; +} + +export interface ControlGeneralViewSelectorDeps { + selector: ControlSelector; + selectors: ControlSelector[]; + index: number; + onChange(selector: ControlSelector, index: number): void; + onRemove(index: number): void; + onDuplicate(selector: ControlSelector): void; +} + +export interface ControlGeneralViewResponseDeps { + response: ControlResponse; + selectors: ControlSelector[]; + responses: ControlResponse[]; + index: number; + onChange(response: ControlResponse, index: number): void; + onRemove(index: number): void; + onDuplicate(response: ControlResponse): void; +} + +export interface ControlFormErrorMap { + [key: string]: string[]; +} diff --git a/x-pack/plugins/cloud_integrations/cloud_data_migration/public/application/components/app.tsx b/x-pack/plugins/cloud_integrations/cloud_data_migration/public/application/components/app.tsx index 013adce3e04c6..d48cb672e05c3 100755 --- a/x-pack/plugins/cloud_integrations/cloud_data_migration/public/application/components/app.tsx +++ b/x-pack/plugins/cloud_integrations/cloud_data_migration/public/application/components/app.tsx @@ -132,7 +132,13 @@ export const CloudDataMigrationApp = ({ http, breadcrumbService }: CloudDataMigr
    - + { +export class CloudDataMigrationPlugin + implements Plugin +{ private breadcrumbService = new BreadcrumbService(); public setup(core: CoreSetup, { cloud, management }: CloudDataMigrationPluginSetup) { @@ -41,8 +44,20 @@ export class CloudDataMigrationPlugin implements Plugin ( - -); +}: CspNoDataPageProps) => { + const { euiTheme } = useEuiTheme(); + return ( + + ); +}; const packageNotInstalledRenderer = ({ kspmIntegrationLink, diff --git a/x-pack/plugins/cross_cluster_replication/public/__jest__/client_integration/auto_follow_pattern_list.test.js b/x-pack/plugins/cross_cluster_replication/public/__jest__/client_integration/auto_follow_pattern_list.test.js index 8eab5feeb9cfd..e2de5b4dbc09e 100644 --- a/x-pack/plugins/cross_cluster_replication/public/__jest__/client_integration/auto_follow_pattern_list.test.js +++ b/x-pack/plugins/cross_cluster_replication/public/__jest__/client_integration/auto_follow_pattern_list.test.js @@ -269,7 +269,10 @@ describe('', () => { test('should have a "settings" section', () => { actions.clickAutoFollowPatternAt(0); expect(find('settingsSection').find('h3').text()).toEqual('Settings'); - expect(exists('settingsValues')).toBe(true); + + // The number of different settings of an auto-follower pattern + const AVAILABLE_SETTINGS = 4; + expect(find('settingsValues').length).toBe(AVAILABLE_SETTINGS); }); test('should set the correct auto-follow pattern settings values', () => { diff --git a/x-pack/plugins/cross_cluster_replication/public/app/sections/home/auto_follow_pattern_list/components/detail_panel/detail_panel.js b/x-pack/plugins/cross_cluster_replication/public/app/sections/home/auto_follow_pattern_list/components/detail_panel/detail_panel.js index 9718f6f34eef8..44f68bd10368c 100644 --- a/x-pack/plugins/cross_cluster_replication/public/app/sections/home/auto_follow_pattern_list/components/detail_panel/detail_panel.js +++ b/x-pack/plugins/cross_cluster_replication/public/app/sections/home/auto_follow_pattern_list/components/detail_panel/detail_panel.js @@ -102,9 +102,9 @@ export class DetailPanel extends Component { - - - + + + {remoteCluster} - + + - + + {leaderIndexPatterns.join(', ')} - - + + + - + - - + + + )} - + + - + + )} - - - + + + ); diff --git a/x-pack/plugins/cross_cluster_replication/public/app/sections/home/follower_indices_list/components/detail_panel/detail_panel.js b/x-pack/plugins/cross_cluster_replication/public/app/sections/home/follower_indices_list/components/detail_panel/detail_panel.js index 75263594d5a42..a45fcd71b3762 100644 --- a/x-pack/plugins/cross_cluster_replication/public/app/sections/home/follower_indices_list/components/detail_panel/detail_panel.js +++ b/x-pack/plugins/cross_cluster_replication/public/app/sections/home/follower_indices_list/components/detail_panel/detail_panel.js @@ -70,9 +70,9 @@ export class DetailPanel extends Component {
    - - - + + + )} - - + + + - + - - + + + {remoteCluster} - + + - + + {leaderIndex} - - - + + +
    @@ -166,36 +170,40 @@ export class DetailPanel extends Component { } /> ) : ( - + <> - - - - - - - - {maxReadRequestOperationCount} - + + + + + + + + + {maxReadRequestOperationCount} + + - - - - - - - - {maxOutstandingReadRequests} - + + + + + + + + + {maxOutstandingReadRequests} + + @@ -203,33 +211,37 @@ export class DetailPanel extends Component { - - - - - - - - {maxReadRequestSize} - + + + + + + + + + {maxReadRequestSize} + + - - - - - - - - {maxWriteRequestOperationCount} - + + + + + + + + + {maxWriteRequestOperationCount} + + @@ -237,33 +249,37 @@ export class DetailPanel extends Component { - - - - - - - - {maxWriteRequestSize} - + + + + + + + + + {maxWriteRequestSize} + + - - - - - - - - {maxOutstandingWriteRequests} - + + + + + + + + + {maxOutstandingWriteRequests} + + @@ -271,33 +287,37 @@ export class DetailPanel extends Component { - - - - - - - - {maxWriteBufferCount} - + + + + + + + + + {maxWriteBufferCount} + + - - - - - - - - {maxWriteBufferSize} - + + + + + + + + + {maxWriteBufferSize} + + @@ -305,36 +325,40 @@ export class DetailPanel extends Component { - - - - - - - - {maxRetryDelay} - + + + + + + + + + {maxRetryDelay} + + - - - - - - - - {readPollTimeout} - + + + + + + + + + {readPollTimeout} + + - + )} diff --git a/x-pack/plugins/data_visualizer/public/application/common/components/combined_fields/utils.ts b/x-pack/plugins/data_visualizer/public/application/common/components/combined_fields/utils.ts index cb0763ecde504..cd3bf01224e43 100644 --- a/x-pack/plugins/data_visualizer/public/application/common/components/combined_fields/utils.ts +++ b/x-pack/plugins/data_visualizer/public/application/common/components/combined_fields/utils.ts @@ -7,7 +7,7 @@ import { i18n } from '@kbn/i18n'; import { cloneDeep } from 'lodash'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import type { FindFileStructureResponse, IngestPipeline, @@ -164,7 +164,7 @@ function getGeoPointField(results: FindFileStructureResponse) { 'location', 'point_location', `${latField}_${lonField}`, - `location_${uuid()}`, + `location_${uuidv4()}`, ]; // Use first combinedFieldNames that does not have a naming collision const geoPointField = combinedFieldNames.find((name) => { diff --git a/x-pack/plugins/enterprise_search/common/connectors/native_connectors.ts b/x-pack/plugins/enterprise_search/common/connectors/native_connectors.ts index e2518ce9918b4..a19b1e2bb7c19 100644 --- a/x-pack/plugins/enterprise_search/common/connectors/native_connectors.ts +++ b/x-pack/plugins/enterprise_search/common/connectors/native_connectors.ts @@ -70,6 +70,10 @@ export const NATIVE_CONNECTOR_DEFINITIONS: Record | null; export interface Connector { api_key_id: string | null; configuration: ConnectorConfiguration; description: string | null; error: string | null; - features: Partial> | null; + features: ConnectorFeatures; filtering: FilteringConfig[]; id: string; index_name: string; diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_collection_view/analytics_collection_integrate/analytics_collection_integrate_javascript_embed.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_collection_view/analytics_collection_integrate/analytics_collection_integrate_javascript_embed.tsx index 0cd91a14b4e21..425912d8166e6 100644 --- a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_collection_view/analytics_collection_integrate/analytics_collection_integrate_javascript_embed.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_collection_view/analytics_collection_integrate/analytics_collection_integrate_javascript_embed.tsx @@ -12,6 +12,8 @@ import { EuiCodeBlock, EuiLink, EuiText } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; +import { docLinks } from '../../../../shared/doc_links'; + export const javascriptEmbedSteps = (webClientSrc: string, analyticsDNSUrl: string) => [ { title: i18n.translate( @@ -82,7 +84,7 @@ export const javascriptEmbedSteps = (webClientSrc: string, analyticsDNSUrl: stri values={{ link: (

    - - {``} + + {`window.elasticAnalytics.trackEvent("click", { + category: "product", + action: "add_to_cart", + label: "product_id", + value: "123" +});`} diff --git a/x-pack/plugins/enterprise_search/public/applications/app_search/components/curations/components/curations_table.test.tsx b/x-pack/plugins/enterprise_search/public/applications/app_search/components/curations/components/curations_table.test.tsx index d86cb8592635a..3d98b684f8dfc 100644 --- a/x-pack/plugins/enterprise_search/public/applications/app_search/components/curations/components/curations_table.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/app_search/components/curations/components/curations_table.test.tsx @@ -84,8 +84,8 @@ describe('CurationsTable', () => { expect(tableContent).toContain('mountains, valleys'); expect(tableContent).toContain('Last updated'); - expect(tableContent).toContain('Jan 1, 1970 12:00 PM'); - expect(tableContent).toContain('Jan 2, 1970 12:00 PM'); + expect(tableContent).toContain('Jan 1, 1970 12:00 PM'); + expect(tableContent).toContain('Jan 2, 1970 12:00 PM'); }); it('renders queries with curation links and curation suggestion badges', () => { diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.test.ts new file mode 100644 index 0000000000000..d7b322bdcef3f --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.test.ts @@ -0,0 +1,31 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { mockHttpValues } from '../../../__mocks__/kea_logic'; + +import { nextTick } from '@kbn/test-jest-helpers'; + +import { deleteEngine } from './delete_engines_api_logic'; + +describe('deleteEngineApiLogic', () => { + const { http } = mockHttpValues; + beforeEach(() => { + jest.clearAllMocks(); + }); + describe('deleteEngine', () => { + it('calls correct api', async () => { + const promise = Promise.resolve(); + http.post.mockReturnValue(promise); + const result = deleteEngine({ engineName: 'deleteEngineName' }); + await nextTick(); + expect(http.delete).toHaveBeenCalledWith( + '/internal/enterprise_search/engines/deleteEngineName' + ); + await expect(result).resolves; + }); + }); +}); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.ts new file mode 100644 index 0000000000000..c99e8c641c2db --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/delete_engines_api_logic.ts @@ -0,0 +1,44 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; + +import { Actions, createApiLogic } from '../../../shared/api_logic/create_api_logic'; +import { HttpLogic } from '../../../shared/http'; + +export interface DeleteEnginesApiLogicArguments { + engineName: string; +} +export interface DeleteEnginesApiLogicResponse { + engineName: string; +} + +export const deleteEngine = async ({ + engineName, +}: DeleteEnginesApiLogicArguments): Promise => { + const route = `/internal/enterprise_search/engines/${engineName}`; + await HttpLogic.values.http.delete(route); + return { engineName }; +}; +export const DeleteEngineAPILogic = createApiLogic( + ['content', 'delete_engine_api_logic'], + deleteEngine, + { + showSuccessFlashFn: ({ engineName }) => + i18n.translate('xpack.enterpriseSearch.content.engineList.deleteEngine.successToast.title', { + defaultMessage: '{engineName} has been deleted', + values: { + engineName, + }, + }), + } +); + +export type DeleteEnginesApiLogicActions = Actions< + DeleteEnginesApiLogicArguments, + DeleteEnginesApiLogicResponse +>; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/fetch_engines_api_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/fetch_engines_api_logic.ts index 472f74ef472ea..f29edf8ec4206 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/fetch_engines_api_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/engines/fetch_engines_api_logic.ts @@ -14,16 +14,18 @@ import { Meta } from '../../components/engines/types'; export interface EnginesListAPIArguments { meta: Meta; - // searchQuery?: string; + searchQuery?: string; } export const fetchEngines = async ({ meta, + searchQuery, }: EnginesListAPIArguments): Promise => { const route = '/internal/enterprise_search/engines'; const query = { from: meta.from, size: meta.size, + ...(searchQuery && searchQuery.trim() !== '' ? { q: searchQuery } : {}), }; return await HttpLogic.values.http.get(route, { query, diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail.tsx deleted file mode 100644 index 26dd7ad0adf89..0000000000000 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail.tsx +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import React, { useEffect } from 'react'; - -import { useParams } from 'react-router-dom'; - -import { useActions, useValues } from 'kea'; - -import { EuiButton, EuiPanel, EuiSpacer } from '@elastic/eui'; - -import { i18n } from '@kbn/i18n'; - -import { generateEncodedPath } from '../../../shared/encode_path_params'; -import { EuiButtonTo } from '../../../shared/react_router_helpers'; -import { SEARCH_INDEX_TAB_PATH } from '../../routes'; -import { EnterpriseSearchContentPageTemplate } from '../layout/page_template'; -import { CrawlCustomSettingsFlyout } from '../search_index/crawler/crawl_custom_settings_flyout/crawl_custom_settings_flyout'; -import { CrawlerStatusBanner } from '../search_index/crawler/domain_management/crawler_status_banner'; -import { DeleteDomainModal } from '../search_index/crawler/domain_management/delete_domain_modal'; -import { DeleteDomainModalLogic } from '../search_index/crawler/domain_management/delete_domain_modal_logic'; -import { IndexNameLogic } from '../search_index/index_name_logic'; -import { SearchIndexTabId } from '../search_index/search_index'; -import { baseBreadcrumbs } from '../search_indices'; -import { CrawlerStatusIndicator } from '../shared/crawler_status_indicator/crawler_status_indicator'; - -import { AuthenticationPanel } from './authentication_panel/authentication_panel'; -import { CrawlRulesTable } from './crawl_rules_table'; -import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; -import { DeduplicationPanel } from './deduplication_panel/deduplication_panel'; -import { EntryPointsTable } from './entry_points_table'; -import { SitemapsTable } from './sitemaps_table'; - -export const CrawlerDomainDetail: React.FC = () => { - const { domainId } = useParams<{ - domainId: string; - }>(); - - const { indexName } = useValues(IndexNameLogic); - const crawlerDomainDetailLogic = CrawlerDomainDetailLogic({ domainId }); - const { domain, getLoading } = useValues(crawlerDomainDetailLogic); - const { fetchDomainData } = useActions(crawlerDomainDetailLogic); - const { showModal } = useActions(DeleteDomainModalLogic); - - useEffect(() => { - fetchDomainData(domainId); - }, [domainId]); - - const domainUrl = domain?.url ?? '...'; - - return ( - , - { - if (domain) { - showModal(domain); - } - }} - > - {i18n.translate('xpack.enterpriseSearch.crawler.domainDetail.deleteDomainButtonLabel', { - defaultMessage: 'Delete domain', - })} - , - ], - }} - > - - - {i18n.translate('xpack.enterpriseSearch.crawler.domainDetail.allDomainsButtonLabel', { - defaultMessage: 'All domains', - })} - - - {domain && ( - <> - - - - - - - - - - - - - - - - - )} - - - - ); -}; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engine/engine_indices.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engine/engine_indices.tsx index 7168f37c8b678..537c83cac5b1e 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engine/engine_indices.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engine/engine_indices.tsx @@ -92,15 +92,15 @@ export const EngineIndices: React.FC = () => { width: '15%', }, { - field: 'ingestionMethod', + field: 'source', name: i18n.translate( 'xpack.enterpriseSearch.content.engine.indices.ingestionMethod.columnTitle', { defaultMessage: 'Ingestion method', } ), - render: (ingestionMethod: IngestionMethod) => ( - {ingestionMethodToText(ingestionMethod)} + render: (source: IngestionMethod) => ( + {ingestionMethodToText(source)} ), truncateText: true, width: '15%', diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/components/tables/engines_table.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/components/tables/engines_table.tsx index b06264e85012a..6bdb73a074d4b 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/components/tables/engines_table.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/components/tables/engines_table.tsx @@ -14,13 +14,15 @@ import { CriteriaWithPagination, EuiBasicTable, EuiBasicTableColumn } from '@ela import { i18n } from '@kbn/i18n'; import { EnterpriseSearchEngine } from '../../../../../../../common/types/engines'; +import { MANAGE_BUTTON_LABEL } from '../../../../../shared/constants'; -import { DELETE_BUTTON_LABEL, MANAGE_BUTTON_LABEL } from '../../../../../shared/constants'; import { generateEncodedPath } from '../../../../../shared/encode_path_params'; +import { FormattedDateTime } from '../../../../../shared/formatted_date_time'; import { KibanaLogic } from '../../../../../shared/kibana'; import { EuiLinkTo } from '../../../../../shared/react_router_helpers'; import { ENGINE_PATH } from '../../../../routes'; + import { convertMetaToPagination, Meta } from '../../types'; // add health status @@ -30,12 +32,14 @@ interface EnginesListTableProps { loading: boolean; meta: Meta; onChange: (criteria: CriteriaWithPagination) => void; + onDelete: (engine: EnterpriseSearchEngine) => void; } export const EnginesListTable: React.FC = ({ enginesList, - meta, isLoading, + meta, onChange, + onDelete, }) => { const { navigateToUrl } = useValues(KibanaLogic); const columns: Array> = [ @@ -52,6 +56,7 @@ export const EnginesListTable: React.FC = ({ render: (name: string) => ( {name} @@ -61,11 +66,12 @@ export const EnginesListTable: React.FC = ({ width: '30%', }, { - field: 'last_updated', + field: 'updated', name: i18n.translate('xpack.enterpriseSearch.content.enginesList.table.column.lastUpdated', { defaultMessage: 'Last updated', }), dataType: 'string', + render: (dateString: string) => , }, { field: 'indices.length', @@ -83,9 +89,9 @@ export const EnginesListTable: React.FC = ({ { name: MANAGE_BUTTON_LABEL, description: i18n.translate( - 'xpack.enterpriseSearch.content.enginesList.table.column.action.manage.buttonDescription', + 'xpack.enterpriseSearch.content.enginesList.table.column.actions.view.buttonDescription', { - defaultMessage: 'Manage this engine', + defaultMessage: 'View this engine', } ), type: 'icon', @@ -98,7 +104,7 @@ export const EnginesListTable: React.FC = ({ ), }, { - name: DELETE_BUTTON_LABEL, + color: 'danger', description: i18n.translate( 'xpack.enterpriseSearch.content.enginesList.table.column.action.delete.buttonDescription', { @@ -107,8 +113,17 @@ export const EnginesListTable: React.FC = ({ ), type: 'icon', icon: 'trash', - color: 'danger', - onClick: () => {}, + isPrimary: false, + name: () => + i18n.translate( + 'xpack.enterpriseSearch.content.engineList.table.column.actions.deleteEngineLabel', + { + defaultMessage: 'Delete this engine', + } + ), + onClick: (engine) => { + onDelete(engine); + }, }, ], }, diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/delete_engine_modal.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/delete_engine_modal.tsx new file mode 100644 index 0000000000000..16dfdf50a7470 --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/delete_engine_modal.tsx @@ -0,0 +1,60 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; + +import { useActions, useValues } from 'kea'; + +import { EuiConfirmModal } from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; + +import { CANCEL_BUTTON_LABEL } from '../../../shared/constants'; + +import { EnginesListLogic } from './engines_list_logic'; + +export const DeleteEngineModal: React.FC = () => { + const { closeDeleteEngineModal, deleteEngine } = useActions(EnginesListLogic); + const { + deleteModalEngineName: engineName, + isDeleteModalVisible, + isDeleteLoading, + } = useValues(EnginesListLogic); + + if (isDeleteModalVisible) { + return ( + { + deleteEngine({ engineName }); + }} + cancelButtonText={CANCEL_BUTTON_LABEL} + confirmButtonText={i18n.translate( + 'xpack.enterpriseSearch.content.engineList.deleteEngineModal.confirmButton.title', + { + defaultMessage: 'Yes, delete this engine ', + } + )} + buttonColor="danger" + isLoading={isDeleteLoading} + > +

    + {i18n.translate( + 'xpack.enterpriseSearch.content.engineList.deleteEngineModal.delete.description', + { + defaultMessage: + 'Deleting your engine is not a reversible action. Your indices will not be affected. ', + } + )} +

    +
    + ); + } else { + return <>; + } +}; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engine_list_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engine_list_logic.test.ts index 3dc99d5717845..e6128bab79bb6 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engine_list_logic.test.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engine_list_logic.test.ts @@ -19,13 +19,19 @@ import { DEFAULT_META } from './types'; const DEFAULT_VALUES = { data: undefined, - results: [], + deleteModalEngine: null, + deleteModalEngineName: '', + deleteStatus: Status.IDLE, + isDeleteLoading: false, + isDeleteModalVisible: false, + isLoading: false, meta: DEFAULT_META, parameters: { meta: DEFAULT_META }, + results: [], status: Status.IDLE, }; -// sample engines list +// may need to call mock engines response when ready const results: EnterpriseSearchEngine[] = [ { @@ -33,24 +39,18 @@ const results: EnterpriseSearchEngine[] = [ indices: ['index-18', 'index-23'], name: 'engine-name-1', updated: '1999-12-31T23:59:59Z', - // last_updated: '21 March 2021', - // document_count: 18, }, { created: '1999-12-31T23:59:59Z', indices: ['index-180', 'index-230', 'index-8', 'index-2'], name: 'engine-name-2', updated: '1999-12-31T23:59:59Z', - // last_updated: '10 Jul 2018', - // document_count: 10, }, { created: '1999-12-31T23:59:59Z', indices: ['index-2', 'index-3'], name: 'engine-name-3', updated: '1999-12-31T23:59:59Z', - // last_updated: '21 December 2022', - // document_count: 8, }, ]; @@ -71,21 +71,57 @@ describe('EnginesListLogic', () => { describe('onPaginate', () => { it('updates meta with newPageIndex', () => { expect(EnginesListLogic.values).toEqual(DEFAULT_VALUES); - // test below code when pagination is ready - // EnginesListLogic.actions.onPaginate(1); - // expect(EnginesListLogic.values).toEqual({ - // ...DEFAULT_VALUES, - // meta: { - // ...DEFAULT_META, - // from: 1, - // }, - // parameters: { - // meta: { - // ...DEFAULT_META, - // from: 1, - // }, - // }, - // }); + + EnginesListLogic.actions.onPaginate({ page: { index: 1 } }); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + meta: { + ...DEFAULT_META, + from: 10, + }, + parameters: { + meta: { + ...DEFAULT_META, + from: 10, + }, + }, + }); + + EnginesListLogic.actions.onPaginate({ page: { index: 0 } }); + expect(EnginesListLogic.values).toEqual(DEFAULT_VALUES); + + EnginesListLogic.actions.onPaginate({ page: { index: 3 } }); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + meta: { + ...DEFAULT_META, + from: 30, + }, + parameters: { + meta: { + ...DEFAULT_META, + from: 30, + }, + }, + }); + }); + }); + describe('closeDeleteEngineModal', () => { + it('set isDeleteModalVisible to false and engineName to empty string', () => { + EnginesListLogic.actions.openDeleteEngineModal(results[0]); + EnginesListLogic.actions.closeDeleteEngineModal(); + expect(EnginesListLogic.values).toEqual(DEFAULT_VALUES); + }); + }); + describe('openDeleteEngineModal', () => { + it('set deleteModalEngineName and set isDeleteModalVisible to true', () => { + EnginesListLogic.actions.openDeleteEngineModal(results[0]); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + deleteModalEngine: results[0], + deleteModalEngineName: 'engine-name-1', + isDeleteModalVisible: true, + }); }); }); }); @@ -120,14 +156,50 @@ describe('EnginesListLogic', () => { }); }); }); + describe('request to delete Engine', () => { + it('should set isDeleteLoading to true on delete engine request', () => { + EnginesListLogic.actions.deleteEngine({ engineName: results[0].name }); + EnginesListLogic.actions.deleteError({} as HttpError); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + deleteStatus: Status.ERROR, + isDeleteLoading: false, + }); + }); + it('should set isDeleteLoading to false on delete apiError', () => { + EnginesListLogic.actions.deleteEngine({ engineName: results[0].name }); + EnginesListLogic.actions.deleteError({} as HttpError); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + deleteStatus: Status.ERROR, + isDeleteLoading: false, + }); + }); + it('should set isDeleteLoading to false on delete apiSuccess', () => { + EnginesListLogic.actions.deleteEngine({ engineName: results[0].name }); + EnginesListLogic.actions.deleteSuccess({ engineName: results[0].name }); + expect(EnginesListLogic.values).toEqual({ + ...DEFAULT_VALUES, + deleteStatus: Status.SUCCESS, + isDeleteLoading: false, + isLoading: true, + status: Status.LOADING, // fetchEngine api status + }); + }); + }); }); describe('listeners', () => { - it('call flashAPIErrors on apiError', () => { - EnginesListLogic.actions.apiError({} as HttpError); - expect(mockFlashMessageHelpers.flashAPIErrors).toHaveBeenCalledTimes(1); - expect(mockFlashMessageHelpers.flashAPIErrors).toHaveBeenCalledWith({}); - }); + it('calls flashSuccessToast, closeDeleteEngineModal and fetchEngines on deleteSuccess', () => { + EnginesListLogic.actions.fetchEngines = jest.fn(); + EnginesListLogic.actions.closeDeleteEngineModal = jest.fn(); + EnginesListLogic.actions.deleteSuccess({ engineName: results[0].name }); + expect(mockFlashMessageHelpers.flashSuccessToast).toHaveBeenCalledTimes(1); + expect(EnginesListLogic.actions.fetchEngines).toHaveBeenCalledWith( + EnginesListLogic.values.parameters + ); + expect(EnginesListLogic.actions.closeDeleteEngineModal).toHaveBeenCalled(); + }); it('call makeRequest on fetchEngines', async () => { jest.useFakeTimers({ legacyFakeTimers: true }); EnginesListLogic.actions.makeRequest = jest.fn(); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list.tsx index 6c7540cd3f92d..1bafef662a135 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list.tsx @@ -8,133 +8,157 @@ import React, { useEffect, useState } from 'react'; import { useActions, useValues } from 'kea'; +import useThrottle from 'react-use/lib/useThrottle'; import { EuiButton, EuiFieldSearch, EuiLink, EuiSpacer, EuiText } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { FormattedMessage, FormattedNumber } from '@kbn/i18n-react'; +import { INPUT_THROTTLE_DELAY_MS } from '../../../shared/constants/timers'; import { DataPanel } from '../../../shared/data_panel/data_panel'; -import { handlePageChange } from '../../../shared/table_pagination'; import { EnterpriseSearchContentPageTemplate } from '../layout/page_template'; import { EnginesListTable } from './components/tables/engines_table'; +import { DeleteEngineModal } from './delete_engine_modal'; import { EnginesListLogic } from './engines_list_logic'; export const EnginesList: React.FC = () => { - const { fetchEngines, onPaginate } = useActions(EnginesListLogic); + const { fetchEngines, onPaginate, openDeleteEngineModal } = useActions(EnginesListLogic); const { meta, results } = useValues(EnginesListLogic); const [searchQuery, setSearchValue] = useState(''); + const throttledSearchQuery = useThrottle(searchQuery, INPUT_THROTTLE_DELAY_MS); useEffect(() => { fetchEngines({ meta, - searchQuery, + searchQuery: throttledSearchQuery, }); - }, [meta.from, meta.size, searchQuery]); + }, [meta.from, meta.size, throttledSearchQuery]); return ( - - {i18n.translate('xpack.enterpriseSearch.content.engines.createEngineButtonLabel', { - defaultMessage: 'Create engine', - })} -
    , - ], - }} - pageViewTelemetry="Engines" - isLoading={false} - > - - {i18n.translate('xpack.enterpriseSearch.content.engines.description', { - defaultMessage: - 'Engines allow you to query indexed data with a complete set of relevance, analytics and personalization tools. To learn more about how engines work in Enterprise search ', - })} - - - {i18n.translate('xpack.enterpriseSearch.content.engines.documentation', { - defaultMessage: 'explore our Engines documentation', - })} - - - -
    - + + + {i18n.translate('xpack.enterpriseSearch.content.engines.createEngineButtonLabel', { + defaultMessage: 'Create engine', + })} + , + ], + }} + pageViewTelemetry="Engines" + isLoading={false} + > + + + {' '} + {/* TODO: navigate to documentation url */}{' '} + {i18n.translate('xpack.enterpriseSearch.content.engines.documentation', { + defaultMessage: 'explore our Engines documentation', + })} + + ), + }} + /> + + +
    + { + setSearchValue(event.currentTarget.value); + }} + /> +
    + + + {i18n.translate('xpack.enterpriseSearch.content.engines.searchPlaceholder.description', { + defaultMessage: 'Locate an engine via name or indices', })} - fullWidth - onChange={(event) => { - setSearchValue(event.currentTarget.value); - }} - /> -
    - - - {i18n.translate('xpack.enterpriseSearch.content.engines.searchPlaceholder.description', { - defaultMessage: 'Locate an engine via name or indices', - })} - + - - - - - - ), - size: ( - - - - ), - total: , - }} - /> - - - {i18n.translate('xpack.enterpriseSearch.content.engines.title', { - defaultMessage: 'Engines', - })} - - } - > - - + + + + + + ), + to: ( + + + + ), + total: , + }} + /> + + + {i18n.translate('xpack.enterpriseSearch.content.engines.title', { + defaultMessage: 'Engines', + })} + + } + > + + - -
    - + +
    + + ); }; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list_logic.ts index 10f13265c4ea5..8f7a012518905 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/engines_list_logic.ts @@ -7,6 +7,8 @@ import { kea, MakeLogicType } from 'kea'; +import { Status } from '../../../../../common/types/api'; + import { EnterpriseSearchEngine, EnterpriseSearchEnginesResponse, @@ -14,6 +16,11 @@ import { import { Actions } from '../../../shared/api_logic/create_api_logic'; +import { + DeleteEngineAPILogic, + DeleteEnginesApiLogicActions, +} from '../../api/engines/delete_engines_api_logic'; + import { EnginesListAPIArguments, FetchEnginesAPILogic, @@ -21,44 +28,81 @@ import { import { DEFAULT_META, Meta, updateMetaPageIndex } from './types'; +interface EuiBasicTableOnChange { + page: { index: number }; +} + type EnginesListActions = Pick< Actions, 'apiError' | 'apiSuccess' | 'makeRequest' > & { + closeDeleteEngineModal(): void; + deleteEngine: DeleteEnginesApiLogicActions['makeRequest']; + deleteError: DeleteEnginesApiLogicActions['apiError']; + deleteSuccess: DeleteEnginesApiLogicActions['apiSuccess']; + fetchEngines({ meta, searchQuery }: { meta: Meta; searchQuery?: string }): { meta: Meta; searchQuery?: string; }; - onPaginate(pageNumber: number): { pageNumber: number }; + + onPaginate(args: EuiBasicTableOnChange): { pageNumber: number }; + openDeleteEngineModal: (engine: EnterpriseSearchEngine) => { engine: EnterpriseSearchEngine }; }; interface EngineListValues { data: typeof FetchEnginesAPILogic.values.data; + deleteModalEngine: EnterpriseSearchEngine | null; + deleteModalEngineName: string; + deleteStatus: typeof DeleteEngineAPILogic.values.status; + isDeleteLoading: boolean; + isDeleteModalVisible: boolean; + isLoading: boolean; meta: Meta; - results: EnterpriseSearchEngine[]; // stores engine list value from data parameters: { meta: Meta; searchQuery?: string }; // Added this variable to store to the search Query value as well + results: EnterpriseSearchEngine[]; // stores engine list value from data status: typeof FetchEnginesAPILogic.values.status; } export const EnginesListLogic = kea>({ + connect: { + actions: [ + FetchEnginesAPILogic, + ['makeRequest', 'apiSuccess', 'apiError'], + DeleteEngineAPILogic, + ['apiSuccess as deleteSuccess', 'makeRequest as deleteEngine', 'apiError as deleteError'], + ], + values: [ + FetchEnginesAPILogic, + ['data', 'status'], + DeleteEngineAPILogic, + ['status as deleteStatus'], + ], + }, actions: { + closeDeleteEngineModal: true, fetchEngines: ({ meta, searchQuery }) => ({ meta, searchQuery, }), - - onPaginate: (pageNumber) => ({ pageNumber }), + onPaginate: (args: EuiBasicTableOnChange) => ({ pageNumber: args.page.index }), + openDeleteEngineModal: (engine) => ({ engine }), }, - connect: { - actions: [FetchEnginesAPILogic, ['makeRequest', 'apiSuccess', 'apiError']], - values: [FetchEnginesAPILogic, ['data', 'status']], - }, - listeners: ({ actions }) => ({ - fetchEngines: async (input) => { - actions.makeRequest(input); - }, - }), path: ['enterprise_search', 'content', 'engine_list_logic'], reducers: ({}) => ({ + deleteModalEngine: [ + null, + { + closeDeleteEngineModal: () => null, + openDeleteEngineModal: (_, { engine }) => engine, + }, + ], + isDeleteModalVisible: [ + false, + { + closeDeleteEngineModal: () => false, + openDeleteEngineModal: () => true, + }, + ], parameters: [ { meta: DEFAULT_META }, { @@ -73,7 +117,25 @@ export const EnginesListLogic = kea ({ - meta: [() => [selectors.parameters], (parameters) => parameters.meta], + deleteModalEngineName: [() => [selectors.deleteModalEngine], (engine) => engine?.name ?? ''], + isDeleteLoading: [ + () => [selectors.deleteStatus], + (status: EngineListValues['deleteStatus']) => [Status.LOADING].includes(status), + ], + isLoading: [ + () => [selectors.status], + (status: EngineListValues['status']) => [Status.LOADING].includes(status), + ], results: [() => [selectors.data], (data) => data?.results ?? []], + meta: [() => [selectors.parameters], (parameters) => parameters.meta], + }), + listeners: ({ actions, values }) => ({ + deleteSuccess: () => { + actions.closeDeleteEngineModal(); + actions.fetchEngines(values.parameters); + }, + fetchEngines: async (input) => { + actions.makeRequest(input); + }, }), }); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/types.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/types.ts index 2dc0b2f7fe335..90fb49a054688 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/types.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/engines/types.ts @@ -17,11 +17,13 @@ export const DEFAULT_META = { total: 0, }; -export const convertMetaToPagination = (meta: Meta) => ({ - pageIndex: meta.from - 1, - pageSize: meta.size, - totalItemCount: meta.total, -}); +export const convertMetaToPagination = (meta: Meta) => { + return { + pageIndex: meta.from / meta.size, + pageSize: meta.size, + totalItemCount: meta.total, + }; +}; export const updateMetaPageIndex = (oldState: Meta, newPageIndex: number) => { - return { ...oldState, from: newPageIndex }; + return { ...oldState, from: newPageIndex * oldState.size }; }; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel.scss b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel.scss similarity index 100% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel.scss rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel.scss diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel.tsx similarity index 55% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel.tsx index ddfa88cf27ff0..4f406ebe67939 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel.tsx @@ -9,11 +9,10 @@ import React from 'react'; import { useValues } from 'kea'; +import { EuiFlexGroup, EuiFlexItem, EuiText, EuiTitle } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; -import { DataPanel } from '../../../../shared/data_panel/data_panel'; - import { AuthenticationPanelActions } from './authentication_panel_actions'; import { AuthenticationPanelDeleteConfirmationModal } from './authentication_panel_delete_confirmation_modal'; import { AuthenticationPanelEditContent } from './authentication_panel_edit_content'; @@ -27,26 +26,31 @@ export const AuthenticationPanel: React.FC = () => { return ( <> - - {i18n.translate('xpack.enterpriseSearch.crawler.authenticationPanel.title', { - defaultMessage: 'Authentication', - })} - - } - action={} - subtitle={ - - } - > +
    + + + +

    + {i18n.translate('xpack.enterpriseSearch.crawler.authenticationPanel.title', { + defaultMessage: 'Authentication', + })} +

    +
    +
    + + + +
    + +

    + +

    +
    {isEditing ? : } - +
    {isModalVisible && } ); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx index 28285e004182e..f07f9369e2b8c 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_actions.tsx @@ -17,8 +17,8 @@ import { SAVE_BUTTON_LABEL, CANCEL_BUTTON_LABEL, DELETE_BUTTON_LABEL, -} from '../../../../shared/constants'; -import { CrawlerAuth } from '../../../api/crawler/types'; +} from '../../../../../../shared/constants'; +import { CrawlerAuth } from '../../../../../api/crawler/types'; import { CrawlerDomainDetailLogic } from '../crawler_domain_detail_logic'; import { AuthenticationPanelLogic } from './authentication_panel_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx index 98c9737801887..cf51dd692a63d 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_delete_confirmation_modal.tsx @@ -12,7 +12,7 @@ import { useActions } from 'kea'; import { EuiConfirmModal } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { CANCEL_BUTTON_LABEL } from '../../../../shared/constants'; +import { CANCEL_BUTTON_LABEL } from '../../../../../../shared/constants'; import { AuthenticationPanelLogic } from './authentication_panel_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx similarity index 97% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx index 55b930e7c9c21..c8d24525747e0 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_edit_content.tsx @@ -23,7 +23,7 @@ import { import { i18n } from '@kbn/i18n'; -import { USERNAME_LABEL, PASSWORD_LABEL } from '../../../../shared/constants'; +import { USERNAME_LABEL, PASSWORD_LABEL } from '../../../../../../shared/constants'; import { AuthenticationPanelLogic } from './authentication_panel_logic'; import { AUTHENTICATION_LABELS } from './constants'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts similarity index 96% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts index de78802ca2ee0..e0e71575eb1d0 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_logic.ts @@ -7,8 +7,8 @@ import { kea, MakeLogicType } from 'kea'; -import { CrawlerAuth } from '../../../api/crawler/types'; -import { isRawCrawlerAuth, isBasicCrawlerAuth } from '../../../api/crawler/utils'; +import { CrawlerAuth } from '../../../../../api/crawler/types'; +import { isRawCrawlerAuth, isBasicCrawlerAuth } from '../../../../../api/crawler/utils'; import { CrawlerDomainDetailActions, CrawlerDomainDetailLogic, diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_view_content.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_view_content.tsx similarity index 100% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/authentication_panel_view_content.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/authentication_panel_view_content.tsx diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/constants.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/constants.ts similarity index 100% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/authentication_panel/constants.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/authentication_panel/constants.ts diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.test.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.test.tsx similarity index 97% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.test.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.test.tsx index c5d871a70cf20..7eb4c04db4480 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { mockFlashMessageHelpers, setMockActions } from '../../../__mocks__/kea_logic'; +import { mockFlashMessageHelpers, setMockActions } from '../../../../../__mocks__/kea_logic'; import React from 'react'; @@ -13,8 +13,8 @@ import { shallow, ShallowWrapper } from 'enzyme'; import { EuiFieldText, EuiSelect } from '@elastic/eui'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; -import { CrawlerPolicies, CrawlerRules } from '../../api/crawler/types'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; +import { CrawlerPolicies, CrawlerRules } from '../../../../api/crawler/types'; import { CrawlRulesTable, CrawlRulesTableProps } from './crawl_rules_table'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.tsx similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.tsx index ea4617139d045..6bead7b4314d9 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawl_rules_table.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawl_rules_table.tsx @@ -23,13 +23,13 @@ import { import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; -import { docLinks } from '../../../shared/doc_links'; -import { clearFlashMessages, flashSuccessToast } from '../../../shared/flash_messages'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; +import { docLinks } from '../../../../../shared/doc_links'; +import { clearFlashMessages, flashSuccessToast } from '../../../../../shared/flash_messages'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; -import { InlineEditableTableColumn } from '../../../shared/tables/inline_editable_table/types'; -import { ItemWithAnID } from '../../../shared/tables/types'; -import { CrawlerPolicies, CrawlRule, CrawlerRules } from '../../api/crawler/types'; +import { InlineEditableTableColumn } from '../../../../../shared/tables/inline_editable_table/types'; +import { ItemWithAnID } from '../../../../../shared/tables/types'; +import { CrawlerPolicies, CrawlRule, CrawlerRules } from '../../../../api/crawler/types'; import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail.tsx new file mode 100644 index 0000000000000..cdee1ca599689 --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail.tsx @@ -0,0 +1,111 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useEffect } from 'react'; + +import { useActions, useValues } from 'kea'; + +import { + EuiButton, + EuiFlexGroup, + EuiFlexItem, + EuiSpacer, + EuiSplitPanel, + EuiTitle, +} from '@elastic/eui'; + +import { i18n } from '@kbn/i18n'; + +import { generateEncodedPath } from '../../../../../shared/encode_path_params'; +import { Loading } from '../../../../../shared/loading'; +import { EuiButtonTo } from '../../../../../shared/react_router_helpers'; +import { SEARCH_INDEX_TAB_PATH } from '../../../../routes'; +import { IndexNameLogic } from '../../index_name_logic'; +import { SearchIndexTabId } from '../../search_index'; +import { CrawlCustomSettingsFlyout } from '../crawl_custom_settings_flyout/crawl_custom_settings_flyout'; +import { DeleteDomainModal } from '../domain_management/delete_domain_modal'; +import { DeleteDomainModalLogic } from '../domain_management/delete_domain_modal_logic'; + +import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; +import { CrawlerDomainDetailTabs } from './crawler_domain_detail_tabs'; + +export const CrawlerDomainDetail: React.FC<{ domainId: string }> = ({ domainId }) => { + const { indexName } = useValues(IndexNameLogic); + const crawlerDomainDetailLogic = CrawlerDomainDetailLogic({ domainId }); + const { domain, getLoading } = useValues(crawlerDomainDetailLogic); + const { fetchDomainData } = useActions(crawlerDomainDetailLogic); + const { showModal } = useActions(DeleteDomainModalLogic); + + useEffect(() => { + fetchDomainData(domainId); + }, [domainId]); + + const domainUrl = domain?.url ?? '...'; + + return getLoading ? ( + + ) : ( + <> + + + {i18n.translate('xpack.enterpriseSearch.crawler.domainDetail.allDomainsButtonLabel', { + defaultMessage: 'All domains', + })} + + + + + + + +

    + {i18n.translate('xpack.enterpriseSearch.content.crawler.domainDetail.title', { + defaultMessage: 'Manage {domain}', + values: { domain: domainUrl }, + })} +

    +
    +
    + + { + if (domain) { + showModal(domain); + } + }} + > + {i18n.translate( + 'xpack.enterpriseSearch.crawler.domainDetail.deleteDomainButtonLabel', + { + defaultMessage: 'Delete domain', + } + )} + + +
    +
    + + {domain && } + + + +
    + + ); +}; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_logic.ts similarity index 89% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail_logic.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_logic.ts index e36f62333a588..b36671d492714 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/crawler_domain_detail_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_logic.ts @@ -7,19 +7,19 @@ import { kea, MakeLogicType } from 'kea'; -import { HttpError, Status } from '../../../../../common/types/api'; +import { HttpError, Status } from '../../../../../../../common/types/api'; -import { generateEncodedPath } from '../../../shared/encode_path_params'; +import { generateEncodedPath } from '../../../../../shared/encode_path_params'; -import { flashAPIErrors } from '../../../shared/flash_messages'; +import { flashAPIErrors } from '../../../../../shared/flash_messages'; -import { HttpLogic } from '../../../shared/http'; -import { KibanaLogic } from '../../../shared/kibana'; +import { HttpLogic } from '../../../../../shared/http'; +import { KibanaLogic } from '../../../../../shared/kibana'; import { DeleteCrawlerDomainApiLogic, DeleteCrawlerDomainArgs, DeleteCrawlerDomainResponse, -} from '../../api/crawler/delete_crawler_domain_api_logic'; +} from '../../../../api/crawler/delete_crawler_domain_api_logic'; import { CrawlerAuth, CrawlerDomain, @@ -27,11 +27,11 @@ import { CrawlRule, EntryPoint, Sitemap, -} from '../../api/crawler/types'; -import { crawlerDomainServerToClient } from '../../api/crawler/utils'; -import { SEARCH_INDEX_TAB_PATH } from '../../routes'; -import { IndexNameLogic } from '../search_index/index_name_logic'; -import { SearchIndexTabId } from '../search_index/search_index'; +} from '../../../../api/crawler/types'; +import { crawlerDomainServerToClient } from '../../../../api/crawler/utils'; +import { SEARCH_INDEX_TAB_PATH } from '../../../../routes'; +import { IndexNameLogic } from '../../index_name_logic'; +import { SearchIndexTabId } from '../../search_index'; export interface CrawlerDomainDetailProps { domainId: string; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_tabs.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_tabs.tsx new file mode 100644 index 0000000000000..a62dc8bf3d558 --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/crawler_domain_detail_tabs.tsx @@ -0,0 +1,110 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useState } from 'react'; + +import { EuiSpacer, EuiTabbedContent, EuiTabbedContentTab } from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; + +import { CrawlerDomain } from '../../../../api/crawler/types'; + +import { AuthenticationPanel } from './authentication_panel/authentication_panel'; +import { CrawlRulesTable } from './crawl_rules_table'; +import { DeduplicationPanel } from './deduplication_panel/deduplication_panel'; +import { EntryPointsTable } from './entry_points_table'; +import { SitemapsTable } from './sitemaps_table'; + +export enum CrawlerDomainTabId { + ENTRY_POINTS = 'entry_points', + AUTHENTICATION = 'authentication', + SITE_MAPS = 'site_maps', + CRAWL_RULES = 'crawl_rules', + DEDUPLICATION = 'deduplication', +} + +export interface CrawlerDomainDetailTabsProps { + domain: CrawlerDomain; + indexName: string; +} + +export const CrawlerDomainDetailTabs: React.FC = ({ + domain, + indexName, +}) => { + const [tabIndex, setTabIndex] = useState(0); + const tabs = [ + { + content: ( + <> + + + + ), + id: CrawlerDomainTabId.ENTRY_POINTS, + name: i18n.translate('xpack.enterpriseSearch.content.crawler.entryPoints', { + defaultMessage: 'Entry points', + }), + }, + { + content: ( + <> + + + + ), + id: CrawlerDomainTabId.AUTHENTICATION, + name: i18n.translate('xpack.enterpriseSearch.content.crawler.authentication', { + defaultMessage: 'Authentication', + }), + }, + { + content: ( + <> + + + + ), + id: CrawlerDomainTabId.SITE_MAPS, + name: i18n.translate('xpack.enterpriseSearch.content.crawler.siteMaps', { + defaultMessage: 'Site maps', + }), + }, + { + content: ( + <> + + + + ), + id: CrawlerDomainTabId.CRAWL_RULES, + name: i18n.translate('xpack.enterpriseSearch.content.crawler.crawlRules', { + defaultMessage: 'Crawl rules', + }), + }, + { + content: , + id: CrawlerDomainTabId.DEDUPLICATION, + name: i18n.translate('xpack.enterpriseSearch.content.crawler.deduplication', { + defaultMessage: 'Duplicate document handling', + }), + }, + ]; + return ( + { + setTabIndex(tabs.findIndex(({ id }) => id === tab.id) || 0); + }} + /> + ); +}; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.scss b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.scss similarity index 100% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.scss rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.scss diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx similarity index 93% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx index bf6caaf0b03c6..54c93ff744ede 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { setMockActions, setMockValues } from '../../../../__mocks__/kea_logic'; +import { setMockActions, setMockValues } from '../../../../../../__mocks__/kea_logic'; import React from 'react'; @@ -26,8 +26,7 @@ import { import { mountWithIntl } from '@kbn/test-jest-helpers'; -import { DataPanel } from '../../../../shared/data_panel/data_panel'; -import { rerender } from '../../../../test_helpers'; +import { rerender } from '../../../../../../test_helpers'; import { DeduplicationPanel } from './deduplication_panel'; @@ -63,7 +62,7 @@ describe('DeduplicationPanel', () => { it('contains a button to reset to defaults', () => { const wrapper = shallow(); - wrapper.find(DataPanel).dive().find(EuiButton).simulate('click'); + wrapper.find('EuiFlexGroup').first().dive().find(EuiButton).simulate('click'); expect(MOCK_ACTIONS.submitDeduplicationUpdate).toHaveBeenCalledWith({ fields: [], diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx similarity index 75% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx index b8963ea3ef3ab..8076b3e49aa1f 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/deduplication_panel.tsx @@ -21,6 +21,8 @@ import { EuiSelectable, EuiSpacer, EuiSwitch, + EuiText, + EuiTitle, } from '@elastic/eui'; import { EuiSelectableLIOption } from '@elastic/eui/src/components/selectable/selectable_option'; @@ -28,8 +30,7 @@ import { EuiSelectableLIOption } from '@elastic/eui/src/components/selectable/se import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; -import { DataPanel } from '../../../../shared/data_panel/data_panel'; -import { docLinks } from '../../../../shared/doc_links'; +import { docLinks } from '../../../../../../shared/doc_links'; import { CrawlerDomainDetailLogic } from '../crawler_domain_detail_logic'; import { getCheckedOptionLabels, getSelectableOptions } from './utils'; @@ -52,53 +53,60 @@ export const DeduplicationPanel: React.FC = () => { const selectableOptions = getSelectableOptions(domain, showAllFields); return ( - - {i18n.translate('xpack.enterpriseSearch.crawler.deduplicationPanel.title', { - defaultMessage: 'Duplicate document handling', - })} - - } - action={ - submitDeduplicationUpdate({ fields: [] })} - disabled={deduplicationFields.length === 0} - > - {i18n.translate( - 'xpack.enterpriseSearch.crawler.deduplicationPanel.resetToDefaultsButtonLabel', - { - defaultMessage: 'Reset to defaults', - } - )} - - } - subtitle={ - + + + + +

    + {i18n.translate('xpack.enterpriseSearch.crawler.deduplicationPanel.title', { + defaultMessage: 'Duplicate document handling', + })} +

    +
    +
    + + submitDeduplicationUpdate({ fields: [] })} + disabled={deduplicationFields.length === 0} + > + {i18n.translate( + 'xpack.enterpriseSearch.crawler.deduplicationPanel.resetToDefaultsButtonLabel', + { + defaultMessage: 'Reset to defaults', + } + )} + + +
    + + +

    + - {i18n.translate( - 'xpack.enterpriseSearch.crawler.deduplicationPanel.learnMoreMessage', - { - defaultMessage: 'Learn more about content hashing', - } - )} - - ), - }} - /> - } - > + values={{ + documentationLink: ( + + {i18n.translate( + 'xpack.enterpriseSearch.crawler.deduplicationPanel.learnMoreMessage', + { + defaultMessage: 'Learn more about content hashing', + } + )} + + ), + }} + /> +

    +
    + {
    - +
    ); }; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/utils.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/utils.ts similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/utils.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/utils.ts index 256385722c188..162761f43057d 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/deduplication_panel/utils.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/deduplication_panel/utils.ts @@ -6,7 +6,7 @@ */ import { EuiSelectableLIOption } from '@elastic/eui/src/components/selectable/selectable_option'; -import { CrawlerDomain } from '../../../api/crawler/types'; +import { CrawlerDomain } from '../../../../../api/crawler/types'; export const getSelectableOptions = ( domain: CrawlerDomain, diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.test.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.test.tsx similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.test.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.test.tsx index a540a24188783..cf1224cb0dc47 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.test.tsx @@ -13,8 +13,8 @@ import { EuiFieldText } from '@elastic/eui'; import { mountWithIntl } from '@kbn/test-jest-helpers'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; -import { CrawlerDomain } from '../../api/crawler/types'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; +import { CrawlerDomain } from '../../../../api/crawler/types'; import { EntryPointsTable, EntryPointsTableProps } from './entry_points_table'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.tsx similarity index 91% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.tsx index 5f637c506e185..a80ecc85646b3 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table.tsx @@ -14,12 +14,12 @@ import { EuiFieldText, EuiLink, EuiSpacer, EuiText, EuiTitle } from '@elastic/eu import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; -import { docLinks } from '../../../shared/doc_links'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; +import { docLinks } from '../../../../../shared/doc_links'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; -import { InlineEditableTableColumn } from '../../../shared/tables/inline_editable_table/types'; -import { ItemWithAnID } from '../../../shared/tables/types'; -import { CrawlerDomain, EntryPoint } from '../../api/crawler/types'; +import { InlineEditableTableColumn } from '../../../../../shared/tables/inline_editable_table/types'; +import { ItemWithAnID } from '../../../../../shared/tables/types'; +import { CrawlerDomain, EntryPoint } from '../../../../api/crawler/types'; import { EntryPointsTableLogic } from './entry_points_table_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.test.ts similarity index 98% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.test.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.test.ts index b5a0a3aec37ce..afe1eb941f83b 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.test.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.test.ts @@ -13,7 +13,7 @@ jest.mock('./crawler_domain_detail_logic', () => ({ }, })); -import { LogicMounter, mockFlashMessageHelpers } from '../../../__mocks__/kea_logic'; +import { LogicMounter, mockFlashMessageHelpers } from '../../../../../__mocks__/kea_logic'; import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; import { EntryPointsTableLogic } from './entry_points_table_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.ts similarity index 95% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.ts rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.ts index b7b2daa525a8d..d79fff69b9f62 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/entry_points_table_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/entry_points_table_logic.ts @@ -7,9 +7,9 @@ import { kea, MakeLogicType } from 'kea'; -import { clearFlashMessages, flashSuccessToast } from '../../../shared/flash_messages'; +import { clearFlashMessages, flashSuccessToast } from '../../../../../shared/flash_messages'; -import { EntryPoint } from '../../api/crawler/types'; +import { EntryPoint } from '../../../../api/crawler/types'; import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.test.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.test.tsx similarity index 96% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.test.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.test.tsx index f8d1ddd3d4b57..1cae5f5cbe096 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { mockFlashMessageHelpers, setMockActions } from '../../../__mocks__/kea_logic'; +import { mockFlashMessageHelpers, setMockActions } from '../../../../../__mocks__/kea_logic'; import React from 'react'; @@ -14,9 +14,9 @@ import { shallow } from 'enzyme'; import { EuiEmptyPrompt, EuiFieldText } from '@elastic/eui'; import { mountWithIntl } from '@kbn/test-jest-helpers'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; -import { CrawlerDomain } from '../../api/crawler/types'; +import { CrawlerDomain } from '../../../../api/crawler/types'; import { SitemapsTable } from './sitemaps_table'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.tsx similarity index 90% rename from x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.tsx rename to x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.tsx index d4c2ab5f4955a..c486cb2eeaed7 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/crawler_domain_detail/sitemaps_table.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/crawler_domain_detail/sitemaps_table.tsx @@ -13,12 +13,12 @@ import { EuiButton, EuiEmptyPrompt, EuiFieldText, EuiText } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { clearFlashMessages, flashSuccessToast } from '../../../shared/flash_messages'; -import { GenericEndpointInlineEditableTable } from '../../../shared/tables/generic_endpoint_inline_editable_table'; +import { clearFlashMessages, flashSuccessToast } from '../../../../../shared/flash_messages'; +import { GenericEndpointInlineEditableTable } from '../../../../../shared/tables/generic_endpoint_inline_editable_table'; -import { InlineEditableTableColumn } from '../../../shared/tables/inline_editable_table/types'; -import { ItemWithAnID } from '../../../shared/tables/types'; -import { CrawlerDomain, Sitemap } from '../../api/crawler/types'; +import { InlineEditableTableColumn } from '../../../../../shared/tables/inline_editable_table/types'; +import { ItemWithAnID } from '../../../../../shared/tables/types'; +import { CrawlerDomain, Sitemap } from '../../../../api/crawler/types'; import { CrawlerDomainDetailLogic } from './crawler_domain_detail_logic'; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/add_domain/add_domain_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/add_domain/add_domain_logic.test.ts index c2933889aa4a8..16947a575cf5f 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/add_domain/add_domain_logic.test.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/add_domain/add_domain_logic.test.ts @@ -301,7 +301,7 @@ describe('AddDomainLogic', () => { expect(flashSuccessToast).toHaveBeenCalled(); expect(navigateToUrl).toHaveBeenCalledWith( - '/search_indices/index-name/crawler/domains/test-domain' + '/search_indices/index-name/domain_management/test-domain' ); }); }); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domain_management.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domain_management.tsx index 3400dd19347d2..1bcecb5c05e70 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domain_management.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domain_management.tsx @@ -7,6 +7,8 @@ import React from 'react'; +import { useParams } from 'react-router-dom'; + import { useValues } from 'kea'; import { EuiSpacer } from '@elastic/eui'; @@ -16,6 +18,8 @@ import { Loading } from '../../../../../shared/loading'; import { DeleteCrawlerDomainApiLogic } from '../../../../api/crawler/delete_crawler_domain_api_logic'; import { GetCrawlerDomainsApiLogic } from '../../../../api/crawler/get_crawler_domains_api_logic'; +import { CrawlerDomainDetail } from '../crawler_domain_detail/crawler_domain_detail'; + import { AddDomainFlyout } from './add_domain/add_domain_flyout'; import { CrawlerStatusBanner } from './crawler_status_banner'; import { DeleteDomainModal } from './delete_domain_modal'; @@ -28,11 +32,17 @@ export const SearchIndexDomainManagement: React.FC = () => { GetCrawlerDomainsApiLogic.mount(); const { domains, isLoading } = useValues(DomainManagementLogic); + const { detailId } = useParams<{ + detailId?: string; + }>(); + if (isLoading) { return ; } - return ( + return detailId ? ( + + ) : ( <> diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domains_table.test.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domains_table.test.tsx index 6ef7512a59483..46b3ed3ba6058 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domains_table.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/crawler/domain_management/domains_table.test.tsx @@ -117,7 +117,7 @@ describe('DomainsTable', () => { expect(link.dive().text()).toContain('elastic.co'); expect(link.props()).toEqual( expect.objectContaining({ - to: '/search_indices/index-name/crawler/domains/1234', + to: '/search_indices/index-name/domain_management/1234', }) ); }); @@ -157,7 +157,7 @@ describe('DomainsTable', () => { getManageAction().simulate('click'); expect(navigateToUrl).toHaveBeenCalledWith( - '/search_indices/index-name/crawler/domains/1234' + '/search_indices/index-name/domain_management/1234' ); }); }); diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.ts index 2d3651a598fc1..26c1f823b479d 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.ts @@ -197,12 +197,18 @@ export const IndexViewLogic = kea [selectors.connector], (connector?: Connector) => - connector?.features ? connector.features[FeatureName.FILTERING_ADVANCED_CONFIG] : false, + connector?.features + ? connector.features[FeatureName.SYNC_RULES]?.advanced?.enabled ?? + connector.features[FeatureName.FILTERING_ADVANCED_CONFIG] + : false, ], hasBasicFilteringFeature: [ () => [selectors.connector], (connector?: Connector) => - connector?.features ? connector.features[FeatureName.FILTERING_RULES] : false, + connector?.features + ? connector.features[FeatureName.SYNC_RULES]?.basic?.enabled ?? + connector.features[FeatureName.FILTERING_RULES] + : false, ], hasFilteringFeature: [ () => [selectors.hasAdvancedFilteringFeature, selectors.hasBasicFilteringFeature], diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/search_index_router.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/search_index_router.tsx index 75d27d4208dc5..e7be83aa64432 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/search_index_router.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/search_index_router.tsx @@ -6,19 +6,18 @@ */ import React, { useEffect } from 'react'; -import { Route, Switch, useParams } from 'react-router-dom'; +import { Redirect, Route, Switch, useParams } from 'react-router-dom'; import { useActions } from 'kea'; import { - SEARCH_INDEX_CRAWLER_DOMAIN_DETAIL_PATH, + OLD_SEARCH_INDEX_CRAWLER_DOMAIN_DETAIL_PATH, SEARCH_INDEX_PATH, SEARCH_INDEX_SELECT_CONNECTOR_PATH, + SEARCH_INDEX_TAB_DETAIL_PATH, SEARCH_INDEX_TAB_PATH, } from '../../routes'; -import { CrawlerDomainDetail } from '../crawler_domain_detail/crawler_domain_detail'; - import { SelectConnector } from './connector/select_connector/select_connector'; import { IndexNameLogic } from './index_name_logic'; import { IndexViewLogic } from './index_view_logic'; @@ -49,15 +48,19 @@ export const SearchIndexRouter: React.FC = () => { - - - + + + + ); }; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_indices/indices_stats.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_indices/indices_stats.tsx index afb25decdfdc3..d4c4fd4f6633e 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_indices/indices_stats.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_indices/indices_stats.tsx @@ -26,6 +26,11 @@ export const IndicesStats: React.FC = () => { makeRequest({}); }, []); + const UNKNOWN_STRING = i18n.translate( + 'xpack.enterpriseSearch.content.searchIndices.jobStats.unknown', + { defaultMessage: 'Unknown' } + ); + return ( @@ -44,7 +49,7 @@ export const IndicesStats: React.FC = () => { } )} isLoading={isLoading} - title={data?.connected} + title={data?.connected ?? UNKNOWN_STRING} /> @@ -62,7 +67,7 @@ export const IndicesStats: React.FC = () => { } )} isLoading={isLoading} - title={data?.incomplete} + title={data?.incomplete ?? UNKNOWN_STRING} /> @@ -80,21 +85,21 @@ export const IndicesStats: React.FC = () => { } )} isLoading={isLoading} - title={data?.in_progress} + title={data?.in_progress ?? UNKNOWN_STRING} /> - + @@ -112,7 +117,7 @@ export const IndicesStats: React.FC = () => { } )} isLoading={isLoading} - title={data?.orphaned_jobs} + title={data?.orphaned_jobs ?? UNKNOWN_STRING} /> @@ -126,7 +131,7 @@ export const IndicesStats: React.FC = () => { } )} isLoading={isLoading} - title={data?.errors} + title={data?.errors ?? UNKNOWN_STRING} /> diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/routes.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/routes.ts index 3617c097ad401..4185addb31445 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/routes.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/routes.ts @@ -19,10 +19,13 @@ export const NEW_DIRECT_UPLOAD_PATH = `${NEW_INDEX_PATH}/upload`; export const SEARCH_INDEX_PATH = `${SEARCH_INDICES_PATH}/:indexName`; export const SEARCH_INDEX_TAB_PATH = `${SEARCH_INDEX_PATH}/:tabId`; -export const SEARCH_INDEX_CRAWLER_DOMAIN_DETAIL_PATH = `${SEARCH_INDEX_PATH}/crawler/domains/:domainId`; +export const SEARCH_INDEX_TAB_DETAIL_PATH = `${SEARCH_INDEX_TAB_PATH}/:detailId`; +export const SEARCH_INDEX_CRAWLER_DOMAIN_DETAIL_PATH = `${SEARCH_INDEX_PATH}/domain_management/:domainId`; +export const OLD_SEARCH_INDEX_CRAWLER_DOMAIN_DETAIL_PATH = `${SEARCH_INDEX_PATH}/crawler/domains/:domainId`; export const SEARCH_INDEX_SELECT_CONNECTOR_PATH = `${SEARCH_INDEX_PATH}/select_connector`; export const ENGINES_PATH = `${ROOT_PATH}engines`; + export const ENGINE_CREATION_PATH = `${ENGINES_PATH}/new`; export const ENGINE_PATH = `${ENGINES_PATH}/:engineName`; export const ENGINE_TAB_PATH = `${ENGINE_PATH}/:tabId`; diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/indices.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/indices.ts index 3bc19bb2a8b65..fd87b60bd99a8 100644 --- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/indices.ts +++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/indices.ts @@ -129,20 +129,26 @@ export function indexToViewIndex(index: ElasticsearchIndex): ApiViewIndex { } export function ingestionMethodToText(ingestionMethod: IngestionMethod) { - if (ingestionMethod === IngestionMethod.CONNECTOR) { - return i18n.translate( - 'xpack.enterpriseSearch.content.searchIndices.ingestionMethod.connector', - { - defaultMessage: 'Connector', - } - ); + switch (ingestionMethod) { + case IngestionMethod.CONNECTOR: + return i18n.translate( + 'xpack.enterpriseSearch.content.searchIndices.ingestionMethod.connector', + { + defaultMessage: 'Connector', + } + ); + case IngestionMethod.CRAWLER: + return i18n.translate( + 'xpack.enterpriseSearch.content.searchIndices.ingestionMethod.crawler', + { + defaultMessage: 'Crawler', + } + ); + case IngestionMethod.API: + return i18n.translate('xpack.enterpriseSearch.content.searchIndices.ingestionMethod.api', { + defaultMessage: 'API', + }); + default: + return ingestionMethod; } - if (ingestionMethod === IngestionMethod.CRAWLER) { - return i18n.translate('xpack.enterpriseSearch.content.searchIndices.ingestionMethod.crawler', { - defaultMessage: 'Crawler', - }); - } - return i18n.translate('xpack.enterpriseSearch.content.searchIndices.ingestionMethod.api', { - defaultMessage: 'API', - }); } diff --git a/x-pack/plugins/enterprise_search/public/applications/shared/constants/timers.ts b/x-pack/plugins/enterprise_search/public/applications/shared/constants/timers.ts new file mode 100644 index 0000000000000..fcfb58f3a485b --- /dev/null +++ b/x-pack/plugins/enterprise_search/public/applications/shared/constants/timers.ts @@ -0,0 +1,8 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +export const INPUT_THROTTLE_DELAY_MS = 1000; diff --git a/x-pack/plugins/enterprise_search/public/applications/shared/doc_links/doc_links.ts b/x-pack/plugins/enterprise_search/public/applications/shared/doc_links/doc_links.ts index 4b391a70076ec..cc1356fc0c140 100644 --- a/x-pack/plugins/enterprise_search/public/applications/shared/doc_links/doc_links.ts +++ b/x-pack/plugins/enterprise_search/public/applications/shared/doc_links/doc_links.ts @@ -34,6 +34,7 @@ class DocLinks { public appSearchWebCrawler: string; public appSearchWebCrawlerEventLogs: string; public appSearchWebCrawlerReference: string; + public behavioralAnalyticsEvents: string; public bulkApi: string; public clientsGoIndex: string; public clientsGuide: string; @@ -148,6 +149,7 @@ class DocLinks { this.appSearchWebCrawler = ''; this.appSearchWebCrawlerEventLogs = ''; this.appSearchWebCrawlerReference = ''; + this.behavioralAnalyticsEvents = ''; this.bulkApi = ''; this.clientsGoIndex = ''; this.clientsGuide = ''; @@ -264,6 +266,7 @@ class DocLinks { this.appSearchWebCrawler = docLinks.links.appSearch.webCrawler; this.appSearchWebCrawlerEventLogs = docLinks.links.appSearch.webCrawlerEventLogs; this.appSearchWebCrawlerReference = docLinks.links.appSearch.webCrawlerReference; + this.behavioralAnalyticsEvents = docLinks.links.enterpriseSearch.behavioralAnalyticsEvents; this.bulkApi = docLinks.links.enterpriseSearch.bulkApi; this.clientsGoIndex = docLinks.links.clients.goIndex; this.clientsGuide = docLinks.links.clients.guide; diff --git a/x-pack/plugins/enterprise_search/public/applications/shared/formatted_date_time/index.test.tsx b/x-pack/plugins/enterprise_search/public/applications/shared/formatted_date_time/index.test.tsx index f74125b1528c7..fd76943d3e727 100644 --- a/x-pack/plugins/enterprise_search/public/applications/shared/formatted_date_time/index.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/shared/formatted_date_time/index.test.tsx @@ -16,7 +16,7 @@ describe('FormattedDateTime', () => { const date = new Date('1970-01-01T12:00:00'); const wrapper = mountWithIntl(); - expect(wrapper.text()).toEqual('Jan 1, 1970 12:00 PM'); + expect(wrapper.text()).toEqual('Jan 1, 1970 12:00 PM'); }); it('does not render time if hideTime is passed', () => { diff --git a/x-pack/plugins/enterprise_search/server/lib/stats/get_sync_jobs.ts b/x-pack/plugins/enterprise_search/server/lib/stats/get_sync_jobs.ts index 2160ca2165007..4e428c797eca5 100644 --- a/x-pack/plugins/enterprise_search/server/lib/stats/get_sync_jobs.ts +++ b/x-pack/plugins/enterprise_search/server/lib/stats/get_sync_jobs.ts @@ -45,7 +45,7 @@ export const fetchSyncJobsStats = async (client: IScopedClusterClient): Promise< }, }); - const stuckJobsCountResponse = await client.asCurrentUser.count({ + const idleJobsCountResponse = await client.asCurrentUser.count({ index: CONNECTORS_JOBS_INDEX, query: { bool: { @@ -127,10 +127,10 @@ export const fetchSyncJobsStats = async (client: IScopedClusterClient): Promise< const response = { connected: connectedResponse.count, errors: errorResponse.count, + idle: idleJobsCountResponse.count, in_progress: inProgressJobsCountResponse.count, incomplete: incompleteResponse.count, orphaned_jobs: orphanedJobsCountResponse.count, - stuck: stuckJobsCountResponse.count, }; return response; diff --git a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/engines.ts b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/engines.ts index cc3337147934b..11cdd16b2f79b 100644 --- a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/engines.ts +++ b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/engines.ts @@ -18,6 +18,7 @@ export function registerEnginesRoutes({ validate: { query: schema.object({ from: schema.number({ defaultValue: 0, min: 0 }), + q: schema.maybe(schema.string()), size: schema.number({ defaultValue: 10, min: 1 }), }), }, @@ -41,12 +42,12 @@ export function registerEnginesRoutes({ { path: '/internal/enterprise_search/engines/{engine_name}', validate: { - params: schema.object({ - engine_name: schema.string(), - }), body: schema.object({ - name: schema.maybe(schema.string()), indices: schema.arrayOf(schema.string()), + name: schema.maybe(schema.string()), + }), + params: schema.object({ + engine_name: schema.string(), }), }, }, @@ -62,6 +63,9 @@ export function registerEnginesRoutes({ }), }, }, - enterpriseSearchRequestHandler.createRequest({ path: '/api/engines/:engine_name' }) + enterpriseSearchRequestHandler.createRequest({ + hasJsonResponse: false, + path: '/api/engines/:engine_name', + }) ); } diff --git a/x-pack/plugins/enterprise_search/tsconfig.json b/x-pack/plugins/enterprise_search/tsconfig.json index 495810e2e2f40..37d800e154a76 100644 --- a/x-pack/plugins/enterprise_search/tsconfig.json +++ b/x-pack/plugins/enterprise_search/tsconfig.json @@ -46,5 +46,6 @@ "@kbn/data-views-plugin", "@kbn/cypress-config", "@kbn/discover-plugin", + "@kbn/guided-onboarding", ] } diff --git a/x-pack/plugins/event_log/server/saved_object_provider_registry.test.ts b/x-pack/plugins/event_log/server/saved_object_provider_registry.test.ts index 7ae2c5e577811..b46a27a5cc7d0 100644 --- a/x-pack/plugins/event_log/server/saved_object_provider_registry.test.ts +++ b/x-pack/plugins/event_log/server/saved_object_provider_registry.test.ts @@ -6,7 +6,7 @@ */ import { SavedObjectProviderRegistry } from './saved_object_provider_registry'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { KibanaRequest } from '@kbn/core/server'; import { savedObjectsClientMock } from '@kbn/core/server/mocks'; @@ -41,7 +41,7 @@ describe('SavedObjectProviderRegistry', () => { const request = fakeRequest(); const alert = { - id: uuid.v4(), + id: uuidv4(), }; getter.mockResolvedValue(alert); @@ -61,7 +61,7 @@ describe('SavedObjectProviderRegistry', () => { const request = fakeRequest(); const action = { - id: uuid.v4(), + id: uuidv4(), type: 'action', attributes: {}, references: [], diff --git a/x-pack/plugins/features/common/kibana_feature.ts b/x-pack/plugins/features/common/kibana_feature.ts index 2989872d024c9..debcec588dee0 100644 --- a/x-pack/plugins/features/common/kibana_feature.ts +++ b/x-pack/plugins/features/common/kibana_feature.ts @@ -32,6 +32,11 @@ export interface KibanaFeatureConfig { */ name: string; + /** + * An optional description that will appear as subtext underneath the feature name + */ + description?: string; + /** * The category for this feature. * This will be used to organize the list of features for display within the @@ -156,6 +161,10 @@ export class KibanaFeature { return this.config.name; } + public get description() { + return this.config.description; + } + public get order() { return this.config.order; } diff --git a/x-pack/plugins/features/common/sub_feature.ts b/x-pack/plugins/features/common/sub_feature.ts index 58142fd88c0c3..e51fc42195797 100644 --- a/x-pack/plugins/features/common/sub_feature.ts +++ b/x-pack/plugins/features/common/sub_feature.ts @@ -29,6 +29,11 @@ export interface SubFeatureConfig { /** Collection of privilege groups */ privilegeGroups: readonly SubFeaturePrivilegeGroupConfig[]; + + /** + * An optional description that will appear as subtext underneath the sub-feature name + */ + description?: string; } /** @@ -105,6 +110,10 @@ export class SubFeature { return this.config.requireAllSpaces ?? false; } + public get description() { + return this.config.description || ''; + } + public toRaw() { return { ...this.config }; } diff --git a/x-pack/plugins/features/server/feature_schema.ts b/x-pack/plugins/features/server/feature_schema.ts index 05d172887d870..cfc7c2ee47eaa 100644 --- a/x-pack/plugins/features/server/feature_schema.ts +++ b/x-pack/plugins/features/server/feature_schema.ts @@ -165,6 +165,7 @@ const kibanaSubFeatureSchema = schema.object({ name: schema.string(), requireAllSpaces: schema.maybe(schema.boolean()), privilegesTooltip: schema.maybe(schema.string()), + description: schema.maybe(schema.string()), privilegeGroups: schema.maybe( schema.arrayOf( schema.oneOf([ @@ -198,6 +199,7 @@ const kibanaFeatureSchema = schema.object({ }), name: schema.string(), category: appCategorySchema, + description: schema.maybe(schema.string()), order: schema.maybe(schema.number()), excludeFromBasePrivileges: schema.maybe(schema.boolean()), minimumLicense: schema.maybe(validLicenseSchema), diff --git a/x-pack/plugins/fleet/.storybook/context/notifications.ts b/x-pack/plugins/fleet/.storybook/context/notifications.ts index f1a95797cb5ba..7d65a65b234fd 100644 --- a/x-pack/plugins/fleet/.storybook/context/notifications.ts +++ b/x-pack/plugins/fleet/.storybook/context/notifications.ts @@ -5,14 +5,14 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { of } from 'rxjs'; import { action } from '@storybook/addon-actions'; import type { NotificationsStart } from '@kbn/core/public'; const handler = (type: string, ...rest: any[]) => { action(`${type} Toast`)(rest); - return { id: uuid() }; + return { id: uuidv4() }; }; const notifications: NotificationsStart = { diff --git a/x-pack/plugins/fleet/common/experimental_features.ts b/x-pack/plugins/fleet/common/experimental_features.ts index b64a1192f3930..bc39429cccfd4 100644 --- a/x-pack/plugins/fleet/common/experimental_features.ts +++ b/x-pack/plugins/fleet/common/experimental_features.ts @@ -17,6 +17,7 @@ export const allowedExperimentalValues = Object.freeze({ showDevtoolsRequest: true, diagnosticFileUploadEnabled: false, experimentalDataStreamSettings: false, + showIntegrationsSubcategories: false, }); type ExperimentalConfigKeys = Array; diff --git a/x-pack/plugins/fleet/common/openapi/bundled.json b/x-pack/plugins/fleet/common/openapi/bundled.json index af7160c45d653..96b60ee3d8d2b 100644 --- a/x-pack/plugins/fleet/common/openapi/bundled.json +++ b/x-pack/plugins/fleet/common/openapi/bundled.json @@ -380,9 +380,44 @@ } } }, - "operationId": "bulk-install-packages" - }, - "parameters": [] + "operationId": "bulk-install-packages", + "parameters": [ + { + "in": "query", + "name": "prerelease", + "schema": { + "type": "boolean", + "default": false + }, + "description": "Whether to return prerelease versions of packages (e.g. beta, rc, preview) " + } + ], + "requestBody": { + "content": { + "application/json": { + "schema": { + "type": "object", + "properties": { + "packages": { + "type": "array", + "items": { + "type": "string" + }, + "description": "list of package names to install" + }, + "force": { + "type": "boolean", + "description": "force install to ignore package verification errors" + } + }, + "required": [ + "packages" + ] + } + } + } + } + } }, "/epm/packages/{pkgkey}": { "get": { @@ -443,6 +478,15 @@ "name": "pkgkey", "in": "path", "required": true + }, + { + "in": "query", + "name": "prerelease", + "schema": { + "type": "boolean", + "default": false + }, + "description": "Whether to return prerelease versions of packages (e.g. beta, rc, preview) " } ], "deprecated": true @@ -695,6 +739,15 @@ "name": "full", "description": "Return all fields from the package manifest, not just those supported by the Elastic Package Registry", "in": "query" + }, + { + "in": "query", + "name": "prerelease", + "schema": { + "type": "boolean", + "default": false + }, + "description": "Whether to return prerelease versions of packages (e.g. beta, rc, preview) " } ], "post": { diff --git a/x-pack/plugins/fleet/common/openapi/bundled.yaml b/x-pack/plugins/fleet/common/openapi/bundled.yaml index f364623e124b8..d4a10183a3a6f 100644 --- a/x-pack/plugins/fleet/common/openapi/bundled.yaml +++ b/x-pack/plugins/fleet/common/openapi/bundled.yaml @@ -247,7 +247,31 @@ paths: schema: $ref: '#/components/schemas/bulk_install_packages_response' operationId: bulk-install-packages - parameters: [] + parameters: + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, + preview) + requestBody: + content: + application/json: + schema: + type: object + properties: + packages: + type: array + items: + type: string + description: list of package names to install + force: + type: boolean + description: force install to ignore package verification errors + required: + - packages /epm/packages/{pkgkey}: get: summary: Packages - Info @@ -285,6 +309,14 @@ paths: name: pkgkey in: path required: true + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, + preview) deprecated: true post: summary: Packages - Install @@ -437,6 +469,14 @@ paths: Return all fields from the package manifest, not just those supported by the Elastic Package Registry in: query + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, + preview) post: summary: Packages - Install tags: [] diff --git a/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkg_name}@{pkg_version}.yaml b/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkg_name}@{pkg_version}.yaml index 3e3cbbb0c1f56..c6a5e55123591 100644 --- a/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkg_name}@{pkg_version}.yaml +++ b/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkg_name}@{pkg_version}.yaml @@ -57,6 +57,13 @@ parameters: name: full description: 'Return all fields from the package manifest, not just those supported by the Elastic Package Registry' in: query + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, preview) post: summary: Packages - Install tags: [] diff --git a/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkgkey}_deprecated.yaml b/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkgkey}_deprecated.yaml index 796a28fbf0ff0..8704a09f54473 100644 --- a/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkgkey}_deprecated.yaml +++ b/x-pack/plugins/fleet/common/openapi/paths/epm@packages@{pkgkey}_deprecated.yaml @@ -34,6 +34,13 @@ get: name: pkgkey in: path required: true + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, preview) deprecated: true post: summary: Packages - Install diff --git a/x-pack/plugins/fleet/common/openapi/paths/epm@packages_bulk.yaml b/x-pack/plugins/fleet/common/openapi/paths/epm@packages_bulk.yaml index d5b1d9ab43824..b954c2475915c 100644 --- a/x-pack/plugins/fleet/common/openapi/paths/epm@packages_bulk.yaml +++ b/x-pack/plugins/fleet/common/openapi/paths/epm@packages_bulk.yaml @@ -9,4 +9,28 @@ post: schema: $ref: ../components/schemas/bulk_install_packages_response.yaml operationId: bulk-install-packages -parameters: [] + parameters: + - in: query + name: prerelease + schema: + type: boolean + default: false + description: >- + Whether to return prerelease versions of packages (e.g. beta, rc, preview) + requestBody: + content: + application/json: + schema: + type: object + properties: + packages: + type: array + items: + type: string + description: list of package names to install + force: + type: boolean + description: force install to ignore package verification errors + required: + - packages + diff --git a/x-pack/plugins/fleet/common/services/index.ts b/x-pack/plugins/fleet/common/services/index.ts index 1d75aa34e9239..7b076729f5a4e 100644 --- a/x-pack/plugins/fleet/common/services/index.ts +++ b/x-pack/plugins/fleet/common/services/index.ts @@ -51,3 +51,8 @@ export { } from './datastream_es_name'; export * from './file_storage'; +export { + getPackageReleaseLabel, + isPackagePrerelease, + mapPackageReleaseToIntegrationCardRelease, +} from './package_prerelease'; diff --git a/x-pack/plugins/fleet/public/services/package_prerelease.test.ts b/x-pack/plugins/fleet/common/services/package_prerelease.test.ts similarity index 100% rename from x-pack/plugins/fleet/public/services/package_prerelease.test.ts rename to x-pack/plugins/fleet/common/services/package_prerelease.test.ts diff --git a/x-pack/plugins/fleet/public/services/package_prerelease.ts b/x-pack/plugins/fleet/common/services/package_prerelease.ts similarity index 97% rename from x-pack/plugins/fleet/public/services/package_prerelease.ts rename to x-pack/plugins/fleet/common/services/package_prerelease.ts index 6cda43e20e642..9c980b3c6e48a 100644 --- a/x-pack/plugins/fleet/public/services/package_prerelease.ts +++ b/x-pack/plugins/fleet/common/services/package_prerelease.ts @@ -5,7 +5,7 @@ * 2.0. */ -import type { IntegrationCardReleaseLabel, RegistryRelease } from '../../common/types'; +import type { IntegrationCardReleaseLabel, RegistryRelease } from '../types'; export function isPackagePrerelease(version: string): boolean { // derive from semver diff --git a/x-pack/plugins/fleet/common/services/policy_template.ts b/x-pack/plugins/fleet/common/services/policy_template.ts index 912ec96f6091f..4265767a9be25 100644 --- a/x-pack/plugins/fleet/common/services/policy_template.ts +++ b/x-pack/plugins/fleet/common/services/policy_template.ts @@ -13,6 +13,7 @@ import type { PackageInfo, RegistryVarsEntry, RegistryDataStream, + InstallablePackage, } from '../types'; const DATA_STREAM_DATASET_VAR: RegistryVarsEntry = { @@ -52,7 +53,10 @@ export const getNormalizedInputs = (policyTemplate: RegistryPolicyTemplate): Reg return [input]; }; -export const getNormalizedDataStreams = (packageInfo: PackageInfo): RegistryDataStream[] => { +export const getNormalizedDataStreams = ( + packageInfo: PackageInfo | InstallablePackage, + datasetName?: string +): RegistryDataStream[] => { if (packageInfo.type !== 'input') { return packageInfo.data_streams || []; } @@ -66,11 +70,12 @@ export const getNormalizedDataStreams = (packageInfo: PackageInfo): RegistryData return policyTemplates.map((policyTemplate) => { const dataStream: RegistryDataStream = { type: policyTemplate.type, - dataset: createDefaultDatasetName(packageInfo, policyTemplate), + dataset: datasetName || createDefaultDatasetName(packageInfo, policyTemplate), title: policyTemplate.title + ' Dataset', release: packageInfo.release || 'ga', package: packageInfo.name, path: packageInfo.name, + elasticsearch: packageInfo.elasticsearch, streams: [ { input: policyTemplate.input, @@ -104,6 +109,6 @@ const addDatasetVarIfNotPresent = (vars?: RegistryVarsEntry[]): RegistryVarsEntr }; const createDefaultDatasetName = ( - packageInfo: PackageInfo, - policyTemplate: RegistryPolicyInputOnlyTemplate + packageInfo: { name: string }, + policyTemplate: { name: string } ): string => packageInfo.name + '.' + policyTemplate.name; diff --git a/x-pack/plugins/fleet/common/types/models/epm.ts b/x-pack/plugins/fleet/common/types/models/epm.ts index b9f471f1b4d43..6c9a61cf17ce1 100644 --- a/x-pack/plugins/fleet/common/types/models/epm.ts +++ b/x-pack/plugins/fleet/common/types/models/epm.ts @@ -289,6 +289,8 @@ export interface CategorySummaryItem { id: CategoryId; title: string; count: number; + parent_id?: string; + parent_title?: string; } export type RequirementsByServiceName = PackageSpecManifest['conditions']; @@ -357,11 +359,16 @@ export interface RegistryElasticsearch { privileges?: RegistryDataStreamPrivileges; 'index_template.settings'?: estypes.IndicesIndexSettings; 'index_template.mappings'?: estypes.MappingTypeMapping; + 'index_template.data_stream'?: RegistryDataStreamProperties; 'ingest_pipeline.name'?: string; source_mode?: 'default' | 'synthetic'; index_mode?: 'time_series'; } +export interface RegistryDataStreamProperties { + hidden?: boolean; +} + export interface RegistryDataStreamPrivileges { cluster?: string[]; indices?: string[]; diff --git a/x-pack/plugins/fleet/common/types/models/package_spec.ts b/x-pack/plugins/fleet/common/types/models/package_spec.ts index 52f993499ea4e..48dd619ae3aea 100644 --- a/x-pack/plugins/fleet/common/types/models/package_spec.ts +++ b/x-pack/plugins/fleet/common/types/models/package_spec.ts @@ -5,7 +5,7 @@ * 2.0. */ -import type { RegistryPolicyTemplate, RegistryVarsEntry } from './epm'; +import type { RegistryElasticsearch, RegistryPolicyTemplate, RegistryVarsEntry } from './epm'; // Based on https://github.com/elastic/package-spec/blob/master/versions/1/manifest.spec.yml#L8 export interface PackageSpecManifest { @@ -27,6 +27,10 @@ export interface PackageSpecManifest { policy_templates?: RegistryPolicyTemplate[]; vars?: RegistryVarsEntry[]; owner: { github: string }; + elasticsearch?: Pick< + RegistryElasticsearch, + 'index_template.settings' | 'index_template.mappings' + >; } export type PackageSpecPackageType = 'integration' | 'input'; diff --git a/x-pack/plugins/fleet/cypress/e2e/integrations_real.cy.ts b/x-pack/plugins/fleet/cypress/e2e/integrations_real.cy.ts index cce1269585cbb..3e570d0e76f78 100644 --- a/x-pack/plugins/fleet/cypress/e2e/integrations_real.cy.ts +++ b/x-pack/plugins/fleet/cypress/e2e/integrations_real.cy.ts @@ -172,7 +172,8 @@ describe('Add Integration - Real API', () => { it('should filter integrations by category', () => { setupIntegrations(); - cy.getBySel(getIntegrationCategories('aws')).click(); + cy.getBySel(getIntegrationCategories('aws')).click({ scrollBehavior: false }); + cy.getBySel(INTEGRATIONS_SEARCHBAR.BADGE).contains('AWS').should('exist'); cy.getBySel(INTEGRATION_LIST).find('.euiCard').should('have.length.greaterThan', 29); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_create_inline.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_create_inline.tsx index 32100ea137930..4e371767c0ece 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_create_inline.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_create_inline.tsx @@ -22,8 +22,7 @@ import { FormattedMessage } from '@kbn/i18n-react'; import styled from 'styled-components'; import { i18n } from '@kbn/i18n'; -import { dataTypes } from '../../../../../../common/constants'; - +import { generateNewAgentPolicyWithDefaults } from '../../../services'; import type { AgentPolicy, NewAgentPolicy } from '../../../types'; import { sendCreateAgentPolicy, useStartServices } from '../../../hooks'; @@ -57,13 +56,12 @@ export const AgentPolicyCreateInlineForm: React.FunctionComponent = ({ const [isLoading, setIsLoading] = useState(false); - const [newAgentPolicy, setNewAgentPolicy] = useState({ - name: agentPolicyName, - description: '', - namespace: 'default', - monitoring_enabled: Object.values(dataTypes), - has_fleet_server: isFleetServerPolicy, - }); + const [newAgentPolicy, setNewAgentPolicy] = useState( + generateNewAgentPolicyWithDefaults({ + name: agentPolicyName, + has_fleet_server: isFleetServerPolicy, + }) + ); const updateNewAgentPolicy = useCallback( (updatedFields: Partial) => { diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/dataset_combo.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/dataset_combo.tsx index 15e1a18f26dcd..6908f8fea130f 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/dataset_combo.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/dataset_combo.tsx @@ -9,27 +9,52 @@ import React, { useEffect, useState } from 'react'; import { EuiComboBox } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; +import type { DataStream } from '../../../../../../../../../common/types'; + +interface SelectedDataset { + dataset: string; + package: string; +} + +const GENERIC_DATASET_NAME = 'generic'; + export const DatasetComboBox: React.FC<{ - value: any; - onChange: (newValue: any) => void; - datasets: string[]; + value?: SelectedDataset | string; + onChange: (newValue: SelectedDataset) => void; + datastreams: DataStream[]; + pkgName?: string; isDisabled?: boolean; -}> = ({ value, onChange, datasets, isDisabled }) => { - const datasetOptions = datasets.map((dataset: string) => ({ label: dataset })) ?? []; - const defaultOption = 'generic'; - const [selectedOptions, setSelectedOptions] = useState>([ - { - label: value ?? defaultOption, - }, - ]); +}> = ({ value, onChange, datastreams, isDisabled, pkgName = '' }) => { + const datasetOptions = + datastreams.map((datastream: DataStream) => ({ + label: datastream.dataset, + value: datastream, + })) ?? []; + const existingGenericStream = datasetOptions.find((ds) => ds.label === GENERIC_DATASET_NAME); + const valueAsOption = value + ? typeof value === 'string' + ? { label: value, value: { dataset: value, package: pkgName } } + : { label: value.dataset, value: { dataset: value.dataset, package: value.package } } + : undefined; + const defaultOption = valueAsOption || + existingGenericStream || { + label: GENERIC_DATASET_NAME, + value: { dataset: GENERIC_DATASET_NAME, package: pkgName }, + }; + + const [selectedOptions, setSelectedOptions] = useState>([defaultOption]); useEffect(() => { - if (!value) onChange(defaultOption); - }, [value, defaultOption, onChange]); + if (!value || typeof value === 'string') onChange(defaultOption.value as SelectedDataset); + }, [value, defaultOption.value, onChange, pkgName]); - const onDatasetChange = (newSelectedOptions: Array<{ label: string }>) => { + const onDatasetChange = (newSelectedOptions: Array<{ label: string; value?: DataStream }>) => { setSelectedOptions(newSelectedOptions); - onChange(newSelectedOptions[0]?.label); + const dataStream = newSelectedOptions[0].value; + onChange({ + dataset: newSelectedOptions[0].label, + package: !dataStream || typeof dataStream === 'string' ? pkgName : dataStream.package, + }); }; const onCreateOption = (searchValue: string = '') => { @@ -39,9 +64,13 @@ export const DatasetComboBox: React.FC<{ } const newOption = { label: searchValue, + value: { dataset: searchValue, package: pkgName }, }; setSelectedOptions([newOption]); - onChange(searchValue); + onChange({ + dataset: searchValue, + package: pkgName, + }); }; return ( { - it('should move datasets up that match name', () => { - const datasets = orderDatasets( - ['system.memory', 'elastic_agent', 'elastic_agent.filebeat', 'system.cpu'], - 'elastic_agent' - ); - - expect(datasets).toEqual([ - 'elastic_agent', - 'elastic_agent.filebeat', - 'system.cpu', - 'system.memory', - ]); - }); - - it('should order alphabetically if name does not match', () => { - const datasets = orderDatasets(['system.memory', 'elastic_agent'], 'nginx'); - - expect(datasets).toEqual(['elastic_agent', 'system.memory']); - }); -}); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/order_datasets.ts b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/order_datasets.ts deleted file mode 100644 index 8262af7064142..0000000000000 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/order_datasets.ts +++ /dev/null @@ -1,16 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { partition } from 'lodash'; - -export function orderDatasets(datasetList: string[], name: string): string[] { - const [relevantDatasets, otherDatasets] = partition(datasetList.sort(), (record) => - record.startsWith(name) - ); - const datasets = relevantDatasets.concat(otherDatasets); - return datasets; -} diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_stream.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_stream.tsx index 814d1b47783f3..50b585cac9c89 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_stream.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_stream.tsx @@ -23,7 +23,7 @@ import { useRouteMatch } from 'react-router-dom'; import { useConfig, useGetDataStreams } from '../../../../../../../../hooks'; -import { mapPackageReleaseToIntegrationCardRelease } from '../../../../../../../../services/package_prerelease'; +import { mapPackageReleaseToIntegrationCardRelease } from '../../../../../../../../../common/services'; import type { ExperimentalDataStreamFeature } from '../../../../../../../../../common/types/models/epm'; import type { @@ -42,7 +42,7 @@ import { PackagePolicyEditorDatastreamMappings } from '../../datastream_mappings import { ExperimentDatastreamSettings } from './experimental_datastream_settings'; import { PackagePolicyInputVarField } from './package_policy_input_var_field'; import { useDataStreamId } from './hooks'; -import { orderDatasets } from './order_datasets'; +import { sortDatastreamsByDataset } from './sort_datastreams'; const ScrollAnchor = styled.div` display: none; @@ -144,9 +144,8 @@ export const PackagePolicyInputStreamConfig = memo( ); const { data: dataStreamsData } = useGetDataStreams(); - const datasetList = - uniq(dataStreamsData?.data_streams.map((dataStream) => dataStream.dataset)) ?? []; - const datasets = orderDatasets(datasetList, packageInfo.name); + const datasetList = uniq(dataStreamsData?.data_streams) ?? []; + const datastreams = sortDatastreamsByDataset(datasetList, packageInfo.name); return ( <> @@ -227,7 +226,8 @@ export const PackagePolicyInputStreamConfig = memo( errors={inputStreamValidationResults?.vars![varName]} forceShowErrors={forceShowErrors} packageType={packageInfo.type} - datasets={datasets} + packageName={packageInfo.name} + datastreams={datastreams} isEditPage={isEditPage} /> @@ -289,7 +289,8 @@ export const PackagePolicyInputStreamConfig = memo( errors={inputStreamValidationResults?.vars![varName]} forceShowErrors={forceShowErrors} packageType={packageInfo.type} - datasets={datasets} + packageName={packageInfo.name} + datastreams={datastreams} isEditPage={isEditPage} /> diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_var_field.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_var_field.tsx index 48b67d3078336..3c5115442f44f 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_var_field.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/package_policy_input_var_field.tsx @@ -22,7 +22,7 @@ import styled from 'styled-components'; import { CodeEditor } from '@kbn/kibana-react-plugin/public'; -import type { RegistryVarsEntry } from '../../../../../../types'; +import type { DataStream, RegistryVarsEntry } from '../../../../../../types'; import { MultiTextInput } from './multi_text_input'; import { DatasetComboBox } from './dataset_combo'; @@ -39,7 +39,8 @@ export const PackagePolicyInputVarField: React.FunctionComponent<{ forceShowErrors?: boolean; frozen?: boolean; packageType?: string; - datasets?: string[]; + packageName?: string; + datastreams?: DataStream[]; isEditPage?: boolean; }> = memo( ({ @@ -50,7 +51,8 @@ export const PackagePolicyInputVarField: React.FunctionComponent<{ forceShowErrors, frozen, packageType, - datasets = [], + packageName, + datastreams = [], isEditPage = false, }) => { const [isDirty, setIsDirty] = useState(false); @@ -73,7 +75,8 @@ export const PackagePolicyInputVarField: React.FunctionComponent<{ if (name === 'data_stream.dataset' && packageType === 'input') { return ( ({ dataset } as DataStream); +describe('orderDatasets', () => { + it('should move datasets up that match package name', () => { + const datasets = sortDatastreamsByDataset( + [ds('system.memory'), ds('elastic_agent'), ds('elastic_agent.filebeat'), ds('system.cpu')], + 'elastic_agent' + ); + + expect(datasets).toEqual([ + ds('elastic_agent'), + ds('elastic_agent.filebeat'), + ds('system.cpu'), + ds('system.memory'), + ]); + }); + + it('should order alphabetically if name does not match', () => { + const datasets = sortDatastreamsByDataset([ds('system.memory'), ds('elastic_agent')], 'nginx'); + + expect(datasets).toEqual([ds('elastic_agent'), ds('system.memory')]); + }); +}); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/sort_datastreams.ts b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/sort_datastreams.ts new file mode 100644 index 0000000000000..71ea6ee4b44d6 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/components/steps/components/sort_datastreams.ts @@ -0,0 +1,19 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { partition, sortBy } from 'lodash'; + +import type { DataStream } from '../../../../../../../../../common/types'; + +// sort data streams by dataset name, but promote datastreams that are from this package to the start +export function sortDatastreamsByDataset(datasetList: DataStream[], name: string): DataStream[] { + const [relevantDatasets, otherDatasets] = partition(sortBy(datasetList, 'dataset'), (record) => + record.dataset.startsWith(name) + ); + const datasets = relevantDatasets.concat(otherDatasets); + return datasets; +} diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/components/page_steps/add_integration.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/components/page_steps/add_integration.tsx index cd0164124bfbc..f84d3fbfc2988 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/components/page_steps/add_integration.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/components/page_steps/add_integration.tsx @@ -28,6 +28,7 @@ import type { PackagePolicyValidationResults } from '../../../services'; import { validatePackagePolicy, validationHasErrors } from '../../../services'; import { NotObscuredByBottomBar } from '..'; import { StepConfigurePackagePolicy, StepDefinePackagePolicy } from '../../../components'; +import { prepareInputPackagePolicyDataset } from '../../../services/prepare_input_pkg_policy_dataset'; const ExpandableAdvancedSettings: React.FC = ({ children }) => { const [isShowingAdvanced, setIsShowingAdvanced] = useState(false); @@ -147,7 +148,11 @@ export const AddIntegrationPageStep: React.FC = (props force?: boolean; }) => { setFormState('LOADING'); - const result = await sendCreatePackagePolicy({ ...newPackagePolicy, force }); + const { policy, forceCreateNeeded } = await prepareInputPackagePolicyDataset(newPackagePolicy); + const result = await sendCreatePackagePolicy({ + ...policy, + force: forceCreateNeeded || force, + }); setFormState('SUBMITTED'); return result; }; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/hooks/use_get_agent_policy_or_default.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/hooks/use_get_agent_policy_or_default.tsx index 888c6807976d3..0c51b78c8d1af 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/hooks/use_get_agent_policy_or_default.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/multi_page_layout/hooks/use_get_agent_policy_or_default.tsx @@ -14,6 +14,8 @@ import { sendGetEnrollmentAPIKeys, } from '../../../../../../../hooks'; +import { generateNewAgentPolicyWithDefaults } from '../../../../../../../services'; + import type { AgentPolicy, NewAgentPolicy, EnrollmentAPIKey } from '../../../../../../../types'; interface UseGetAgentPolicyOrDefaultResponse { @@ -24,14 +26,14 @@ interface UseGetAgentPolicyOrDefaultResponse { created?: boolean; } export const DEFAULT_AGENT_POLICY_ID: string = 'fleet-first-agent-policy'; -export const DEFAULT_AGENT_POLICY: NewAgentPolicy = Object.freeze({ - id: DEFAULT_AGENT_POLICY_ID, - name: i18n.translate('xpack.fleet.createPackagePolicy.firstAgentPolicyNameText', { - defaultMessage: 'My first agent policy', - }), - namespace: 'default', - monitoring_enabled: ['logs', 'metrics'] as NewAgentPolicy['monitoring_enabled'], -}); +export const DEFAULT_AGENT_POLICY: NewAgentPolicy = Object.freeze( + generateNewAgentPolicyWithDefaults({ + id: DEFAULT_AGENT_POLICY_ID, + name: i18n.translate('xpack.fleet.createPackagePolicy.firstAgentPolicyNameText', { + defaultMessage: 'My first agent policy', + }), + }) +); const sendGetAgentPolicy = async (agentPolicyId: string) => { let result; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.test.ts b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.test.ts new file mode 100644 index 0000000000000..09e17b744e15c --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.test.ts @@ -0,0 +1,101 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { NewPackagePolicy } from '../../../../types'; + +import { prepareInputPackagePolicyDataset } from './prepare_input_pkg_policy_dataset'; +const customLogsPackagePolicyWithDataset = ( + datasetValue: + | { + dataset: string; + package: string; + } + | string +) => ({ + name: 'custom_logs-1', + description: '', + namespace: 'default', + policy_id: '05034740-9285-11ed-87a3-4ff599bc9864', + enabled: true, + inputs: [ + { + type: 'logfile', + policy_template: 'first_policy_template', + enabled: true, + streams: [ + { + enabled: true, + data_stream: { + type: 'logs', + dataset: 'custom_logs.first_policy_template', + }, + vars: { + paths: { + type: 'text', + value: ['/tmp/test.log'], + }, + tags: { + type: 'text', + value: ['tag1'], + }, + ignore_older: { + value: '72h', + type: 'text', + }, + 'data_stream.dataset': { + type: 'text', + value: datasetValue, + }, + }, + }, + ], + }, + ], + package: { + name: 'custom_logs', + title: 'Custom Logs', + version: '1.1.0', + experimental_data_stream_features: [], + }, +}); + +const expectDatasetVarToEqual = (policy: NewPackagePolicy, expected: any) => + expect(policy?.inputs?.[0]?.streams?.[0]?.vars?.['data_stream.dataset']?.value).toEqual(expected); + +describe('prepareInputPackagePolicyDataset', function () { + it('should do nothing if dataset value is not an object', function () { + const newPolicy = customLogsPackagePolicyWithDataset('generic'); + const result = prepareInputPackagePolicyDataset(newPolicy); + expect(result.forceCreateNeeded).toEqual(false); + expect(result.policy).toEqual(newPolicy); + }); + it('should do nothing if no inputs', function () { + const newPolicy = customLogsPackagePolicyWithDataset('generic'); + newPolicy.inputs = []; + const result = prepareInputPackagePolicyDataset(newPolicy); + expect(result.forceCreateNeeded).toEqual(false); + expect(result.policy).toEqual(newPolicy); + }); + it('should not force create if dataset from same package', function () { + const newPolicy = customLogsPackagePolicyWithDataset({ + dataset: 'generic', + package: 'custom_logs', + }); + const result = prepareInputPackagePolicyDataset(newPolicy); + expect(result.forceCreateNeeded).toEqual(false); + expectDatasetVarToEqual(result.policy, 'generic'); + }); + it('should force create if dataset from different package', function () { + const newPolicy = customLogsPackagePolicyWithDataset({ + dataset: 'generic', + package: 'not_custom_logs', + }); + const result = prepareInputPackagePolicyDataset(newPolicy); + expect(result.forceCreateNeeded).toEqual(true); + expectDatasetVarToEqual(result.policy, 'generic'); + }); +}); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.ts b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.ts new file mode 100644 index 0000000000000..e4f1fae4419c1 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/services/prepare_input_pkg_policy_dataset.ts @@ -0,0 +1,60 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { NewPackagePolicy } from '../../../../types'; + +export function prepareInputPackagePolicyDataset(newPolicy: NewPackagePolicy): { + policy: NewPackagePolicy; + forceCreateNeeded: boolean; +} { + let forceCreateNeeded = false; + const { inputs } = newPolicy; + + if (!inputs || !inputs.length) { + return { policy: newPolicy, forceCreateNeeded: false }; + } + + const newInputs = inputs.map((input) => { + const { streams } = input; + if (!streams) { + return input; + } + + const newStreams = streams.map((stream) => { + if ( + !stream.vars || + !stream.vars['data_stream.dataset'] || + !stream.vars['data_stream.dataset'].value?.package + ) { + return stream; + } + + const datasetVar = stream.vars['data_stream.dataset']; + + forceCreateNeeded = datasetVar.value?.package !== newPolicy?.package?.name; + stream.vars['data_stream.dataset'] = { + ...datasetVar, + value: datasetVar.value?.dataset, + }; + + return stream; + }); + + return { + ...input, + streams: newStreams, + }; + }); + + return { + policy: { + ...newPolicy, + inputs: newInputs, + }, + forceCreateNeeded, + }; +} diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/hooks/form.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/hooks/form.tsx index a1b0e2065b3a5..24277e464582c 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/hooks/form.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/hooks/form.tsx @@ -38,6 +38,7 @@ import type { PackagePolicyValidationResults } from '../../services'; import type { PackagePolicyFormState } from '../../types'; import { SelectedPolicyTab } from '../../components'; import { useOnSaveNavigate } from '../../hooks'; +import { prepareInputPackagePolicyDataset } from '../../services/prepare_input_pkg_policy_dataset'; async function createAgentPolicy({ packagePolicy, @@ -63,7 +64,11 @@ async function createAgentPolicy({ } async function savePackagePolicy(pkgPolicy: CreatePackagePolicyRequest['body']) { - const result = await sendCreatePackagePolicy(pkgPolicy); + const { policy, forceCreateNeeded } = await prepareInputPackagePolicyDataset(pkgPolicy); + const result = await sendCreatePackagePolicy({ + ...policy, + ...(forceCreateNeeded && { force: true }), + }); return result; } diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.test.tsx index 0cdc581260b53..5c80b2276ae09 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.test.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.test.tsx @@ -383,6 +383,7 @@ describe('when on the package policy create page', () => { monitoring_enabled: ['logs', 'metrics'], name: 'Agent policy 2', namespace: 'default', + inactivity_timeout: 1209600, }, { withSysMonitoring: false } ); @@ -413,6 +414,7 @@ describe('when on the package policy create page', () => { monitoring_enabled: ['logs', 'metrics'], name: 'Agent policy 2', namespace: 'default', + inactivity_timeout: 1209600, }, { withSysMonitoring: true } ); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.tsx index 9146dfe36eee0..cd5b997d9c788 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/create_package_policy_page/single_page_layout/index.tsx @@ -25,7 +25,7 @@ import type { EuiStepProps } from '@elastic/eui/src/components/steps/step'; import { useCancelAddPackagePolicy } from '../hooks'; import { splitPkgKey } from '../../../../../../../common/services'; -import { dataTypes } from '../../../../../../../common/constants'; +import { generateNewAgentPolicyWithDefaults } from '../../../../services'; import type { NewAgentPolicy } from '../../../../types'; import { useConfig, sendGetAgentStatus, useGetPackageInfoByKey } from '../../../../hooks'; import { @@ -80,12 +80,9 @@ export const CreatePackagePolicySinglePage: CreatePackagePolicyParams = ({ } = useConfig(); const { params } = useRouteMatch(); - const [newAgentPolicy, setNewAgentPolicy] = useState({ - name: 'Agent policy 1', - description: '', - namespace: 'default', - monitoring_enabled: Object.values(dataTypes), - }); + const [newAgentPolicy, setNewAgentPolicy] = useState( + generateNewAgentPolicyWithDefaults({ name: 'Agent policy 1' }) + ); const [withSysMonitoring, setWithSysMonitoring] = useState(true); const validation = agentPolicyFormValidation(newAgentPolicy); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/list_page/components/create_agent_policy.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/list_page/components/create_agent_policy.tsx index ec1b19679760b..2c48eac8923a8 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/list_page/components/create_agent_policy.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/list_page/components/create_agent_policy.tsx @@ -24,13 +24,15 @@ import { EuiSpacer, } from '@elastic/eui'; -import { dataTypes } from '../../../../../../../common/constants'; import type { NewAgentPolicy, AgentPolicy } from '../../../../types'; import { useAuthz, useStartServices, sendCreateAgentPolicy } from '../../../../hooks'; import { AgentPolicyForm, agentPolicyFormValidation } from '../../components'; import { DevtoolsRequestFlyoutButton } from '../../../../components'; import { generateCreateAgentPolicyDevToolsRequest } from '../../services'; -import { ExperimentalFeaturesService } from '../../../../services'; +import { + ExperimentalFeaturesService, + generateNewAgentPolicyWithDefaults, +} from '../../../../services'; const FlyoutWithHigherZIndex = styled(EuiFlyout)` z-index: ${(props) => props.theme.eui.euiZLevel5}; @@ -47,12 +49,9 @@ export const CreateAgentPolicyFlyout: React.FunctionComponent = ({ }) => { const { notifications } = useStartServices(); const hasFleetAllPrivileges = useAuthz().fleet.all; - const [agentPolicy, setAgentPolicy] = useState({ - name: '', - description: '', - namespace: 'default', - monitoring_enabled: Object.values(dataTypes), - }); + const [agentPolicy, setAgentPolicy] = useState( + generateNewAgentPolicyWithDefaults() + ); const [isLoading, setIsLoading] = useState(false); const [withSysMonitoring, setWithSysMonitoring] = useState(true); const validation = agentPolicyFormValidation(agentPolicy); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/services/devtools_request.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/services/devtools_request.tsx index 51831fdfa6b7c..b9c69d083d21d 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/services/devtools_request.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/services/devtools_request.tsx @@ -105,7 +105,12 @@ function formatVars(vars: NewPackagePolicy['inputs'][number]['vars']) { } return Object.entries(vars).reduce((acc, [varKey, varRecord]) => { - acc[varKey] = varRecord?.value; + // the data_stream.dataset var uses an internal format before we send it + if (varKey === 'data_stream.dataset' && varRecord?.value?.dataset) { + acc[varKey] = varRecord?.value.dataset; + } else { + acc[varKey] = varRecord?.value; + } return acc; }, {} as SimplifiedVars); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.test.tsx new file mode 100644 index 0000000000000..71853b29c3820 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.test.tsx @@ -0,0 +1,111 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React from 'react'; +import { render, act, fireEvent, waitForElementToBeRemoved, waitFor } from '@testing-library/react'; +import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; + +import { AgentStatusFilter } from './agent_status_filter'; + +const PARTIAL_TOUR_TEXT = 'Some agents have become inactive and have been hidden'; + +const renderComponent = (props: React.ComponentProps) => { + return render( + + + + ); +}; + +const mockLocalStorage: Record = {}; +describe('AgentStatusFilter', () => { + beforeEach(() => { + Object.defineProperty(window, 'localStorage', { + value: { + getItem: jest.fn((key) => mockLocalStorage[key]), + setItem: jest.fn((key, val) => (mockLocalStorage[key] = val)), + }, + writable: true, + }); + }); + + it('Renders all statuses', () => { + const { getByText } = renderComponent({ + selectedStatus: [], + onSelectedStatusChange: () => {}, + totalInactiveAgents: 0, + isOpenByDefault: true, + }); + + expect(getByText('Healthy')).toBeInTheDocument(); + expect(getByText('Unhealthy')).toBeInTheDocument(); + expect(getByText('Updating')).toBeInTheDocument(); + expect(getByText('Offline')).toBeInTheDocument(); + expect(getByText('Inactive')).toBeInTheDocument(); + expect(getByText('Unenrolled')).toBeInTheDocument(); + }); + + it('Shows tour and inactive count if first time seeing newly inactive agents', async () => { + const { container, getByText, queryByText } = renderComponent({ + selectedStatus: [], + onSelectedStatusChange: () => {}, + totalInactiveAgents: 999, + }); + + await act(async () => { + expect(getByText(PARTIAL_TOUR_TEXT, { exact: false })).toBeVisible(); + + const statusFilterButton = container.querySelector( + '[data-test-subj="agentList.statusFilter"]' + ); + + expect(statusFilterButton).not.toBeNull(); + + fireEvent.click(statusFilterButton!); + + await waitForElementToBeRemoved(() => queryByText(PARTIAL_TOUR_TEXT, { exact: false })); + + expect(getByText('999')).toBeInTheDocument(); + + expect(mockLocalStorage['fleet.inactiveAgentsCalloutHasBeenDismissed']).toBe('true'); + }); + }); + + it('Should not show tour if previously been dismissed', async () => { + mockLocalStorage['fleet.inactiveAgentsCalloutHasBeenDismissed'] = 'true'; + + const { getByText } = renderComponent({ + selectedStatus: [], + onSelectedStatusChange: () => {}, + totalInactiveAgents: 999, + }); + + await act(async () => { + expect(getByText(PARTIAL_TOUR_TEXT, { exact: false })).not.toBeVisible(); + }); + }); + + it('Should should show difference between last seen inactive agents and total agents', async () => { + mockLocalStorage['fleet.lastSeenInactiveAgentsCount'] = '100'; + + const { getByText, container } = renderComponent({ + selectedStatus: [], + onSelectedStatusChange: () => {}, + totalInactiveAgents: 999, + }); + + await act(async () => { + const statusFilterButton = container.querySelector( + '[data-test-subj="agentList.statusFilter"]' + ); + + expect(statusFilterButton).not.toBeNull(); + fireEvent.click(statusFilterButton!); + + await waitFor(() => expect(getByText('899')).toBeInTheDocument()); + }); + }); +}); diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.tsx new file mode 100644 index 0000000000000..f75fc74d601d6 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_status_filter.tsx @@ -0,0 +1,207 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + EuiFilterButton, + EuiFilterSelectItem, + EuiNotificationBadge, + EuiPopover, + EuiText, + EuiTourStep, +} from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import { FormattedMessage } from '@kbn/i18n-react'; +import React, { useMemo, useState } from 'react'; +import styled from 'styled-components'; + +import { useInactiveAgentsCalloutHasBeenDismissed, useLastSeenInactiveAgentsCount } from '../hooks'; + +const statusFilters = [ + { + status: 'healthy', + label: i18n.translate('xpack.fleet.agentList.statusHealthyFilterText', { + defaultMessage: 'Healthy', + }), + }, + { + status: 'unhealthy', + label: i18n.translate('xpack.fleet.agentList.statusUnhealthyFilterText', { + defaultMessage: 'Unhealthy', + }), + }, + { + status: 'updating', + label: i18n.translate('xpack.fleet.agentList.statusUpdatingFilterText', { + defaultMessage: 'Updating', + }), + }, + { + status: 'offline', + label: i18n.translate('xpack.fleet.agentList.statusOfflineFilterText', { + defaultMessage: 'Offline', + }), + }, + { + status: 'inactive', + label: i18n.translate('xpack.fleet.agentList.statusInactiveFilterText', { + defaultMessage: 'Inactive', + }), + }, + { + status: 'unenrolled', + label: i18n.translate('xpack.fleet.agentList.statusUnenrolledFilterText', { + defaultMessage: 'Unenrolled', + }), + }, +]; + +const LeftpaddedNotificationBadge = styled(EuiNotificationBadge)` + margin-left: 10px; +`; + +const TourStepNoHeaderFooter = styled(EuiTourStep)` + .euiTourFooter { + display: none; + } + .euiTourHeader { + display: none; + } +`; + +const InactiveAgentsTourStep: React.FC<{ isOpen: boolean }> = ({ children, isOpen }) => ( + + + + } + isStepOpen={isOpen} + minWidth={300} + step={1} + stepsTotal={0} + title="" + onFinish={() => {}} + anchorPosition="upCenter" + maxWidth={280} + > + {children as React.ReactElement} + +); + +export const AgentStatusFilter: React.FC<{ + selectedStatus: string[]; + onSelectedStatusChange: (status: string[]) => void; + disabled?: boolean; + totalInactiveAgents: number; + isOpenByDefault?: boolean; +}> = (props) => { + const { + selectedStatus, + onSelectedStatusChange, + disabled, + totalInactiveAgents, + isOpenByDefault = false, + } = props; + const [lastSeenInactiveAgentsCount, setLastSeenInactiveAgentsCount] = + useLastSeenInactiveAgentsCount(); + const [inactiveAgentsCalloutHasBeenDismissed, setInactiveAgentsCalloutHasBeenDismissed] = + useInactiveAgentsCalloutHasBeenDismissed(); + + const newlyInactiveAgentsCount = useMemo(() => { + const newVal = totalInactiveAgents - lastSeenInactiveAgentsCount; + + if (newVal < 0) { + return 0; + } + + return newVal; + }, [lastSeenInactiveAgentsCount, totalInactiveAgents]); + + useMemo(() => { + if (selectedStatus.length && selectedStatus.includes('inactive') && newlyInactiveAgentsCount) { + setLastSeenInactiveAgentsCount(totalInactiveAgents); + } + }, [ + selectedStatus, + newlyInactiveAgentsCount, + setLastSeenInactiveAgentsCount, + totalInactiveAgents, + ]); + + useMemo(() => { + // reduce the number of last seen inactive agents count to the total inactive agents count + // e.g if agents have become healthy again + if (totalInactiveAgents > 0 && lastSeenInactiveAgentsCount > totalInactiveAgents) { + setLastSeenInactiveAgentsCount(totalInactiveAgents); + } + }, [lastSeenInactiveAgentsCount, totalInactiveAgents, setLastSeenInactiveAgentsCount]); + + // Status for filtering + const [isStatusFilterOpen, setIsStatusFilterOpen] = useState(isOpenByDefault); + + const updateIsStatusFilterOpen = (isOpen: boolean) => { + if (isOpen && newlyInactiveAgentsCount > 0 && !inactiveAgentsCalloutHasBeenDismissed) { + setInactiveAgentsCalloutHasBeenDismissed(true); + } + + setIsStatusFilterOpen(isOpen); + }; + return ( + 0 && !inactiveAgentsCalloutHasBeenDismissed} + > + updateIsStatusFilterOpen(!isStatusFilterOpen)} + isSelected={isStatusFilterOpen} + hasActiveFilters={selectedStatus.length > 0} + numActiveFilters={selectedStatus.length} + numFilters={statusFilters.length} + disabled={disabled} + data-test-subj="agentList.statusFilter" + > + + + } + isOpen={isStatusFilterOpen} + closePopover={() => updateIsStatusFilterOpen(false)} + panelPaddingSize="none" + > +
    + {statusFilters.map(({ label, status }, idx) => ( + { + if (selectedStatus.includes(status)) { + onSelectedStatusChange([...selectedStatus.filter((s) => s !== status)]); + } else { + onSelectedStatusChange([...selectedStatus, status]); + } + }} + > + + {label} + {status === 'inactive' && newlyInactiveAgentsCount > 0 && ( + + {newlyInactiveAgentsCount} + + )} + + + ))} +
    +
    +
    + ); +}; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/search_and_filter_bar.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/search_and_filter_bar.tsx index 105fbe9773536..db173776e2458 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/search_and_filter_bar.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/search_and_filter_bar.tsx @@ -18,7 +18,6 @@ import { EuiPopover, EuiToolTip, } from '@elastic/eui'; -import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import styled from 'styled-components'; @@ -31,45 +30,7 @@ import { MAX_TAG_DISPLAY_LENGTH, truncateTag } from '../utils'; import { AgentBulkActions } from './bulk_actions'; import type { SelectionMode } from './types'; import { AgentActivityButton } from './agent_activity_button'; - -const statusFilters = [ - { - status: 'healthy', - label: i18n.translate('xpack.fleet.agentList.statusHealthyFilterText', { - defaultMessage: 'Healthy', - }), - }, - { - status: 'unhealthy', - label: i18n.translate('xpack.fleet.agentList.statusUnhealthyFilterText', { - defaultMessage: 'Unhealthy', - }), - }, - { - status: 'updating', - label: i18n.translate('xpack.fleet.agentList.statusUpdatingFilterText', { - defaultMessage: 'Updating', - }), - }, - { - status: 'offline', - label: i18n.translate('xpack.fleet.agentList.statusOfflineFilterText', { - defaultMessage: 'Offline', - }), - }, - { - status: 'inactive', - label: i18n.translate('xpack.fleet.agentList.statusInactiveFilterText', { - defaultMessage: 'Inactive', - }), - }, - { - status: 'unenrolled', - label: i18n.translate('xpack.fleet.agentList.statusUnenrolledFilterText', { - defaultMessage: 'Unenrolled', - }), - }, -]; +import { AgentStatusFilter } from './agent_status_filter'; const ClearAllTagsFilterItem = styled(EuiFilterSelectItem)` padding: ${(props) => props.theme.eui.euiSizeS}; @@ -133,9 +94,6 @@ export const SearchAndFilterBar: React.FunctionComponent<{ // Policies state for filtering const [isAgentPoliciesFilterOpen, setIsAgentPoliciesFilterOpen] = useState(false); - // Status for filtering - const [isStatusFilterOpen, setIsStatusFilterOpen] = useState(false); - const [isTagsFilterOpen, setIsTagsFilterOpen] = useState(false); // Add a agent policy id to current search @@ -223,47 +181,12 @@ export const SearchAndFilterBar: React.FunctionComponent<{ - setIsStatusFilterOpen(!isStatusFilterOpen)} - isSelected={isStatusFilterOpen} - hasActiveFilters={selectedStatus.length > 0} - numActiveFilters={selectedStatus.length} - numFilters={statusFilters.length} - disabled={agentPolicies.length === 0} - data-test-subj="agentList.statusFilter" - > - - - } - isOpen={isStatusFilterOpen} - closePopover={() => setIsStatusFilterOpen(false)} - panelPaddingSize="none" - > -
    - {statusFilters.map(({ label, status }, idx) => ( - { - if (selectedStatus.includes(status)) { - onSelectedStatusChange([...selectedStatus.filter((s) => s !== status)]); - } else { - onSelectedStatusChange([...selectedStatus, status]); - } - }} - > - {label} - - ))} -
    -
    + void] => { + const [inactiveAgentsCalloutHasBeenDismissed, setInactiveAgentsCalloutHasBeenDismissed] = + useState(false); + + useEffect(() => { + const storageValue = localStorage.getItem(LOCAL_STORAGE_KEY); + if (storageValue) { + setInactiveAgentsCalloutHasBeenDismissed(Boolean(storageValue)); + } + }, []); + + const updateInactiveAgentsCalloutHasBeenDismissed = (newValue: boolean) => { + localStorage.setItem(LOCAL_STORAGE_KEY, newValue.toString()); + setInactiveAgentsCalloutHasBeenDismissed(newValue); + }; + + return [inactiveAgentsCalloutHasBeenDismissed, updateInactiveAgentsCalloutHasBeenDismissed]; +}; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/hooks/use_last_seen_inactive_agents_count.ts b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/hooks/use_last_seen_inactive_agents_count.ts new file mode 100644 index 0000000000000..ce767c82eec37 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/hooks/use_last_seen_inactive_agents_count.ts @@ -0,0 +1,28 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useState, useEffect } from 'react'; + +const LOCAL_STORAGE_KEY = 'fleet.lastSeenInactiveAgentsCount'; + +export const useLastSeenInactiveAgentsCount = (): [number, (val: number) => void] => { + const [lastSeenInactiveAgentsCount, setLastSeenInactiveAgentsCount] = useState(0); + + useEffect(() => { + const storageValue = localStorage.getItem(LOCAL_STORAGE_KEY); + if (storageValue) { + setLastSeenInactiveAgentsCount(parseInt(storageValue, 10)); + } + }, []); + + const updateLastSeenInactiveAgentsCount = (inactiveAgents: number) => { + localStorage.setItem(LOCAL_STORAGE_KEY, inactiveAgents.toString()); + setLastSeenInactiveAgentsCount(inactiveAgents); + }; + + return [lastSeenInactiveAgentsCount, updateLastSeenInactiveAgentsCount]; +}; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.stories.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.stories.tsx index aa472212940a3..1ff0c435693e2 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.stories.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.stories.tsx @@ -45,10 +45,13 @@ const categories = [ export const EmptyList = (props: Args) => ( ); @@ -129,10 +132,13 @@ export const List = (props: Args) => ( categories: ['category_two'], }, ]} - onSearchChange={action('onSearchChange')} - setSelectedCategory={action('setSelectedCategory')} + searchTerm="" + setSearchTerm={action('setSearchTerm')} + setCategory={action('setCategory')} categories={categories} selectedCategory="" + setUrlandReplaceHistory={action('setUrlandReplaceHistory')} + setUrlandPushHistory={action('setUrlandPushHistory')} {...props} /> ); diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.tsx index 4a3fc126cce59..ccb53ac7dc355 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/components/package_list_grid.tsx @@ -7,7 +7,7 @@ import type { ReactNode, FunctionComponent } from 'react'; import { useMemo } from 'react'; -import React, { useCallback, useState, useRef, useEffect } from 'react'; +import React, { useCallback, useState } from 'react'; import { css } from '@emotion/react'; import { @@ -22,6 +22,11 @@ import { useEuiTheme, EuiIcon, EuiScreenReaderOnly, + EuiButton, + EuiButtonIcon, + EuiPopover, + EuiContextMenuPanel, + EuiContextMenuItem, } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; @@ -35,6 +40,10 @@ import type { IntegrationCardItem } from '../../../../../../common/types/models' import type { ExtendedIntegrationCategory, CategoryFacet } from '../screens/home/category_facets'; +import type { IntegrationsURLParameters } from '../screens/home/hooks/use_available_packages'; + +import { ExperimentalFeaturesService } from '../../../services'; + import { promoteFeaturedIntegrations } from './utils'; import { PackageCard } from './package_card'; @@ -42,16 +51,22 @@ import { PackageCard } from './package_card'; export interface Props { isLoading?: boolean; controls?: ReactNode | ReactNode[]; - title?: string; list: IntegrationCardItem[]; - initialSearch?: string; + searchTerm: string; + setSearchTerm: (search: string) => void; selectedCategory: ExtendedIntegrationCategory; - setSelectedCategory: (category: string) => void; + setCategory: (category: ExtendedIntegrationCategory) => void; categories: CategoryFacet[]; - onSearchChange: (search: string) => void; - showMissingIntegrationMessage?: boolean; + setUrlandReplaceHistory: (params: IntegrationsURLParameters) => void; + setUrlandPushHistory: (params: IntegrationsURLParameters) => void; callout?: JSX.Element | null; + // Props used only in AvailablePackages component: showCardLabels?: boolean; + title?: string; + availableSubCategories?: CategoryFacet[]; + selectedSubCategory?: string; + setSelectedSubCategory?: (c: string | undefined) => void; + showMissingIntegrationMessage?: boolean; } export const PackageListGrid: FunctionComponent = ({ @@ -59,43 +74,63 @@ export const PackageListGrid: FunctionComponent = ({ controls, title, list, - initialSearch, - onSearchChange, + searchTerm, + setSearchTerm, selectedCategory, - setSelectedCategory, + setCategory, categories, + availableSubCategories, + setSelectedSubCategory, + selectedSubCategory, + setUrlandReplaceHistory, + setUrlandPushHistory, showMissingIntegrationMessage = false, callout, showCardLabels = true, }) => { - const [searchTerm, setSearchTerm] = useState(initialSearch || ''); const localSearchRef = useLocalSearch(list); - const menuRef = useRef(null); - const [isSticky, setIsSticky] = useState(false); - const [windowScrollY] = useState(window.scrollY); const { euiTheme } = useEuiTheme(); - useEffect(() => { - const menuRefCurrent = menuRef.current; - const onScroll = () => { - if (menuRefCurrent) { - setIsSticky(menuRefCurrent?.getBoundingClientRect().top < 110); - } - }; - window.addEventListener('scroll', onScroll); - return () => window.removeEventListener('scroll', onScroll); - }, [windowScrollY, isSticky]); + const [isPopoverOpen, setPopover] = useState(false); + + const MAX_SUBCATEGORIES_NUMBER = 6; + + const { showIntegrationsSubcategories } = ExperimentalFeaturesService.get(); + + const onButtonClick = () => { + setPopover(!isPopoverOpen); + }; + + const closePopover = () => { + setPopover(false); + }; const onQueryChange = (e: any) => { const queryText = e.target.value; setSearchTerm(queryText); - onSearchChange(queryText); + setUrlandReplaceHistory({ + searchString: queryText, + categoryId: selectedCategory, + subCategoryId: selectedSubCategory, + }); }; const resetQuery = () => { setSearchTerm(''); + setUrlandReplaceHistory({ searchString: '', categoryId: '', subCategoryId: '' }); }; + const onSubCategoryClick = useCallback( + (subCategory: string) => { + if (setSelectedSubCategory) setSelectedSubCategory(subCategory); + setUrlandPushHistory({ + categoryId: selectedCategory, + subCategoryId: subCategory, + }); + }, + [selectedCategory, setSelectedSubCategory, setUrlandPushHistory] + ); + const selectedCategoryTitle = selectedCategory ? categories.find((category) => category.id === selectedCategory)?.title : undefined; @@ -113,116 +148,199 @@ export const PackageListGrid: FunctionComponent = ({ return promoteFeaturedIntegrations(filteredList, selectedCategory); }, [isLoading, list, localSearchRef, searchTerm, selectedCategory]); - const controlsContent = ; - let gridContent: JSX.Element; - - if (isLoading || !localSearchRef.current) { - gridContent = ; - } else { - gridContent = ( - - ); - } + const splitSubcategories = ( + subcategories: CategoryFacet[] | undefined + ): { visibleSubCategories?: CategoryFacet[]; hiddenSubCategories?: CategoryFacet[] } => { + if (!subcategories) return {}; + else if (subcategories && subcategories?.length < MAX_SUBCATEGORIES_NUMBER) { + return { visibleSubCategories: subcategories, hiddenSubCategories: [] }; + } else if (subcategories && subcategories?.length >= MAX_SUBCATEGORIES_NUMBER) { + return { + visibleSubCategories: subcategories.slice(0, MAX_SUBCATEGORIES_NUMBER), + hiddenSubCategories: subcategories.slice(MAX_SUBCATEGORIES_NUMBER), + }; + } + return {}; + }; - return ( - <> -
    - { + return splitSubcat?.hiddenSubCategories?.map((subCategory) => { + return ( + { + onSubCategoryClick(subCategory.id); + closePopover(); + }} > - - {controlsContent} - - - onQueryChange(e)} - isClearable={true} - incremental={true} - fullWidth={true} - prepend={ - selectedCategoryTitle ? ( - + ); + }); + }, [onSubCategoryClick, splitSubcat.hiddenSubCategories]); + + return ( + + + + + + onQueryChange(e)} + isClearable={true} + incremental={true} + fullWidth={true} + prepend={ + selectedCategoryTitle ? ( + + + Searching category: + + {selectedCategoryTitle} + - - ) : undefined - } - /> - {callout ? ( - <> - - {callout} - + /> + + + ) : undefined + } + /> + {showIntegrationsSubcategories && availableSubCategories?.length ? : null} + {showIntegrationsSubcategories ? ( + + {visibleSubCategories?.map((subCategory) => ( + + onSubCategoryClick(subCategory.id)} + > + + + + ))} + {hiddenSubCategoriesItems?.length ? ( + + + } + isOpen={isPopoverOpen} + closePopover={closePopover} + panelPaddingSize="none" + anchorPosition="downLeft" + > + + + ) : null} + + ) : null} + {callout ? ( + <> - {gridContent} - {showMissingIntegrationMessage && ( - <> - - - - )} - - -
    - + {callout} + + ) : null} + + + {showMissingIntegrationMessage && ( + <> + + + + + )} +
    +
    ); }; interface ControlsColumnProps { controls: ReactNode; title: string | undefined; - sticky: boolean; } -function ControlsColumn({ controls, title, sticky }: ControlsColumnProps) { +const ControlsColumn = ({ controls, title }: ControlsColumnProps) => { let titleContent; if (title) { titleContent = ( @@ -235,24 +353,28 @@ function ControlsColumn({ controls, title, sticky }: ControlsColumnProps) { ); } return ( - + {titleContent} {controls} ); -} +}; interface GridColumnProps { list: IntegrationCardItem[]; + isLoading: boolean; showMissingIntegrationMessage?: boolean; showCardLabels?: boolean; } -function GridColumn({ +const GridColumn = ({ list, showMissingIntegrationMessage = false, showCardLabels = false, -}: GridColumnProps) { + isLoading, +}: GridColumnProps) => { + if (isLoading) return ; + return ( {list.length ? ( @@ -294,21 +416,27 @@ function GridColumn({ )} ); -} +}; interface MissingIntegrationContentProps { resetQuery: () => void; - setSelectedCategory: (category: string) => void; + setSelectedCategory: (category: ExtendedIntegrationCategory) => void; + setUrlandPushHistory: (params: IntegrationsURLParameters) => void; } -function MissingIntegrationContent({ +const MissingIntegrationContent = ({ resetQuery, setSelectedCategory, -}: MissingIntegrationContentProps) { + setUrlandPushHistory, +}: MissingIntegrationContentProps) => { const handleCustomInputsLinkClick = useCallback(() => { resetQuery(); setSelectedCategory('custom'); - }, [resetQuery, setSelectedCategory]); + setUrlandPushHistory({ + categoryId: 'custom', + subCategoryId: '', + }); + }, [resetQuery, setSelectedCategory, setUrlandPushHistory]); return ( @@ -338,4 +466,4 @@ function MissingIntegrationContent({

    ); -} +}; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/index.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/index.tsx index b18e0b49d2445..dafe901121c54 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/index.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/index.tsx @@ -25,9 +25,11 @@ import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import semverLt from 'semver/functions/lt'; -import { getPackageReleaseLabel } from '../../../../../../services/package_prerelease'; - -import { splitPkgKey } from '../../../../../../../common/services'; +import { + getPackageReleaseLabel, + isPackagePrerelease, + splitPkgKey, +} from '../../../../../../../common/services'; import { HIDDEN_API_REFERENCE_PACKAGES } from '../../../../../../../common/constants'; import { @@ -42,7 +44,7 @@ import { useGetSettings, } from '../../../../hooks'; import { INTEGRATIONS_ROUTING_PATHS } from '../../../../constants'; -import { ExperimentalFeaturesService, isPackagePrerelease } from '../../../../services'; +import { ExperimentalFeaturesService } from '../../../../services'; import { useGetPackageInfoByKey, useLink, diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/overview/overview.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/overview/overview.tsx index 21b3fd0f4f11c..53806c5b4d98c 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/overview/overview.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/overview/overview.tsx @@ -10,10 +10,13 @@ import { EuiCallOut, EuiFlexGroup, EuiFlexItem, EuiSpacer, EuiLink, EuiButton } import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; -import { isIntegrationPolicyTemplate } from '../../../../../../../../common/services'; +import { + isIntegrationPolicyTemplate, + isPackagePrerelease, +} from '../../../../../../../../common/services'; import { useFleetStatus, useLink, useStartServices } from '../../../../../../../hooks'; -import { isPackagePrerelease, isPackageUnverified } from '../../../../../../../services'; +import { isPackageUnverified } from '../../../../../../../services'; import type { PackageInfo, RegistryPolicyTemplate } from '../../../../../types'; import { Screenshots } from './screenshots'; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/available_packages.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/available_packages.tsx index a763d26e2821b..95d89491c620a 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/available_packages.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/available_packages.tsx @@ -6,48 +6,26 @@ */ import type { FunctionComponent } from 'react'; -import React, { useMemo, useState } from 'react'; -import { useLocation, useHistory, useParams } from 'react-router-dom'; -import _ from 'lodash'; +import React from 'react'; import { i18n } from '@kbn/i18n'; import { FormattedMessage } from '@kbn/i18n-react'; import { EuiHorizontalRule, EuiFlexItem, EuiCallOut, EuiLink } from '@elastic/eui'; -import type { CustomIntegration } from '@kbn/custom-integrations-plugin/common'; +import { useStartServices } from '../../../../hooks'; -import { - isInputOnlyPolicyTemplate, - isIntegrationPolicyTemplate, -} from '../../../../../../../common/services'; +import { useBreadcrumbs } from '../../../../hooks'; -import { useCategories, usePackages, useStartServices } from '../../../../hooks'; - -import { pagePathGetters } from '../../../../constants'; -import { - useBreadcrumbs, - useGetAppendCustomIntegrations, - useGetReplacementCustomIntegrations, - useLink, -} from '../../../../hooks'; -import { doesPackageHaveIntegrations } from '../../../../services'; -import type { PackageList } from '../../../../types'; import { PackageListGrid } from '../../components/package_list_grid'; -import type { PackageListItem } from '../../../../types'; - -import type { IntegrationCardItem } from '../../../../../../../common/types/models'; +import { IntegrationPreference } from '../../components/integration_preference'; -import { useMergeEprPackagesWithReplacements } from '../../../../hooks/use_merge_epr_with_replacements'; +import { CategoryFacets } from './category_facets'; -import type { IntegrationPreferenceType } from '../../components/integration_preference'; -import { IntegrationPreference } from '../../components/integration_preference'; +import { categoryExists } from '.'; -import { mergeCategoriesAndCount } from './util'; -import { ALL_CATEGORY, CategoryFacets } from './category_facets'; -import type { CategoryFacet, ExtendedIntegrationCategory } from './category_facets'; +import { useAvailablePackages } from './hooks/use_available_packages'; -import type { CategoryParams } from '.'; -import { getParams, categoryExists, mapToCard } from '.'; +import type { ExtendedIntegrationCategory } from './category_facets'; const NoEprCallout: FunctionComponent<{ statusCode?: number }> = ({ statusCode, @@ -119,180 +97,35 @@ function OnPremLink() { ); } -function getAllCategoriesFromIntegrations(pkg: PackageListItem) { - if (!doesPackageHaveIntegrations(pkg)) { - return pkg.categories; - } - - const allCategories = pkg.policy_templates?.reduce((accumulator, policyTemplate) => { - if (isInputOnlyPolicyTemplate(policyTemplate)) { - // input only policy templates do not have categories - return accumulator; - } - return [...accumulator, ...(policyTemplate.categories || [])]; - }, pkg.categories || []); - - return _.uniq(allCategories); -} - -// Packages can export multiple integrations, aka `policy_templates` -// In the case where packages ship >1 `policy_templates`, we flatten out the -// list of packages by bringing all integrations to top-level so that -// each integration is displayed as its own tile -const packageListToIntegrationsList = (packages: PackageList): PackageList => { - return packages.reduce((acc: PackageList, pkg) => { - const { - policy_templates: policyTemplates = [], - categories: topCategories = [], - ...restOfPackage - } = pkg; - - const topPackage = { - ...restOfPackage, - categories: getAllCategoriesFromIntegrations(pkg), - }; - - return [ - ...acc, - topPackage, - ...(doesPackageHaveIntegrations(pkg) - ? policyTemplates.map((policyTemplate) => { - const { name, title, description, icons } = policyTemplate; - - const categories = - isIntegrationPolicyTemplate(policyTemplate) && policyTemplate.categories - ? policyTemplate.categories - : []; - const allCategories = [...topCategories, ...categories]; - return { - ...restOfPackage, - id: `${restOfPackage.id}-${name}`, - integration: name, - title, - description, - icons: icons || restOfPackage.icons, - categories: _.uniq(allCategories), - }; - }) - : []), - ]; - }, []); -}; - -// TODO: clintandrewhall - this component is hard to test due to the hooks, particularly those that use `http` -// or `location` to load data. Ideally, we'll split this into "connected" and "pure" components. export const AvailablePackages: React.FC<{}> = ({}) => { - const [preference, setPreference] = useState('recommended'); - const [prereleaseIntegrationsEnabled, setPrereleaseIntegrationsEnabled] = React.useState< - boolean | undefined - >(undefined); - useBreadcrumbs('integrations_all'); - const { http } = useStartServices(); - const addBasePath = http.basePath.prepend; - - const { selectedCategory, searchParam } = getParams( - useParams(), - useLocation().search - ); - const [category, setCategory] = useState(selectedCategory); - - const history = useHistory(); - const { getHref, getAbsolutePath } = useLink(); - - function setUrlCategory(categoryId: string) { - setCategory(categoryId as ExtendedIntegrationCategory); - - const url = pagePathGetters.integrations_all({ - category: categoryId, - searchTerm: searchParam, - })[1]; - history.push(url); - } - - function setUrlSearchTerm(search: string) { - // Use .replace so the browser's back button is not tied to single keystroke - history.replace(pagePathGetters.integrations_all({ searchTerm: search, category })[1]); - } - - const { - data: eprPackages, - isLoading: isLoadingAllPackages, - error: eprPackageLoadingError, - } = usePackages(prereleaseIntegrationsEnabled); - - // Remove Kubernetes package granularity - if (eprPackages?.items) { - eprPackages.items.forEach(function (element) { - if (element.id === 'kubernetes') { - element.policy_templates = []; - } - }); - } - - const eprIntegrationList = useMemo( - () => packageListToIntegrationsList(eprPackages?.items || []), - [eprPackages] - ); - const { value: replacementCustomIntegrations } = useGetReplacementCustomIntegrations(); - - const { loading: isLoadingAppendCustomIntegrations, value: appendCustomIntegrations } = - useGetAppendCustomIntegrations(); - - const mergedEprPackages: Array = - useMergeEprPackagesWithReplacements( - preference === 'beats' ? [] : eprIntegrationList, - preference === 'agent' ? [] : replacementCustomIntegrations || [] - ); - const cards: IntegrationCardItem[] = useMemo(() => { - const eprAndCustomPackages = [...mergedEprPackages, ...(appendCustomIntegrations || [])]; - - return eprAndCustomPackages - .map((item) => { - return mapToCard({ getAbsolutePath, getHref, item, addBasePath }); - }) - .sort((a, b) => a.title.localeCompare(b.title)); - }, [addBasePath, appendCustomIntegrations, getAbsolutePath, getHref, mergedEprPackages]); - - const filteredCards = useMemo( - () => - cards.filter((c) => { - if (category === '') { - return true; - } - - return c.categories.includes(category); - }), - [cards, category] - ); - const { - data: eprCategories, - isLoading: isLoadingCategories, - error: eprCategoryLoadingError, - } = useCategories(prereleaseIntegrationsEnabled); - - const categories: CategoryFacet[] = useMemo(() => { - const eprAndCustomCategories: CategoryFacet[] = isLoadingCategories - ? [] - : mergeCategoriesAndCount( - eprCategories - ? (eprCategories.items as Array<{ id: string; title: string; count: number }>) - : [], - cards - ); - return [ - { - ...ALL_CATEGORY, - count: cards.length, - }, - ...(eprAndCustomCategories ? eprAndCustomCategories : []), - ]; - }, [cards, eprCategories, isLoadingCategories]); - - if (!isLoadingCategories && !categoryExists(selectedCategory, categories)) { - history.replace(pagePathGetters.integrations_all({ category: '', searchTerm: searchParam })[1]); + initialSelectedCategory, + selectedCategory, + setCategory, + allCategories, + mainCategories, + preference, + setPreference, + isLoadingCategories, + isLoadingAllPackages, + isLoadingAppendCustomIntegrations, + eprPackageLoadingError, + eprCategoryLoadingError, + searchTerm, + setSearchTerm, + setUrlandPushHistory, + setUrlandReplaceHistory, + filteredCards, + setPrereleaseIntegrationsEnabled, + availableSubCategories, + selectedSubCategory, + setSelectedSubCategory, + } = useAvailablePackages(); + + if (!isLoadingCategories && !categoryExists(initialSelectedCategory, allCategories)) { + setUrlandReplaceHistory({ searchString: searchTerm, categoryId: '', subCategoryId: '' }); return null; } @@ -309,17 +142,20 @@ export const AvailablePackages: React.FC<{}> = ({}) => { , ]; - if (categories) { + if (mainCategories) { controls = [ { - setUrlCategory(id); + setCategory(id as ExtendedIntegrationCategory); + setSearchTerm(''); + setSelectedSubCategory(undefined); + setUrlandPushHistory({ searchString: '', categoryId: id, subCategoryId: '' }); }} /> , @@ -337,15 +173,20 @@ export const AvailablePackages: React.FC<{}> = ({}) => { ); }; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/category_facets.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/category_facets.tsx index 9f88e2c391b3d..b74ee96929968 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/category_facets.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/category_facets.tsx @@ -17,6 +17,8 @@ export interface CategoryFacet { count: number; id: string; title: string; + parent_id?: string; + parent_title?: string; } export const UPDATES_AVAILABLE = 'updates_available'; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/hooks/use_available_packages.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/hooks/use_available_packages.tsx new file mode 100644 index 0000000000000..c1190a66c7034 --- /dev/null +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/hooks/use_available_packages.tsx @@ -0,0 +1,282 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useState, useMemo } from 'react'; +import { useLocation, useParams, useHistory } from 'react-router-dom'; + +import { uniq, xorBy } from 'lodash'; + +import type { CustomIntegration } from '@kbn/custom-integrations-plugin/common'; + +import type { IntegrationPreferenceType } from '../../../components/integration_preference'; +import { usePackages, useCategories, useStartServices } from '../../../../../hooks'; +import { + useGetAppendCustomIntegrations, + useGetReplacementCustomIntegrations, + useLink, +} from '../../../../../hooks'; +import { useMergeEprPackagesWithReplacements } from '../../../../../hooks/use_merge_epr_with_replacements'; + +import type { CategoryParams } from '..'; +import { getParams, mapToCard } from '..'; +import type { PackageList, PackageListItem } from '../../../../../types'; + +import { doesPackageHaveIntegrations } from '../../../../../services'; + +import { + isInputOnlyPolicyTemplate, + isIntegrationPolicyTemplate, +} from '../../../../../../../../common/services'; + +import { pagePathGetters } from '../../../../../constants'; + +import type { IntegrationCardItem } from '../../../../../../../../common/types/models'; + +import { ALL_CATEGORY } from '../category_facets'; +import type { CategoryFacet } from '../category_facets'; + +import { mergeCategoriesAndCount } from '../util'; + +export interface IntegrationsURLParameters { + searchString?: string; + categoryId?: string; + subCategoryId?: string; +} + +function getAllCategoriesFromIntegrations(pkg: PackageListItem) { + if (!doesPackageHaveIntegrations(pkg)) { + return pkg.categories; + } + + const allCategories = pkg.policy_templates?.reduce((accumulator, policyTemplate) => { + if (isInputOnlyPolicyTemplate(policyTemplate)) { + // input only policy templates do not have categories + return accumulator; + } + return [...accumulator, ...(policyTemplate.categories || [])]; + }, pkg.categories || []); + + return uniq(allCategories); +} + +// Packages can export multiple integrations, aka `policy_templates` +// In the case where packages ship >1 `policy_templates`, we flatten out the +// list of packages by bringing all integrations to top-level so that +// each integration is displayed as its own tile +const packageListToIntegrationsList = (packages: PackageList): PackageList => { + return packages.reduce((acc: PackageList, pkg) => { + const { + policy_templates: policyTemplates = [], + categories: topCategories = [], + ...restOfPackage + } = pkg; + + const topPackage = { + ...restOfPackage, + categories: getAllCategoriesFromIntegrations(pkg), + }; + + return [ + ...acc, + topPackage, + ...(doesPackageHaveIntegrations(pkg) + ? policyTemplates.map((policyTemplate) => { + const { name, title, description, icons } = policyTemplate; + + const categories = + isIntegrationPolicyTemplate(policyTemplate) && policyTemplate.categories + ? policyTemplate.categories + : []; + const allCategories = [...topCategories, ...categories]; + return { + ...restOfPackage, + id: `${restOfPackage.id}-${name}`, + integration: name, + title, + description, + icons: icons || restOfPackage.icons, + categories: uniq(allCategories), + }; + }) + : []), + ]; + }, []); +}; + +export const useAvailablePackages = () => { + const [preference, setPreference] = useState('recommended'); + const [prereleaseIntegrationsEnabled, setPrereleaseIntegrationsEnabled] = React.useState< + boolean | undefined + >(undefined); + const { http } = useStartServices(); + const addBasePath = http.basePath.prepend; + + const { + selectedCategory: initialSelectedCategory, + selectedSubcategory: initialSubcategory, + searchParam, + } = getParams(useParams(), useLocation().search); + + const [selectedCategory, setCategory] = useState(initialSelectedCategory); + const [selectedSubCategory, setSelectedSubCategory] = useState( + initialSubcategory + ); + const [searchTerm, setSearchTerm] = useState(searchParam || ''); + + const { getHref, getAbsolutePath } = useLink(); + const history = useHistory(); + + const buildUrl = ({ searchString, categoryId, subCategoryId }: IntegrationsURLParameters) => { + const url = pagePathGetters.integrations_all({ + category: categoryId ? categoryId : '', + subCategory: subCategoryId ? subCategoryId : '', + searchTerm: searchString ? searchString : '', + })[1]; + return url; + }; + + const setUrlandPushHistory = ({ + searchString, + categoryId, + subCategoryId, + }: IntegrationsURLParameters) => { + const url = buildUrl({ + categoryId, + searchString, + subCategoryId, + }); + history.push(url); + }; + + const setUrlandReplaceHistory = ({ + searchString, + categoryId, + subCategoryId, + }: IntegrationsURLParameters) => { + const url = buildUrl({ + categoryId, + searchString, + subCategoryId, + }); + // Use .replace so the browser's back button is not tied to single keystroke + history.replace(url); + }; + + const { + data: eprPackages, + isLoading: isLoadingAllPackages, + error: eprPackageLoadingError, + } = usePackages(prereleaseIntegrationsEnabled); + + // Remove Kubernetes package granularity + if (eprPackages?.items) { + eprPackages.items.forEach(function (element) { + if (element.id === 'kubernetes') { + element.policy_templates = []; + } + }); + } + + const eprIntegrationList = useMemo( + () => packageListToIntegrationsList(eprPackages?.items || []), + [eprPackages] + ); + const { value: replacementCustomIntegrations } = useGetReplacementCustomIntegrations(); + + const { loading: isLoadingAppendCustomIntegrations, value: appendCustomIntegrations } = + useGetAppendCustomIntegrations(); + + const mergedEprPackages: Array = + useMergeEprPackagesWithReplacements( + preference === 'beats' ? [] : eprIntegrationList, + preference === 'agent' ? [] : replacementCustomIntegrations || [] + ); + + const cards: IntegrationCardItem[] = useMemo(() => { + const eprAndCustomPackages = [...mergedEprPackages, ...(appendCustomIntegrations || [])]; + + return eprAndCustomPackages + .map((item) => { + return mapToCard({ getAbsolutePath, getHref, item, addBasePath }); + }) + .sort((a, b) => a.title.localeCompare(b.title)); + }, [addBasePath, appendCustomIntegrations, getAbsolutePath, getHref, mergedEprPackages]); + + // Packages to show + // Filters out based on selected category and subcategory (if any) + const filteredCards = useMemo( + () => + cards.filter((c) => { + if (selectedCategory === '') { + return true; + } + if (!selectedSubCategory) return c.categories.includes(selectedCategory); + + return c.categories.includes(selectedSubCategory); + }), + [cards, selectedCategory, selectedSubCategory] + ); + + const { + data: eprCategories, + isLoading: isLoadingCategories, + error: eprCategoryLoadingError, + } = useCategories(prereleaseIntegrationsEnabled); + + // Subcategories + const subCategories = useMemo(() => { + return eprCategories?.items.filter((item) => item.parent_id !== undefined); + }, [eprCategories?.items]); + + const allCategories: CategoryFacet[] = useMemo(() => { + const eprAndCustomCategories: CategoryFacet[] = isLoadingCategories + ? [] + : mergeCategoriesAndCount( + eprCategories + ? (eprCategories.items as Array<{ id: string; title: string; count: number }>) + : [], + cards + ); + return [ + { + ...ALL_CATEGORY, + count: cards.length, + }, + ...(eprAndCustomCategories ? eprAndCustomCategories : []), + ]; + }, [cards, eprCategories, isLoadingCategories]); + + // Filter out subcategories + const mainCategories = xorBy(allCategories, subCategories, 'id'); + + const availableSubCategories = useMemo(() => { + return subCategories?.filter((c) => c.parent_id === selectedCategory); + }, [selectedCategory, subCategories]); + + return { + initialSelectedCategory, + selectedCategory, + setCategory, + allCategories, + mainCategories, + availableSubCategories, + selectedSubCategory, + setSelectedSubCategory, + searchTerm, + setSearchTerm, + setUrlandPushHistory, + setUrlandReplaceHistory, + preference, + setPreference, + isLoadingCategories, + isLoadingAllPackages, + isLoadingAppendCustomIntegrations, + eprPackageLoadingError, + eprCategoryLoadingError, + filteredCards, + setPrereleaseIntegrationsEnabled, + }; +}; diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/index.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/index.tsx index ea6e1ad3d0e12..7b0431a1cd618 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/index.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/index.tsx @@ -10,7 +10,7 @@ import { Switch, Route } from 'react-router-dom'; import type { CustomIntegration } from '@kbn/custom-integrations-plugin/common'; -import { getPackageReleaseLabel } from '../../../../../../services/package_prerelease'; +import { getPackageReleaseLabel } from '../../../../../../../common/services'; import { installationStatuses } from '../../../../../../../common/constants'; @@ -35,14 +35,15 @@ import { AvailablePackages } from './available_packages'; export interface CategoryParams { category?: ExtendedIntegrationCategory; + subcategory?: string; } export const getParams = (params: CategoryParams, search: string) => { - const { category } = params; + const { category, subcategory } = params; const selectedCategory: ExtendedIntegrationCategory = category || ''; const queryParams = new URLSearchParams(search); const searchParam = queryParams.get(INTEGRATIONS_SEARCH_QUERYPARAM) || ''; - return { selectedCategory, searchParam }; + return { selectedCategory, searchParam, selectedSubcategory: subcategory }; }; export const categoryExists = (category: string, categories: CategoryFacet[]) => { diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/installed_packages.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/installed_packages.tsx index 679c9763d4735..695646d20f6a6 100644 --- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/installed_packages.tsx +++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/home/installed_packages.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import React, { useMemo } from 'react'; +import React, { useMemo, useState } from 'react'; import { useLocation, useHistory, useParams } from 'react-router-dom'; import semverLt from 'semver/functions/lt'; import { i18n } from '@kbn/i18n'; @@ -19,7 +19,9 @@ import { PackageListGrid } from '../../components/package_list_grid'; import type { PackageListItem } from '../../../../types'; -import type { CategoryFacet } from './category_facets'; +import type { IntegrationsURLParameters } from './hooks/use_available_packages'; + +import type { CategoryFacet, ExtendedIntegrationCategory } from './category_facets'; import { CategoryFacets } from './category_facets'; import type { CategoryParams } from '.'; @@ -113,8 +115,6 @@ const VerificationWarningCallout: React.FC = () => { ); }; -// TODO: clintandrewhall - this component is hard to test due to the hooks, particularly those that use `http` -// or `location` to load data. Ideally, we'll split this into "connected" and "pure" components. export const InstalledPackages: React.FC<{ installedPackages: PackageListItem[]; isLoading: boolean; @@ -125,34 +125,42 @@ export const InstalledPackages: React.FC<{ const { getHref, getAbsolutePath } = useLink(); - const { selectedCategory, searchParam } = getParams( + const { selectedCategory: initialSelectedCategory, searchParam } = getParams( useParams(), useLocation().search ); + const [selectedCategory, setCategory] = useState(initialSelectedCategory); + const [searchTerm, setSearchTerm] = useState(searchParam || ''); const { http } = useStartServices(); const addBasePath = http.basePath.prepend; const history = useHistory(); - function setUrlCategory(categoryId: string) { + const buildUrl = ({ searchString, categoryId, subCategoryId }: IntegrationsURLParameters) => { const url = pagePathGetters.integrations_installed({ - category: categoryId, - searchTerm: searchParam, + category: categoryId ? categoryId : '', + query: searchString ? searchString : '', })[1]; - + return url; + }; + + const setUrlandPushHistory = ({ searchString, categoryId }: IntegrationsURLParameters) => { + const url = buildUrl({ + categoryId, + searchString, + }); history.push(url); - } + }; - function setUrlSearchTerm(search: string) { + const setUrlandReplaceHistory = ({ searchString, categoryId }: IntegrationsURLParameters) => { + const url = buildUrl({ + categoryId, + searchString, + }); // Use .replace so the browser's back button is not tied to single keystroke - history.replace( - pagePathGetters.integrations_installed({ - searchTerm: search, - selectedCategory, - })[1] - ); - } + history.replace(url); + }; const updatablePackages = useMemo( () => @@ -178,10 +186,7 @@ export const InstalledPackages: React.FC<{ ); if (!categoryExists(selectedCategory, categories)) { - history.replace( - pagePathGetters.integrations_installed({ category: '', searchTerm: searchParam })[1] - ); - + setUrlandReplaceHistory({ searchString: searchTerm, categoryId: '' }); return null; } @@ -189,7 +194,11 @@ export const InstalledPackages: React.FC<{ setUrlCategory(id)} + onCategoryChange={({ id }: CategoryFacet) => { + setCategory(id as ExtendedIntegrationCategory); + setSearchTerm(''); + setUrlandPushHistory({ searchString: '', categoryId: id }); + }} /> ); @@ -221,9 +230,11 @@ export const InstalledPackages: React.FC<{ ); diff --git a/x-pack/plugins/fleet/public/constants/page_paths.ts b/x-pack/plugins/fleet/public/constants/page_paths.ts index 4966583891f08..3146bdce90150 100644 --- a/x-pack/plugins/fleet/public/constants/page_paths.ts +++ b/x-pack/plugins/fleet/public/constants/page_paths.ts @@ -91,7 +91,7 @@ export const FLEET_ROUTING_PATHS = { export const INTEGRATIONS_SEARCH_QUERYPARAM = 'q'; export const INTEGRATIONS_ROUTING_PATHS = { integrations: '/:tabId', - integrations_all: '/browse/:category?', + integrations_all: '/browse/:category?/:subcategory?', integrations_installed: '/installed/:category?', integrations_installed_updates_available: '/installed/updates_available/:category?', integration_details: '/detail/:pkgkey/:panel?', @@ -114,8 +114,21 @@ export const pagePathGetters: { base: () => [FLEET_BASE_PATH, '/'], overview: () => [FLEET_BASE_PATH, '/'], integrations: () => [INTEGRATIONS_BASE_PATH, '/'], - integrations_all: ({ searchTerm, category }: { searchTerm?: string; category?: string }) => { - const categoryPath = category ? `/${category}` : ``; + integrations_all: ({ + searchTerm, + category, + subCategory, + }: { + searchTerm?: string; + category?: string; + subCategory?: string; + }) => { + const categoryPath = + category && subCategory + ? `/${category}/${subCategory} ` + : category && !subCategory + ? `/${category}` + : ``; const queryParams = searchTerm ? `?${INTEGRATIONS_SEARCH_QUERYPARAM}=${searchTerm}` : ``; return [INTEGRATIONS_BASE_PATH, `/browse${categoryPath}${queryParams}`]; }, diff --git a/x-pack/plugins/fleet/public/services/generate_new_agent_policy.test.ts b/x-pack/plugins/fleet/public/services/generate_new_agent_policy.test.ts new file mode 100644 index 0000000000000..5cd6c5d144019 --- /dev/null +++ b/x-pack/plugins/fleet/public/services/generate_new_agent_policy.test.ts @@ -0,0 +1,39 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { generateNewAgentPolicyWithDefaults } from './generate_new_agent_policy'; + +describe('generateNewAgentPolicyWithDefaults', () => { + it('should generate a new agent policy with defaults', () => { + const newAgentPolicy = generateNewAgentPolicyWithDefaults(); + + expect(newAgentPolicy).toEqual({ + name: '', + description: '', + namespace: 'default', + monitoring_enabled: ['logs', 'metrics'], + inactivity_timeout: 1209600, + }); + }); + + it('should override defaults', () => { + const newAgentPolicy = generateNewAgentPolicyWithDefaults({ + name: 'test', + description: 'test description', + namespace: 'test-namespace', + monitoring_enabled: ['logs'], + }); + + expect(newAgentPolicy).toEqual({ + name: 'test', + description: 'test description', + namespace: 'test-namespace', + monitoring_enabled: ['logs'], + inactivity_timeout: 1209600, + }); + }); +}); diff --git a/x-pack/plugins/fleet/public/services/generate_new_agent_policy.ts b/x-pack/plugins/fleet/public/services/generate_new_agent_policy.ts new file mode 100644 index 0000000000000..94fdf5f26632c --- /dev/null +++ b/x-pack/plugins/fleet/public/services/generate_new_agent_policy.ts @@ -0,0 +1,26 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { dataTypes } from '../../common/constants'; + +import type { NewAgentPolicy } from '../types'; + +const TWO_WEEKS_SECONDS = 1209600; +// create a new agent policy with the defaults set +// used by forms which create new agent policies for initial state value +export function generateNewAgentPolicyWithDefaults( + overrideProps: Partial = {} +): NewAgentPolicy { + return { + name: '', + description: '', + namespace: 'default', + monitoring_enabled: Object.values(dataTypes), + inactivity_timeout: TWO_WEEKS_SECONDS, + ...overrideProps, + }; +} diff --git a/x-pack/plugins/fleet/public/services/index.ts b/x-pack/plugins/fleet/public/services/index.ts index 7f29e0ba452da..ad5dab5d5868d 100644 --- a/x-pack/plugins/fleet/public/services/index.ts +++ b/x-pack/plugins/fleet/public/services/index.ts @@ -48,4 +48,4 @@ export { pkgKeyFromPackageInfo } from './pkg_key_from_package_info'; export { createExtensionRegistrationCallback } from './ui_extensions'; export { incrementPolicyName } from './increment_policy_name'; export { policyHasFleetServer } from './has_fleet_server'; -export { isPackagePrerelease } from './package_prerelease'; +export { generateNewAgentPolicyWithDefaults } from './generate_new_agent_policy'; diff --git a/x-pack/plugins/fleet/scripts/create_agents/create_agents.ts b/x-pack/plugins/fleet/scripts/create_agents/create_agents.ts index db7c404324a38..4b47b56d9a48d 100644 --- a/x-pack/plugins/fleet/scripts/create_agents/create_agents.ts +++ b/x-pack/plugins/fleet/scripts/create_agents/create_agents.ts @@ -6,7 +6,7 @@ */ import fetch from 'node-fetch'; import { ToolingLog } from '@kbn/tooling-log'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import yargs from 'yargs'; import type { AgentStatus } from '../../common'; @@ -147,7 +147,7 @@ function createAgentWithStatus({ version, }, }, - host: { hostname: uuid() }, + host: { hostname: uuidv4() }, }, user_provided_metadata: {}, enrolled_at: new Date().toISOString(), @@ -316,7 +316,7 @@ export async function run() { logger.info('Creating agent policy'); - const agentPolicyId = 'script-create-agent-' + uuid(); + const agentPolicyId = 'script-create-agent-' + uuidv4(); const agentPolicy = await createAgentPolicy(agentPolicyId); logger.info(`Created agent policy ${agentPolicy.item.id}`); diff --git a/x-pack/plugins/fleet/server/collectors/register.ts b/x-pack/plugins/fleet/server/collectors/register.ts index 820a51f7f29fc..de199234693ec 100644 --- a/x-pack/plugins/fleet/server/collectors/register.ts +++ b/x-pack/plugins/fleet/server/collectors/register.ts @@ -19,7 +19,6 @@ import type { PackageUsage } from './package_collectors'; import { getFleetServerUsage, getFleetServerConfig } from './fleet_server_collector'; import type { FleetServerUsage } from './fleet_server_collector'; import { getAgentPoliciesUsage } from './agent_policies'; -import { getAgentLogsTopErrors } from './agent_logs'; export interface Usage { agents_enabled: boolean; @@ -40,8 +39,8 @@ export interface FleetUsage extends Usage { degraded: number; }; agents_per_policy: number[]; - agent_logs_top_errors: string[]; - fleet_server_logs_top_errors: string[]; + agent_logs_top_errors?: string[]; + fleet_server_logs_top_errors?: string[]; } export const fetchFleetUsage = async ( @@ -61,7 +60,8 @@ export const fetchFleetUsage = async ( ...(await getAgentData(esClient, abortController)), fleet_server_config: await getFleetServerConfig(soClient), agent_policies: await getAgentPoliciesUsage(esClient, abortController), - ...(await getAgentLogsTopErrors(esClient)), + // TODO removed top errors telemetry as it causes this issue: https://github.com/elastic/kibana/issues/148976 + // ...(await getAgentLogsTopErrors(esClient)), }; return usage; }; diff --git a/x-pack/plugins/fleet/server/integration_tests/fleet_usage_telemetry.test.ts b/x-pack/plugins/fleet/server/integration_tests/fleet_usage_telemetry.test.ts index e6a55e0585af9..d662f28300020 100644 --- a/x-pack/plugins/fleet/server/integration_tests/fleet_usage_telemetry.test.ts +++ b/x-pack/plugins/fleet/server/integration_tests/fleet_usage_telemetry.test.ts @@ -286,8 +286,8 @@ describe('fleet usage telemetry', () => { ], }, agent_policies: { count: 3, output_types: ['elasticsearch'] }, - agent_logs_top_errors: ['stderr panic close of closed channel'], - fleet_server_logs_top_errors: ['failed to unenroll offline agents'], + // agent_logs_top_errors: ['stderr panic close of closed channel'], + // fleet_server_logs_top_errors: ['failed to unenroll offline agents'], }) ); }); diff --git a/x-pack/plugins/fleet/server/integration_tests/upgrade_agent_policy_schema_version.test.ts b/x-pack/plugins/fleet/server/integration_tests/upgrade_agent_policy_schema_version.test.ts index 277339a6ee0d8..00701e141d8c6 100644 --- a/x-pack/plugins/fleet/server/integration_tests/upgrade_agent_policy_schema_version.test.ts +++ b/x-pack/plugins/fleet/server/integration_tests/upgrade_agent_policy_schema_version.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import type { KibanaRequest, @@ -143,7 +143,7 @@ describe('upgrade agent policy schema version', () => { // up-to-date schema_version { type: AGENT_POLICY_SAVED_OBJECT_TYPE, - id: uuid(), + id: uuidv4(), attributes: { schema_version: FLEET_AGENT_POLICIES_SCHEMA_VERSION, revision: 1, @@ -152,7 +152,7 @@ describe('upgrade agent policy schema version', () => { // out-of-date schema_version { type: AGENT_POLICY_SAVED_OBJECT_TYPE, - id: uuid(), + id: uuidv4(), attributes: { schema_version: '0.0.1', revision: 1, @@ -161,7 +161,7 @@ describe('upgrade agent policy schema version', () => { // missing schema_version { type: AGENT_POLICY_SAVED_OBJECT_TYPE, - id: uuid(), + id: uuidv4(), attributes: { revision: 1, }, diff --git a/x-pack/plugins/fleet/server/routes/data_streams/handlers.ts b/x-pack/plugins/fleet/server/routes/data_streams/handlers.ts index 274ab22999ff8..e6e497991ca82 100644 --- a/x-pack/plugins/fleet/server/routes/data_streams/handlers.ts +++ b/x-pack/plugins/fleet/server/routes/data_streams/handlers.ts @@ -12,11 +12,10 @@ import { KibanaSavedObjectType } from '../../../common/types'; import type { GetDataStreamsResponse } from '../../../common/types'; import { getPackageSavedObjects } from '../../services/epm/packages/get'; import { defaultFleetErrorHandler } from '../../errors'; +import { dataStreamService } from '../../services/data_streams'; import { getDataStreamsQueryMetadata } from './get_data_streams_query_metadata'; -const DATA_STREAM_INDEX_PATTERN = 'logs-*-*,metrics-*-*,traces-*-*,synthetics-*-*'; - interface ESDataStreamInfo { name: string; timestamp_field: { @@ -49,13 +48,9 @@ export const getListHandler: RequestHandler = async (context, request, response) try { // Get matching data streams, their stats, and package SOs - const [ - { data_streams: dataStreamsInfo }, - { data_streams: dataStreamStats }, - packageSavedObjects, - ] = await Promise.all([ - esClient.indices.getDataStream({ name: DATA_STREAM_INDEX_PATTERN }), - esClient.indices.dataStreamsStats({ name: DATA_STREAM_INDEX_PATTERN, human: true }), + const [dataStreamsInfo, dataStreamStats, packageSavedObjects] = await Promise.all([ + dataStreamService.getAllFleetDataStreams(esClient), + dataStreamService.getAllFleetDataStreamsStats(esClient), getPackageSavedObjects(savedObjects.client), ]); diff --git a/x-pack/plugins/fleet/server/routes/epm/handlers.ts b/x-pack/plugins/fleet/server/routes/epm/handlers.ts index 702b70bee117b..d0fef5e241708 100644 --- a/x-pack/plugins/fleet/server/routes/epm/handlers.ts +++ b/x-pack/plugins/fleet/server/routes/epm/handlers.ts @@ -33,7 +33,7 @@ import type { InstallPackageFromRegistryRequestSchema, InstallPackageByUploadRequestSchema, DeletePackageRequestSchema, - BulkUpgradePackagesFromRegistryRequestSchema, + BulkInstallPackagesFromRegistryRequestSchema, GetStatsRequestSchema, FleetRequestHandler, UpdatePackageRequestSchema, @@ -273,7 +273,7 @@ export const getStatsHandler: FleetRequestHandler< export const installPackageFromRegistryHandler: FleetRequestHandler< TypeOf, - undefined, + TypeOf, TypeOf > = async (context, request, response) => { const coreContext = await context.core; @@ -291,6 +291,7 @@ export const installPackageFromRegistryHandler: FleetRequestHandler< spaceId, force: request.body?.force, ignoreConstraints: request.body?.ignore_constraints, + prerelease: request.query?.prerelease, }); if (!res.error) { @@ -323,8 +324,8 @@ const bulkInstallServiceResponseToHttpEntry = ( export const bulkInstallPackagesFromRegistryHandler: FleetRequestHandler< undefined, - TypeOf, - TypeOf + TypeOf, + TypeOf > = async (context, request, response) => { const coreContext = await context.core; const fleetContext = await context.fleet; @@ -337,6 +338,7 @@ export const bulkInstallPackagesFromRegistryHandler: FleetRequestHandler< packagesToInstall: request.body.packages, spaceId, prerelease: request.query.prerelease, + force: request.body.force, }); const payload = bulkInstalledResponses.map(bulkInstallServiceResponseToHttpEntry); const body: BulkInstallPackagesResponse = { diff --git a/x-pack/plugins/fleet/server/routes/epm/index.ts b/x-pack/plugins/fleet/server/routes/epm/index.ts index fecf49471c97d..950dca7009355 100644 --- a/x-pack/plugins/fleet/server/routes/epm/index.ts +++ b/x-pack/plugins/fleet/server/routes/epm/index.ts @@ -35,7 +35,7 @@ import { InstallPackageByUploadRequestSchema, DeletePackageRequestSchema, DeletePackageRequestSchemaDeprecated, - BulkUpgradePackagesFromRegistryRequestSchema, + BulkInstallPackagesFromRegistryRequestSchema, GetStatsRequestSchema, UpdatePackageRequestSchema, UpdatePackageRequestSchemaDeprecated, @@ -149,7 +149,7 @@ export const registerRoutes = (router: FleetAuthzRouter) => { router.post( { path: EPM_API_ROUTES.BULK_INSTALL_PATTERN, - validate: BulkUpgradePackagesFromRegistryRequestSchema, + validate: BulkInstallPackagesFromRegistryRequestSchema, fleetAuthz: { integrations: { installPackages: true, upgradePackages: true }, }, @@ -244,7 +244,11 @@ export const registerRoutes = (router: FleetAuthzRouter) => { }, }, async (context, request, response) => { - const newRequest = { ...request, params: splitPkgKey(request.params.pkgkey) } as any; + const newRequest = { + ...request, + params: splitPkgKey(request.params.pkgkey), + query: request.query, + } as any; const resp: IKibanaResponse = await installPackageFromRegistryHandler( context, newRequest, diff --git a/x-pack/plugins/fleet/server/services/agent_policy.ts b/x-pack/plugins/fleet/server/services/agent_policy.ts index ea8b3ff572e32..1e529aa732412 100644 --- a/x-pack/plugins/fleet/server/services/agent_policy.ts +++ b/x-pack/plugins/fleet/server/services/agent_policy.ts @@ -6,7 +6,7 @@ */ import { omit, isEqual, keyBy, groupBy } from 'lodash'; -import uuidv5 from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import { safeDump } from 'js-yaml'; import pMap from 'p-map'; import { lt } from 'semver'; @@ -1042,7 +1042,7 @@ class AgentPolicyService { type: SAVED_OBJECT_TYPE, page: 1, perPage: SO_SEARCH_LIMIT, - filter: `${SAVED_OBJECT_TYPE}.attributes.inactivity_timeout: *`, + filter: `${SAVED_OBJECT_TYPE}.attributes.inactivity_timeout > 0`, fields: [`inactivity_timeout`], }); diff --git a/x-pack/plugins/fleet/server/services/agents/action_runner.ts b/x-pack/plugins/fleet/server/services/agents/action_runner.ts index b29083dc7c5b2..cba8f677c8b0f 100644 --- a/x-pack/plugins/fleet/server/services/agents/action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/action_runner.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SortResults } from '@elastic/elasticsearch/lib/api/types'; import type { ElasticsearchClient, SavedObjectsClientContract } from '@kbn/core/server'; import { withSpan } from '@kbn/apm-utils'; @@ -59,7 +59,7 @@ export abstract class ActionRunner { ) { this.esClient = esClient; this.soClient = soClient; - this.actionParams = { ...actionParams, actionId: actionParams.actionId ?? uuid() }; + this.actionParams = { ...actionParams, actionId: actionParams.actionId ?? uuidv4() }; this.retryParams = retryParams; } diff --git a/x-pack/plugins/fleet/server/services/agents/actions.ts b/x-pack/plugins/fleet/server/services/agents/actions.ts index 025e71b8376b7..76fcaac7086d5 100644 --- a/x-pack/plugins/fleet/server/services/agents/actions.ts +++ b/x-pack/plugins/fleet/server/services/agents/actions.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ElasticsearchClient, SavedObjectsClientContract } from '@kbn/core/server'; import { appContextService } from '../app_context'; @@ -32,7 +32,7 @@ export async function createAgentAction( esClient: ElasticsearchClient, newAgentAction: NewAgentAction ): Promise { - const actionId = newAgentAction.id ?? uuid.v4(); + const actionId = newAgentAction.id ?? uuidv4(); const timestamp = new Date().toISOString(); const body: FleetServerAgentAction = { '@timestamp': timestamp, @@ -52,7 +52,7 @@ export async function createAgentAction( await esClient.create({ index: AGENT_ACTIONS_INDEX, - id: uuid.v4(), + id: uuidv4(), body, refresh: 'wait_for', }); @@ -69,7 +69,7 @@ export async function bulkCreateAgentActions( newAgentActions: NewAgentAction[] ): Promise { const actions = newAgentActions.map((newAgentAction) => { - const id = newAgentAction.id ?? uuid.v4(); + const id = newAgentAction.id ?? uuidv4(); return { id, ...newAgentAction, @@ -157,7 +157,7 @@ export async function bulkCreateAgentActionResults( return [ { create: { - _id: uuid.v4(), + _id: uuidv4(), }, }, body, @@ -254,7 +254,7 @@ export async function cancelAgentAction(esClient: ElasticsearchClient, actionId: throw new AgentActionNotFoundError('Action not found'); } - const cancelActionId = uuid.v4(); + const cancelActionId = uuidv4(); const now = new Date().toISOString(); for (const hit of res.hits.hits) { if (!hit._source || !hit._source.agents || !hit._source.action_id) { diff --git a/x-pack/plugins/fleet/server/services/agents/reassign_action_runner.ts b/x-pack/plugins/fleet/server/services/agents/reassign_action_runner.ts index c15857bb4ae32..cf6e3988e7bef 100644 --- a/x-pack/plugins/fleet/server/services/agents/reassign_action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/reassign_action_runner.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SavedObjectsClientContract, ElasticsearchClient } from '@kbn/core/server'; import type { Agent } from '../../types'; @@ -84,7 +84,7 @@ export async function reassignBatch( errors ); - const actionId = options.actionId ?? uuid(); + const actionId = options.actionId ?? uuidv4(); const total = options.total ?? givenAgents.length; const now = new Date().toISOString(); diff --git a/x-pack/plugins/fleet/server/services/agents/request_diagnostics_action_runner.ts b/x-pack/plugins/fleet/server/services/agents/request_diagnostics_action_runner.ts index 4b3cca06d061c..9728afedbb028 100644 --- a/x-pack/plugins/fleet/server/services/agents/request_diagnostics_action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/request_diagnostics_action_runner.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ElasticsearchClient } from '@kbn/core/server'; import type { Agent } from '../../types'; @@ -38,7 +38,7 @@ export async function requestDiagnosticsBatch( ): Promise<{ actionId: string }> { const now = new Date().toISOString(); - const actionId = options.actionId ?? uuid(); + const actionId = options.actionId ?? uuidv4(); const total = options.total ?? givenAgents.length; const agentIds = givenAgents.map((agent) => agent.id); diff --git a/x-pack/plugins/fleet/server/services/agents/status.ts b/x-pack/plugins/fleet/server/services/agents/status.ts index 77babf8c8c19c..d05d972925eb5 100644 --- a/x-pack/plugins/fleet/server/services/agents/status.ts +++ b/x-pack/plugins/fleet/server/services/agents/status.ts @@ -108,7 +108,7 @@ export async function getAgentStatusForAgentPolicy( }, }); } catch (error) { - logger.warn(`Error getting agent statuses: ${error}`); + logger.debug(`Error getting agent statuses: ${error}`); throw error; } diff --git a/x-pack/plugins/fleet/server/services/agents/unenroll.ts b/x-pack/plugins/fleet/server/services/agents/unenroll.ts index a82c0f41589b3..f13a8f91d81e9 100644 --- a/x-pack/plugins/fleet/server/services/agents/unenroll.ts +++ b/x-pack/plugins/fleet/server/services/agents/unenroll.ts @@ -7,7 +7,7 @@ import type { ElasticsearchClient, SavedObjectsClientContract } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Agent } from '../../types'; import { HostedAgentPolicyRestrictionRelatedError } from '../../errors'; @@ -119,5 +119,5 @@ export async function forceUnenrollAgent( active: false, unenrolled_at: new Date().toISOString(), }); - await updateActionsForForceUnenroll(esClient, [agent.id], uuid(), 1); + await updateActionsForForceUnenroll(esClient, [agent.id], uuidv4(), 1); } diff --git a/x-pack/plugins/fleet/server/services/agents/unenroll_action_runner.ts b/x-pack/plugins/fleet/server/services/agents/unenroll_action_runner.ts index 1b17e688a8a26..359b016bd1b8c 100644 --- a/x-pack/plugins/fleet/server/services/agents/unenroll_action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/unenroll_action_runner.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SavedObjectsClientContract, ElasticsearchClient } from '@kbn/core/server'; import { intersection } from 'lodash'; @@ -95,7 +95,7 @@ export async function unenrollBatch( outgoingErrors ); - const actionId = options.actionId ?? uuid(); + const actionId = options.actionId ?? uuidv4(); const total = options.total ?? givenAgents.length; const agentIds = agentsToUpdate.map((agent) => agent.id); diff --git a/x-pack/plugins/fleet/server/services/agents/update_agent_tags_action_runner.ts b/x-pack/plugins/fleet/server/services/agents/update_agent_tags_action_runner.ts index 8abab53e66272..9c87259452493 100644 --- a/x-pack/plugins/fleet/server/services/agents/update_agent_tags_action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/update_agent_tags_action_runner.ts @@ -6,7 +6,7 @@ */ import type { SavedObjectsClientContract, ElasticsearchClient } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { uniq } from 'lodash'; import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; @@ -133,15 +133,15 @@ export async function updateTagsBatch( refresh: true, wait_for_completion: true, script: { - source: ` + source: ` if (ctx._source.tags == null) { ctx._source.tags = []; } - if (params.tagsToAdd.length == 1 && params.tagsToRemove.length == 1) { + if (params.tagsToAdd.length == 1 && params.tagsToRemove.length == 1) { ctx._source.tags.replaceAll(tag -> params.tagsToRemove[0] == tag ? params.tagsToAdd[0] : tag); } else { ctx._source.tags.removeAll(params.tagsToRemove); - } + } ctx._source.tags.addAll(params.tagsToAdd); LinkedHashSet uniqueSet = new LinkedHashSet(); @@ -166,7 +166,7 @@ export async function updateTagsBatch( appContextService.getLogger().debug(JSON.stringify(res).slice(0, 1000)); - const actionId = options.actionId ?? uuid(); + const actionId = options.actionId ?? uuidv4(); if (options.retryCount === undefined) { // creating an action doc so that update tags shows up in activity @@ -180,7 +180,7 @@ export async function updateTagsBatch( } // creating unique ids to use as agentId, as we don't have all agent ids in case of action by kuery - const getUuidArray = (count: number) => Array.from({ length: count }, () => uuid()); + const getUuidArray = (count: number) => Array.from({ length: count }, () => uuidv4()); // writing successful action results if (res.updated ?? 0 > 0) { diff --git a/x-pack/plugins/fleet/server/services/agents/upgrade_action_runner.ts b/x-pack/plugins/fleet/server/services/agents/upgrade_action_runner.ts index 2473705f131f9..501afe0d54043 100644 --- a/x-pack/plugins/fleet/server/services/agents/upgrade_action_runner.ts +++ b/x-pack/plugins/fleet/server/services/agents/upgrade_action_runner.ts @@ -7,7 +7,7 @@ import type { SavedObjectsClientContract, ElasticsearchClient } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import moment from 'moment'; import { isAgentUpgradeable } from '../../../common/services'; @@ -120,7 +120,7 @@ export async function upgradeBatch( errors ); - const actionId = options.actionId ?? uuid(); + const actionId = options.actionId ?? uuidv4(); const total = options.total ?? givenAgents.length; await createAgentAction(esClient, { diff --git a/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts b/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts index 4ef3a009c5d94..dadb41a27aac1 100644 --- a/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts +++ b/x-pack/plugins/fleet/server/services/api_keys/enrollment_api_key.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import Boom from '@hapi/boom'; import { i18n } from '@kbn/i18n'; import { errors } from '@elastic/elasticsearch'; @@ -161,7 +161,7 @@ export async function generateEnrollmentAPIKey( forceRecreate?: boolean; } ): Promise { - const id = uuid.v4(); + const id = uuidv4(); const { name: providedKeyName, forceRecreate } = data; if (data.agentPolicyId) { await validateAgentPolicyId(soClient, data.agentPolicyId); diff --git a/x-pack/plugins/fleet/server/services/data_streams.ts b/x-pack/plugins/fleet/server/services/data_streams.ts new file mode 100644 index 0000000000000..aef5ee1e6570e --- /dev/null +++ b/x-pack/plugins/fleet/server/services/data_streams.ts @@ -0,0 +1,78 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { IndicesDataStream, IndicesIndexTemplate } from '@elastic/elasticsearch/lib/api/types'; +import type { ElasticsearchClient } from '@kbn/core/server'; + +const DATA_STREAM_INDEX_PATTERN = 'logs-*-*,metrics-*-*,traces-*-*,synthetics-*-*'; + +class DataStreamService { + public async getAllFleetDataStreams(esClient: ElasticsearchClient) { + const { data_streams: dataStreamsInfo } = await esClient.indices.getDataStream({ + name: DATA_STREAM_INDEX_PATTERN, + }); + + return dataStreamsInfo; + } + + public async getAllFleetDataStreamsStats(esClient: ElasticsearchClient) { + const { data_streams: dataStreamStats } = await esClient.indices.dataStreamsStats({ + name: DATA_STREAM_INDEX_PATTERN, + human: true, + }); + + return dataStreamStats; + } + + public streamPartsToIndexPattern({ type, dataset }: { dataset: string; type: string }) { + return `${type}-${dataset}-*`; + } + + public async getMatchingDataStreams( + esClient: ElasticsearchClient, + dataStreamParts: { + dataset: string; + type: string; + } + ): Promise { + try { + const { data_streams: dataStreamsInfo } = await esClient.indices.getDataStream({ + name: this.streamPartsToIndexPattern(dataStreamParts), + }); + + return dataStreamsInfo; + } catch (e) { + if (e.statusCode === 404) { + return []; + } + throw e; + } + } + + public async getMatchingIndexTemplate( + esClient: ElasticsearchClient, + dataStreamParts: { + dataset: string; + type: string; + } + ): Promise { + try { + const { index_templates: indexTemplates } = await esClient.indices.getIndexTemplate({ + name: `${dataStreamParts.type}-${dataStreamParts.dataset}`, + }); + + return indexTemplates[0]?.index_template; + } catch (e) { + if (e.statusCode === 404) { + return null; + } + throw e; + } + } +} + +export const dataStreamService = new DataStreamService(); diff --git a/x-pack/plugins/fleet/server/services/epm/archive/extract.ts b/x-pack/plugins/fleet/server/services/epm/archive/extract.ts index 03caf8901f40b..84c2457f4dafe 100644 --- a/x-pack/plugins/fleet/server/services/epm/archive/extract.ts +++ b/x-pack/plugins/fleet/server/services/epm/archive/extract.ts @@ -5,6 +5,8 @@ * 2.0. */ +import { finished } from 'stream/promises'; + import tar from 'tar'; import yauzl from 'yauzl'; @@ -16,19 +18,20 @@ export async function untarBuffer( buffer: Buffer, filter = (entry: ArchiveEntry): boolean => true, onEntry = (entry: ArchiveEntry): void => {} -): Promise { +) { const deflatedStream = bufferToStream(buffer); // use tar.list vs .extract to avoid writing to disk - const inflateStream = tar.list().on('entry', (entry: tar.FileStat) => { - const path = entry.header.path || ''; + const inflateStream = tar.list().on('entry', (entry) => { + const path = entry.path || ''; if (!filter({ path })) return; - streamToBuffer(entry).then((entryBuffer) => onEntry({ buffer: entryBuffer, path })); + streamToBuffer(entry as unknown as NodeJS.ReadableStream).then((entryBuffer) => + onEntry({ buffer: entryBuffer, path }) + ); }); - return new Promise((resolve, reject) => { - inflateStream.on('end', resolve).on('error', reject); - deflatedStream.pipe(inflateStream); - }); + deflatedStream.pipe(inflateStream); + + await finished(inflateStream); } export async function unzipBuffer( diff --git a/x-pack/plugins/fleet/server/services/epm/archive/parse.test.ts b/x-pack/plugins/fleet/server/services/epm/archive/parse.test.ts index 32393eebd12e5..27c2baf656791 100644 --- a/x-pack/plugins/fleet/server/services/epm/archive/parse.test.ts +++ b/x-pack/plugins/fleet/server/services/epm/archive/parse.test.ts @@ -4,7 +4,11 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import { parseDefaultIngestPipeline, parseDataStreamElasticsearchEntry } from './parse'; +import { + parseDefaultIngestPipeline, + parseDataStreamElasticsearchEntry, + parseTopLevelElasticsearchEntry, +} from './parse'; describe('parseDefaultIngestPipeline', () => { it('Should return undefined for stream without any elasticsearch dir', () => { expect( @@ -142,3 +146,89 @@ describe('parseDataStreamElasticsearchEntry', () => { }); }); }); + +describe('parseTopLevelElasticsearchEntry', () => { + it('Should handle undefined elasticsearch', () => { + expect(parseTopLevelElasticsearchEntry()).toEqual({}); + }); + it('Should handle empty elasticsearch', () => { + expect(parseTopLevelElasticsearchEntry({})).toEqual({}); + }); + it('Should not include junk keys', () => { + expect(parseTopLevelElasticsearchEntry({ a: 1, b: 2 })).toEqual({}); + }); + it('Should add privileges', () => { + expect( + parseTopLevelElasticsearchEntry({ privileges: { index: ['priv1'], cluster: ['priv2'] } }) + ).toEqual({ privileges: { index: ['priv1'], cluster: ['priv2'] } }); + }); + it('Should add index_template mappings and expand dots', () => { + expect( + parseTopLevelElasticsearchEntry({ + index_template: { mappings: { dynamic: false, something: { 'dot.somethingelse': 'val' } } }, + }) + ).toEqual({ + 'index_template.mappings': { dynamic: false, something: { dot: { somethingelse: 'val' } } }, + }); + }); + it('Should add index_template settings and expand dots', () => { + expect( + parseTopLevelElasticsearchEntry({ + index_template: { + settings: { + index: { + codec: 'best_compression', + 'sort.field': 'monitor.id', + }, + }, + }, + }) + ).toEqual({ + 'index_template.settings': { + index: { + codec: 'best_compression', + sort: { field: 'monitor.id' }, + }, + }, + }); + }); + it('Should handle dotted values for mappings and settings', () => { + expect( + parseTopLevelElasticsearchEntry({ + 'index_template.mappings': { dynamic: false }, + 'index_template.settings': { 'index.lifecycle.name': 'reference' }, + }) + ).toEqual({ + 'index_template.mappings': { dynamic: false }, + 'index_template.settings': { 'index.lifecycle.name': 'reference' }, + }); + }); + it('Should handle non-dotted values for privileges', () => { + expect( + parseTopLevelElasticsearchEntry({ + privileges: { + indices: ['read'], + cluster: ['test'], + }, + }) + ).toEqual({ + privileges: { + indices: ['read'], + cluster: ['test'], + }, + }); + }); + it('Should handle dotted values for privileges', () => { + expect( + parseTopLevelElasticsearchEntry({ + 'privileges.indices': ['read'], + 'privileges.cluster': ['test'], + }) + ).toEqual({ + privileges: { + indices: ['read'], + cluster: ['test'], + }, + }); + }); +}); diff --git a/x-pack/plugins/fleet/server/services/epm/archive/parse.ts b/x-pack/plugins/fleet/server/services/epm/archive/parse.ts index 80642496c4fb8..3e3329e49a59a 100644 --- a/x-pack/plugins/fleet/server/services/epm/archive/parse.ts +++ b/x-pack/plugins/fleet/server/services/epm/archive/parse.ts @@ -117,6 +117,7 @@ const optionalArchivePackageProps: readonly OptionalPackageProp[] = [ 'icons', 'policy_templates', 'release', + 'elasticsearch', ] as const; const registryInputProps = Object.values(RegistryInputKeys); @@ -214,6 +215,9 @@ function parseAndVerifyArchive( // at least have all required properties // get optional values and combine into one object for the remaining operations const optGiven = pick(manifest, optionalArchivePackageProps); + if (optGiven.elasticsearch) { + optGiven.elasticsearch = parseTopLevelElasticsearchEntry(optGiven.elasticsearch); + } const parsed: ArchivePackage = { ...reqGiven, ...optGiven }; // Package name and version from the manifest must match those from the toplevel directory @@ -561,6 +565,28 @@ export function parseDataStreamElasticsearchEntry( return parsedElasticsearchEntry; } +export function parseTopLevelElasticsearchEntry(elasticsearch?: Record) { + const parsedElasticsearchEntry: Record = {}; + const expandedElasticsearch = expandDottedObject(elasticsearch); + + if (expandedElasticsearch?.privileges) { + parsedElasticsearchEntry.privileges = expandedElasticsearch.privileges; + } + + if (expandedElasticsearch?.index_template?.mappings) { + parsedElasticsearchEntry['index_template.mappings'] = expandDottedEntries( + expandedElasticsearch.index_template.mappings + ); + } + + if (expandedElasticsearch?.index_template?.settings) { + parsedElasticsearchEntry['index_template.settings'] = expandDottedEntries( + expandedElasticsearch.index_template.settings + ); + } + return parsedElasticsearchEntry; +} + const isDefaultPipelineFile = (pipelinePath: string) => pipelinePath.endsWith(DEFAULT_INGEST_PIPELINE_FILE_NAME_YML) || pipelinePath.endsWith(DEFAULT_INGEST_PIPELINE_FILE_NAME_JSON); diff --git a/x-pack/plugins/fleet/server/services/epm/archive/storage.ts b/x-pack/plugins/fleet/server/services/epm/archive/storage.ts index 3b6f38971eff7..3ecdcdaad8aa7 100644 --- a/x-pack/plugins/fleet/server/services/epm/archive/storage.ts +++ b/x-pack/plugins/fleet/server/services/epm/archive/storage.ts @@ -11,7 +11,7 @@ import { uniq } from 'lodash'; import { safeLoad } from 'js-yaml'; import { isBinaryFile } from 'isbinaryfile'; import mime from 'mime-types'; -import uuidv5 from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import type { SavedObjectsClientContract, SavedObjectsBulkCreateObject } from '@kbn/core/server'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; @@ -28,7 +28,11 @@ import { appContextService } from '../../app_context'; import { getArchiveEntry, setArchiveEntry, setArchiveFilelist, setPackageInfo } from '.'; import type { ArchiveEntry } from '.'; -import { parseAndVerifyPolicyTemplates, parseAndVerifyStreams } from './parse'; +import { + parseAndVerifyPolicyTemplates, + parseAndVerifyStreams, + parseTopLevelElasticsearchEntry, +} from './parse'; const ONE_BYTE = 1024 * 1024; // could be anything, picked this from https://github.com/elastic/elastic-agent-client/issues/17 @@ -230,7 +234,9 @@ export const getEsPackage = async ( assetPathToObjectId(manifestPath) ); const packageInfo = safeLoad(soResManifest.attributes.data_utf8); - + if (packageInfo.elasticsearch) { + packageInfo.elasticsearch = parseTopLevelElasticsearchEntry(packageInfo.elasticsearch); + } try { const readmePath = `docs/README.md`; await savedObjectsClient.get( diff --git a/x-pack/plugins/fleet/server/services/epm/elasticsearch/ingest_pipeline/install.ts b/x-pack/plugins/fleet/server/services/epm/elasticsearch/ingest_pipeline/install.ts index 7ada81c26c926..5e063e26c6a63 100644 --- a/x-pack/plugins/fleet/server/services/epm/elasticsearch/ingest_pipeline/install.ts +++ b/x-pack/plugins/fleet/server/services/epm/elasticsearch/ingest_pipeline/install.ts @@ -9,7 +9,12 @@ import type { TransportRequestOptions } from '@elastic/elasticsearch'; import type { ElasticsearchClient, Logger } from '@kbn/core/server'; import { ElasticsearchAssetType } from '../../../../types'; -import type { EsAssetReference, RegistryDataStream, InstallablePackage } from '../../../../types'; +import type { + EsAssetReference, + RegistryDataStream, + InstallablePackage, + PackageInfo, +} from '../../../../types'; import { getAsset, getPathParts } from '../../archive'; import type { ArchiveEntry } from '../../archive'; import { @@ -34,8 +39,9 @@ import { import type { PipelineInstall, RewriteSubstitution } from './types'; export const prepareToInstallPipelines = ( - installablePackage: InstallablePackage, - paths: string[] + installablePackage: InstallablePackage | PackageInfo, + paths: string[], + onlyForDataStreams?: RegistryDataStream[] ): { assetsToAdd: EsAssetReference[]; install: (esClient: ElasticsearchClient, logger: Logger) => Promise; @@ -43,7 +49,7 @@ export const prepareToInstallPipelines = ( // unlike other ES assets, pipeline names are versioned so after a template is updated // it can be created pointing to the new template, without removing the old one and effecting data // so do not remove the currently installed pipelines here - const dataStreams = installablePackage.data_streams; + const dataStreams = onlyForDataStreams || installablePackage.data_streams; const { version: pkgVersion } = installablePackage; const pipelinePaths = paths.filter((path) => isPipeline(path)); const topLevelPipelinePaths = paths.filter((path) => isTopLevelPipeline(path)); @@ -141,7 +147,7 @@ export async function installAllPipelines({ logger: Logger; paths: string[]; dataStream?: RegistryDataStream; - installablePackage: InstallablePackage; + installablePackage: InstallablePackage | PackageInfo; }): Promise { const pipelinePaths = dataStream ? paths.filter((path) => isDataStreamPipeline(path, dataStream.path)) @@ -219,7 +225,7 @@ async function installPipeline({ esClient: ElasticsearchClient; logger: Logger; pipeline: PipelineInstall; - installablePackage?: InstallablePackage; + installablePackage?: InstallablePackage | PackageInfo; shouldAddCustomPipelineProcessor?: boolean; }): Promise { let pipelineToInstall = appendMetadataToIngestPipeline({ diff --git a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/install.ts b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/install.ts index fd1369748c867..993f26c3a38e0 100644 --- a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/install.ts +++ b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/install.ts @@ -61,10 +61,11 @@ import { buildDefaultSettings } from './default_settings'; const FLEET_COMPONENT_TEMPLATE_NAMES = FLEET_COMPONENT_TEMPLATES.map((tmpl) => tmpl.name); export const prepareToInstallTemplates = ( - installablePackage: InstallablePackage, + installablePackage: InstallablePackage | PackageInfo, paths: string[], esReferences: EsAssetReference[], - experimentalDataStreamFeatures: ExperimentalDataStreamFeature[] = [] + experimentalDataStreamFeatures: ExperimentalDataStreamFeature[] = [], + onlyForDataStreams?: RegistryDataStream[] ): { assetsToAdd: EsAssetReference[]; assetsToRemove: EsAssetReference[]; @@ -78,7 +79,7 @@ export const prepareToInstallTemplates = ( ); // build templates per data stream from yml files - const dataStreams = installablePackage.data_streams; + const dataStreams = onlyForDataStreams || installablePackage.data_streams; if (!dataStreams) return { assetsToAdd: [], assetsToRemove, install: () => Promise.resolve([]) }; const templates = dataStreams.map((dataStream) => { @@ -343,7 +344,6 @@ async function installDataStreamComponentTemplates({ logger: Logger; componentTemplates: TemplateMap; }) { - // TODO: Check return values for errors await Promise.all( Object.entries(componentTemplates).map(async ([name, body]) => { if (isUserSettingsTemplate(name)) { diff --git a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/remove_legacy.test.ts b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/remove_legacy.test.ts index 4877d28cbead0..1d34dd97d431e 100644 --- a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/remove_legacy.test.ts +++ b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/remove_legacy.test.ts @@ -12,7 +12,7 @@ import type { import type { Logger } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { loggingSystemMock } from '@kbn/core/server/mocks'; @@ -39,7 +39,7 @@ const createMockDataStream = ({ }) => { return { type: type || pickRandomType(), - dataset: dataset || uuid.v4(), + dataset: dataset || uuidv4(), title: packageName, package: packageName, path: 'some_path', diff --git a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.test.ts b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.test.ts index 5ed56f45e9d0e..44e0014630d15 100644 --- a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.test.ts +++ b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.test.ts @@ -109,6 +109,73 @@ describe('EPM template', () => { expect(templateWithoutHidden.data_stream.hidden).toEqual(undefined); }); + it('adds index_template.data_stream.hidden field correctly', () => { + const templateIndexPattern = 'logs-nginx.access-abcd-*'; + + const templateWithGlobalAndDataStreamHidden = getTemplate({ + templateIndexPattern, + packageName: 'nginx', + composedOfTemplates: [], + templatePriority: 200, + hidden: false, + mappings: { properties: [] }, + registryElasticsearch: { + 'index_template.data_stream': { + hidden: true, + }, + }, + }); + expect(templateWithGlobalAndDataStreamHidden.data_stream.hidden).toEqual(true); + + const templateWithDataStreamHidden = getTemplate({ + templateIndexPattern, + packageName: 'nginx', + composedOfTemplates: [], + templatePriority: 200, + mappings: { properties: [] }, + registryElasticsearch: { + 'index_template.data_stream': { + hidden: true, + }, + }, + }); + expect(templateWithDataStreamHidden.data_stream.hidden).toEqual(true); + + const templateWithoutDataStreamHidden = getTemplate({ + templateIndexPattern, + packageName: 'nginx', + composedOfTemplates: [], + templatePriority: 200, + hidden: true, + mappings: { properties: [] }, + }); + expect(templateWithoutDataStreamHidden.data_stream.hidden).toEqual(true); + + const templateWithGlobalHiddenTrueAndDataStreamHiddenFalse = getTemplate({ + templateIndexPattern, + packageName: 'nginx', + composedOfTemplates: [], + templatePriority: 200, + hidden: true, + mappings: { properties: [] }, + registryElasticsearch: { + 'index_template.data_stream': { + hidden: false, + }, + }, + }); + expect(templateWithGlobalHiddenTrueAndDataStreamHiddenFalse.data_stream.hidden).toEqual(true); + + const templateWithoutHidden = getTemplate({ + templateIndexPattern, + packageName: 'nginx', + composedOfTemplates: [], + templatePriority: 200, + mappings: { properties: [] }, + }); + expect(templateWithoutHidden.data_stream.hidden).toEqual(undefined); + }); + it('tests loading base.yml', () => { const ymlPath = path.join(__dirname, '../../fields/tests/base.yml'); const fieldsYML = readFileSync(ymlPath, 'utf-8'); diff --git a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.ts b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.ts index 2c9ec135c10c3..ac7afd143666b 100644 --- a/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.ts +++ b/x-pack/plugins/fleet/server/services/epm/elasticsearch/template/template.ts @@ -542,7 +542,9 @@ function getBaseTemplate({ _meta, }, }, - data_stream: { hidden }, + data_stream: { + hidden: registryElasticsearch?.['index_template.data_stream']?.hidden || hidden, + }, composed_of: composedOfTemplates, _meta, }; diff --git a/x-pack/plugins/fleet/server/services/epm/packages/_install_package.test.ts b/x-pack/plugins/fleet/server/services/epm/packages/_install_package.test.ts index db9803ea70f3a..23cdd399344e7 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/_install_package.test.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/_install_package.test.ts @@ -23,8 +23,14 @@ jest.mock('./get'); import { updateCurrentWriteIndices } from '../elasticsearch/template/template'; import { installKibanaAssetsAndReferences } from '../kibana/assets/install'; +import { installIndexTemplatesAndPipelines } from './install'; + import { _installPackage } from './_install_package'; +const mockedInstallIndexTemplatesAndPipelines = + installIndexTemplatesAndPipelines as jest.MockedFunction< + typeof installIndexTemplatesAndPipelines + >; const mockedUpdateCurrentWriteIndices = updateCurrentWriteIndices as jest.MockedFunction< typeof updateCurrentWriteIndices >; @@ -57,7 +63,10 @@ describe('_installPackage', () => { // and force it to take long enough for the errors to occur // @ts-expect-error about call signature mockedUpdateCurrentWriteIndices.mockImplementation(async () => await sleep(1000)); - + mockedInstallIndexTemplatesAndPipelines.mockResolvedValue({ + installedTemplates: [], + esReferences: [], + }); const installationPromise = _installPackage({ savedObjectsClient: soClient, // @ts-ignore diff --git a/x-pack/plugins/fleet/server/services/epm/packages/_install_package.ts b/x-pack/plugins/fleet/server/services/epm/packages/_install_package.ts index 2109cb00599da..596ad94a067d8 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/_install_package.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/_install_package.ts @@ -16,6 +16,8 @@ import { SavedObjectsErrorHelpers } from '@kbn/core/server'; import type { IAssignmentService, ITagsClient } from '@kbn/saved-objects-tagging-plugin/server'; +import { getNormalizedDataStreams } from '../../../../common/services'; + import { MAX_TIME_COMPLETE_INSTALL, ASSETS_SAVED_OBJECT_TYPE, @@ -31,17 +33,11 @@ import type { InstallSource, PackageAssetReference, PackageVerificationResult, + IndexTemplateEntry, } from '../../../types'; -import { - ensureFileUploadWriteIndices, - prepareToInstallTemplates, -} from '../elasticsearch/template/install'; +import { ensureFileUploadWriteIndices } from '../elasticsearch/template/install'; import { removeLegacyTemplates } from '../elasticsearch/template/remove_legacy'; -import { - prepareToInstallPipelines, - isTopLevelPipeline, - deletePreviousPipelines, -} from '../elasticsearch/ingest_pipeline'; +import { isTopLevelPipeline, deletePreviousPipelines } from '../elasticsearch/ingest_pipeline'; import { installILMPolicy } from '../elasticsearch/ilm/install'; import { installKibanaAssetsAndReferences } from '../kibana/assets/install'; import { updateCurrentWriteIndices } from '../elasticsearch/template/template'; @@ -52,7 +48,11 @@ import { saveArchiveEntries } from '../archive/storage'; import { ConcurrentInstallOperationError } from '../../../errors'; import { appContextService, packagePolicyService } from '../..'; -import { createInstallation, updateEsAssetReferences, restartInstallation } from './install'; +import { + createInstallation, + restartInstallation, + installIndexTemplatesAndPipelines, +} from './install'; import { withPackageSpan } from './utils'; // this is only exported for testing @@ -171,53 +171,52 @@ export async function _installPackage({ installMlModel(packageInfo, paths, esClient, savedObjectsClient, logger, esReferences) ); - /** - * In order to install assets in parallel, we need to split the preparation step from the installation step. This - * allows us to know which asset references are going to be installed so that we can save them on the packages - * SO before installation begins. In the case of a failure during installing any individual asset, we'll have the - * references necessary to remove any assets in that were successfully installed during the rollback phase. - * - * This split of prepare/install could be extended to all asset types. Besides performance, it also allows us to - * more easily write unit tests against the asset generation code without needing to mock ES responses. - */ - const experimentalDataStreamFeatures = - installedPkg?.attributes?.experimental_data_stream_features ?? []; + let indexTemplates: IndexTemplateEntry[] = []; - const preparedIngestPipelines = prepareToInstallPipelines(packageInfo, paths); - const preparedIndexTemplates = prepareToInstallTemplates( - packageInfo, - paths, - esReferences, - experimentalDataStreamFeatures - ); + if (packageInfo.type === 'integration') { + const { installedTemplates, esReferences: templateEsReferences } = + await installIndexTemplatesAndPipelines({ + installedPkg: installedPkg ? installedPkg.attributes : undefined, + packageInfo, + paths, + esClient, + savedObjectsClient, + logger, + esReferences, + }); + esReferences = templateEsReferences; + indexTemplates = installedTemplates; + } - // Update the references for the templates and ingest pipelines together. Need to be done togther to avoid race - // conditions on updating the installed_es field at the same time - // These must be saved before we actually attempt to install the templates or pipelines so that we know what to - // cleanup in the case that a single asset fails to install. - esReferences = await updateEsAssetReferences( - savedObjectsClient, - packageInfo.name, - esReferences, - { - assetsToRemove: preparedIndexTemplates.assetsToRemove, - assetsToAdd: [ - ...preparedIngestPipelines.assetsToAdd, - ...preparedIndexTemplates.assetsToAdd, - ], - } - ); + if (packageInfo.type === 'input' && installedPkg) { + // input packages create their data streams during package policy creation + // we must use installed_es to infer which streams exist first then + // we can install the new index templates + const dataStreamNames = installedPkg.attributes.installed_es + .filter((ref) => ref.type === 'index_template') + // index templates are named {type}-{dataset}, remove everything before first hyphen + .map((ref) => ref.id.replace(/^[^-]+-/, '')); - // Install index templates and ingest pipelines in parallel since they typically take the longest - const [installedTemplates] = await Promise.all([ - withPackageSpan('Install index templates', () => - preparedIndexTemplates.install(esClient, logger) - ), - // installs versionized pipelines without removing currently installed ones - withPackageSpan('Install ingest pipelines', () => - preparedIngestPipelines.install(esClient, logger) - ), - ]); + const dataStreams = dataStreamNames.flatMap((dataStreamName) => + getNormalizedDataStreams(packageInfo, dataStreamName) + ); + + if (dataStreams.length) { + const { installedTemplates, esReferences: templateEsReferences } = + await installIndexTemplatesAndPipelines({ + installedPkg: installedPkg ? installedPkg.attributes : undefined, + packageInfo, + paths, + esClient, + savedObjectsClient, + logger, + esReferences, + onlyForDataStreams: dataStreams, + }); + esReferences = templateEsReferences; + indexTemplates = installedTemplates; + } + } try { await removeLegacyTemplates({ packageInfo, esClient, logger }); @@ -236,7 +235,7 @@ export async function _installPackage({ // update current backing indices of each data stream await withPackageSpan('Update write indices', () => - updateCurrentWriteIndices(esClient, logger, installedTemplates) + updateCurrentWriteIndices(esClient, logger, indexTemplates) ); ({ esReferences } = await withPackageSpan('Install transforms', () => diff --git a/x-pack/plugins/fleet/server/services/epm/packages/assets.test.ts b/x-pack/plugins/fleet/server/services/epm/packages/assets.test.ts index b019729b65eb1..1ed525a71b14f 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/assets.test.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/assets.test.ts @@ -18,52 +18,88 @@ jest.mock('../archive/cache', () => { }); const mockedGetArchiveFilelist = getArchiveFilelist as jest.Mock; -mockedGetArchiveFilelist.mockImplementation(() => [ - 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-plaintext.json', - 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-json.json', -]); -const tests = [ - { - package: { - name: 'coredns', - version: '1.0.1', +test('testGetAssets integration pkg', () => { + const tests = [ + { + package: { + name: 'coredns', + version: '1.0.1', + }, + dataset: 'log', + filter: (path: string) => { + return true; + }, + expected: [ + 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-plaintext.json', + 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-json.json', + ], }, - dataset: 'log', - filter: (path: string) => { - return true; + { + package: { + name: 'coredns', + version: '1.0.1', + }, + // Non existent dataset + dataset: 'foo', + filter: (path: string) => { + return true; + }, + expected: [], }, - expected: [ - 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-plaintext.json', - 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-json.json', - ], - }, - { - package: { - name: 'coredns', - version: '1.0.1', + { + package: { + name: 'coredns', + version: '1.0.1', + }, + // Filter which does not exist + filter: (path: string) => { + return path.includes('foo'); + }, + expected: [], }, - // Non existent dataset - dataset: 'foo', - filter: (path: string) => { - return true; - }, - expected: [], - }, - { - package: { - name: 'coredns', - version: '1.0.1', - }, - // Filter which does not exist - filter: (path: string) => { - return path.includes('foo'); + ]; + + mockedGetArchiveFilelist.mockImplementation(() => [ + 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-plaintext.json', + 'coredns-1.0.1/data_stream/log/elasticsearch/ingest-pipeline/pipeline-json.json', + ]); + for (const value of tests) { + // as needed to pretend it is an InstallablePackage + const assets = getAssets(value.package as PackageInfo, value.filter, value.dataset); + expect(assets).toStrictEqual(value.expected); + } +}); + +test('testGetAssets input pkg', () => { + mockedGetArchiveFilelist.mockImplementation(() => [ + 'input_package_upgrade-1.0.0/agent/input/input.yml.hbs', + 'input_package_upgrade-1.0.0/changelog.yml', + 'input_package_upgrade-1.0.0/docs/README.md', + 'input_package_upgrade-1.0.0/fields/input.yml', + 'input_package_upgrade-1.0.0/img/sample-logo.svg', + 'input_package_upgrade-1.0.0/img/sample-screenshot.png', + 'input_package_upgrade-1.0.0/manifest.yml', + ]); + + const tests = [ + { + package: { + name: 'input_package_upgrade', + version: '1.0.0', + type: 'input', + }, + dataset: 'log', + filter: (path: string) => { + return true; + }, + expected: [ + 'input_package_upgrade-1.0.0/agent/input/input.yml.hbs', + 'input_package_upgrade-1.0.0/fields/input.yml', + ], }, - expected: [], - }, -]; + ]; -test('testGetAssets', () => { for (const value of tests) { // as needed to pretend it is an InstallablePackage const assets = getAssets(value.package as PackageInfo, value.filter, value.dataset); diff --git a/x-pack/plugins/fleet/server/services/epm/packages/assets.ts b/x-pack/plugins/fleet/server/services/epm/packages/assets.ts index 915b68e1173d3..89bd9b25af75a 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/assets.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/assets.ts @@ -9,47 +9,41 @@ import type { PackageInfo } from '../../../types'; import { getArchiveFilelist, getAsset } from '../archive'; import type { ArchiveEntry } from '../archive'; +const maybeFilterByDataset = + (packageInfo: Pick, datasetName: string) => + (path: string): boolean => { + const basePath = `${packageInfo.name}-${packageInfo.version}`; + const comparePaths = + packageInfo?.type === 'input' + ? [`${basePath}/agent/input/`, `${basePath}/fields/`] + : [`${basePath}/data_stream/${datasetName}/`]; + + return comparePaths.some((comparePath) => path.includes(comparePath)); + }; + // paths from RegistryPackage are routes to the assets on EPR // e.g. `/package/nginx/1.2.0/data_stream/access/fields/fields.yml` // paths for ArchiveEntry are routes to the assets in the archive // e.g. `nginx-1.2.0/data_stream/access/fields/fields.yml` // RegistryPackage paths have a `/package/` prefix compared to ArchiveEntry paths // and different package and version structure - export function getAssets( packageInfo: Pick, filter = (path: string): boolean => true, datasetName?: string ): string[] { - const assets: string[] = []; - const { name, version } = packageInfo; - const paths = getArchiveFilelist({ name, version }); - // TODO: might be better to throw a PackageCacheError here - if (!paths || paths.length === 0) return assets; + const paths = getArchiveFilelist(packageInfo); - // Skip directories - for (const path of paths) { - if (path.endsWith('/')) { - continue; - } + if (!paths || paths.length === 0) return []; - // if dataset, filter for them - if (datasetName) { - const comparePath = - packageInfo?.type === 'input' - ? `${packageInfo.name}-${packageInfo.version}/agent/input/` - : `${packageInfo.name}-${packageInfo.version}/data_stream/${datasetName}/`; - if (!path.includes(comparePath)) { - continue; - } - } - if (!filter(path)) { - continue; - } + // filter out directories + let assets: string[] = paths.filter((path) => !path.endsWith('/')); - assets.push(path); + if (datasetName) { + assets = paths.filter(maybeFilterByDataset(packageInfo, datasetName)); } - return assets; + + return assets.filter(filter); } export function getAssetsData( diff --git a/x-pack/plugins/fleet/server/services/epm/packages/bulk_install_packages.ts b/x-pack/plugins/fleet/server/services/epm/packages/bulk_install_packages.ts index 66b9323dd0939..659d8d1a1c5db 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/bulk_install_packages.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/bulk_install_packages.ts @@ -93,6 +93,7 @@ export async function bulkInstallPackages({ installSource: 'registry', spaceId, force, + prerelease, }); if (installResult.error) { diff --git a/x-pack/plugins/fleet/server/services/epm/packages/install.ts b/x-pack/plugins/fleet/server/services/epm/packages/install.ts index 7d80c968edd93..a16b0c28cff81 100644 --- a/x-pack/plugins/fleet/server/services/epm/packages/install.ts +++ b/x-pack/plugins/fleet/server/services/epm/packages/install.ts @@ -13,12 +13,15 @@ import type { ElasticsearchClient, SavedObject, SavedObjectsClientContract, + Logger, } from '@kbn/core/server'; import { DEFAULT_SPACE_ID } from '@kbn/spaces-plugin/common/constants'; import pRetry from 'p-retry'; +import { isPackagePrerelease, getNormalizedDataStreams } from '../../../../common/services'; + import { FLEET_INSTALL_FORMAT_VERSION } from '../../../constants/fleet_es_assets'; import { generateESIndexPatterns } from '../elasticsearch/template/template'; @@ -33,12 +36,15 @@ import type { InstallSource, InstallType, KibanaAssetType, + NewPackagePolicy, + PackageInfo, PackageVerificationResult, + RegistryDataStream, } from '../../../types'; import { AUTO_UPGRADE_POLICIES_PACKAGES } from '../../../../common/constants'; -import { FleetError, PackageOutdatedError } from '../../../errors'; +import { FleetError, PackageOutdatedError, PackagePolicyValidationError } from '../../../errors'; import { PACKAGES_SAVED_OBJECT_TYPE, MAX_TIME_COMPLETE_INSTALL } from '../../../constants'; -import { licenseService } from '../..'; +import { dataStreamService, licenseService } from '../..'; import { appContextService } from '../../app_context'; import * as Registry from '../registry'; import { @@ -46,6 +52,7 @@ import { generatePackageInfoFromArchiveBuffer, unpackBufferToCache, deleteVerificationResult, + getArchiveFilelist, } from '../archive'; import { toAssetReference } from '../kibana/assets/install'; import type { ArchiveAsset } from '../kibana/assets/install'; @@ -53,6 +60,10 @@ import type { ArchiveAsset } from '../kibana/assets/install'; import type { PackageUpdateEvent } from '../../upgrade_sender'; import { sendTelemetryEvents, UpdateEventType } from '../../upgrade_sender'; +import { prepareToInstallPipelines } from '../elasticsearch/ingest_pipeline'; + +import { prepareToInstallTemplates } from '../elasticsearch/template/install'; + import { formatVerificationResultForSO } from './package_verification'; import { getInstallation, getInstallationObject } from '.'; @@ -61,6 +72,7 @@ import { getPackageSavedObjects } from './get'; import { _installPackage } from './_install_package'; import { removeOldAssets } from './cleanup'; import { getBundledPackages } from './bundled_packages'; +import { withPackageSpan } from './utils'; export async function isPackageInstalled(options: { savedObjectsClient: SavedObjectsClientContract; @@ -273,10 +285,12 @@ async function installPackageFromRegistry({ force = false, ignoreConstraints = false, neverIgnoreVerificationError = false, + prerelease = false, }: InstallRegistryPackageParams): Promise { const logger = appContextService.getLogger(); // TODO: change epm API to /packageName/version so we don't need to do this - const { pkgName, pkgVersion } = Registry.splitPkgKey(pkgkey); + const { pkgName, pkgVersion: version } = Registry.splitPkgKey(pkgkey); + let pkgVersion = version; // Workaround apm issue with async spans: https://github.com/elastic/apm-agent-nodejs/issues/2611 await Promise.resolve(); @@ -298,12 +312,22 @@ async function installPackageFromRegistry({ installType, }); - // get latest package version and requested version in parallel for performance - const [latestPackage, { paths, packageInfo, verificationResult }] = await Promise.all([ + const queryLatest = () => Registry.fetchFindLatestPackageOrThrow(pkgName, { ignoreConstraints, - prerelease: true, - }), + prerelease: prerelease === true || isPackagePrerelease(pkgVersion), // fetching latest GA version if the package to install is GA, so that it is allowed to install + }); + + let latestPkg; + // fetching latest package first to set the version + if (!pkgVersion) { + latestPkg = await queryLatest(); + pkgVersion = latestPkg.version; + } + + // get latest package version and requested version in parallel for performance + const [latestPackage, { paths, packageInfo, verificationResult }] = await Promise.all([ + latestPkg ? Promise.resolve(latestPkg) : queryLatest(), Registry.getPackage(pkgName, pkgVersion, { ignoreUnverified: force && !neverIgnoreVerificationError, }), @@ -564,7 +588,8 @@ export async function installPackage(args: InstallPackageParams): Promise Registry.pkgToPkgKey(pkg) === pkgkey @@ -596,6 +621,7 @@ export async function installPackage(args: InstallPackageParams): Promise + preparedIndexTemplates.install(esClient, logger) + ), + // installs versionized pipelines without removing currently installed ones + withPackageSpan('Install ingest pipelines', () => + preparedIngestPipelines.install(esClient, logger) + ), + ]); + + return { + esReferences: newEsReferences, + installedTemplates, + }; +} + +export async function installAssetsForInputPackagePolicy(opts: { + pkgInfo: PackageInfo; + logger: Logger; + packagePolicy: NewPackagePolicy; + esClient: ElasticsearchClient; + soClient: SavedObjectsClientContract; + force: boolean; +}) { + const { pkgInfo, logger, packagePolicy, esClient, soClient, force } = opts; + + if (pkgInfo.type !== 'input') return; + + const paths = await getArchiveFilelist(pkgInfo); + if (!paths) throw new Error('No paths found for '); + + const datasetName = packagePolicy.inputs[0].streams[0].vars?.['data_stream.dataset']?.value; + const [dataStream] = getNormalizedDataStreams(pkgInfo, datasetName); + const existingDataStreams = await dataStreamService.getMatchingDataStreams(esClient, { + type: dataStream.type, + dataset: datasetName, + }); + + if (existingDataStreams.length) { + const existingDataStreamsAreFromDifferentPackage = existingDataStreams.some( + (ds) => ds._meta?.package?.name !== pkgInfo.name + ); + if (existingDataStreamsAreFromDifferentPackage && !force) { + // user has opted to send data to an existing data stream which is managed by another + // package. This means certain custom setting such as elasticsearch settings + // defined by the package will not have been applied which could lead + // to unforeseen circumstances, so force flag must be used. + const streamIndexPattern = dataStreamService.streamPartsToIndexPattern({ + type: dataStream.type, + dataset: datasetName, + }); + + throw new PackagePolicyValidationError( + `Datastreams matching "${streamIndexPattern}" already exist and are not managed by this package, force flag is required` + ); + } else { + logger.info( + `Data stream ${dataStream.name} already exists, skipping index template creation for ${packagePolicy.id}` + ); + return; + } + } + + const existingIndexTemplate = await dataStreamService.getMatchingIndexTemplate(esClient, { + type: dataStream.type, + dataset: datasetName, + }); + + if (existingIndexTemplate) { + const indexTemplateOwnnedByDifferentPackage = + existingIndexTemplate._meta?.package?.name !== pkgInfo.name; + if (indexTemplateOwnnedByDifferentPackage && !force) { + // index template already exists but there is no data stream yet + // we do not want to override the index template + + throw new PackagePolicyValidationError( + `Index template "${dataStream.type}-${datasetName}" already exist and is not managed by this package, force flag is required` + ); + } else { + logger.info( + `Index template "${dataStream.type}-${datasetName}" already exists, skipping index template creation for ${packagePolicy.id}` + ); + return; + } + } + + const installedPkg = await getInstallation({ + savedObjectsClient: soClient, + pkgName: pkgInfo.name, + logger, + }); + if (!installedPkg) + throw new Error('Unable to find installed package while creating index templates'); + await installIndexTemplatesAndPipelines({ + installedPkg, + paths, + packageInfo: pkgInfo, + esReferences: installedPkg.installed_es || [], + savedObjectsClient: soClient, + esClient, + logger, + onlyForDataStreams: [dataStream], + }); +} + interface NoPkgArgs { pkgVersion: string; installedPkg?: undefined; diff --git a/x-pack/plugins/fleet/server/services/fleet_usage_logger.ts b/x-pack/plugins/fleet/server/services/fleet_usage_logger.ts index d1f6a0f5aba36..92a1dc6da33cf 100644 --- a/x-pack/plugins/fleet/server/services/fleet_usage_logger.ts +++ b/x-pack/plugins/fleet/server/services/fleet_usage_logger.ts @@ -39,7 +39,7 @@ export async function registerFleetUsageLogger( } catch (error) { appContextService .getLogger() - .warn('Error occurred while fetching fleet usage: ' + error); + .debug('Error occurred while fetching fleet usage: ' + error); } }, diff --git a/x-pack/plugins/fleet/server/services/index.ts b/x-pack/plugins/fleet/server/services/index.ts index a5078471d934d..cfd8eb95ceb4d 100644 --- a/x-pack/plugins/fleet/server/services/index.ts +++ b/x-pack/plugins/fleet/server/services/index.ts @@ -45,6 +45,7 @@ export { packagePolicyService } from './package_policy'; export { outputService } from './output'; export { downloadSourceService } from './download_source'; export { settingsService }; +export { dataStreamService } from './data_streams'; // Plugin services export { appContextService } from './app_context'; diff --git a/x-pack/plugins/fleet/server/services/output.ts b/x-pack/plugins/fleet/server/services/output.ts index f1f871d373afe..41f699ab5e318 100644 --- a/x-pack/plugins/fleet/server/services/output.ts +++ b/x-pack/plugins/fleet/server/services/output.ts @@ -6,7 +6,7 @@ */ import type { KibanaRequest, SavedObject, SavedObjectsClientContract } from '@kbn/core/server'; -import uuid from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import { omit } from 'lodash'; import { safeLoad } from 'js-yaml'; @@ -64,7 +64,7 @@ export function outputIdToUuid(id: string) { } // UUID v5 need a namespace (uuid.DNS), changing this params will result in loosing the ability to generate predicable uuid - return uuid(id, uuid.DNS); + return uuidv5(id, uuidv5.DNS); } function outputSavedObjectToOutput(so: SavedObject): Output { diff --git a/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.test.ts b/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.test.ts index 9d43a9fad7efd..4e6db957633ef 100644 --- a/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.test.ts +++ b/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.test.ts @@ -98,9 +98,7 @@ describe('experimental_datastream_features', () => { template: { settings: {}, mappings: { - _source: { - mode: 'stored', - }, + _source: {}, properties: { test_dimension: { type: 'keyword', diff --git a/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.ts b/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.ts index 06a51a0b02eb4..0355b9a8553e8 100644 --- a/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.ts +++ b/x-pack/plugins/fleet/server/services/package_policies/experimental_datastream_features.ts @@ -63,7 +63,7 @@ export async function handleExperimentalDatastreamFeatureOptIn({ mappings: { ...componentTemplate.template.mappings, _source: { - mode: featureMapEntry.features.synthetic_source ? 'synthetic' : 'stored', + ...(featureMapEntry.features.synthetic_source ? { mode: 'synthetic' } : {}), }, }, }, diff --git a/x-pack/plugins/fleet/server/services/package_policy.ts b/x-pack/plugins/fleet/server/services/package_policy.ts index 73fda5ac50aff..c7152e2d26a3e 100644 --- a/x-pack/plugins/fleet/server/services/package_policy.ts +++ b/x-pack/plugins/fleet/server/services/package_policy.ts @@ -17,7 +17,7 @@ import type { SavedObjectsClientContract, Logger, } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { safeLoad } from 'js-yaml'; import { DEFAULT_SPACE_ID } from '@kbn/spaces-plugin/common/constants'; @@ -101,6 +101,7 @@ import { sendTelemetryEvents } from './upgrade_sender'; import { handleExperimentalDatastreamFeatureOptIn } from './package_policies'; import { updateDatastreamExperimentalFeatures } from './epm/packages/update'; import type { PackagePolicyClient, PackagePolicyService } from './package_policy_service'; +import { installAssetsForInputPackagePolicy } from './epm/packages/install'; export type InputsOverride = Partial & { vars?: Array; @@ -134,6 +135,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { packageInfo?: PackageInfo; } ): Promise { + const logger = appContextService.getLogger(); const agentPolicy = await agentPolicyService.get(soClient, packagePolicy.policy_id, true); if (agentPolicy && packagePolicy.package?.name === FLEET_APM_PACKAGE) { @@ -160,9 +162,9 @@ class PackagePolicyClientImpl implements PackagePolicyClient { } } - let elasticsearch: PackagePolicy['elasticsearch']; + let elasticsearchPrivileges: NonNullable['privileges']; // Add ids to stream - const packagePolicyId = options?.id || uuid.v4(); + const packagePolicyId = options?.id || uuidv4(); let inputs: PackagePolicyInput[] = packagePolicy.inputs.map((input) => assignStreamIdToInput(packagePolicyId, input) ); @@ -205,7 +207,18 @@ class PackagePolicyClientImpl implements PackagePolicyClient { inputs = await _compilePackagePolicyInputs(pkgInfo, packagePolicy.vars || {}, inputs); - elasticsearch = pkgInfo.elasticsearch; + elasticsearchPrivileges = pkgInfo.elasticsearch?.privileges; + + if (pkgInfo.type === 'input') { + await installAssetsForInputPackagePolicy({ + soClient, + esClient, + pkgInfo, + packagePolicy, + force: !!options?.force, + logger, + }); + } } const isoDate = new Date().toISOString(); @@ -217,7 +230,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { ? { package: omit(packagePolicy.package, 'experimental_data_stream_features') } : {}), inputs, - elasticsearch, + ...(elasticsearchPrivileges && { elasticsearch: { privileges: elasticsearchPrivileges } }), revision: 1, created_at: isoDate, created_by: options?.user?.username ?? 'system', @@ -263,7 +276,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { // eslint-disable-next-line @typescript-eslint/naming-convention const { saved_objects } = await soClient.bulkCreate( await pMap(packagePolicies, async (packagePolicy) => { - const packagePolicyId = packagePolicy.id ?? uuid.v4(); + const packagePolicyId = packagePolicy.id ?? uuidv4(); const agentPolicyId = packagePolicy.policy_id; let inputs = packagePolicy.inputs.map((input) => @@ -511,7 +524,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { ); inputs = enforceFrozenInputs(oldPackagePolicy.inputs, inputs, options?.force); - let elasticsearch: PackagePolicy['elasticsearch']; + let elasticsearchPrivileges: NonNullable['privileges']; if (packagePolicy.package?.name) { const pkgInfo = await getPackageInfo({ savedObjectsClient: soClient, @@ -527,7 +540,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { validatePackagePolicyOrThrow(packagePolicy, pkgInfo); inputs = await _compilePackagePolicyInputs(pkgInfo, packagePolicy.vars || {}, inputs); - elasticsearch = pkgInfo.elasticsearch; + elasticsearchPrivileges = pkgInfo.elasticsearch?.privileges; } // Handle component template/mappings updates for experimental features, e.g. synthetic source @@ -542,7 +555,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { ? { package: omit(restOfPackagePolicy.package, 'experimental_data_stream_features') } : {}), inputs, - elasticsearch, + ...(elasticsearchPrivileges && { elasticsearch: { privileges: elasticsearchPrivileges } }), revision: oldPackagePolicy.revision + 1, updated_at: new Date().toISOString(), updated_by: options?.user?.username ?? 'system', @@ -614,7 +627,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { ); inputs = enforceFrozenInputs(oldPackagePolicy.inputs, inputs, options?.force); - let elasticsearch: PackagePolicy['elasticsearch']; + let elasticsearchPrivileges: NonNullable['privileges']; if (packagePolicy.package?.name) { const pkgInfo = packageInfos.get( `${packagePolicy.package.name}-${packagePolicy.package.version}` @@ -623,7 +636,7 @@ class PackagePolicyClientImpl implements PackagePolicyClient { validatePackagePolicyOrThrow(packagePolicy, pkgInfo); inputs = await _compilePackagePolicyInputs(pkgInfo, packagePolicy.vars || {}, inputs); - elasticsearch = pkgInfo.elasticsearch; + elasticsearchPrivileges = pkgInfo.elasticsearch?.privileges; } } @@ -639,7 +652,9 @@ class PackagePolicyClientImpl implements PackagePolicyClient { ? { package: omit(restOfPackagePolicy.package, 'experimental_data_stream_features') } : {}), inputs, - elasticsearch, + ...(elasticsearchPrivileges && { + elasticsearch: { privileges: elasticsearchPrivileges }, + }), revision: oldPackagePolicy.revision + 1, updated_at: new Date().toISOString(), updated_by: options?.user?.username ?? 'system', @@ -1985,7 +2000,8 @@ export function _validateRestrictedFieldsNotModifiedOrThrow(opts: { if ( oldStream && oldStream?.vars?.['data_stream.dataset'] && - oldStream?.vars['data_stream.dataset'] !== stream?.vars?.['data_stream.dataset'] + oldStream?.vars['data_stream.dataset']?.value !== + stream?.vars?.['data_stream.dataset']?.value ) { throw new PackagePolicyValidationError( i18n.translate('xpack.fleet.updatePackagePolicy.datasetCannotBeModified', { diff --git a/x-pack/plugins/fleet/server/services/preconfiguration.test.ts b/x-pack/plugins/fleet/server/services/preconfiguration.test.ts index bab3fb75ecdd4..320720c8dbedb 100644 --- a/x-pack/plugins/fleet/server/services/preconfiguration.test.ts +++ b/x-pack/plugins/fleet/server/services/preconfiguration.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { elasticsearchServiceMock, savedObjectsClientMock } from '@kbn/core/server/mocks'; @@ -108,7 +108,7 @@ function getPutPreconfiguredPackagesMock() { const { id } = options!; mockConfiguredPolicies.set(id, attributes); return { - id: id || uuid.v4(), + id: id || uuidv4(), attributes, type, references: [], diff --git a/x-pack/plugins/fleet/server/services/telemetry/fleet_usages_schema.ts b/x-pack/plugins/fleet/server/services/telemetry/fleet_usages_schema.ts index 40c3c77f9418c..c8ef4c32b9938 100644 --- a/x-pack/plugins/fleet/server/services/telemetry/fleet_usages_schema.ts +++ b/x-pack/plugins/fleet/server/services/telemetry/fleet_usages_schema.ts @@ -125,18 +125,6 @@ export const fleetUsagesSchema: RootSchema = { description: 'The number of Fleet Server hosts configured in Fleet settings.', }, }, - inactive: { - type: 'long', - _meta: { - description: 'The total number of enrolled agents currently inactive', - }, - }, - unenrolled: { - type: 'long', - _meta: { - description: 'The total number of unenrolled agents', - }, - }, }, }, packages: { @@ -201,18 +189,4 @@ export const fleetUsagesSchema: RootSchema = { }, }, }, - agent_logs_top_errors: { - type: 'array', - items: { - type: 'text', - _meta: { description: 'Top messages from agent error logs' }, - }, - }, - fleet_server_logs_top_errors: { - type: 'array', - items: { - type: 'text', - _meta: { description: 'Top messages from fleet server error logs' }, - }, - }, }; diff --git a/x-pack/plugins/fleet/server/types/models/agent_policy.ts b/x-pack/plugins/fleet/server/types/models/agent_policy.ts index f709c7b92f89a..750613abfd21a 100644 --- a/x-pack/plugins/fleet/server/types/models/agent_policy.ts +++ b/x-pack/plugins/fleet/server/types/models/agent_policy.ts @@ -17,6 +17,8 @@ function validateNonEmptyString(val: string) { } } +const TWO_WEEKS_SECONDS = 1209600; + export const AgentPolicyBaseSchema = { id: schema.maybe(schema.string()), name: schema.string({ minLength: 1, validate: validateNonEmptyString }), @@ -27,7 +29,7 @@ export const AgentPolicyBaseSchema = { is_default: schema.maybe(schema.boolean()), is_default_fleet_server: schema.maybe(schema.boolean()), unenroll_timeout: schema.maybe(schema.number({ min: 0 })), - inactivity_timeout: schema.maybe(schema.number({ min: 0 })), + inactivity_timeout: schema.number({ min: 0, defaultValue: TWO_WEEKS_SECONDS }), monitoring_enabled: schema.maybe( schema.arrayOf( schema.oneOf([schema.literal(dataTypes.Logs), schema.literal(dataTypes.Metrics)]) diff --git a/x-pack/plugins/fleet/server/types/rest_spec/epm.ts b/x-pack/plugins/fleet/server/types/rest_spec/epm.ts index 3fbf8b98f5eea..5ffcc2078d983 100644 --- a/x-pack/plugins/fleet/server/types/rest_spec/epm.ts +++ b/x-pack/plugins/fleet/server/types/rest_spec/epm.ts @@ -91,6 +91,9 @@ export const InstallPackageFromRegistryRequestSchema = { pkgName: schema.string(), pkgVersion: schema.maybe(schema.string()), }), + query: schema.object({ + prerelease: schema.maybe(schema.boolean()), + }), body: schema.nullable( schema.object({ force: schema.boolean({ defaultValue: false }), @@ -103,6 +106,9 @@ export const InstallPackageFromRegistryRequestSchemaDeprecated = { params: schema.object({ pkgkey: schema.string(), }), + query: schema.object({ + prerelease: schema.maybe(schema.boolean()), + }), body: schema.nullable( schema.object({ force: schema.boolean(), @@ -110,12 +116,13 @@ export const InstallPackageFromRegistryRequestSchemaDeprecated = { ), }; -export const BulkUpgradePackagesFromRegistryRequestSchema = { +export const BulkInstallPackagesFromRegistryRequestSchema = { query: schema.object({ prerelease: schema.maybe(schema.boolean()), }), body: schema.object({ packages: schema.arrayOf(schema.string(), { minSize: 1 }), + force: schema.boolean({ defaultValue: false }), }), }; diff --git a/x-pack/plugins/global_search/public/services/utils.ts b/x-pack/plugins/global_search/public/services/utils.ts index b3854f1e9b280..c86be88f00951 100644 --- a/x-pack/plugins/global_search/public/services/utils.ts +++ b/x-pack/plugins/global_search/public/services/utils.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; const defaultPrefStorageKey = 'globalSearch:defaultPref'; @@ -19,7 +19,7 @@ export const getDefaultPreference = (storage: Storage = window.sessionStorage): if (pref) { return pref; } - pref = uuid.v4(); + pref = uuidv4(); storage.setItem(defaultPrefStorageKey, pref); return pref; }; diff --git a/x-pack/plugins/graph/public/apps/workspace_route.tsx b/x-pack/plugins/graph/public/apps/workspace_route.tsx index 9b1fde2e7cb25..75aafeb1a7868 100644 --- a/x-pack/plugins/graph/public/apps/workspace_route.tsx +++ b/x-pack/plugins/graph/public/apps/workspace_route.tsx @@ -10,7 +10,6 @@ import { I18nProvider } from '@kbn/i18n-react'; import { Provider } from 'react-redux'; import { useHistory } from 'react-router-dom'; import { KibanaContextProvider } from '@kbn/kibana-react-plugin/public'; -import { showSaveModal } from '@kbn/saved-objects-plugin/public'; import { Workspace } from '../types'; import { createGraphStore } from '../state_management'; import { createWorkspace } from '../services/workspace/graph_client_workspace'; @@ -108,12 +107,10 @@ export const WorkspaceRoute = ({ http: coreStart.http, overlays: coreStart.overlays, savedObjectsClient, - showSaveModal, savePolicy: graphSavePolicy, changeUrl: (newUrl) => history.push(newUrl), notifyReact: () => setRenderCounter((cur) => cur + 1), chrome, - I18nContext: coreStart.i18n.Context, handleSearchQueryError, }) ); diff --git a/x-pack/plugins/graph/public/services/save_modal.tsx b/x-pack/plugins/graph/public/services/save_modal.tsx index 9e95a53c12f9a..ab1db894a47c2 100644 --- a/x-pack/plugins/graph/public/services/save_modal.tsx +++ b/x-pack/plugins/graph/public/services/save_modal.tsx @@ -5,9 +5,10 @@ * 2.0. */ -import React, { ReactElement } from 'react'; -import { I18nStart, OverlayStart, SavedObjectsClientContract } from '@kbn/core/public'; +import React from 'react'; +import { OverlayStart, SavedObjectsClientContract } from '@kbn/core/public'; import { SaveResult } from '@kbn/saved-objects-plugin/public'; +import { showSaveModal } from '@kbn/saved-objects-plugin/public'; import { GraphWorkspaceSavedObject, GraphSavePolicy } from '../types'; import { SaveModal, OnSaveGraphProps } from '../components/save_modal'; @@ -31,16 +32,12 @@ export function openSaveModal({ hasData, workspace, saveWorkspace, - showSaveModal, - I18nContext, services, }: { savePolicy: GraphSavePolicy; hasData: boolean; workspace: GraphWorkspaceSavedObject; saveWorkspace: SaveWorkspaceHandler; - showSaveModal: (el: ReactElement, I18nContext: I18nStart['Context']) => void; - I18nContext: I18nStart['Context']; services: SaveWorkspaceServices; }) { const currentTitle = workspace.title; @@ -79,7 +76,6 @@ export function openSaveModal({ title={workspace.title} description={workspace.description} showCopyOnSave={Boolean(workspace.id)} - />, - I18nContext + /> ); } diff --git a/x-pack/plugins/graph/public/state_management/mocks.ts b/x-pack/plugins/graph/public/state_management/mocks.ts index 00619f118a1d0..d6d0cd8e1acd4 100644 --- a/x-pack/plugins/graph/public/state_management/mocks.ts +++ b/x-pack/plugins/graph/public/state_management/mocks.ts @@ -66,9 +66,6 @@ export function createMockGraphStore({ return { id: '123', title: 'test-pattern' } as unknown as DataView; }), }, - I18nContext: jest - .fn() - .mockImplementation(({ children }: { children: React.ReactNode }) => children), notifications: { toasts: { addDanger: jest.fn(), @@ -78,7 +75,6 @@ export function createMockGraphStore({ http: {} as HttpStart, notifyReact: jest.fn(), savePolicy: 'configAndData', - showSaveModal: jest.fn(), overlays: { openModal: jest.fn(), } as unknown as OverlayStart, diff --git a/x-pack/plugins/graph/public/state_management/persistence.ts b/x-pack/plugins/graph/public/state_management/persistence.ts index aa460d247ac7c..41bc07485cf0a 100644 --- a/x-pack/plugins/graph/public/state_management/persistence.ts +++ b/x-pack/plugins/graph/public/state_management/persistence.ts @@ -229,9 +229,7 @@ function showModal( savePolicy: deps.savePolicy, hasData: workspace.nodes.length > 0 || workspace.blocklistedNodes.length > 0, workspace: savedWorkspace, - showSaveModal: deps.showSaveModal, saveWorkspace: saveWorkspaceHandler, - I18nContext: deps.I18nContext, services: { savedObjectsClient: deps.savedObjectsClient, overlays: deps.overlays, diff --git a/x-pack/plugins/graph/public/state_management/store.ts b/x-pack/plugins/graph/public/state_management/store.ts index 657f3021e24e5..c2a14dc88024a 100644 --- a/x-pack/plugins/graph/public/state_management/store.ts +++ b/x-pack/plugins/graph/public/state_management/store.ts @@ -7,9 +7,8 @@ import createSagaMiddleware, { SagaMiddleware } from 'redux-saga'; import { combineReducers, createStore, Store, AnyAction, Dispatch, applyMiddleware } from 'redux'; -import { ChromeStart, I18nStart, OverlayStart, SavedObjectsClientContract } from '@kbn/core/public'; +import { ChromeStart, OverlayStart, SavedObjectsClientContract } from '@kbn/core/public'; import { CoreStart } from '@kbn/core/public'; -import { ReactElement } from 'react'; import { fieldsReducer, FieldsState, @@ -48,12 +47,10 @@ export interface GraphStoreDependencies { http: CoreStart['http']; overlays: OverlayStart; savedObjectsClient: SavedObjectsClientContract; - showSaveModal: (el: ReactElement, I18nContext: I18nStart['Context']) => void; savePolicy: GraphSavePolicy; changeUrl: (newUrl: string) => void; notifyReact: () => void; chrome: ChromeStart; - I18nContext: I18nStart['Context']; basePath: string; handleSearchQueryError: (err: Error | string) => void; } diff --git a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phases/shared_fields/forcemerge_field.tsx b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phases/shared_fields/forcemerge_field.tsx index 356eff73150b7..9f8735b9f2916 100644 --- a/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phases/shared_fields/forcemerge_field.tsx +++ b/x-pack/plugins/index_lifecycle_management/public/application/sections/edit_policy/components/phases/shared_fields/forcemerge_field.tsx @@ -8,7 +8,7 @@ import React, { useMemo } from 'react'; import { FormattedMessage } from '@kbn/i18n-react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { EuiCheckbox, EuiSpacer, EuiFlexGroup, EuiFlexItem, EuiIconTip } from '@elastic/eui'; import { NumericField, useKibana } from '../../../../../../shared_imports'; import { i18nTexts } from '../../../i18n_texts'; @@ -80,7 +80,7 @@ export const ForcemergeField: React.FunctionComponent = ({ phase }) => { checked={field.value as boolean} onChange={field.onChange} data-test-subj={`${phase}-bestCompression`} - id={uuid()} + id={uuidv4()} /> diff --git a/x-pack/plugins/index_management/public/application/components/mappings_editor/constants/parameters_definition.tsx b/x-pack/plugins/index_management/public/application/components/mappings_editor/constants/parameters_definition.tsx index c00885de6b967..8c26701498f0d 100644 --- a/x-pack/plugins/index_management/public/application/components/mappings_editor/constants/parameters_definition.tsx +++ b/x-pack/plugins/index_management/public/application/components/mappings_editor/constants/parameters_definition.tsx @@ -448,7 +448,7 @@ export const PARAMETERS_DEFINITION: { [key in ParameterName]: ParameterDefinitio }, ], }, - schema: t.string, + schema: t.union([t.string, t.array(t.string)]), }, value: { fieldConfig: { diff --git a/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/mappings_validator.test.ts b/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/mappings_validator.test.ts index d41821bf3aeba..2006f72a7e35d 100644 --- a/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/mappings_validator.test.ts +++ b/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/mappings_validator.test.ts @@ -183,6 +183,23 @@ describe('Properties validator', () => { expect(errors).toEqual([]); }); + it(`should allow copy_to to be an array of strings`, () => { + const properties = { + text1: { type: 'text', copy_to: ['field1', 'field2'] }, + field1: { type: 'text' }, + field2: { type: 'text' }, + }; + + const { value, errors } = validateProperties(properties as any); + + expect(value).toEqual({ + text1: { type: 'text', copy_to: ['field1', 'field2'] }, + field1: { type: 'text' }, + field2: { type: 'text' }, + }); + expect(errors).toEqual([]); + }); + it('should strip field whose type is not a string or is unknown', () => { const properties = { prop1: { type: 123 }, @@ -254,7 +271,7 @@ describe('Properties validator', () => { ignore_malformed: 0, null_value_numeric: 'abc', null_value_boolean: [], - copy_to: [], + copy_to: [1], max_input_length: true, locale: 1, orientation: [], diff --git a/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/utils.ts b/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/utils.ts index 44461f1b98aef..33555bb2ce1d0 100644 --- a/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/utils.ts +++ b/x-pack/plugins/index_management/public/application/components/mappings_editor/lib/utils.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DataType, @@ -37,7 +37,7 @@ import { import { FieldConfig } from '../shared_imports'; import { TreeItem } from '../components/tree'; -export const getUniqueId = () => uuid.v4(); +export const getUniqueId = () => uuidv4(); export const getChildFieldsName = (dataType: DataType): ChildFieldName | undefined => { if (dataType === 'text' || dataType === 'keyword' || dataType === 'ip') { diff --git a/x-pack/plugins/infra/common/performance_tracing.ts b/x-pack/plugins/infra/common/performance_tracing.ts index 6907ea198bc6f..044dc0f93c909 100644 --- a/x-pack/plugins/infra/common/performance_tracing.ts +++ b/x-pack/plugins/infra/common/performance_tracing.ts @@ -6,7 +6,7 @@ */ import * as rt from 'io-ts'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export const tracingSpanRT = rt.type({ duration: rt.number, @@ -22,7 +22,7 @@ export type ActiveTrace = (endTime?: number) => TracingSpan; export const startTracingSpan = (name: string): ActiveTrace => { const initialState: TracingSpan = { duration: Number.POSITIVE_INFINITY, - id: uuid.v4(), + id: uuidv4(), name, start: Date.now(), }; diff --git a/x-pack/plugins/infra/public/pages/metrics/inventory_view/components/waffle/metric_control/custom_metric_form.tsx b/x-pack/plugins/infra/public/pages/metrics/inventory_view/components/waffle/metric_control/custom_metric_form.tsx index 30d25cd183fad..98c4e92785905 100644 --- a/x-pack/plugins/infra/public/pages/metrics/inventory_view/components/waffle/metric_control/custom_metric_form.tsx +++ b/x-pack/plugins/infra/public/pages/metrics/inventory_view/components/waffle/metric_control/custom_metric_form.tsx @@ -6,7 +6,7 @@ */ import React, { useState, useCallback } from 'react'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { EuiForm, EuiButton, @@ -78,7 +78,7 @@ export const CustomMetricForm = withTheme( } else if (aggregation && field) { const newMetric: SnapshotCustomMetricInput = { type: 'custom', - id: uuid.v1(), + id: uuidv1(), label, aggregation, field, diff --git a/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.test.ts b/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.test.ts index d3dfad0e4bbb0..10aeeadb74060 100644 --- a/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.test.ts +++ b/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.test.ts @@ -12,17 +12,15 @@ import { timeRange, chartOptions, } from '../../../../../utils/fixtures/metrics_explorer'; -import uuid from 'uuid'; -import { OutputBuffer } from 'uuid/interfaces'; import { MetricsExplorerYAxisMode, MetricsExplorerChartType, } from '../../hooks/use_metrics_explorer_options'; import { MetricsExplorerOptions } from '../../hooks/use_metrics_explorer_options'; +jest.mock('uuid', () => ({ + v1: jest.fn().mockReturnValue('test-id'), +})); -jest.mock('uuid'); -const mockedUuid = uuid as jest.Mocked; -mockedUuid.v1.mockReturnValue('test-id' as unknown as OutputBuffer); const series = { id: 'example-01', rows: [], columns: [] }; describe('createTSVBLink()', () => { diff --git a/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.ts b/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.ts index 30d521392d584..1f781daa934cb 100644 --- a/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.ts +++ b/x-pack/plugins/infra/public/pages/metrics/metrics_explorer/components/helpers/create_tsvb_link.ts @@ -6,7 +6,7 @@ */ import { encode } from '@kbn/rison'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { set } from '@kbn/safer-lodash-set'; import { LinkDescriptor } from '@kbn/observability-plugin/public'; import { TIMESTAMP_FIELD } from '../../../../../../common/constants'; @@ -35,9 +35,9 @@ const TSVB_WORKAROUND_INDEX_PATTERN = 'metric*'; export const metricsExplorerMetricToTSVBMetric = (metric: MetricsExplorerOptionsMetric) => { if (metric.aggregation === 'rate') { - const metricId = uuid.v1(); - const positiveOnlyId = uuid.v1(); - const derivativeId = uuid.v1(); + const metricId = uuidv1(); + const positiveOnlyId = uuidv1(); + const derivativeId = uuidv1(); return [ { id: metricId, @@ -60,12 +60,12 @@ export const metricsExplorerMetricToTSVBMetric = (metric: MetricsExplorerOptions const percentileValue = metric.aggregation === 'p95' ? '95' : '99'; return [ { - id: uuid.v1(), + id: uuidv1(), type: 'percentile', field: metric.field, percentiles: [ { - id: uuid.v1(), + id: uuidv1(), value: percentileValue, mode: 'line', percentile: '', @@ -77,7 +77,7 @@ export const metricsExplorerMetricToTSVBMetric = (metric: MetricsExplorerOptions } else { return [ { - id: uuid.v1(), + id: uuidv1(), type: metric.aggregation, field: metric.field || void 0, }, @@ -96,7 +96,7 @@ const mapMetricToSeries = fill: chartOptions.type === MetricsExplorerChartType.area ? 0.5 : 0, formatter: format === InfraFormatterType.bits ? InfraFormatterType.bytes : format, value_template: 'rate' === metric.aggregation ? '{{value}}/s' : '{{value}}', - id: uuid.v1(), + id: uuidv1(), line_width: 2, metrics: metricsExplorerMetricToTSVBMetric(metric), point_size: 0, @@ -163,7 +163,7 @@ export const createTSVBLink = ( axis_formatter: 'number', axis_position: 'left', axis_scale: 'normal', - id: uuid.v1(), + id: uuidv1(), default_index_pattern: tsvbIndexPattern, index_pattern: tsvbIndexPattern, interval: 'auto', diff --git a/x-pack/plugins/infra/server/lib/alerting/inventory_metric_threshold/inventory_metric_threshold_executor.ts b/x-pack/plugins/infra/server/lib/alerting/inventory_metric_threshold/inventory_metric_threshold_executor.ts index cb3ab0f834f96..b6e0c5dd578e5 100644 --- a/x-pack/plugins/infra/server/lib/alerting/inventory_metric_threshold/inventory_metric_threshold_executor.ts +++ b/x-pack/plugins/infra/server/lib/alerting/inventory_metric_threshold/inventory_metric_threshold_executor.ts @@ -6,7 +6,7 @@ */ import { i18n } from '@kbn/i18n'; -import { ALERT_REASON, ALERT_RULE_PARAMETERS } from '@kbn/rule-data-utils'; +import { ALERT_REASON } from '@kbn/rule-data-utils'; import { first, get } from 'lodash'; import { ActionGroup, @@ -95,7 +95,6 @@ export const createInventoryMetricThresholdExecutor = (libs: InfraBackendLibs) = id, fields: { [ALERT_REASON]: reason, - [ALERT_RULE_PARAMETERS]: params as any, // the type assumes the object is already flattened when writing the same way as when reading https://github.com/elastic/kibana/blob/main/x-pack/plugins/rule_registry/common/field_map/runtime_type_from_fieldmap.ts#L60 ...flattenAdditionalContext(additionalContext), }, }); diff --git a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/components/processor_form/field_components/drag_and_drop_text_list.tsx b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/components/processor_form/field_components/drag_and_drop_text_list.tsx index a27251978ab6f..ea9f460a5899a 100644 --- a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/components/processor_form/field_components/drag_and_drop_text_list.tsx +++ b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/components/processor_form/field_components/drag_and_drop_text_list.tsx @@ -7,7 +7,7 @@ import { i18n } from '@kbn/i18n'; import React, { useState, useCallback, memo } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { EuiButtonEmpty, EuiButtonIcon, @@ -74,8 +74,8 @@ function DragAndDropTextListComponent({ textDeserializer, textSerializer, }: Props): JSX.Element { - const [droppableId] = useState(() => uuid.v4()); - const [firstItemId] = useState(() => uuid.v4()); + const [droppableId] = useState(() => uuidv4()); + const [firstItemId] = useState(() => uuidv4()); const onDragEnd = useCallback( ({ source, destination }) => { diff --git a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/deserialize.ts b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/deserialize.ts index af452ac851232..a44fde65f4efe 100644 --- a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/deserialize.ts +++ b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/deserialize.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Processor } from '../../../../common/types'; import { ProcessorInternal, @@ -44,7 +44,7 @@ const convertToPipelineInternalProcessor = (processor: Processor): ProcessorInte ? convertProcessors(originalOnFailure) : (originalOnFailure as ProcessorInternal[] | undefined); return { - id: uuid.v4(), + id: uuidv4(), type, onFailure, options, diff --git a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/processors_reducer.ts b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/processors_reducer.ts index c0a3e88f50a8f..7071992caa237 100644 --- a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/processors_reducer.ts +++ b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/processors_reducer.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Reducer, useReducer, Dispatch } from 'react'; import { DeserializeResult } from '../deserialize'; import { getValue, setValue } from '../utils'; @@ -94,10 +94,10 @@ export const reducer: Reducer = (state, action) => { return setValue( targetSelector, state, - targetProcessor.concat({ ...processor, id: uuid.v4() }) + targetProcessor.concat({ ...processor, id: uuidv4() }) ); } else { - const processorWithId = { ...processor, id: uuid.v4() }; + const processorWithId = { ...processor, id: uuidv4() }; targetProcessor.onFailure = targetProcessor.onFailure ? targetProcessor.onFailure.concat(processorWithId) : [processorWithId]; diff --git a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/utils.ts b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/utils.ts index 889a2db971481..8eb0c635e9805 100644 --- a/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/utils.ts +++ b/x-pack/plugins/ingest_pipelines/public/application/components/pipeline_editor/processors_reducer/utils.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { State } from './processors_reducer'; import { ProcessorInternal, ProcessorSelector } from '../types'; import { DropSpecialLocations } from '../constants'; @@ -31,7 +31,7 @@ export const duplicateProcessor = (sourceProcessor: ProcessorInternal): Processo return { ...sourceProcessor, onFailure, - id: uuid.v4(), + id: uuidv4(), options: { ...sourceProcessor.options, }, diff --git a/x-pack/plugins/lens/common/constants.ts b/x-pack/plugins/lens/common/constants.ts index 329b1cb7d182b..1495410cdb14c 100644 --- a/x-pack/plugins/lens/common/constants.ts +++ b/x-pack/plugins/lens/common/constants.ts @@ -6,7 +6,8 @@ */ import rison from '@kbn/rison'; -import type { TimeRange } from '@kbn/data-plugin/common/query'; +import type { RefreshInterval, TimeRange } from '@kbn/data-plugin/common/query'; +import type { Filter } from '@kbn/es-query'; export const PLUGIN_ID = 'lens'; export const APP_ID = 'lens'; @@ -53,16 +54,35 @@ export function getBasePath() { const GLOBAL_RISON_STATE_PARAM = '_g'; -export function getEditPath(id: string | undefined, timeRange?: TimeRange) { - let timeParam = ''; +export function getEditPath( + id: string | undefined, + timeRange?: TimeRange, + filters?: Filter[], + refreshInterval?: RefreshInterval +) { + const searchArgs: { + time?: TimeRange; + filters?: Filter[]; + refreshInterval?: RefreshInterval; + } = {}; if (timeRange) { - timeParam = `?${GLOBAL_RISON_STATE_PARAM}=${rison.encode({ time: timeRange })}`; + searchArgs.time = timeRange; } + if (filters) { + searchArgs.filters = filters; + } + if (refreshInterval) { + searchArgs.refreshInterval = refreshInterval; + } + + const searchParam = Object.keys(searchArgs).length + ? `?${GLOBAL_RISON_STATE_PARAM}=${rison.encode(searchArgs)}` + : ''; return id - ? `#/edit/${encodeURIComponent(id)}${timeParam}` - : `#/${LENS_EDIT_BY_VALUE}${timeParam}`; + ? `#/edit/${encodeURIComponent(id)}${searchParam}` + : `#/${LENS_EDIT_BY_VALUE}${searchParam}`; } export function getFullPath(id?: string) { diff --git a/x-pack/plugins/lens/common/helpers.test.ts b/x-pack/plugins/lens/common/helpers.test.ts index 1bf3ec49a4780..bfc490fd1e977 100644 --- a/x-pack/plugins/lens/common/helpers.test.ts +++ b/x-pack/plugins/lens/common/helpers.test.ts @@ -5,6 +5,7 @@ * 2.0. */ +import { FilterStateStore } from '@kbn/es-query'; import { getEditPath } from './constants'; describe('getEditPath', function () { @@ -27,4 +28,76 @@ describe('getEditPath', function () { '#/edit/12345?_g=(time:(from:now-15m,to:now))' ); }); + + it('should return value when filters are given', () => { + expect( + getEditPath(undefined, undefined, [ + { + meta: { + alias: 'foo', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.APP_STATE, + }, + }, + { + meta: { + alias: 'bar', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.GLOBAL_STATE, + }, + }, + ]) + ).toEqual( + "#/edit_by_value?_g=(filters:!(('$state':(store:appState),meta:(alias:foo,disabled:!f,negate:!f)),('$state':(store:globalState),meta:(alias:bar,disabled:!f,negate:!f))))" + ); + }); + + it('should return value when refresh interval is given', () => { + expect(getEditPath(undefined, undefined, undefined, { pause: false, value: 10 })).toEqual( + '#/edit_by_value?_g=(refreshInterval:(pause:!f,value:10))' + ); + }); + + it('should return value when time, filters and refresh interval are given', () => { + expect( + getEditPath( + undefined, + { from: 'now-15m', to: 'now' }, + [ + { + meta: { + alias: 'foo', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.APP_STATE, + }, + }, + { + meta: { + alias: 'bar', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.GLOBAL_STATE, + }, + }, + ], + { + pause: false, + value: 10, + } + ) + ).toEqual( + "#/edit_by_value?_g=(filters:!(('$state':(store:appState),meta:(alias:foo,disabled:!f,negate:!f)),('$state':(store:globalState),meta:(alias:bar,disabled:!f,negate:!f))),refreshInterval:(pause:!f,value:10),time:(from:now-15m,to:now))" + ); + }); }); diff --git a/x-pack/plugins/lens/common/locator/locator.test.ts b/x-pack/plugins/lens/common/locator/locator.test.ts new file mode 100644 index 0000000000000..b91f3d6a0412f --- /dev/null +++ b/x-pack/plugins/lens/common/locator/locator.test.ts @@ -0,0 +1,172 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FilterStateStore } from '@kbn/es-query'; +import { LensAppLocatorDefinition, type LensAppLocatorParams } from './locator'; + +const savedObjectId: string = '571aaf70-4c88-11e8-b3d7-01146121b73d'; + +const setup = async () => { + const locator = new LensAppLocatorDefinition(); + + return { + locator, + }; +}; + +const lensShareableState: LensAppLocatorParams = { + visualization: { activeId: 'bar_chart', state: {} }, + activeDatasourceId: 'xxxxx', + datasourceStates: { formBased: { state: {} } }, + references: [], +}; + +function getParams(path: string, param: string) { + // just make it a valid URL + // in order to extract the search params + const basepathTest = 'http://localhost/'; + const url = new URL(path, basepathTest); + return url.searchParams.get(param); +} + +describe('Lens url generator', () => { + test('can create a link to Lens with no state and no saved viz', async () => { + const { locator } = await setup(); + const { app, path, state } = await locator.getLocation({}); + + expect(app).toBe('lens'); + expect(path).toBeDefined(); + expect(state.payload).toBeDefined(); + expect(Object.keys(state.payload)).toHaveLength(0); + }); + + test('can create a link to a saved viz in Lens', async () => { + const { locator } = await setup(); + const { path } = await locator.getLocation({ savedObjectId }); + + expect(path.includes(`#/edit/${savedObjectId}`)).toBe(true); + }); + + test('can specify specific time range', async () => { + const { locator } = await setup(); + const { path, state } = await locator.getLocation({ + resolvedDateRange: { fromDate: 'now', toDate: 'now-15m', mode: 'relative' }, + }); + expect(getParams(path, '_g')).toEqual('(time:(from:now,to:now-15m))'); + expect(state.payload.resolvedDateRange).toBeDefined(); + }); + + test('can specify query', async () => { + const { locator } = await setup(); + const { path, state } = await locator.getLocation({ + query: { + language: 'kuery', + query: 'foo', + }, + }); + expect(getParams(path, '_g')).toEqual('()'); + expect(state.payload).toEqual({ + query: { + language: 'kuery', + query: 'foo', + }, + }); + }); + + test('can specify local and global filters', async () => { + const { locator } = await setup(); + const { path, state } = await locator.getLocation({ + filters: [ + { + meta: { + alias: 'foo', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.APP_STATE, + }, + }, + { + meta: { + alias: 'bar', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.GLOBAL_STATE, + }, + }, + ], + }); + expect(getParams(path, '_g')).toEqual( + "(filters:!(('$state':(store:appState),meta:(alias:foo,disabled:!f,negate:!f))))" + ); + expect(state.payload).toEqual({ + filters: [ + { + meta: { + alias: 'foo', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.APP_STATE, + }, + }, + { + meta: { + alias: 'bar', + disabled: false, + negate: false, + }, + $state: { + store: FilterStateStore.GLOBAL_STATE, + }, + }, + ], + }); + }); + + test('can specify a search session id', async () => { + const { locator } = await setup(); + const { state } = await locator.getLocation({ + searchSessionId: '__test__', + }); + + expect(state.payload).toEqual({ searchSessionId: '__test__' }); + }); + + test('should return state if all params are passed correctly', async () => { + const { locator } = await setup(); + const { state } = await locator.getLocation(lensShareableState); + + expect(Object.keys(state.payload)).toHaveLength(Object.keys(lensShareableState).length); + }); + + test('should return no state for partial/missing state params', async () => { + const { locator } = await setup(); + const { state } = await locator.getLocation({ ...lensShareableState, references: undefined }); + + expect(Object.keys(state.payload)).toHaveLength(0); + }); + + test('should create data view when dataViewSpec is used', async () => { + const dataViewSpecMock = { + id: 'mock-id', + title: 'mock-title', + timeFieldName: 'mock-time-field-name', + }; + const { locator } = await setup(); + const { state } = await locator.getLocation({ + ...lensShareableState, + dataViewSpecs: [dataViewSpecMock], + }); + + expect(state.payload.dataViewSpecs).toEqual([dataViewSpecMock]); + }); +}); diff --git a/x-pack/plugins/lens/common/locator/locator.ts b/x-pack/plugins/lens/common/locator/locator.ts new file mode 100644 index 0000000000000..ea0e54136ffc9 --- /dev/null +++ b/x-pack/plugins/lens/common/locator/locator.ts @@ -0,0 +1,215 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import rison from '@kbn/rison'; +import type { SerializableRecord } from '@kbn/utility-types'; +import type { GlobalQueryStateFromUrl } from '@kbn/data-plugin/public'; +import type { LocatorDefinition, LocatorPublic } from '@kbn/share-plugin/common'; +import type { Filter, Query } from '@kbn/es-query'; +import type { DataViewSpec, SavedQuery } from '@kbn/data-plugin/common'; +import { SavedObjectReference } from '@kbn/core-saved-objects-common'; +import type { DateRange } from '../types'; + +export const LENS_APP_LOCATOR = 'LENS_APP_LOCATOR'; +export const LENS_SHARE_STATE_ACTION = 'LENS_SHARE_STATE_ACTION'; + +interface LensShareableState { + /** + * Optionally apply filters. + */ + filters?: Filter[]; + + /** + * Optionally set a query. + */ + query?: Query; + + /** + * Optionally set the date range in the date picker. + */ + resolvedDateRange?: DateRange & SerializableRecord; + + /** + * Optionally set the id of the used saved query + */ + savedQuery?: SavedQuery & SerializableRecord; + + /** + * Set the visualization configuration + */ + visualization: { activeId: string | null; state: unknown } & SerializableRecord; + + /** + * Set the active datasource used + */ + activeDatasourceId?: string; + + /** + * Set the datasources configurations + */ + datasourceStates: Record & SerializableRecord; + + /** + * Background search session id + */ + searchSessionId?: string; + + /** + * Set the references used in the Lens state + */ + references: Array; + + /** + * Pass adHoc dataViews specs used in the Lens state + */ + dataViewSpecs?: DataViewSpec[]; +} + +export interface LensAppLocatorParams extends SerializableRecord { + /** + * Optionally set saved object ID. + */ + savedObjectId?: string; + + /** + * Background search session id + */ + searchSessionId?: string; + + /** + * Optionally apply filters. + */ + filters?: Filter[]; + + /** + * Optionally set a query. + */ + query?: Query; + + /** + * Optionally set the date range in the date picker. + */ + resolvedDateRange?: DateRange & SerializableRecord; + + /** + * Optionally set the id of the used saved query + */ + savedQuery?: SavedQuery & SerializableRecord; + + /** + * In case of no savedObjectId passed, the properties above have to be passed + */ + + /** + * Set the active datasource used + */ + activeDatasourceId?: string | null; + + /** + * Set the visualization configuration + */ + visualization?: { activeId: string | null; state: unknown } & SerializableRecord; + + /** + * Set the datasources configurations + */ + datasourceStates?: Record & SerializableRecord; + + /** + * Set the references used in the Lens state + */ + references?: Array; + + /** + * Pass adHoc dataViews specs used in the Lens state + */ + dataViewSpecs?: DataViewSpec[]; +} + +export type LensAppLocator = LocatorPublic; + +/** + * Location state of scoped history (history instance of Kibana Platform application service) + */ +export interface MainHistoryLocationState { + type: typeof LENS_SHARE_STATE_ACTION; + payload: + | LensShareableState + | Omit< + LensShareableState, + 'activeDatasourceId' | 'visualization' | 'datasourceStates' | 'references' + >; +} + +function getStateFromParams(params: LensAppLocatorParams): MainHistoryLocationState['payload'] { + if (params.savedObjectId) { + return {}; + } + + // return no state for malformed state? + if ( + !( + params.activeDatasourceId && + params.datasourceStates && + params.visualization && + params.references + ) + ) { + return {}; + } + const outputState: LensShareableState = { + activeDatasourceId: params.activeDatasourceId!, + visualization: params.visualization!, + datasourceStates: Object.fromEntries( + Object.entries(params.datasourceStates!).map(([id, { state }]) => [id, state]) + ) as Record & SerializableRecord, + references: params.references!, + }; + if (params.dataViewSpecs) { + outputState.dataViewSpecs = params.dataViewSpecs; + } + return outputState; +} + +export class LensAppLocatorDefinition implements LocatorDefinition { + public readonly id = LENS_APP_LOCATOR; + + public readonly getLocation = async (params: LensAppLocatorParams) => { + const { filters, query, savedObjectId, resolvedDateRange, searchSessionId } = params; + const appState = getStateFromParams(params); + const queryState: GlobalQueryStateFromUrl = {}; + const { isFilterPinned } = await import('@kbn/es-query'); + + if (query) { + appState.query = query; + } + if (resolvedDateRange) { + appState.resolvedDateRange = resolvedDateRange; + queryState.time = { from: resolvedDateRange.fromDate, to: resolvedDateRange.toDate }; + } + if (filters?.length) { + appState.filters = filters; + queryState.filters = filters?.filter((f) => !isFilterPinned(f)); + } + + const savedObjectPath = savedObjectId ? `/edit/${encodeURIComponent(savedObjectId)}` : ''; + const basepath = `${window.location.origin}${window.location.pathname}`; + const url = new URL(basepath); + url.hash = savedObjectPath; + url.searchParams.append('_g', rison.encodeUnknown(queryState) || ''); + + if (searchSessionId) { + appState.searchSessionId = searchSessionId; + } + + return { + app: 'lens', + path: url.href.replace(basepath, ''), + state: { type: LENS_SHARE_STATE_ACTION, payload: appState }, + }; + }; +} diff --git a/x-pack/plugins/lens/public/app_plugin/app.test.tsx b/x-pack/plugins/lens/public/app_plugin/app.test.tsx index 648fd61203943..fbb82b11c0012 100644 --- a/x-pack/plugins/lens/public/app_plugin/app.test.tsx +++ b/x-pack/plugins/lens/public/app_plugin/app.test.tsx @@ -899,19 +899,19 @@ describe('Lens App', () => { }); }); - describe('download button', () => { - function getButton(inst: ReactWrapper): TopNavMenuData { + describe('share button', () => { + function getShareButton(inst: ReactWrapper): TopNavMenuData { return ( inst.find('[data-test-subj="lnsApp_topNav"]').prop('config') as TopNavMenuData[] - ).find((button) => button.testId === 'lnsApp_downloadCSVButton')!; + ).find((button) => button.testId === 'lnsApp_shareButton')!; } it('should be disabled when no data is available', async () => { const { instance } = await mountWith({ preloadedState: { isSaveable: true } }); - expect(getButton(instance).disableButton).toEqual(true); + expect(getShareButton(instance).disableButton).toEqual(true); }); - it('should disable download when not saveable', async () => { + it('should not disable share when not saveable', async () => { const { instance } = await mountWith({ preloadedState: { isSaveable: false, @@ -919,7 +919,7 @@ describe('Lens App', () => { }, }); - expect(getButton(instance).disableButton).toEqual(true); + expect(getShareButton(instance).disableButton).toEqual(false); }); it('should still be enabled even if the user is missing save permissions', async () => { @@ -928,7 +928,27 @@ describe('Lens App', () => { ...services.application, capabilities: { ...services.application.capabilities, - visualize: { save: false, saveQuery: false, show: true }, + visualize: { save: false, saveQuery: false, show: true, createShortUrl: true }, + }, + }; + + const { instance } = await mountWith({ + services, + preloadedState: { + isSaveable: true, + activeData: { layer1: { type: 'datatable', columns: [], rows: [] } }, + }, + }); + expect(getShareButton(instance).disableButton).toEqual(false); + }); + + it('should still be enabled even if the user is missing shortUrl permissions', async () => { + const services = makeDefaultServicesForApp(); + services.application = { + ...services.application, + capabilities: { + ...services.application.capabilities, + visualize: { save: true, saveQuery: false, show: true, createShortUrl: false }, }, }; @@ -939,7 +959,27 @@ describe('Lens App', () => { activeData: { layer1: { type: 'datatable', columns: [], rows: [] } }, }, }); - expect(getButton(instance).disableButton).toEqual(false); + expect(getShareButton(instance).disableButton).toEqual(false); + }); + + it('should be disabled if the user is missing shortUrl permissions and visualization is not saveable', async () => { + const services = makeDefaultServicesForApp(); + services.application = { + ...services.application, + capabilities: { + ...services.application.capabilities, + visualize: { save: false, saveQuery: false, show: true, createShortUrl: false }, + }, + }; + + const { instance } = await mountWith({ + services, + preloadedState: { + isSaveable: false, + activeData: { layer1: { type: 'datatable', columns: [], rows: [] } }, + }, + }); + expect(getShareButton(instance).disableButton).toEqual(true); }); }); diff --git a/x-pack/plugins/lens/public/app_plugin/app.tsx b/x-pack/plugins/lens/public/app_plugin/app.tsx index 81cc45e0af432..6c70000ed4e0c 100644 --- a/x-pack/plugins/lens/public/app_plugin/app.tsx +++ b/x-pack/plugins/lens/public/app_plugin/app.tsx @@ -12,6 +12,7 @@ import { EuiBreadcrumb, EuiConfirmModal } from '@elastic/eui'; import { useExecutionContext, useKibana } from '@kbn/kibana-react-plugin/public'; import { OnSaveProps } from '@kbn/saved-objects-plugin/public'; import type { VisualizeFieldContext } from '@kbn/ui-actions-plugin/public'; +import type { LensAppLocatorParams } from '../../common/locator/locator'; import { LensAppProps, LensAppServices } from './types'; import { LensTopNavMenu } from './lens_top_nav'; import { LensByReferenceInput } from '../embeddable'; @@ -32,7 +33,10 @@ import { SaveModalContainer, runSaveLensVisualization } from './save_modal_conta import { LensInspector } from '../lens_inspector_service'; import { getEditPath } from '../../common'; import { isLensEqual } from './lens_document_equality'; -import { IndexPatternServiceAPI, createIndexPatternService } from '../data_views_service/service'; +import { + type IndexPatternServiceAPI, + createIndexPatternService, +} from '../data_views_service/service'; import { replaceIndexpattern } from '../state_management/lens_slice'; export type SaveProps = Omit & { @@ -77,6 +81,8 @@ export function App({ executionContext, // Temporarily required until the 'by value' paradigm is default. dashboardFeatureFlag, + locator, + share, } = lensAppServices; const saveAndExit = useRef<() => void>(); @@ -109,6 +115,8 @@ export function App({ selectSavedObjectFormat(state, selectorDependencies) ); + const shortUrls = useMemo(() => share?.url.shortUrls.get(null), [share]); + // Used to show a popover that guides the user towards changing the date range when no data is available. const [indicateNoData, setIndicateNoData] = useState(false); const [isSaveModalVisible, setIsSaveModalVisible] = useState(false); @@ -427,6 +435,31 @@ export function App({ }; }, []); + // remember latest URL based on the configuration + // url_panel_content has a similar logic + const shareURLCache = useRef({ params: '', url: '' }); + + const shortUrlService = useCallback( + async (params: LensAppLocatorParams) => { + const cacheKey = JSON.stringify(params); + if (shareURLCache.current.params === cacheKey) { + return shareURLCache.current.url; + } + if (locator && shortUrls) { + // This is a stripped down version of what the share URL plugin is doing + const relativeUrl = await shortUrls.create({ locator, params }); + const absoluteShortUrl = application.getUrlForApp('', { + path: `/r/s/${relativeUrl.data.slug}`, + absolute: true, + }); + shareURLCache.current = { params: cacheKey, url: absoluteShortUrl }; + return absoluteShortUrl; + } + return ''; + }, + [locator, application, shortUrls] + ); + const returnToOriginSwitchLabelForContext = initialContext && 'isEmbeddable' in initialContext && @@ -457,6 +490,14 @@ export function App({ title={persistedDoc?.title} lensInspector={lensInspector} currentDoc={currentDoc} + isCurrentStateDirty={ + !isLensEqual( + persistedDoc, + lastKnownDoc, + data.query.filterManager.inject.bind(data.query.filterManager), + datasourceMap + ) + } goBackToOriginatingApp={goBackToOriginatingApp} contextOriginatingApp={contextOriginatingApp} initialContextIsEmbedded={initialContextIsEmbedded} @@ -465,6 +506,7 @@ export function App({ theme$={theme$} indexPatternService={indexPatternService} onTextBasedSavedAndExit={onTextBasedSavedAndExit} + shortUrlService={shortUrlService} /> {getLegacyUrlConflictCallout()} {(!isLoading || persistedDoc) && ( diff --git a/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content.tsx b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content.tsx new file mode 100644 index 0000000000000..59d76f78123fc --- /dev/null +++ b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content.tsx @@ -0,0 +1,52 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { EuiButton, EuiForm, EuiSpacer, EuiText } from '@elastic/eui'; +import React from 'react'; +import { FormattedMessage } from '@kbn/i18n-react'; + +export interface DownloadPanelContentProps { + isDisabled: boolean; + onClick: () => void; + warnings?: React.ReactNode[]; +} + +export function DownloadPanelContent({ + isDisabled, + onClick, + warnings = [], +}: DownloadPanelContentProps) { + return ( + + +

    + +

    + {warnings.map((warning, i) => ( +

    {warning}

    + ))} +
    + + + + +
    + ); +} diff --git a/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content_lazy.tsx b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content_lazy.tsx new file mode 100644 index 0000000000000..dded4f4768a16 --- /dev/null +++ b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_panel_content_lazy.tsx @@ -0,0 +1,39 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { EuiSpacer, EuiFlexGroup, EuiFlexItem, EuiLoadingSpinner } from '@elastic/eui'; +import * as React from 'react'; +import { FC, lazy, Suspense } from 'react'; +import type { DownloadPanelContentProps } from './csv_download_panel_content'; + +const LazyComponent = lazy(() => + import('./csv_download_panel_content').then(({ DownloadPanelContent }) => ({ + default: DownloadPanelContent, + })) +); + +export const PanelSpinner: React.FC = (props) => { + return ( + <> + + + + + + + + + ); +}; + +export const DownloadPanelContent: FC> = (props) => { + return ( + }> + + + ); +}; diff --git a/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_provider.tsx b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_provider.tsx new file mode 100644 index 0000000000000..bdcb5e5e74edd --- /dev/null +++ b/x-pack/plugins/lens/public/app_plugin/csv_download_provider/csv_download_provider.tsx @@ -0,0 +1,155 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; +import React from 'react'; +import { tableHasFormulas } from '@kbn/data-plugin/common'; +import { downloadMultipleAs, ShareContext, ShareMenuProvider } from '@kbn/share-plugin/public'; +import { exporters } from '@kbn/data-plugin/public'; +import { IUiSettingsClient } from '@kbn/core-ui-settings-browser'; +import { FormatFactory } from '../../../common'; +import { DownloadPanelContent } from './csv_download_panel_content_lazy'; +import { TableInspectorAdapter } from '../../editor_frame_service/types'; + +declare global { + interface Window { + /** + * Debug setting to test CSV download + */ + ELASTIC_LENS_CSV_DOWNLOAD_DEBUG?: boolean; + ELASTIC_LENS_CSV_CONTENT?: Record; + } +} + +async function downloadCSVs({ + activeData, + title, + formatFactory, + uiSettings, +}: { + title: string; + activeData: TableInspectorAdapter; + formatFactory: FormatFactory; + uiSettings: IUiSettingsClient; +}) { + if (!activeData) { + if (window.ELASTIC_LENS_CSV_DOWNLOAD_DEBUG) { + window.ELASTIC_LENS_CSV_CONTENT = undefined; + } + return; + } + const datatables = Object.values(activeData); + const content = datatables.reduce>( + (memo, datatable, i) => { + // skip empty datatables + if (datatable) { + const postFix = datatables.length > 1 ? `-${i + 1}` : ''; + + memo[`${title}${postFix}.csv`] = { + content: exporters.datatableToCSV(datatable, { + csvSeparator: uiSettings.get('csv:separator', ','), + quoteValues: uiSettings.get('csv:quoteValues', true), + formatFactory, + escapeFormulaValues: false, + }), + type: exporters.CSV_MIME_TYPE, + }; + } + return memo; + }, + {} + ); + if (window.ELASTIC_LENS_CSV_DOWNLOAD_DEBUG) { + window.ELASTIC_LENS_CSV_CONTENT = content; + } + if (content) { + downloadMultipleAs(content); + } +} + +function getWarnings(activeData: TableInspectorAdapter) { + const messages = []; + if (activeData) { + const datatables = Object.values(activeData); + const formulaDetected = datatables.some((datatable) => { + return tableHasFormulas(datatable.columns, datatable.rows); + }); + if (formulaDetected) { + messages.push( + i18n.translate('xpack.lens.app.downloadButtonFormulasWarning', { + defaultMessage: + 'Your CSV contains characters that spreadsheet applications might interpret as formulas.', + }) + ); + } + } + return messages; +} + +interface DownloadPanelShareOpts { + uiSettings: IUiSettingsClient; + formatFactoryFn: () => FormatFactory; +} + +export const downloadCsvShareProvider = ({ + uiSettings, + formatFactoryFn, +}: DownloadPanelShareOpts): ShareMenuProvider => { + const getShareMenuItems = ({ objectType, sharingData, onClose }: ShareContext) => { + if ('lens_visualization' !== objectType) { + return []; + } + + const { title, activeData, csvEnabled } = sharingData as { + title: string; + activeData: TableInspectorAdapter; + csvEnabled: boolean; + }; + + const panelTitle = i18n.translate( + 'xpack.lens.reporting.shareContextMenu.csvReportsButtonLabel', + { + defaultMessage: 'CSV Download', + } + ); + + return [ + { + shareMenuItem: { + name: panelTitle, + icon: 'document', + disabled: !csvEnabled, + sortOrder: 1, + }, + panel: { + id: 'csvDownloadPanel', + title: panelTitle, + content: ( + { + await downloadCSVs({ + title, + formatFactory: formatFactoryFn(), + activeData, + uiSettings, + }); + onClose?.(); + }} + /> + ), + }, + }, + ]; + }; + + return { + id: 'csvDownload', + getShareMenuItems, + }; +}; diff --git a/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx b/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx index 2b94c0bf20c6e..4a498cbb23266 100644 --- a/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx +++ b/x-pack/plugins/lens/public/app_plugin/lens_top_nav.tsx @@ -11,19 +11,12 @@ import React, { useCallback, useEffect, useMemo, useState, useRef } from 'react' import { isOfAggregateQueryType } from '@kbn/es-query'; import { useStore } from 'react-redux'; import { TopNavMenuData } from '@kbn/navigation-plugin/public'; -import { downloadMultipleAs } from '@kbn/share-plugin/public'; -import { tableHasFormulas } from '@kbn/data-plugin/common'; -import { exporters, getEsQueryConfig } from '@kbn/data-plugin/public'; +import { getEsQueryConfig } from '@kbn/data-plugin/public'; import type { DataView } from '@kbn/data-views-plugin/public'; import { useKibana } from '@kbn/kibana-react-plugin/public'; import { DataViewPickerProps } from '@kbn/unified-search-plugin/public'; import { ENABLE_SQL } from '../../common'; -import { - LensAppServices, - LensTopNavActions, - LensTopNavMenuProps, - LensTopNavTooltips, -} from './types'; +import { LensAppServices, LensTopNavActions, LensTopNavMenuProps } from './types'; import { toggleSettingsMenuOpen } from './settings_menu'; import { setState, @@ -42,16 +35,72 @@ import { import { combineQueryAndFilters, getLayerMetaInfo } from './show_underlying_data'; import { changeIndexPattern } from '../state_management/lens_slice'; import { LensByReferenceInput } from '../embeddable'; +import { getShareURL } from './share_action'; -function getLensTopNavConfig(options: { +function getSaveButtonMeta({ + contextFromEmbeddable, + showSaveAndReturn, + showReplaceInDashboard, + showReplaceInCanvas, +}: { + contextFromEmbeddable: boolean | undefined; showSaveAndReturn: boolean; - enableExportToCSV: boolean; - showOpenInDiscover?: boolean; - showCancel: boolean; + showReplaceInDashboard: boolean; + showReplaceInCanvas: boolean; +}) { + if (showSaveAndReturn) { + return { + label: contextFromEmbeddable + ? i18n.translate('xpack.lens.app.saveAndReplace', { + defaultMessage: 'Save and replace', + }) + : i18n.translate('xpack.lens.app.saveAndReturn', { + defaultMessage: 'Save and return', + }), + emphasize: true, + iconType: contextFromEmbeddable ? 'save' : 'checkInCircleFilled', + testId: 'lnsApp_saveAndReturnButton', + description: i18n.translate('xpack.lens.app.saveAndReturnButtonAriaLabel', { + defaultMessage: 'Save the current lens visualization and return to the last app', + }), + }; + } + + if (showReplaceInDashboard) { + return { + label: i18n.translate('xpack.lens.app.replaceInDashboard', { + defaultMessage: 'Replace in dashboard', + }), + emphasize: true, + iconType: 'merge', + testId: 'lnsApp_replaceInDashboardButton', + description: i18n.translate('xpack.lens.app.replaceInDashboardButtonAriaLabel', { + defaultMessage: + 'Replace legacy visualization with lens visualization and return to the dashboard', + }), + }; + } + + if (showReplaceInCanvas) { + return { + label: i18n.translate('xpack.lens.app.replaceInCanvas', { + defaultMessage: 'Replace in canvas', + }), + emphasize: true, + iconType: 'merge', + testId: 'lnsApp_replaceInCanvasButton', + description: i18n.translate('xpack.lens.app.replaceInCanvasButtonAriaLabel', { + defaultMessage: + 'Replace legacy visualization with lens visualization and return to the canvas', + }), + }; + } +} + +function getLensTopNavConfig(options: { isByValueMode: boolean; allowByValue: boolean; actions: LensTopNavActions; - tooltips: LensTopNavTooltips; savingToLibraryPermitted: boolean; savingToDashboardPermitted: boolean; contextOriginatingApp?: string; @@ -62,34 +111,28 @@ function getLensTopNavConfig(options: { }): TopNavMenuData[] { const { actions, - showCancel, allowByValue, - enableExportToCSV, - showOpenInDiscover, - showSaveAndReturn, savingToLibraryPermitted, savingToDashboardPermitted, - tooltips, contextOriginatingApp, - isSaveable, showReplaceInDashboard, showReplaceInCanvas, contextFromEmbeddable, + isByValueMode, } = options; const topNavMenu: TopNavMenuData[] = []; + const showSaveAndReturn = actions.saveAndReturn.visible; + const enableSaveButton = savingToLibraryPermitted || - (allowByValue && - savingToDashboardPermitted && - !options.isByValueMode && - !options.showSaveAndReturn); + (allowByValue && savingToDashboardPermitted && !isByValueMode && !showSaveAndReturn); - const saveButtonLabel = options.isByValueMode + const saveButtonLabel = isByValueMode ? i18n.translate('xpack.lens.app.addToLibrary', { defaultMessage: 'Save to library', }) - : options.showSaveAndReturn + : actions.saveAndReturn.visible ? i18n.translate('xpack.lens.app.saveAs', { defaultMessage: 'Save as', }) @@ -97,38 +140,38 @@ function getLensTopNavConfig(options: { defaultMessage: 'Save', }); - if (contextOriginatingApp && !showCancel) { + if (contextOriginatingApp && !actions.cancel.visible) { topNavMenu.push({ label: i18n.translate('xpack.lens.app.goBackLabel', { defaultMessage: `Go back to {contextOriginatingApp}`, values: { contextOriginatingApp }, }), - run: actions.goBack, + run: actions.goBack.execute, className: 'lnsNavItem__withDivider', testId: 'lnsApp_goBackToAppButton', description: i18n.translate('xpack.lens.app.goBackLabel', { defaultMessage: `Go back to {contextOriginatingApp}`, values: { contextOriginatingApp }, }), - disableButton: false, + disableButton: !actions.goBack.enabled, }); } - if (showOpenInDiscover) { + if (actions.getUnderlyingDataUrl.visible) { const exploreDataInDiscoverLabel = i18n.translate('xpack.lens.app.exploreDataInDiscover', { defaultMessage: 'Explore data in Discover', }); topNavMenu.push({ label: exploreDataInDiscoverLabel, - run: () => {}, + run: actions.getUnderlyingDataUrl.execute, testId: 'lnsApp_openInDiscover', className: 'lnsNavItem__withDivider', description: exploreDataInDiscoverLabel, - disableButton: Boolean(tooltips.showUnderlyingDataWarning()), - tooltip: tooltips.showUnderlyingDataWarning, + disableButton: !actions.getUnderlyingDataUrl.enabled, + tooltip: actions.getUnderlyingDataUrl.tooltip, target: '_blank', - href: actions.getUnderlyingDataUrl(), + href: actions.getUnderlyingDataUrl.getLink?.(), }); } @@ -136,7 +179,7 @@ function getLensTopNavConfig(options: { label: i18n.translate('xpack.lens.app.inspect', { defaultMessage: 'Inspect', }), - run: actions.inspect, + run: actions.inspect.execute, testId: 'lnsApp_inspectButton', description: i18n.translate('xpack.lens.app.inspectAriaLabel', { defaultMessage: 'inspect', @@ -144,24 +187,26 @@ function getLensTopNavConfig(options: { disableButton: false, }); - topNavMenu.push({ - label: i18n.translate('xpack.lens.app.downloadCSV', { - defaultMessage: 'Download as CSV', - }), - run: actions.exportToCSV, - testId: 'lnsApp_downloadCSVButton', - description: i18n.translate('xpack.lens.app.downloadButtonAriaLabel', { - defaultMessage: 'Download the data as CSV file', - }), - disableButton: !enableExportToCSV, - tooltip: tooltips.showExportWarning, - }); + if (actions.share.visible) { + topNavMenu.push({ + label: i18n.translate('xpack.lens.app.shareTitle', { + defaultMessage: 'Share', + }), + run: actions.share.execute, + testId: 'lnsApp_shareButton', + description: i18n.translate('xpack.lens.app.shareTitleAria', { + defaultMessage: 'Share visualization', + }), + disableButton: !actions.share.enabled, + tooltip: actions.share.tooltip, + }); + } topNavMenu.push({ label: i18n.translate('xpack.lens.app.settings', { defaultMessage: 'Settings', }), - run: actions.openSettings, + run: actions.openSettings.execute, className: 'lnsNavItem__withDivider', testId: 'lnsApp_settingsButton', description: i18n.translate('xpack.lens.app.settingsAriaLabel', { @@ -169,12 +214,12 @@ function getLensTopNavConfig(options: { }), }); - if (showCancel) { + if (actions.cancel.visible) { topNavMenu.push({ label: i18n.translate('xpack.lens.app.cancel', { defaultMessage: 'Cancel', }), - run: actions.cancel, + run: actions.cancel.execute, testId: 'lnsApp_cancelButton', description: i18n.translate('xpack.lens.app.cancelButtonAriaLabel', { defaultMessage: 'Return to the last app without saving changes', @@ -188,7 +233,7 @@ function getLensTopNavConfig(options: { ? 'save' : undefined, emphasize: showReplaceInDashboard || showReplaceInCanvas ? false : !showSaveAndReturn, - run: actions.showSaveModal, + run: actions.showSaveModal.execute, testId: 'lnsApp_saveButton', description: i18n.translate('xpack.lens.app.saveButtonAriaLabel', { defaultMessage: 'Save the current lens visualization', @@ -196,59 +241,21 @@ function getLensTopNavConfig(options: { disableButton: !enableSaveButton, }); - if (showSaveAndReturn) { - topNavMenu.push({ - label: contextFromEmbeddable - ? i18n.translate('xpack.lens.app.saveAndReplace', { - defaultMessage: 'Save and replace', - }) - : i18n.translate('xpack.lens.app.saveAndReturn', { - defaultMessage: 'Save and return', - }), - emphasize: true, - iconType: contextFromEmbeddable ? 'save' : 'checkInCircleFilled', - run: actions.saveAndReturn, - testId: 'lnsApp_saveAndReturnButton', - disableButton: !isSaveable, - description: i18n.translate('xpack.lens.app.saveAndReturnButtonAriaLabel', { - defaultMessage: 'Save the current lens visualization and return to the last app', - }), - }); - } + const saveButtonMeta = getSaveButtonMeta({ + showSaveAndReturn, + showReplaceInDashboard, + showReplaceInCanvas, + contextFromEmbeddable, + }); - if (showReplaceInDashboard) { + if (saveButtonMeta) { topNavMenu.push({ - label: i18n.translate('xpack.lens.app.replaceInDashboard', { - defaultMessage: 'Replace in dashboard', - }), - emphasize: true, - iconType: 'merge', - run: actions.saveAndReturn, - testId: 'lnsApp_replaceInDashboardButton', - disableButton: !isSaveable, - description: i18n.translate('xpack.lens.app.replaceInDashboardButtonAriaLabel', { - defaultMessage: - 'Replace legacy visualization with lens visualization and return to the dashboard', - }), + ...saveButtonMeta, + run: actions.saveAndReturn.execute, + disableButton: !actions.saveAndReturn.enabled, }); } - if (showReplaceInCanvas) { - topNavMenu.push({ - label: i18n.translate('xpack.lens.app.replaceInCanvas', { - defaultMessage: 'Replace in canvas', - }), - emphasize: true, - iconType: 'merge', - run: actions.saveAndReturn, - testId: 'lnsApp_replaceInCanvasButton', - disableButton: !isSaveable, - description: i18n.translate('xpack.lens.app.replaceInCanvasButtonAriaLabel', { - defaultMessage: - 'Replace legacy visualization with lens visualization and return to the canvas', - }), - }); - } return topNavMenu; } @@ -274,10 +281,11 @@ export const LensTopNavMenu = ({ indexPatternService, currentDoc, onTextBasedSavedAndExit, + shortUrlService, + isCurrentStateDirty, }: LensTopNavMenuProps) => { const { data, - fieldFormats, navigation, uiSettings, application, @@ -514,6 +522,8 @@ export const LensTopNavMenu = ({ const lensStore = useStore(); + const adHocDataViews = indexPatterns.filter((pattern) => !pattern.isPersisted()); + const topNavConfig = useMemo(() => { const showReplaceInDashboard = initialContext?.originatingApp === 'dashboards' && @@ -523,20 +533,23 @@ export const LensTopNavMenu = ({ !(initialInput as LensByReferenceInput)?.savedObjectId; const contextFromEmbeddable = initialContext && 'isEmbeddable' in initialContext && initialContext.isEmbeddable; + const showSaveAndReturn = + !(showReplaceInDashboard || showReplaceInCanvas) && + (Boolean( + isLinkedToOriginatingApp && + // Temporarily required until the 'by value' paradigm is default. + (dashboardFeatureFlag.allowByValueEmbeddables || Boolean(initialInput)) + ) || + Boolean(initialContextIsEmbedded)); + + const hasData = Boolean(activeData && Object.keys(activeData).length); + const csvEnabled = Boolean(isSaveable && hasData); + const shareUrlEnabled = Boolean(application.capabilities.visualize.createShortUrl && hasData); + + const showShareMenu = csvEnabled || shareUrlEnabled; const baseMenuEntries = getLensTopNavConfig({ - showSaveAndReturn: - !(showReplaceInDashboard || showReplaceInCanvas) && - (Boolean( - isLinkedToOriginatingApp && - // Temporarily required until the 'by value' paradigm is default. - (dashboardFeatureFlag.allowByValueEmbeddables || Boolean(initialInput)) - ) || - Boolean(initialContextIsEmbedded)), - enableExportToCSV: Boolean(isSaveable && activeData && Object.keys(activeData).length), - showOpenInDiscover: Boolean(layerMetaInfo?.isVisible), isByValueMode: getIsByValueMode(), allowByValue: dashboardFeatureFlag.allowByValueEmbeddables, - showCancel: Boolean(isLinkedToOriginatingApp), savingToLibraryPermitted, savingToDashboardPermitted, isSaveable, @@ -544,155 +557,205 @@ export const LensTopNavMenu = ({ showReplaceInDashboard, showReplaceInCanvas, contextFromEmbeddable, - tooltips: { - showExportWarning: () => { - if (activeData) { - const datatables = Object.values(activeData); - const formulaDetected = datatables.some((datatable) => { - return tableHasFormulas(datatable.columns, datatable.rows); - }); - if (formulaDetected) { - return i18n.translate('xpack.lens.app.downloadButtonFormulasWarning', { - defaultMessage: - 'Your CSV contains characters that spreadsheet applications might interpret as formulas.', + actions: { + inspect: { visible: true, execute: () => lensInspector.inspect({ title }) }, + share: { + visible: true, + enabled: showShareMenu, + tooltip: () => { + if (!showShareMenu) { + return i18n.translate('xpack.lens.app.shareButtonDisabledWarning', { + defaultMessage: 'The visualization has no data to share.', }); } - } - return undefined; - }, - showUnderlyingDataWarning: () => { - return layerMetaInfo?.error; - }, - }, - actions: { - inspect: () => lensInspector.inspect({ title }), - exportToCSV: () => { - if (!activeData) { - return; - } - const datatables = Object.values(activeData); - const content = datatables.reduce>( - (memo, datatable, i) => { - // skip empty datatables - if (datatable) { - const postFix = datatables.length > 1 ? `-${i + 1}` : ''; + }, + execute: async (anchorElement) => { + if (!share) { + return; + } + const sharingData = { + activeData, + csvEnabled, + title: title || unsavedTitle, + }; - memo[`${title || unsavedTitle}${postFix}.csv`] = { - content: exporters.datatableToCSV(datatable, { - csvSeparator: uiSettings.get('csv:separator', ','), - quoteValues: uiSettings.get('csv:quoteValues', true), - formatFactory: fieldFormats.deserialize, - escapeFormulaValues: false, - }), - type: exporters.CSV_MIME_TYPE, - }; - } - return memo; - }, - {} - ); - if (content) { - downloadMultipleAs(content); - } - }, - saveAndReturn: () => { - if (isSaveable) { - // disabling the validation on app leave because the document has been saved. - onAppLeave((actions) => { - return actions.default(); - }); - runSave( + const { shareableUrl, savedObjectURL } = await getShareURL( + shortUrlService, + { application, data }, { - newTitle: - title || - (initialContext && 'isEmbeddable' in initialContext && initialContext.isEmbeddable - ? i18n.translate('xpack.lens.app.convertedLabel', { - defaultMessage: '{title} (converted)', - values: { - title: - initialContext.title || `${initialContext.visTypeTitle} visualization`, - }, - }) - : ''), - newCopyOnSave: false, - isTitleDuplicateConfirmed: false, - returnToOrigin: true, - }, - { - saveToLibrary: - (initialInput && attributeService.inputIsRefType(initialInput)) ?? false, + filters, + query, + activeDatasourceId, + datasourceStates, + datasourceMap, + visualizationMap, + visualization, + currentDoc, + adHocDataViews: adHocDataViews.map((dataView) => dataView.toSpec()), } ); - } + + share.toggleShareContextMenu({ + anchorElement, + allowEmbed: false, + allowShortUrl: false, // we'll manage this implicitly via the new service + shareableUrl: shareableUrl || '', + shareableUrlForSavedObject: savedObjectURL.href, + objectId: currentDoc?.savedObjectId, + objectType: 'lens_visualization', + objectTypeTitle: i18n.translate('xpack.lens.app.share.panelTitle', { + defaultMessage: 'visualization', + }), + sharingData, + isDirty: isCurrentStateDirty, + // disable the menu if both shortURL permission and the visualization has not been saved + // TODO: improve here the disabling state with more specific checks + disabledShareUrl: Boolean(!shareUrlEnabled && !currentDoc?.savedObjectId), + showPublicUrlSwitch: () => false, + onClose: () => { + anchorElement?.focus(); + }, + }); + }, }, - showSaveModal: () => { - if (savingToDashboardPermitted || savingToLibraryPermitted) { - setIsSaveModalVisible(true); - } + saveAndReturn: { + visible: showSaveAndReturn, + enabled: isSaveable, + execute: () => { + if (isSaveable) { + // disabling the validation on app leave because the document has been saved. + onAppLeave((actions) => { + return actions.default(); + }); + runSave( + { + newTitle: + title || + (initialContext && + 'isEmbeddable' in initialContext && + initialContext.isEmbeddable + ? i18n.translate('xpack.lens.app.convertedLabel', { + defaultMessage: '{title} (converted)', + values: { + title: + initialContext.title || + `${initialContext.visTypeTitle} visualization`, + }, + }) + : ''), + newCopyOnSave: false, + isTitleDuplicateConfirmed: false, + returnToOrigin: true, + }, + { + saveToLibrary: + (initialInput && attributeService.inputIsRefType(initialInput)) ?? false, + } + ); + } + }, }, - goBack: () => { - if (contextOriginatingApp) { - goBackToOriginatingApp?.(); - } + showSaveModal: { + visible: Boolean(savingToDashboardPermitted || savingToLibraryPermitted), + execute: () => { + if (savingToDashboardPermitted || savingToLibraryPermitted) { + setIsSaveModalVisible(true); + } + }, }, - cancel: () => { - if (redirectToOrigin) { - redirectToOrigin(); - } + goBack: { + visible: Boolean(contextOriginatingApp), + enabled: Boolean(contextOriginatingApp), + execute: () => { + if (contextOriginatingApp) { + goBackToOriginatingApp?.(); + } + }, }, - getUnderlyingDataUrl: () => { - if (!layerMetaInfo) { - return; - } - const { error, meta } = layerMetaInfo; - // If Discover is not available, return - // If there's no data, return - if (error || !discoverLocator || !meta) { - return; - } - const { filters: newFilters, query: newQuery } = combineQueryAndFilters( - query, - filters, - meta, - indexPatterns, - getEsQueryConfig(uiSettings) - ); + cancel: { + visible: Boolean(isLinkedToOriginatingApp), + execute: () => { + if (redirectToOrigin) { + redirectToOrigin(); + } + }, + }, + getUnderlyingDataUrl: { + visible: Boolean(layerMetaInfo?.isVisible), + enabled: !layerMetaInfo?.error, + tooltip: () => { + return layerMetaInfo?.error; + }, + execute: () => {}, + getLink: () => { + if (!layerMetaInfo) { + return; + } + const { error, meta } = layerMetaInfo; + // If Discover is not available, return + // If there's no data, return + if (error || !discoverLocator || !meta) { + return; + } + const { filters: newFilters, query: newQuery } = combineQueryAndFilters( + query, + filters, + meta, + indexPatterns, + getEsQueryConfig(uiSettings) + ); - return discoverLocator.getRedirectUrl({ - dataViewSpec: dataViews.indexPatterns[meta.id]?.spec, - timeRange: data.query.timefilter.timefilter.getTime(), - filters: newFilters, - query: isOnTextBasedMode ? query : newQuery, - columns: meta.columns, - }); + return discoverLocator.getRedirectUrl({ + dataViewSpec: dataViews.indexPatterns[meta.id]?.spec, + timeRange: data.query.timefilter.timefilter.getTime(), + filters: newFilters, + query: isOnTextBasedMode ? query : newQuery, + columns: meta.columns, + }); + }, + }, + openSettings: { + visible: true, + execute: (anchorElement) => + toggleSettingsMenuOpen({ + lensStore, + anchorElement, + theme$, + }), }, - openSettings: (anchorElement: HTMLElement) => - toggleSettingsMenuOpen({ - lensStore, - anchorElement, - theme$, - }), }, }); return [...(additionalMenuEntries || []), ...baseMenuEntries]; }, [ + initialContext, + initialInput, isLinkedToOriginatingApp, dashboardFeatureFlag.allowByValueEmbeddables, - initialInput, initialContextIsEmbedded, - isSaveable, activeData, - layerMetaInfo, + isSaveable, + shortUrlService, + application, getIsByValueMode, savingToLibraryPermitted, savingToDashboardPermitted, contextOriginatingApp, + layerMetaInfo, additionalMenuEntries, lensInspector, title, + share, unsavedTitle, - uiSettings, - fieldFormats.deserialize, + data, + filters, + query, + activeDatasourceId, + datasourceStates, + datasourceMap, + visualizationMap, + visualization, + currentDoc, + isCurrentStateDirty, onAppLeave, runSave, attributeService, @@ -700,15 +763,13 @@ export const LensTopNavMenu = ({ goBackToOriginatingApp, redirectToOrigin, discoverLocator, - query, - filters, indexPatterns, + uiSettings, dataViews.indexPatterns, - data.query.timefilter.timefilter, isOnTextBasedMode, lensStore, theme$, - initialContext, + adHocDataViews, ]); const onQuerySubmitWrapped = useCallback( @@ -919,7 +980,7 @@ export const LensTopNavMenu = ({ onAddField: addField, onDataViewCreated: createNewDataView, onCreateDefaultAdHocDataView, - adHocDataViews: indexPatterns.filter((pattern) => !pattern.isPersisted()), + adHocDataViews, onChangeDataView: async (newIndexPatternId: string) => { const currentDataView = await data.dataViews.get(newIndexPatternId); setCurrentIndexPattern(currentDataView); diff --git a/x-pack/plugins/lens/public/app_plugin/mounter.tsx b/x-pack/plugins/lens/public/app_plugin/mounter.tsx index 81cc7df0b005d..fb791c471fcb5 100644 --- a/x-pack/plugins/lens/public/app_plugin/mounter.tsx +++ b/x-pack/plugins/lens/public/app_plugin/mounter.tsx @@ -52,12 +52,42 @@ import { } from '../state_management'; import { getPreloadedState, setState } from '../state_management/lens_slice'; import { getLensInspectorService } from '../lens_inspector_service'; +import { + LensAppLocator, + LENS_SHARE_STATE_ACTION, + MainHistoryLocationState, +} from '../../common/locator/locator'; + +function getInitialContext(history: AppMountParameters['history']) { + const historyLocationState = history.location.state as + | MainHistoryLocationState + | HistoryLocationState + | undefined; + + if (historyLocationState) { + if (historyLocationState.type === LENS_SHARE_STATE_ACTION) { + return { + contextType: historyLocationState.type, + initialStateFromLocator: historyLocationState.payload, + }; + } + // get state from location, used for navigating from Visualize/Discover to Lens + if ([ACTION_VISUALIZE_LENS_FIELD, ACTION_CONVERT_TO_LENS].includes(historyLocationState.type)) { + return { + contextType: historyLocationState.type, + initialContext: historyLocationState.payload, + originatingApp: historyLocationState.originatingApp, + }; + } + } +} export async function getLensServices( coreStart: CoreStart, startDependencies: LensPluginStartDependencies, attributeService: LensAttributeService, - initialContext?: VisualizeFieldContext | VisualizeEditorContext + initialContext?: VisualizeFieldContext | VisualizeEditorContext, + locator?: LensAppLocator ): Promise { const { data, @@ -112,6 +142,7 @@ export async function getLensServices( share, unifiedSearch, docLinks: coreStart.docLinks, + locator, }; } @@ -123,6 +154,7 @@ export async function mountApp( attributeService: LensAttributeService; getPresentationUtilContext: () => FC; topNavMenuEntryGenerators: LensTopNavMenuEntryGenerator[]; + locator?: LensAppLocator; } ) { const { @@ -130,26 +162,22 @@ export async function mountApp( attributeService, getPresentationUtilContext, topNavMenuEntryGenerators, + locator, } = mountProps; const [[coreStart, startDependencies], instance] = await Promise.all([ core.getStartServices(), createEditorFrame(), ]); - const historyLocationState = params.history.location.state as HistoryLocationState; - // get state from location, used for navigating from Visualize/Discover to Lens - const initialContext = - historyLocationState && - (historyLocationState.type === ACTION_VISUALIZE_LENS_FIELD || - historyLocationState.type === ACTION_CONVERT_TO_LENS) - ? historyLocationState.payload - : undefined; + const { contextType, initialContext, initialStateFromLocator, originatingApp } = + getInitialContext(params.history) || {}; const lensServices = await getLensServices( coreStart, startDependencies, attributeService, - initialContext + initialContext, + locator ); const { stateTransfer, data } = lensServices; @@ -195,8 +223,9 @@ export async function mountApp( const redirectToOrigin = (props?: RedirectToOriginProps) => { const contextOriginatingApp = initialContext && 'originatingApp' in initialContext ? initialContext.originatingApp : null; - const originatingApp = embeddableEditorIncomingState?.originatingApp ?? contextOriginatingApp; - if (!originatingApp) { + const mergedOriginatingApp = + embeddableEditorIncomingState?.originatingApp ?? contextOriginatingApp; + if (!mergedOriginatingApp) { throw new Error('redirectToOrigin called without an originating app'); } let embeddableId = embeddableEditorIncomingState?.embeddableId; @@ -205,7 +234,7 @@ export async function mountApp( } if (stateTransfer && props?.input) { const { input, isCopied } = props; - stateTransfer.navigateToWithEmbeddablePackage(originatingApp, { + stateTransfer.navigateToWithEmbeddablePackage(mergedOriginatingApp, { path: embeddableEditorIncomingState?.originatingPath, state: { embeddableId: isCopied ? undefined : embeddableId, @@ -215,17 +244,17 @@ export async function mountApp( }, }); } else { - coreStart.application.navigateToApp(originatingApp, { + coreStart.application.navigateToApp(mergedOriginatingApp, { path: embeddableEditorIncomingState?.originatingPath, }); } }; - if (historyLocationState && historyLocationState.type === ACTION_VISUALIZE_LENS_FIELD) { + if (contextType === ACTION_VISUALIZE_LENS_FIELD && initialContext?.originatingApp) { // remove originatingApp from context when visualizing a field in Lens // so Lens does not try to return to the original app on Save // see https://github.com/elastic/kibana/issues/128695 - delete initialContext?.originatingApp; + delete initialContext.originatingApp; } if (embeddableEditorIncomingState?.searchSessionId) { @@ -239,6 +268,7 @@ export async function mountApp( visualizationMap, embeddableEditorIncomingState, initialContext, + initialStateFromLocator, }; const lensStore: LensRootStore = makeConfigureStore(storeDeps, { lens: getPreloadedState(storeDeps) as LensAppState, @@ -247,6 +277,7 @@ export async function mountApp( const EditorRenderer = React.memo( (props: { id?: string; history: History; editByValue?: boolean }) => { const [editorState, setEditorState] = useState<'loading' | 'no_data' | 'data'>('loading'); + useEffect(() => { const kbnUrlStateStorage = createKbnUrlStateStorage({ history: props.history, @@ -268,14 +299,14 @@ export async function mountApp( }, [props.history] ); - const initialInput = useMemo( - () => getInitialInput(props.id, props.editByValue), - [props.editByValue, props.id] - ); + const initialInput = useMemo(() => { + return getInitialInput(props.id, props.editByValue); + }, [props.editByValue, props.id]); + const initCallback = useCallback(() => { // Clear app-specific filters when navigating to Lens. Necessary because Lens - // can be loaded without a full page refresh. If the user navigates to Lens from Discover - // we keep the filters + // can be loaded without a full page refresh. + // If the user navigates to Lens from Discover, or comes from a Lens share link we keep the filters if (!initialContext) { data.query.filterManager.setAppFilters([]); } @@ -330,7 +361,7 @@ export async function mountApp( datasourceMap={datasourceMap} visualizationMap={visualizationMap} initialContext={initialContext} - contextOriginatingApp={historyLocationState?.originatingApp} + contextOriginatingApp={originatingApp} topNavMenuEntryGenerators={topNavMenuEntryGenerators} theme$={core.theme.theme$} /> diff --git a/x-pack/plugins/lens/public/app_plugin/share_action.ts b/x-pack/plugins/lens/public/app_plugin/share_action.ts new file mode 100644 index 0000000000000..13ff9d53f25f1 --- /dev/null +++ b/x-pack/plugins/lens/public/app_plugin/share_action.ts @@ -0,0 +1,105 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { SavedObjectReference } from '@kbn/core-saved-objects-common'; +import type { SerializableRecord } from '@kbn/utility-types'; +import { DataViewSpec } from '@kbn/data-views-plugin/common'; +import type { LensAppLocatorParams } from '../../common/locator/locator'; +import type { LensAppState } from '../state_management'; +import type { LensAppServices } from './types'; +import type { Document } from '../persistence/saved_object_store'; +import type { DatasourceMap, VisualizationMap } from '../types'; +import { extractReferencesFromState, getResolvedDateRange } from '../utils'; +import { getEditPath } from '../../common'; + +interface ShareableConfiguration + extends Pick< + LensAppState, + 'activeDatasourceId' | 'datasourceStates' | 'visualization' | 'filters' | 'query' + > { + datasourceMap: DatasourceMap; + visualizationMap: VisualizationMap; + currentDoc: Document | undefined; + adHocDataViews?: DataViewSpec[]; +} + +function getShareURLForSavedObject( + { application, data }: Pick, + currentDoc: Document | undefined +) { + return new URL( + `${application.getUrlForApp('lens', { absolute: true })}${ + currentDoc?.savedObjectId + ? getEditPath( + currentDoc?.savedObjectId, + data.query.timefilter.timefilter.getTime(), + data.query.filterManager.getGlobalFilters(), + data.query.timefilter.timefilter.getRefreshInterval() + ) + : '' + }` + ); +} + +function getShortShareableURL( + shortUrlService: (params: LensAppLocatorParams) => Promise, + data: LensAppServices['data'], + { + filters, + query, + activeDatasourceId, + datasourceStates, + datasourceMap, + visualizationMap, + visualization, + adHocDataViews, + }: ShareableConfiguration +) { + const references = extractReferencesFromState({ + activeDatasources: Object.keys(datasourceStates).reduce( + (acc, datasourceId) => ({ + ...acc, + [datasourceId]: datasourceMap[datasourceId], + }), + {} + ), + datasourceStates, + visualizationState: visualization.state, + activeVisualization: visualization.activeId + ? visualizationMap[visualization.activeId] + : undefined, + }) as Array; + + const serializableVisualization = visualization as LensAppState['visualization'] & + SerializableRecord; + + const serializableDatasourceStates = datasourceStates as LensAppState['datasourceStates'] & + SerializableRecord; + + return shortUrlService({ + filters, + query, + resolvedDateRange: getResolvedDateRange(data.query.timefilter.timefilter), + visualization: serializableVisualization, + datasourceStates: serializableDatasourceStates, + activeDatasourceId, + searchSessionId: data.search.session.getSessionId(), + references, + dataViewSpecs: adHocDataViews, + }); +} + +export async function getShareURL( + shortUrlService: (params: LensAppLocatorParams) => Promise, + services: Pick, + configuration: ShareableConfiguration +) { + return { + shareableUrl: await getShortShareableURL(shortUrlService, services.data, configuration), + savedObjectURL: getShareURLForSavedObject(services, configuration.currentDoc), + }; +} diff --git a/x-pack/plugins/lens/public/app_plugin/show_underlying_data.test.ts b/x-pack/plugins/lens/public/app_plugin/show_underlying_data.test.ts index 68059b293f2f9..311541cdf905c 100644 --- a/x-pack/plugins/lens/public/app_plugin/show_underlying_data.test.ts +++ b/x-pack/plugins/lens/public/app_plugin/show_underlying_data.test.ts @@ -16,6 +16,9 @@ describe('getLayerMetaInfo', () => { navLinks: { discover: true }, discover: { show: true }, }; + const indexPatternsMap = { + test: createMockedIndexPattern(), + }; it('should return error in case of no data', () => { expect( getLayerMetaInfo( @@ -24,7 +27,7 @@ describe('getLayerMetaInfo', () => { createMockVisualization('testVisualization'), {}, undefined, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -43,7 +46,7 @@ describe('getLayerMetaInfo', () => { { datatable1: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -58,7 +61,7 @@ describe('getLayerMetaInfo', () => { createMockVisualization('testVisualization'), {}, undefined, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -73,7 +76,7 @@ describe('getLayerMetaInfo', () => { createMockVisualization('testVisualization'), {}, {}, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -88,7 +91,7 @@ describe('getLayerMetaInfo', () => { undefined, {}, undefined, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -103,7 +106,7 @@ describe('getLayerMetaInfo', () => { createMockVisualization('testVisualization'), undefined, {}, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -126,7 +129,7 @@ describe('getLayerMetaInfo', () => { datatable1: { type: 'datatable', columns: [], rows: [] }, datatable2: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -154,7 +157,7 @@ describe('getLayerMetaInfo', () => { { datatable1: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -181,7 +184,7 @@ describe('getLayerMetaInfo', () => { createMockVisualization('testVisualization'), {}, {}, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -203,7 +206,7 @@ describe('getLayerMetaInfo', () => { { datatable1: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, capabilities ).error @@ -226,7 +229,7 @@ describe('getLayerMetaInfo', () => { { datatable1: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, { navLinks: { discover: false }, @@ -243,7 +246,7 @@ describe('getLayerMetaInfo', () => { { datatable1: { type: 'datatable', columns: [], rows: [] }, }, - {}, + indexPatternsMap, undefined, { navLinks: { discover: true }, diff --git a/x-pack/plugins/lens/public/app_plugin/show_underlying_data.ts b/x-pack/plugins/lens/public/app_plugin/show_underlying_data.ts index bc0e926e64589..a181cea794584 100644 --- a/x-pack/plugins/lens/public/app_plugin/show_underlying_data.ts +++ b/x-pack/plugins/lens/public/app_plugin/show_underlying_data.ts @@ -99,8 +99,15 @@ export function getLayerMetaInfo( const isVisible = Boolean(capabilities.navLinks?.discover && capabilities.discover?.show); // If Multiple tables, return // If there are time shifts, return + // If dataViews have not loaded yet, return const datatables = Object.values(activeData || {}); - if (!datatables.length || !currentDatasource || !datasourceState || !activeVisualization) { + if ( + !datatables.length || + !currentDatasource || + !datasourceState || + !activeVisualization || + !Object.keys(indexPatterns).length + ) { return { meta: undefined, error: i18n.translate('xpack.lens.app.showUnderlyingDataNoData', { diff --git a/x-pack/plugins/lens/public/app_plugin/types.ts b/x-pack/plugins/lens/public/app_plugin/types.ts index 831b7ce54da39..1411598c4033e 100644 --- a/x-pack/plugins/lens/public/app_plugin/types.ts +++ b/x-pack/plugins/lens/public/app_plugin/types.ts @@ -56,6 +56,7 @@ import type { LensEmbeddableInput } from '../embeddable/embeddable'; import type { LensInspector } from '../lens_inspector_service'; import { IndexPatternServiceAPI } from '../data_views_service/service'; import { Document } from '../persistence/saved_object_store'; +import { type LensAppLocator, LensAppLocatorParams } from '../../common/locator/locator'; export interface RedirectToOriginProps { input?: LensEmbeddableInput; @@ -120,6 +121,8 @@ export interface LensTopNavMenuProps { theme$: Observable; indexPatternService: IndexPatternServiceAPI; onTextBasedSavedAndExit: ({ onSave }: { onSave: () => void }) => Promise; + shortUrlService: (params: LensAppLocatorParams) => Promise; + isCurrentStateDirty: boolean; } export interface HistoryLocationState { @@ -160,20 +163,24 @@ export interface LensAppServices { dashboardFeatureFlag: DashboardFeatureFlagConfig; dataViewEditor: DataViewEditorStart; dataViewFieldEditor: IndexPatternFieldEditorStart; + locator?: LensAppLocator; } -export interface LensTopNavTooltips { - showExportWarning: () => string | undefined; - showUnderlyingDataWarning: () => string | undefined; +interface TopNavAction { + visible: boolean; + enabled?: boolean; + execute: (anchorElement: HTMLElement) => void; + getLink?: () => string | undefined; + tooltip?: () => string | undefined; } -export interface LensTopNavActions { - inspect: () => void; - saveAndReturn: () => void; - showSaveModal: () => void; - goBack: () => void; - cancel: () => void; - exportToCSV: () => void; - getUnderlyingDataUrl: () => string | undefined; - openSettings: (anchorElement: HTMLElement) => void; -} +type AvailableTopNavActions = + | 'inspect' + | 'saveAndReturn' + | 'showSaveModal' + | 'goBack' + | 'cancel' + | 'share' + | 'getUnderlyingDataUrl' + | 'openSettings'; +export type LensTopNavActions = Record; diff --git a/x-pack/plugins/lens/public/datasources/form_based/mocks.ts b/x-pack/plugins/lens/public/datasources/form_based/mocks.ts index c2a85fbf0bac4..7ae9262f922ad 100644 --- a/x-pack/plugins/lens/public/datasources/form_based/mocks.ts +++ b/x-pack/plugins/lens/public/datasources/form_based/mocks.ts @@ -81,6 +81,26 @@ export const createMockedIndexPattern = (someProps?: Partial): Ind lang: 'painless' as const, script: '1234', }, + { + name: 'runtime-keyword', + displayName: 'Runtime keyword field', + type: 'string', + searchable: true, + aggregatable: true, + runtime: true, + lang: 'painless' as const, + script: 'emit("123")', + }, + { + name: 'runtime-number', + displayName: 'Runtime number field', + type: 'number', + searchable: true, + aggregatable: true, + runtime: true, + lang: 'painless' as const, + script: 'emit(123)', + }, ]; return { id: '1', diff --git a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/formula/editor/math_completion.test.ts b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/formula/editor/math_completion.test.ts index bb91fc4a7b3ac..419208ec48d80 100644 --- a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/formula/editor/math_completion.test.ts +++ b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/formula/editor/math_completion.test.ts @@ -335,7 +335,7 @@ describe('math completion', () => { triggerCharacter: '(', }) ); - expect(results.list).toEqual(['bytes', 'memory']); + expect(results.list).toEqual(['bytes', 'memory', 'runtime-number']); }); it('should autocomplete only operations that provide numeric or date output', async () => { @@ -346,7 +346,13 @@ describe('math completion', () => { triggerCharacter: '(', }) ); - expect(results.list).toEqual(['bytes', 'memory', 'timestamp', 'start_date']); + expect(results.list).toEqual([ + 'bytes', + 'memory', + 'runtime-number', + 'timestamp', + 'start_date', + ]); }); it('should autocomplete shift parameter with relative suggestions and a couple of abs ones', async () => { diff --git a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.test.tsx b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.test.tsx index 104f6da48041f..5bd3aaada9a41 100644 --- a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.test.tsx +++ b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.test.tsx @@ -290,6 +290,44 @@ describe('last_value', () => { ).params.showArrayValues ).toBeTruthy(); }); + + it('should set show array values if field is runtime and not of type number', () => { + const oldColumn: LastValueIndexPatternColumn = { + operationType: 'last_value', + sourceField: 'bytes', + label: 'Last value of bytes', + isBucketed: false, + dataType: 'number', + params: { + sortField: 'datefield', + showArrayValues: false, + }, + }; + const indexPattern = createMockedIndexPattern(); + const field = indexPattern.fields.find((i) => i.name === 'runtime-keyword')!; + + expect( + lastValueOperation.onFieldChange(oldColumn, field).params.showArrayValues + ).toBeTruthy(); + }); + + it('should not set show array values if field is runtime and of type number', () => { + const oldColumn: LastValueIndexPatternColumn = { + operationType: 'last_value', + sourceField: 'bytes', + label: 'Last value of bytes', + isBucketed: false, + dataType: 'number', + params: { + sortField: 'datefield', + showArrayValues: false, + }, + }; + const indexPattern = createMockedIndexPattern(); + const field = indexPattern.fields.find((i) => i.name === 'runtime-number')!; + + expect(lastValueOperation.onFieldChange(oldColumn, field).params.showArrayValues).toBeFalsy(); + }); }); describe('getPossibleOperationForField', () => { @@ -480,11 +518,19 @@ describe('last_value', () => { ); }); - it('should set showArrayValues if field is scripted or comes from existing params', () => { + it('should set showArrayValues if field is scripted, non-numeric runtime or comes from existing params', () => { const indexPattern = createMockedIndexPattern(); const scriptedField = indexPattern.fields.find((field) => field.scripted); - const nonScriptedField = indexPattern.fields.find((field) => !field.scripted); + const runtimeKeywordField = indexPattern.fields.find( + (field) => field.runtime && field.type !== 'number' + ); + const runtimeNumericField = indexPattern.fields.find( + (field) => field.runtime && field.type === 'number' + ); + const nonScriptedField = indexPattern.fields.find( + (field) => !field.scripted && !field.runtime + ); const localLayer = { columns: { @@ -508,6 +554,22 @@ describe('last_value', () => { }).params.showArrayValues ).toBeTruthy(); + expect( + lastValueOperation.buildColumn({ + indexPattern, + layer: localLayer, + field: runtimeKeywordField!, + }).params.showArrayValues + ).toBeTruthy(); + + expect( + lastValueOperation.buildColumn({ + indexPattern, + layer: localLayer, + field: runtimeNumericField!, + }).params.showArrayValues + ).toBeFalsy(); + expect( lastValueOperation.buildColumn( { diff --git a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.tsx b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.tsx index 698cdba8da13e..db9c7c0d6ab0c 100644 --- a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.tsx +++ b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/last_value.tsx @@ -30,7 +30,7 @@ import { } from './helpers'; import { adjustTimeScaleLabelSuffix } from '../time_scale_utils'; import { getDisallowedPreviousShiftMessage } from '../../time_shift_utils'; -import { isScriptedField } from './terms/helpers'; +import { isRuntimeField, isScriptedField } from './terms/helpers'; import { FormRow } from './shared_components/form_row'; import { getColumnReducedTimeRangeError } from '../../reduced_time_range_utils'; import { getGroupByKey } from './get_group_by_key'; @@ -107,6 +107,17 @@ function getDateFields(indexPattern: IndexPattern): IndexPatternField[] { return dateFields; } +function setDefaultShowArrayValues( + field: IndexPatternField, + oldParams: LastValueIndexPatternColumn['params'] +) { + return ( + isScriptedField(field) || + (isRuntimeField(field) && field.type !== 'number') || + oldParams?.showArrayValues + ); +} + export interface LastValueIndexPatternColumn extends FieldBasedIndexPatternColumn { operationType: 'last_value'; params: { @@ -154,7 +165,7 @@ export const lastValueOperation: OperationDefinition< onFieldChange: (oldColumn, field) => { const newParams = { ...oldColumn.params }; - newParams.showArrayValues = isScriptedField(field) || oldColumn.params.showArrayValues; + newParams.showArrayValues = setDefaultShowArrayValues(field, oldColumn.params); if ('format' in newParams && field.type !== 'number') { delete newParams.format; @@ -221,7 +232,7 @@ export const lastValueOperation: OperationDefinition< ); } - const showArrayValues = isScriptedField(field) || lastValueParams?.showArrayValues; + const showArrayValues = setDefaultShowArrayValues(field, lastValueParams); return { label: ofName(field.displayName, previousColumn?.timeShift, previousColumn?.reducedTimeRange), diff --git a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/terms/helpers.ts b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/terms/helpers.ts index 27e6dc7b69d71..7b451445911df 100644 --- a/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/terms/helpers.ts +++ b/x-pack/plugins/lens/public/datasources/form_based/operations/definitions/terms/helpers.ts @@ -265,6 +265,10 @@ export function isScriptedField( return fieldName.scripted; } +export function isRuntimeField(field: IndexPatternField): boolean { + return Boolean(field.runtime); +} + export function getFieldsByValidationState( newIndexPattern: IndexPattern, column?: GenericIndexPatternColumn, diff --git a/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts b/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts index 8df771d8eb94b..9f53e4822e239 100644 --- a/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts +++ b/x-pack/plugins/lens/public/editor_frame_service/editor_frame/state_helpers.ts @@ -49,18 +49,19 @@ function getIndexPatterns( adHocDataviews?: string[] ) { const indexPatternIds = []; + + // use the initialId only when no context is passed over + if (!initialContext && initialId) { + indexPatternIds.push(initialId); + } if (initialContext) { if ('isVisualizeAction' in initialContext) { indexPatternIds.push(...initialContext.indexPatternIds); } else { indexPatternIds.push(initialContext.dataViewSpec.id!); } - } else { - // use the initialId only when no context is passed over - if (initialId) { - indexPatternIds.push(initialId); - } } + if (references) { for (const reference of references) { if (reference.type === 'index-pattern') { diff --git a/x-pack/plugins/lens/public/embeddable/embeddable.test.tsx b/x-pack/plugins/lens/public/embeddable/embeddable.test.tsx index 8ad477642c191..5a2f3d002ad8e 100644 --- a/x-pack/plugins/lens/public/embeddable/embeddable.test.tsx +++ b/x-pack/plugins/lens/public/embeddable/embeddable.test.tsx @@ -90,7 +90,7 @@ const attributeServiceMockFromSavedVis = (document: Document): LensAttributeServ LensByValueInput, LensByReferenceInput, LensUnwrapMetaInfo - >('lens', jest.fn(), core.i18n.Context, core.notifications.toasts, options); + >('lens', core.notifications.toasts, options); service.unwrapAttributes = jest.fn((input: LensByValueInput | LensByReferenceInput) => { return Promise.resolve({ attributes: { diff --git a/x-pack/plugins/lens/public/id_generator/id_generator.ts b/x-pack/plugins/lens/public/id_generator/id_generator.ts index 363b8035a23f7..009b7d5e841e6 100644 --- a/x-pack/plugins/lens/public/id_generator/id_generator.ts +++ b/x-pack/plugins/lens/public/id_generator/id_generator.ts @@ -5,8 +5,8 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export function generateId() { - return uuid(); + return uuidv4(); } diff --git a/x-pack/plugins/lens/public/mocks/services_mock.tsx b/x-pack/plugins/lens/public/mocks/services_mock.tsx index 81aa4e0617931..019a37001312c 100644 --- a/x-pack/plugins/lens/public/mocks/services_mock.tsx +++ b/x-pack/plugins/lens/public/mocks/services_mock.tsx @@ -157,7 +157,7 @@ export function makeDefaultServices( ...core.application, capabilities: { ...core.application.capabilities, - visualize: { save: true, saveQuery: true, show: true }, + visualize: { save: true, saveQuery: true, show: true, createShortUrl: true }, }, getUrlForApp: jest.fn((appId: string) => `/testbasepath/app/${appId}#/`), }, diff --git a/x-pack/plugins/lens/public/plugin.ts b/x-pack/plugins/lens/public/plugin.ts index f0c09a9fe31a7..2b3dce5583978 100644 --- a/x-pack/plugins/lens/public/plugin.ts +++ b/x-pack/plugins/lens/public/plugin.ts @@ -110,6 +110,8 @@ import { setupExpressions } from './expressions'; import { getSearchProvider } from './search_provider'; import { OpenInDiscoverDrilldown } from './trigger_actions/open_in_discover_drilldown'; import { ChartInfoApi } from './chart_info_api'; +import { type LensAppLocator, LensAppLocatorDefinition } from '../common/locator/locator'; +import { downloadCsvShareProvider } from './app_plugin/csv_download_provider/csv_download_provider'; export interface LensPluginSetupDependencies { urlForwarding: UrlForwardingSetup; @@ -250,6 +252,7 @@ export class LensPlugin { private hasDiscoverAccess: boolean = false; private dataViewsService: DataViewsPublicPluginStart | undefined; private initDependenciesForApi: () => void = () => {}; + private locator?: LensAppLocator; setup( core: CoreSetup, @@ -324,6 +327,17 @@ export class LensPlugin { embeddable.registerEmbeddableFactory('lens', new EmbeddableFactory(getStartServices)); } + if (share) { + this.locator = share.url.locators.create(new LensAppLocatorDefinition()); + + share.register( + downloadCsvShareProvider({ + uiSettings: core.uiSettings, + formatFactoryFn: () => startServices().plugins.fieldFormats.deserialize, + }) + ); + } + visualizations.registerAlias(getLensAliasConfig()); uiActionsEnhanced.registerDrilldown( @@ -384,6 +398,7 @@ export class LensPlugin { attributeService: getLensAttributeService(coreStart, deps), getPresentationUtilContext, topNavMenuEntryGenerators: this.topNavMenuEntries, + locator: this.locator, }); }, }); diff --git a/x-pack/plugins/lens/public/state_management/init_middleware/load_initial.ts b/x-pack/plugins/lens/public/state_management/init_middleware/load_initial.ts index 7ca55e9447392..97c08a1ad3258 100644 --- a/x-pack/plugins/lens/public/state_management/init_middleware/load_initial.ts +++ b/x-pack/plugins/lens/public/state_management/init_middleware/load_initial.ts @@ -103,6 +103,7 @@ export function loadInitial( datasourceMap, embeddableEditorIncomingState, initialContext, + initialStateFromLocator, visualizationMap, } = storeDeps; const { resolvedDateRange, searchSessionId, isLinkedToOriginatingApp, ...emptyState } = @@ -121,6 +122,82 @@ export function loadInitial( activeDatasourceId = 'textBased'; } + if (initialStateFromLocator) { + const locatorReferences = + 'references' in initialStateFromLocator ? initialStateFromLocator.references : undefined; + + const newFilters = initialStateFromLocator.filters + ? cloneDeep(initialStateFromLocator.filters) + : undefined; + + if (newFilters) { + data.query.filterManager.setAppFilters(newFilters); + } + + if (initialStateFromLocator.resolvedDateRange) { + const newTimeRange = { + from: initialStateFromLocator.resolvedDateRange.fromDate, + to: initialStateFromLocator.resolvedDateRange.toDate, + }; + data.query.timefilter.timefilter.setTime(newTimeRange); + } + + return initializeSources( + { + datasourceMap, + visualizationMap, + visualizationState: emptyState.visualization, + datasourceStates: emptyState.datasourceStates, + initialContext, + adHocDataViews: + lens.persistedDoc?.state.adHocDataViews || initialStateFromLocator.dataViewSpecs, + references: locatorReferences, + ...loaderSharedArgs, + }, + { + isFullEditor: true, + } + ) + .then(({ datasourceStates, visualizationState, indexPatterns, indexPatternRefs }) => { + const currentSessionId = + initialStateFromLocator?.searchSessionId || data.search.session.getSessionId(); + store.dispatch( + setState({ + isSaveable: true, + filters: initialStateFromLocator.filters || data.query.filterManager.getFilters(), + query: initialStateFromLocator.query || emptyState.query, + searchSessionId: currentSessionId, + activeDatasourceId: emptyState.activeDatasourceId, + visualization: { + activeId: emptyState.visualization.activeId, + state: visualizationState, + }, + dataViews: getInitialDataViewsObject(indexPatterns, indexPatternRefs), + datasourceStates: Object.entries(datasourceStates).reduce( + (state, [datasourceId, datasourceState]) => ({ + ...state, + [datasourceId]: { + ...datasourceState, + isLoading: false, + }, + }), + {} + ), + isLoading: false, + }) + ); + + if (autoApplyDisabled) { + store.dispatch(disableAutoApply()); + } + }) + .catch((e: { message: string }) => { + notifications.toasts.addDanger({ + title: e.message, + }); + }); + } + if ( !initialInput || (attributeService.inputIsRefType(initialInput) && diff --git a/x-pack/plugins/lens/public/state_management/lens_slice.ts b/x-pack/plugins/lens/public/state_management/lens_slice.ts index e74e8c94edede..da64209a8a80f 100644 --- a/x-pack/plugins/lens/public/state_management/lens_slice.ts +++ b/x-pack/plugins/lens/public/state_management/lens_slice.ts @@ -56,12 +56,33 @@ export const initialState: LensAppState = { export const getPreloadedState = ({ lensServices: { data }, initialContext, + initialStateFromLocator, embeddableEditorIncomingState, datasourceMap, visualizationMap, }: LensStoreDeps) => { const initialDatasourceId = getInitialDatasourceId(datasourceMap); const datasourceStates: LensAppState['datasourceStates'] = {}; + if (initialStateFromLocator) { + if ('datasourceStates' in initialStateFromLocator) { + Object.keys(datasourceMap).forEach((datasourceId) => { + datasourceStates[datasourceId] = { + state: initialStateFromLocator.datasourceStates[datasourceId], + isLoading: true, + }; + }); + } + return { + ...initialState, + isLoading: true, + ...initialStateFromLocator, + activeDatasourceId: + ('activeDatasourceId' in initialStateFromLocator && + initialStateFromLocator.activeDatasourceId) || + initialDatasourceId, + datasourceStates, + }; + } if (initialDatasourceId) { Object.keys(datasourceMap).forEach((datasourceId) => { datasourceStates[datasourceId] = { diff --git a/x-pack/plugins/lens/public/state_management/types.ts b/x-pack/plugins/lens/public/state_management/types.ts index 4f7500ec20a5e..a25ca282a85ea 100644 --- a/x-pack/plugins/lens/public/state_management/types.ts +++ b/x-pack/plugins/lens/public/state_management/types.ts @@ -5,16 +5,17 @@ * 2.0. */ -import { VisualizeFieldContext } from '@kbn/ui-actions-plugin/public'; -import { EmbeddableEditorState } from '@kbn/embeddable-plugin/public'; +import type { VisualizeFieldContext } from '@kbn/ui-actions-plugin/public'; +import type { EmbeddableEditorState } from '@kbn/embeddable-plugin/public'; import type { Filter, Query } from '@kbn/es-query'; -import { SavedQuery } from '@kbn/data-plugin/public'; -import { Document } from '../persistence'; +import type { SavedQuery } from '@kbn/data-plugin/public'; +import type { MainHistoryLocationState } from '../../common/locator/locator'; +import type { Document } from '../persistence'; import type { TableInspectorAdapter } from '../editor_frame_service/types'; -import { DateRange } from '../../common'; -import { LensAppServices } from '../app_plugin/types'; -import { +import type { DateRange } from '../../common'; +import type { LensAppServices } from '../app_plugin/types'; +import type { DatasourceMap, VisualizationMap, SharingSavedObjectProps, @@ -79,5 +80,6 @@ export interface LensStoreDeps { datasourceMap: DatasourceMap; visualizationMap: VisualizationMap; initialContext?: VisualizeFieldContext | VisualizeEditorContext; + initialStateFromLocator?: MainHistoryLocationState['payload']; embeddableEditorIncomingState?: EmbeddableEditorState; } diff --git a/x-pack/plugins/lens/public/utils.ts b/x-pack/plugins/lens/public/utils.ts index 16ad6a026851d..c268a79599e77 100644 --- a/x-pack/plugins/lens/public/utils.ts +++ b/x-pack/plugins/lens/public/utils.ts @@ -120,7 +120,7 @@ export async function refreshIndexPatternsList({ }); } -export function getIndexPatternsIds({ +export function extractReferencesFromState({ activeDatasources, datasourceStates, visualizationState, @@ -130,13 +130,10 @@ export function getIndexPatternsIds({ datasourceStates: DatasourceStates; visualizationState: unknown; activeVisualization?: Visualization; -}): string[] { - let currentIndexPatternId: string | undefined; +}): SavedObjectReference[] { const references: SavedObjectReference[] = []; Object.entries(activeDatasources).forEach(([id, datasource]) => { const { savedObjectReferences } = datasource.getPersistableState(datasourceStates[id].state); - const indexPatternId = datasource.getUsedDataView(datasourceStates[id].state); - currentIndexPatternId = indexPatternId; references.push(...savedObjectReferences); }); @@ -144,6 +141,35 @@ export function getIndexPatternsIds({ const { savedObjectReferences } = activeVisualization.getPersistableState(visualizationState); references.push(...savedObjectReferences); } + return references; +} + +export function getIndexPatternsIds({ + activeDatasources, + datasourceStates, + visualizationState, + activeVisualization, +}: { + activeDatasources: Record; + datasourceStates: DatasourceStates; + visualizationState: unknown; + activeVisualization?: Visualization; +}): string[] { + const references: SavedObjectReference[] = extractReferencesFromState({ + activeDatasources, + datasourceStates, + visualizationState, + activeVisualization, + }); + + const currentIndexPatternId: string | undefined = Object.entries(activeDatasources).reduce< + string | undefined + >((currentId, [id, datasource]) => { + if (currentId == null) { + return datasource.getUsedDataView(datasourceStates[id].state); + } + return currentId; + }, undefined); const referencesIds = references .filter(({ type }) => type === 'index-pattern') .map(({ id }) => id); diff --git a/x-pack/plugins/lens/public/visualizations/partition/suggestions.test.ts b/x-pack/plugins/lens/public/visualizations/partition/suggestions.test.ts index 0be4fbde6c1d2..95f35f6f21cc2 100644 --- a/x-pack/plugins/lens/public/visualizations/partition/suggestions.test.ts +++ b/x-pack/plugins/lens/public/visualizations/partition/suggestions.test.ts @@ -992,7 +992,7 @@ describe('suggestions', () => { expect(suggs[0].state.layers[0].allowMultipleMetrics).toBeFalsy(); }); - it('mosaic type should be hidden from the suggestion list', () => { + it('mosaic type should be shown in the suggestion list', () => { expect( suggestions({ table: { @@ -1012,6 +1012,7 @@ describe('suggestions', () => { operation: { label: 'Count', dataType: 'number' as DataType, isBucketed: false }, }, ], + changeType: 'unchanged', }, state: { @@ -1035,7 +1036,43 @@ describe('suggestions', () => { }, keptLayerIds: ['first'], }).filter(({ hide, state }) => !hide && state.shape === 'mosaic') - ).toMatchInlineSnapshot(`Array []`); + ).toMatchInlineSnapshot(` + Array [ + Object { + "hide": false, + "previewIcon": "bullseye", + "score": 0.61, + "state": Object { + "layers": Array [ + Object { + "allowMultipleMetrics": false, + "categoryDisplay": "default", + "layerId": "first", + "layerType": "data", + "legendDisplay": "show", + "legendMaxLines": 1, + "metrics": Array [ + "c", + ], + "nestedLegend": true, + "numberDisplay": "hidden", + "percentDecimals": 0, + "primaryGroups": Array [ + "a", + ], + "secondaryGroups": Array [ + "b", + ], + "truncateLegend": true, + }, + ], + "palette": undefined, + "shape": "mosaic", + }, + "title": "As Mosaic", + }, + ] + `); }); }); @@ -1069,7 +1106,7 @@ describe('suggestions', () => { ).toHaveLength(0); }); - it('waffle type should be hidden from the suggestion list', () => { + it('waffle type should be shown in the suggestion list', () => { expect( suggestions({ table: { @@ -1085,6 +1122,7 @@ describe('suggestions', () => { operation: { label: 'Count', dataType: 'number' as DataType, isBucketed: false }, }, ], + changeType: 'unchanged', }, state: { @@ -1107,7 +1145,40 @@ describe('suggestions', () => { }, keptLayerIds: ['first'], }).filter(({ hide, state }) => !hide && state.shape === 'waffle') - ).toMatchInlineSnapshot(`Array []`); + ).toMatchInlineSnapshot(` + Array [ + Object { + "hide": false, + "previewIcon": "bullseye", + "score": 0.46, + "state": Object { + "layers": Array [ + Object { + "categoryDisplay": "default", + "layerId": "first", + "layerType": "data", + "legendDisplay": "show", + "legendMaxLines": 1, + "metrics": Array [ + "b", + ], + "nestedLegend": true, + "numberDisplay": "hidden", + "percentDecimals": 0, + "primaryGroups": Array [ + "a", + ], + "secondaryGroups": Array [], + "truncateLegend": true, + }, + ], + "palette": undefined, + "shape": "waffle", + }, + "title": "As Waffle", + }, + ] + `); }); }); }); diff --git a/x-pack/plugins/lens/public/visualizations/partition/suggestions.ts b/x-pack/plugins/lens/public/visualizations/partition/suggestions.ts index 93887559a094e..05def4e0a2937 100644 --- a/x-pack/plugins/lens/public/visualizations/partition/suggestions.ts +++ b/x-pack/plugins/lens/public/visualizations/partition/suggestions.ts @@ -267,7 +267,11 @@ export function suggestions({ ], }, previewIcon: 'bullseye', - hide: true, + hide: + groups.length !== 2 || + table.changeType === 'reduced' || + hasIntervalScale(groups) || + (state && state.shape === 'mosaic'), }); } @@ -279,7 +283,7 @@ export function suggestions({ title: i18n.translate('xpack.lens.pie.waffleSuggestionLabel', { defaultMessage: 'As Waffle', }), - score: state?.shape === PieChartTypes.WAFFLE ? 0.7 : 0.5, + score: state?.shape === PieChartTypes.WAFFLE ? 0.7 : 0.4, state: { shape: PieChartTypes.WAFFLE, palette: mainPalette || state?.palette, @@ -307,7 +311,11 @@ export function suggestions({ ], }, previewIcon: 'bullseye', - hide: true, + hide: + groups.length !== 1 || + table.changeType === 'reduced' || + hasIntervalScale(groups) || + (state && state.shape === 'waffle'), }); } diff --git a/x-pack/plugins/lens/server/plugin.tsx b/x-pack/plugins/lens/server/plugin.tsx index 03adef0d2b10a..b455ced2b8767 100644 --- a/x-pack/plugins/lens/server/plugin.tsx +++ b/x-pack/plugins/lens/server/plugin.tsx @@ -21,16 +21,19 @@ import { } from '@kbn/task-manager-plugin/server'; import { EmbeddableSetup } from '@kbn/embeddable-plugin/server'; import { DataViewPersistableStateService } from '@kbn/data-views-plugin/common'; +import { SharePluginSetup } from '@kbn/share-plugin/server'; import { setupSavedObjects } from './saved_objects'; import { setupExpressions } from './expressions'; import { makeLensEmbeddableFactory } from './embeddable/make_lens_embeddable_factory'; import type { CustomVisualizationMigrations } from './migrations/types'; +import { LensAppLocatorDefinition } from '../common/locator/locator'; export interface PluginSetupContract { taskManager?: TaskManagerSetupContract; embeddable: EmbeddableSetup; expressions: ExpressionsServerSetup; data: DataPluginSetup; + share?: SharePluginSetup; } export interface PluginStartContract { @@ -66,6 +69,10 @@ export class LensServerPlugin implements Plugin => { // Generate a new static listId - const newListId = uuid.v4(); + const newListId = uuidv4(); // fetch list container const listToDuplicate = await getExceptionList({ @@ -77,7 +77,7 @@ export const duplicateExceptionListAndItems = async ({ const executeFunctionOnStream = (response: FoundExceptionListItemSchema): void => { const transformedItems = response.data.map((item) => { // Generate a new static listId - const newItemId = uuid.v4(); + const newItemId = uuidv4(); return { comments: [], diff --git a/x-pack/plugins/lists/server/services/exception_lists/import_exception_list_and_items.ts b/x-pack/plugins/lists/server/services/exception_lists/import_exception_list_and_items.ts index 46fe83bccd6dd..3f3dc688ff555 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/import_exception_list_and_items.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/import_exception_list_and_items.ts @@ -18,7 +18,7 @@ import { import { createPromiseFromStreams } from '@kbn/utils'; import { SavedObjectsClientContract } from '@kbn/core/server'; import { chunk } from 'lodash/fp'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { importExceptionLists } from './utils/import/import_exception_lists'; import { importExceptionListItems } from './utils/import/import_exception_list_items'; @@ -115,7 +115,7 @@ export const importExceptions = async ({ if (exceptionList instanceof Error) { return { items: [...acc.items], lists: [...acc.lists] }; } - const newListId = uuid.v4(); + const newListId = uuidv4(); return { items: [ diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_items.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_items.ts index 40d18eebae3d7..e54647ec2381d 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_items.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_items.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { BulkErrorSchema, ImportExceptionListItemSchemaDecoded, @@ -22,7 +22,7 @@ export const getTupleErrorsAndUniqueExceptionListItems = ( const { errors, itemsAcc } = items.reduce( (acc, parsedExceptionItem) => { if (parsedExceptionItem instanceof Error) { - acc.errors.set(uuid.v4(), { + acc.errors.set(uuidv4(), { error: { message: `Error found importing exception list item: ${parsedExceptionItem.message}`, status_code: 400, @@ -32,7 +32,7 @@ export const getTupleErrorsAndUniqueExceptionListItems = ( } else { const { item_id: itemId, list_id: listId } = parsedExceptionItem; if (acc.itemsAcc.has(`${itemId}${listId}`)) { - acc.errors.set(uuid.v4(), { + acc.errors.set(uuidv4(), { error: { message: `More than one exception list item with item_id: "${itemId}" found in imports. The last item will be used.`, status_code: 400, diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_lists.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_lists.ts index 96adeb492f30d..922f7e853d717 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_lists.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/import/dedupe_incoming_lists.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { BulkErrorSchema, ImportExceptionListSchemaDecoded, @@ -22,7 +22,7 @@ export const getTupleErrorsAndUniqueExceptionLists = ( const { errors, listsAcc } = lists.reduce( (acc, parsedExceptionList) => { if (parsedExceptionList instanceof Error) { - acc.errors.set(uuid.v4(), { + acc.errors.set(uuidv4(), { error: { message: `Error found importing exception list: ${parsedExceptionList.message}`, status_code: 400, @@ -32,7 +32,7 @@ export const getTupleErrorsAndUniqueExceptionLists = ( } else { const { list_id: listId } = parsedExceptionList; if (acc.listsAcc.has(listId)) { - acc.errors.set(uuid.v4(), { + acc.errors.set(uuidv4(), { error: { message: `More than one exception list with list_id: "${listId}" found in imports. The last list will be used.`, status_code: 400, diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_items_to_create_update.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_items_to_create_update.ts index d9c9b6702fc49..2c93b0d33e35c 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_items_to_create_update.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_items_to_create_update.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObjectsBulkCreateObject, SavedObjectsBulkUpdateObject } from '@kbn/core/server'; import { getSavedObjectType } from '@kbn/securitysolution-list-utils'; import { @@ -97,7 +97,7 @@ export const sortExceptionItemsToUpdateOrCreate = ({ name, os_types: osTypes, tags, - tie_breaker_id: uuid.v4(), + tie_breaker_id: uuidv4(), type, updated_by: user, version: undefined, diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_lists_to_create_update.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_lists_to_create_update.ts index da91b04d6acf5..6dbfea6e724db 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_lists_to_create_update.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/import/sort_exception_lists_to_create_update.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObjectsBulkCreateObject, SavedObjectsBulkUpdateObject } from '@kbn/core/server'; import { getSavedObjectType } from '@kbn/securitysolution-list-utils'; import { @@ -79,7 +79,7 @@ export const sortExceptionListsToUpdateOrCreate = ({ name, os_types: [], tags, - tie_breaker_id: uuid.v4(), + tie_breaker_id: uuidv4(), type, updated_by: user, version, @@ -115,7 +115,7 @@ export const sortExceptionListsToUpdateOrCreate = ({ immutable: false, item_id: undefined, list_type: 'list', - tie_breaker_id: uuid.v4(), + tie_breaker_id: uuidv4(), updated_by: user, }; results.listsToCreate = [ diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/index.test.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/index.test.ts index 890196b24b3ea..1acbb7051a154 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/index.test.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/index.test.ts @@ -7,11 +7,11 @@ import sinon from 'sinon'; import moment from 'moment'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { transformCreateCommentsToComments, transformUpdateCommentsToComments } from '.'; -jest.mock('uuid/v4'); +jest.mock('uuid'); describe('utils', () => { const oldDate = '2020-03-17T20:34:51.337Z'; @@ -20,7 +20,7 @@ describe('utils', () => { let clock: sinon.SinonFakeTimers; beforeEach(() => { - (uuid.v4 as unknown as jest.Mock) + (uuidv4 as unknown as jest.Mock) .mockImplementationOnce(() => '123') .mockImplementationOnce(() => '456'); diff --git a/x-pack/plugins/lists/server/services/exception_lists/utils/index.ts b/x-pack/plugins/lists/server/services/exception_lists/utils/index.ts index e61ce820af854..1cfce1208ece0 100644 --- a/x-pack/plugins/lists/server/services/exception_lists/utils/index.ts +++ b/x-pack/plugins/lists/server/services/exception_lists/utils/index.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObject, SavedObjectsFindResponse, @@ -303,7 +303,7 @@ export const transformCreateCommentsToComments = ({ comment: comment.comment, created_at: dateNow, created_by: user, - id: uuid.v4(), + id: uuidv4(), })); }; diff --git a/x-pack/plugins/lists/server/services/items/create_list_item.ts b/x-pack/plugins/lists/server/services/items/create_list_item.ts index 966b8b63d5b68..9e80d8e4f4019 100644 --- a/x-pack/plugins/lists/server/services/items/create_list_item.ts +++ b/x-pack/plugins/lists/server/services/items/create_list_item.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ElasticsearchClient } from '@kbn/core/server'; import { DeserializerOrUndefined, @@ -50,7 +50,7 @@ export const createListItem = async ({ tieBreaker, }: CreateListItemOptions): Promise => { const createdAt = dateNow ?? new Date().toISOString(); - const tieBreakerId = tieBreaker ?? uuid.v4(); + const tieBreakerId = tieBreaker ?? uuidv4(); const baseBody = { created_at: createdAt, created_by: user, diff --git a/x-pack/plugins/lists/server/services/items/create_list_items_bulk.ts b/x-pack/plugins/lists/server/services/items/create_list_items_bulk.ts index 83ff9c5bdc95f..0944e916c826a 100644 --- a/x-pack/plugins/lists/server/services/items/create_list_items_bulk.ts +++ b/x-pack/plugins/lists/server/services/items/create_list_items_bulk.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ElasticsearchClient } from '@kbn/core/server'; import type { DeserializerOrUndefined, @@ -52,7 +52,7 @@ export const createListItemsBulk = async ({ (accum, singleValue, index) => { const createdAt = dateNow ?? new Date().toISOString(); const tieBreakerId = - tieBreaker != null && tieBreaker[index] != null ? tieBreaker[index] : uuid.v4(); + tieBreaker != null && tieBreaker[index] != null ? tieBreaker[index] : uuidv4(); const elasticQuery = transformListItemToElasticQuery({ serializer, type, diff --git a/x-pack/plugins/lists/server/services/lists/create_list.ts b/x-pack/plugins/lists/server/services/lists/create_list.ts index a9f7bd48df5d0..3a31b7fdf6b9a 100644 --- a/x-pack/plugins/lists/server/services/lists/create_list.ts +++ b/x-pack/plugins/lists/server/services/lists/create_list.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ElasticsearchClient } from '@kbn/core/server'; import type { Description, @@ -66,7 +66,7 @@ export const createList = async ({ meta, name, serializer, - tie_breaker_id: tieBreaker ?? uuid.v4(), + tie_breaker_id: tieBreaker ?? uuidv4(), type, updated_at: createdAt, updated_by: user, diff --git a/x-pack/plugins/maps/public/actions/data_request_actions.ts b/x-pack/plugins/maps/public/actions/data_request_actions.ts index 5e27b488065ab..94213cf69bb60 100644 --- a/x-pack/plugins/maps/public/actions/data_request_actions.ts +++ b/x-pack/plugins/maps/public/actions/data_request_actions.ts @@ -9,7 +9,7 @@ import { AnyAction, Dispatch } from 'redux'; import { ThunkDispatch } from 'redux-thunk'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FeatureCollection } from 'geojson'; import { Adapters } from '@kbn/inspector-plugin/common/adapters'; import { MapStoreState } from '../reducers/store'; @@ -425,7 +425,7 @@ export function autoFitToBounds() { return async (dispatch: ThunkDispatch) => { // Method can be triggered before async actions complete // Use localSetQueryCallId to only continue execution path if method has not been re-triggered. - const localSetQueryCallId = uuid(); + const localSetQueryCallId = uuidv4(); lastSetQueryCallId = localSetQueryCallId; // Joins are performed on the client. diff --git a/x-pack/plugins/maps/public/classes/layers/create_basemap_layer_descriptor.test.ts b/x-pack/plugins/maps/public/classes/layers/create_basemap_layer_descriptor.test.ts index 4af58615cf99d..933e3d06c96ae 100644 --- a/x-pack/plugins/maps/public/classes/layers/create_basemap_layer_descriptor.test.ts +++ b/x-pack/plugins/maps/public/classes/layers/create_basemap_layer_descriptor.test.ts @@ -22,11 +22,9 @@ jest.mock('../../kibana_services', () => { }, }; }); -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); import { createBasemapLayerDescriptor } from './create_basemap_layer_descriptor'; diff --git a/x-pack/plugins/maps/public/classes/layers/create_region_map_layer_descriptor.ts b/x-pack/plugins/maps/public/classes/layers/create_region_map_layer_descriptor.ts index e88cbaa0d6d87..5cab5ec8b492f 100644 --- a/x-pack/plugins/maps/public/classes/layers/create_region_map_layer_descriptor.ts +++ b/x-pack/plugins/maps/public/classes/layers/create_region_map_layer_descriptor.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { AggDescriptor, ColorDynamicOptions, @@ -72,7 +72,7 @@ export function createRegionMapLayerDescriptor({ } const metricsDescriptor = createAggDescriptor(metricAgg, metricFieldName); - const joinId = uuid(); + const joinId = uuidv4(); const joinKey = getJoinAggKey({ aggType: metricsDescriptor.type, aggFieldName: 'field' in metricsDescriptor ? metricsDescriptor.field : '', diff --git a/x-pack/plugins/maps/public/classes/layers/layer.tsx b/x-pack/plugins/maps/public/classes/layers/layer.tsx index ef1a72649bbf0..9e698fee41fa8 100644 --- a/x-pack/plugins/maps/public/classes/layers/layer.tsx +++ b/x-pack/plugins/maps/public/classes/layers/layer.tsx @@ -12,7 +12,7 @@ import type { Query } from '@kbn/es-query'; import _ from 'lodash'; import React, { ReactElement } from 'react'; import { EuiIcon } from '@elastic/eui'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FeatureCollection } from 'geojson'; import { DataRequest } from '../util/data_request'; import { @@ -141,7 +141,7 @@ export class AbstractLayer implements ILayer { ...options, sourceDescriptor: options.sourceDescriptor ? options.sourceDescriptor : null, __dataRequests: _.get(options, '__dataRequests', []), - id: _.get(options, 'id', uuid()), + id: _.get(options, 'id', uuidv4()), label: options.label && options.label.length > 0 ? options.label : null, minZoom: _.get(options, 'minZoom', MIN_ZOOM), maxZoom: _.get(options, 'maxZoom', MAX_ZOOM), @@ -178,7 +178,7 @@ export class AbstractLayer implements ILayer { async cloneDescriptor(): Promise { const clonedDescriptor = copyPersistentState(this._descriptor); // layer id is uuid used to track styles/layers in mapbox - clonedDescriptor.id = uuid(); + clonedDescriptor.id = uuidv4(); const displayName = await this.getDisplayName(); clonedDescriptor.label = `Clone of ${displayName}`; clonedDescriptor.sourceDescriptor = this.getSource().cloneDescriptor(); diff --git a/x-pack/plugins/maps/public/classes/layers/layer_group/layer_group.tsx b/x-pack/plugins/maps/public/classes/layers/layer_group/layer_group.tsx index 7fa48628ef0db..5430ae76e27c4 100644 --- a/x-pack/plugins/maps/public/classes/layers/layer_group/layer_group.tsx +++ b/x-pack/plugins/maps/public/classes/layers/layer_group/layer_group.tsx @@ -12,7 +12,7 @@ import type { Query } from '@kbn/es-query'; import { asyncMap } from '@kbn/std'; import React, { ReactElement } from 'react'; import { EuiIcon } from '@elastic/eui'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { LAYER_TYPE, MAX_ZOOM, MIN_ZOOM } from '../../../../common/constants'; import { DataRequest } from '../../util/data_request'; import { copyPersistentState } from '../../../reducers/copy_persistent_state'; @@ -48,7 +48,7 @@ export class LayerGroup implements ILayer { return { ...options, type: LAYER_TYPE.LAYER_GROUP, - id: typeof options.id === 'string' && options.id.length ? options.id : uuid(), + id: typeof options.id === 'string' && options.id.length ? options.id : uuidv4(), label: typeof options.label === 'string' && options.label.length ? options.label @@ -86,7 +86,7 @@ export class LayerGroup implements ILayer { async cloneDescriptor(): Promise { const clonedDescriptor = copyPersistentState(this._descriptor); - clonedDescriptor.id = uuid(); + clonedDescriptor.id = uuidv4(); const displayName = await this.getDisplayName(); clonedDescriptor.label = `Clone of ${displayName}`; diff --git a/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.test.ts b/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.test.ts index dae0f5343dcc9..74c9f74c9d2ec 100644 --- a/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.test.ts +++ b/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.test.ts @@ -5,11 +5,9 @@ * 2.0. */ -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); import sinon from 'sinon'; import { MockSyncContext } from '../../__fixtures__/mock_sync_context'; diff --git a/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.ts b/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.ts index 19ad39e41a238..a3cfdabf17249 100644 --- a/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.ts +++ b/x-pack/plugins/maps/public/classes/layers/vector_layer/mvt_vector_layer/mvt_source_data.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { SOURCE_DATA_REQUEST_ID } from '../../../../../common/constants'; import { Timeslice, VectorSourceRequestMeta } from '../../../../../common/descriptor_types'; import { DataRequest } from '../../../util/data_request'; @@ -75,7 +75,7 @@ export async function syncMvtSourceData({ !prevData || syncContext.forceRefreshDueToDrawing || (requestMeta.isForceRefresh && requestMeta.applyForceRefresh) - ? uuid() + ? uuidv4() : prevData.refreshToken; const tileUrl = await source.getTileUrl(requestMeta, refreshToken, hasLabels); diff --git a/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.test.tsx b/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.test.tsx index d450f92467e46..640742b57aa93 100644 --- a/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.test.tsx +++ b/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.test.tsx @@ -11,11 +11,9 @@ jest.mock('../../styles/vector/vector_style', () => ({ VectorStyle: class MockVectorStyle {}, })); -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); import { AGG_TYPE, diff --git a/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.tsx b/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.tsx index 27768dc717bd7..13a093ad59713 100644 --- a/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.tsx +++ b/x-pack/plugins/maps/public/classes/layers/vector_layer/vector_layer.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import type { FilterSpecification, Map as MbMap, LayerSpecification } from '@kbn/mapbox-gl'; import type { Query } from '@kbn/data-plugin/common'; import { Feature, GeoJsonProperties, Geometry, Position } from 'geojson'; @@ -183,7 +183,7 @@ export class AbstractVectorLayer extends AbstractLayer implements IVectorLayer { const originalJoinId = joinDescriptor.right.id!; // right.id is uuid used to track requests in inspector - joinDescriptor.right.id = uuid(); + joinDescriptor.right.id = uuidv4(); // Update all data driven styling properties using join fields if (clonedDescriptor.style && 'properties' in clonedDescriptor.style) { diff --git a/x-pack/plugins/maps/public/classes/layers/wizards/choropleth_layer_wizard/create_choropleth_layer_descriptor.ts b/x-pack/plugins/maps/public/classes/layers/wizards/choropleth_layer_wizard/create_choropleth_layer_descriptor.ts index 2cbf6d3000b9a..b6770f5995891 100644 --- a/x-pack/plugins/maps/public/classes/layers/wizards/choropleth_layer_wizard/create_choropleth_layer_descriptor.ts +++ b/x-pack/plugins/maps/public/classes/layers/wizards/choropleth_layer_wizard/create_choropleth_layer_descriptor.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { AGG_TYPE, COLOR_MAP_TYPE, @@ -48,7 +48,7 @@ function createChoroplethLayerDescriptor({ layerType: LAYER_TYPE.GEOJSON_VECTOR | LAYER_TYPE.MVT_VECTOR; }) { const metricsDescriptor: CountAggDescriptor = { type: AGG_TYPE.COUNT }; - const joinId = uuid(); + const joinId = uuidv4(); const joinKey = getJoinAggKey({ aggType: metricsDescriptor.type, aggFieldName: '', diff --git a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.test.ts b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.test.ts index eff03a29ac99a..8c05c08ebc2b4 100644 --- a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.test.ts +++ b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.test.ts @@ -23,11 +23,9 @@ jest.mock('../../../../../kibana_services', () => { }; }); -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); import { createLayerDescriptor } from './create_layer_descriptor'; import { OBSERVABILITY_LAYER_TYPE } from './layer_select'; diff --git a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.ts b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.ts index b8536d8970939..240e78efae504 100644 --- a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.ts +++ b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/observability/create_layer_descriptor.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { AggDescriptor, @@ -158,7 +158,7 @@ export function createLayerDescriptor({ const metricsDescriptor = createAggDescriptor(metric); if (display === DISPLAY.CHOROPLETH) { - const joinId = uuid(); + const joinId = uuidv4(); const joinKey = getJoinAggKey({ aggType: metricsDescriptor.type, aggFieldName: 'field' in metricsDescriptor ? metricsDescriptor.field : '', diff --git a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/security/create_layer_descriptors.test.ts b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/security/create_layer_descriptors.test.ts index 48cd66c47b53d..22534c6a55658 100644 --- a/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/security/create_layer_descriptors.test.ts +++ b/x-pack/plugins/maps/public/classes/layers/wizards/solution_layers/security/create_layer_descriptors.test.ts @@ -22,11 +22,9 @@ jest.mock('../../../../../kibana_services', () => { }; }); -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); import { createSecurityLayerDescriptors } from './create_layer_descriptors'; diff --git a/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.test.tsx b/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.test.tsx index 0df4c492940b7..8aa320f17cc49 100644 --- a/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.test.tsx +++ b/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.test.tsx @@ -11,11 +11,9 @@ import { shallow } from 'enzyme'; import { UpdateSourceEditor } from './update_source_editor'; import { GRID_RESOLUTION, LAYER_TYPE, RENDER_AS } from '../../../../common/constants'; -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); const defaultProps = { currentLayerType: LAYER_TYPE.GEOJSON_VECTOR, diff --git a/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.tsx b/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.tsx index 52431b95f52c2..3268992c7f2b6 100644 --- a/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.tsx +++ b/x-pack/plugins/maps/public/classes/sources/es_geo_grid_source/update_source_editor.tsx @@ -7,7 +7,7 @@ import React, { Fragment, Component } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FormattedMessage } from '@kbn/i18n-react'; import { EuiPanel, EuiSpacer, EuiComboBoxOptionOption, EuiTitle } from '@elastic/eui'; import { DataViewField } from '@kbn/data-views-plugin/public'; @@ -44,7 +44,7 @@ export class UpdateSourceEditor extends Component { private _isMounted?: boolean; state: State = { fields: [], - metricsEditorKey: uuid(), + metricsEditorKey: uuidv4(), }; componentDidMount() { @@ -110,7 +110,7 @@ export class UpdateSourceEditor extends Component { // Metrics editor persists metrics in state. // Reset metricsEditorKey to force new instance and new internal state with latest metrics - this.setState({ metricsEditorKey: uuid() }); + this.setState({ metricsEditorKey: uuidv4() }); }; _onRequestTypeSelect = (requestType: RENDER_AS) => { diff --git a/x-pack/plugins/maps/public/classes/sources/es_search_source/create_layer_descriptor.test.ts b/x-pack/plugins/maps/public/classes/sources/es_search_source/create_layer_descriptor.test.ts index 0c68bf6d832ad..97b0d2b188ab5 100644 --- a/x-pack/plugins/maps/public/classes/sources/es_search_source/create_layer_descriptor.test.ts +++ b/x-pack/plugins/maps/public/classes/sources/es_search_source/create_layer_descriptor.test.ts @@ -22,11 +22,9 @@ jest.mock('../../../licensed_features', () => { }, }; }); -jest.mock('uuid/v4', () => { - return function () { - return '12345'; - }; -}); +jest.mock('uuid', () => ({ + v4: jest.fn().mockReturnValue('12345'), +})); test('Should create layer descriptor', () => { const layerDescriptor = createLayerDescriptor({ diff --git a/x-pack/plugins/maps/public/classes/sources/es_source/es_source.ts b/x-pack/plugins/maps/public/classes/sources/es_source/es_source.ts index cfc7b052c5569..32d60cac8c7d6 100644 --- a/x-pack/plugins/maps/public/classes/sources/es_source/es_source.ts +++ b/x-pack/plugins/maps/public/classes/sources/es_source/es_source.ts @@ -6,7 +6,7 @@ */ import { i18n } from '@kbn/i18n'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { Adapters } from '@kbn/inspector-plugin/common/adapters'; import { Filter } from '@kbn/es-query'; import { DataViewField, DataView, ISearchSource } from '@kbn/data-plugin/common'; @@ -89,7 +89,7 @@ export class AbstractESSource extends AbstractVectorSource implements IESSource } return { ...descriptor, - id: isValidStringConfig(descriptor.id) ? descriptor.id! : uuid(), + id: isValidStringConfig(descriptor.id) ? descriptor.id! : uuidv4(), type: isValidStringConfig(descriptor.type) ? descriptor.type! : '', indexPatternId: descriptor.indexPatternId!, applyGlobalQuery: @@ -148,7 +148,7 @@ export class AbstractESSource extends AbstractVectorSource implements IESSource cloneDescriptor(): AbstractSourceDescriptor { const clonedDescriptor = copyPersistentState(this._descriptor); // id used as uuid to track requests in inspector - clonedDescriptor.id = uuid(); + clonedDescriptor.id = uuidv4(); return clonedDescriptor; } diff --git a/x-pack/plugins/maps/public/classes/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.tsx b/x-pack/plugins/maps/public/classes/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.tsx index 9bb22c17f4118..539503b1ebafb 100644 --- a/x-pack/plugins/maps/public/classes/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.tsx +++ b/x-pack/plugins/maps/public/classes/sources/mvt_single_layer_vector_source/mvt_single_layer_vector_source.tsx @@ -6,7 +6,7 @@ */ import { i18n } from '@kbn/i18n'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import React from 'react'; import { GeoJsonProperties, Geometry, Position } from 'geojson'; import { AbstractSource, ImmutableSourceProperty, SourceEditorArgs } from '../source'; @@ -53,7 +53,7 @@ export class MVTSingleLayerVectorSource extends AbstractSource implements IMvtVe }: Partial) { return { type: SOURCE_TYPES.MVT_SINGLE_LAYER, - id: uuid(), + id: uuidv4(), urlTemplate: urlTemplate ? urlTemplate : '', layerName: layerName ? layerName : '', minSourceZoom: diff --git a/x-pack/plugins/maps/public/classes/sources/table_source/table_source.ts b/x-pack/plugins/maps/public/classes/sources/table_source/table_source.ts index 211fc65e09167..bfb143ef8b831 100644 --- a/x-pack/plugins/maps/public/classes/sources/table_source/table_source.ts +++ b/x-pack/plugins/maps/public/classes/sources/table_source/table_source.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { GeoJsonProperties } from 'geojson'; import type { Query } from '@kbn/data-plugin/common'; import { FIELD_ORIGIN, SOURCE_TYPES, VECTOR_SHAPE_TYPE } from '../../../../common/constants'; @@ -38,7 +38,7 @@ export class TableSource extends AbstractVectorSource implements ITermJoinSource __rows: descriptor.__rows || [], __columns: descriptor.__columns || [], term: descriptor.term || '', - id: descriptor.id || uuid(), + id: descriptor.id || uuidv4(), }; } @@ -52,7 +52,7 @@ export class TableSource extends AbstractVectorSource implements ITermJoinSource async getDisplayName(): Promise { // no need to localize. this is never rendered. - return `table source ${uuid()}`; + return `table source ${uuidv4()}`; } getSyncMeta(): null { diff --git a/x-pack/plugins/maps/public/classes/styles/vector/symbol_utils.tsx b/x-pack/plugins/maps/public/classes/styles/vector/symbol_utils.tsx index b77b3b69337a4..5a2c1bc687a0e 100644 --- a/x-pack/plugins/maps/public/classes/styles/vector/symbol_utils.tsx +++ b/x-pack/plugins/maps/public/classes/styles/vector/symbol_utils.tsx @@ -7,7 +7,7 @@ import React, { CSSProperties } from 'react'; import xml2js from 'xml2js'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { Canvg } from 'canvg'; // @ts-expect-error import calcSDF from 'bitmap-sdf'; @@ -109,7 +109,7 @@ export function getMakiSymbolAnchor(symbolId: string) { } export function getCustomIconId() { - return `${CUSTOM_ICON_PREFIX_SDF}${uuid()}`; + return `${CUSTOM_ICON_PREFIX_SDF}${uuidv4()}`; } export function buildSrcUrl(svgString: string) { diff --git a/x-pack/plugins/maps/public/connected_components/edit_layer_panel/join_editor/join_editor.tsx b/x-pack/plugins/maps/public/connected_components/edit_layer_panel/join_editor/join_editor.tsx index 68b9290f72b51..9d39724144dab 100644 --- a/x-pack/plugins/maps/public/connected_components/edit_layer_panel/join_editor/join_editor.tsx +++ b/x-pack/plugins/maps/public/connected_components/edit_layer_panel/join_editor/join_editor.tsx @@ -6,7 +6,7 @@ */ import React, { Fragment } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { EuiTitle, EuiSpacer, EuiTextAlign, EuiCallOut } from '@elastic/eui'; @@ -69,7 +69,7 @@ export function JoinEditor({ joins, layer, onChange, leftJoinFields, layerDispla ...joins, { right: { - id: uuid(), + id: uuidv4(), applyGlobalQuery: true, applyGlobalTime: true, }, diff --git a/x-pack/plugins/maps/public/connected_components/map_container/map_container.tsx b/x-pack/plugins/maps/public/connected_components/map_container/map_container.tsx index 51c7b8675f145..5467cb59e900e 100644 --- a/x-pack/plugins/maps/public/connected_components/map_container/map_container.tsx +++ b/x-pack/plugins/maps/public/connected_components/map_container/map_container.tsx @@ -9,7 +9,7 @@ import React, { Component } from 'react'; import classNames from 'classnames'; import { EuiFlexGroup, EuiFlexItem, EuiCallOut } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { Filter } from '@kbn/es-query'; import { ActionExecutionContext, Action } from '@kbn/ui-actions-plugin/public'; import { Observable } from 'rxjs'; @@ -70,7 +70,7 @@ export class MapContainer extends Component { state: State = { isInitialLoadRenderTimeoutComplete: false, - domId: uuid(), + domId: uuidv4(), showFitToBoundsButton: false, showTimesliderButton: false, }; diff --git a/x-pack/plugins/maps/public/connected_components/mb_map/tooltip_control/tooltip_control.tsx b/x-pack/plugins/maps/public/connected_components/mb_map/tooltip_control/tooltip_control.tsx index 70def963d01dd..8bc56e84b02da 100644 --- a/x-pack/plugins/maps/public/connected_components/mb_map/tooltip_control/tooltip_control.tsx +++ b/x-pack/plugins/maps/public/connected_components/mb_map/tooltip_control/tooltip_control.tsx @@ -16,7 +16,7 @@ import { Point2D, PointLike, } from '@kbn/mapbox-gl'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { Geometry } from 'geojson'; import { Filter } from '@kbn/es-query'; import { ActionExecutionContext, Action } from '@kbn/ui-actions-plugin/public'; @@ -251,7 +251,7 @@ export class TooltipControl extends Component { const popupAnchorLocation = justifyAnchorLocation(e.lngLat, targetMbFeataure); const isLocked = true; - const tooltipId = uuid(); + const tooltipId = uuidv4(); const features = this._getTooltipFeatures(mbFeatures, isLocked, tooltipId); if (features.length === 0) { return; @@ -293,7 +293,7 @@ export class TooltipControl extends Component { const popupAnchorLocation = justifyAnchorLocation(e.lngLat, targetMbFeature); const isLocked = false; - const tooltipId = uuid(); + const tooltipId = uuidv4(); const features = this._getTooltipFeatures(mbFeatures, isLocked, tooltipId); if (features.length === 0) { return; diff --git a/x-pack/plugins/maps/public/embeddable/map_component.tsx b/x-pack/plugins/maps/public/embeddable/map_component.tsx index bb331ccf38c0e..18774193ee312 100644 --- a/x-pack/plugins/maps/public/embeddable/map_component.tsx +++ b/x-pack/plugins/maps/public/embeddable/map_component.tsx @@ -6,7 +6,7 @@ */ import React, { Component, RefObject } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { EuiLoadingChart } from '@elastic/eui'; import type { Filter } from '@kbn/es-query'; import type { Query, TimeRange } from '@kbn/es-query'; @@ -80,7 +80,7 @@ export class MapComponent extends Component { editable: false, }, { - id: uuid(), + id: uuidv4(), attributes: { title: this.props.title, layerListJSON: JSON.stringify([ diff --git a/x-pack/plugins/maps/public/lens/passive_map.tsx b/x-pack/plugins/maps/public/lens/passive_map.tsx index 1117ad1d6db28..298d89fba3add 100644 --- a/x-pack/plugins/maps/public/lens/passive_map.tsx +++ b/x-pack/plugins/maps/public/lens/passive_map.tsx @@ -6,7 +6,7 @@ */ import React, { Component, RefObject } from 'react'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { EuiLoadingChart } from '@elastic/eui'; import { EmbeddableFactory, ViewMode } from '@kbn/embeddable-plugin/public'; import type { LayerDescriptor } from '../../common/descriptor_types'; @@ -60,7 +60,7 @@ export class PassiveMap extends Component { const basemapLayerDescriptor = createBasemapLayerDescriptor(); const intialLayers = basemapLayerDescriptor ? [basemapLayerDescriptor] : []; const mapEmbeddable = await this.props.factory.create({ - id: uuid(), + id: uuidv4(), attributes: { title: '', layerListJSON: JSON.stringify([...intialLayers, this.props.passiveLayer]), diff --git a/x-pack/plugins/maps/public/render_app.tsx b/x-pack/plugins/maps/public/render_app.tsx index 23244df45b9b5..d8112b696d24b 100644 --- a/x-pack/plugins/maps/public/render_app.tsx +++ b/x-pack/plugins/maps/public/render_app.tsx @@ -28,8 +28,6 @@ import { MapByValueInput, MapByReferenceInput } from './embeddable/types'; import { APP_ID } from '../common/constants'; import { registerLayerWizards } from './classes/layers/wizards/load_layer_wizards'; -export let goToSpecifiedPath: (path: string) => void; - function setAppChrome() { if (!getMapsCapabilities().save) { getCoreChrome().setBadge({ @@ -73,8 +71,6 @@ export async function renderApp( AppUsageTracker: React.FC; } ) { - goToSpecifiedPath = (path) => history.push(path); - const stateTransfer = getEmbeddableService().getStateTransfer(); registerLayerWizards(); @@ -137,7 +133,7 @@ export async function renderApp( const newPath = hash.substr(1); return ; } else if (pathname === '/' || pathname === '') { - return ; + return ; } else { return ; } diff --git a/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx b/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx index bc81924a1f1cd..62403cd4db327 100644 --- a/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx +++ b/x-pack/plugins/maps/public/routes/list_page/load_list_and_render.tsx @@ -5,15 +5,21 @@ * 2.0. */ -import React from 'react'; +import React, { Component } from 'react'; import { i18n } from '@kbn/i18n'; import { Redirect } from 'react-router-dom'; import { EmbeddableStateTransfer } from '@kbn/embeddable-plugin/public'; +import { ScopedHistory } from '@kbn/core/public'; import { getSavedObjectsClient, getToasts } from '../../kibana_services'; import { MapsListView } from './maps_list_view'; import { APP_ID, MAP_SAVED_OBJECT_TYPE } from '../../../common/constants'; -export class LoadListAndRender extends React.Component<{ stateTransfer: EmbeddableStateTransfer }> { +interface Props { + history: ScopedHistory; + stateTransfer: EmbeddableStateTransfer; +} + +export class LoadListAndRender extends Component { _isMounted: boolean = false; state = { mapsLoaded: false, @@ -57,7 +63,7 @@ export class LoadListAndRender extends React.Component<{ stateTransfer: Embeddab const { mapsLoaded, hasSavedMaps } = this.state; if (mapsLoaded) { - return hasSavedMaps ? : ; + return hasSavedMaps ? : ; } else { return null; } diff --git a/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx b/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx index 1506a2569c273..3dab6db00885d 100644 --- a/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx +++ b/x-pack/plugins/maps/public/routes/list_page/maps_list_view.tsx @@ -7,13 +7,12 @@ import React from 'react'; import { SavedObjectReference } from '@kbn/core/types'; -import type { SavedObjectsFindOptionsReference } from '@kbn/core/public'; +import type { SavedObjectsFindOptionsReference, ScopedHistory } from '@kbn/core/public'; import { METRIC_TYPE } from '@kbn/analytics'; import { i18n } from '@kbn/i18n'; import { TableListView } from '@kbn/content-management-table-list'; import type { UserContentCommonSchema } from '@kbn/content-management-table-list'; import { SimpleSavedObject } from '@kbn/core-saved-objects-api-browser'; -import { goToSpecifiedPath } from '../../render_app'; import { APP_ID, getEditPath, MAP_PATH, MAP_SAVED_OBJECT_TYPE } from '../../../common/constants'; import { getMapsCapabilities, @@ -100,7 +99,11 @@ async function deleteMaps(items: object[]) { await Promise.all(deletions); } -export function MapsListView() { +interface Props { + history: ScopedHistory; +} + +export function MapsListView(props: Props) { getExecutionContext().set({ type: 'application', page: 'list', @@ -131,7 +134,7 @@ export function MapsListView() { defaultMessage: 'maps', })} tableListTitle={getAppTitle()} - onClickTitle={({ id }) => goToSpecifiedPath(getEditPath(id))} + onClickTitle={({ id }) => props.history.push(getEditPath(id))} /> ); } diff --git a/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx b/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx index fffb12130a05d..bf8963de0461d 100644 --- a/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx +++ b/x-pack/plugins/maps/public/routes/map_page/map_app/map_app.tsx @@ -9,7 +9,7 @@ import React from 'react'; import _ from 'lodash'; import { finalize, switchMap, tap } from 'rxjs/operators'; import { i18n } from '@kbn/i18n'; -import { AppLeaveAction, AppMountParameters } from '@kbn/core/public'; +import { AppLeaveAction, AppMountParameters, ScopedHistory } from '@kbn/core/public'; import { Adapters } from '@kbn/embeddable-plugin/public'; import { Subscription } from 'rxjs'; import { type Filter, FilterStateStore, type Query, type TimeRange } from '@kbn/es-query'; @@ -42,7 +42,6 @@ import { AppStateManager, startAppStateSyncing } from '../url_state'; import { MapContainer } from '../../../connected_components/map_container'; import { getIndexPatternsFromIds } from '../../../index_pattern_util'; import { getTopNavConfig } from '../top_nav_config'; -import { goToSpecifiedPath } from '../../../render_app'; import { getEditPath, getFullPath, APP_ID } from '../../../../common/constants'; import { getMapEmbeddableDisplayName } from '../../../../common/i18n_getters'; import { @@ -84,7 +83,7 @@ export interface Props { isSaveDisabled: boolean; query: Query | undefined; setHeaderActionMenu: AppMountParameters['setHeaderActionMenu']; - history: AppMountParameters['history']; + history: ScopedHistory; } export interface State { @@ -397,7 +396,7 @@ export class MapApp extends React.Component { }), text: `${err.message}`, }); - goToSpecifiedPath('/'); + this.props.history.push('/'); } return; } @@ -420,7 +419,7 @@ export class MapApp extends React.Component { return; } - this.props.savedMap.setBreadcrumbs(); + this.props.savedMap.setBreadcrumbs(this.props.history); getCoreChrome().docTitle.change(this.props.savedMap.getTitle()); const savedObjectId = this.props.savedMap.getSavedObjectId(); if (savedObjectId) { @@ -457,6 +456,7 @@ export class MapApp extends React.Component { enableFullScreen: this.props.enableFullScreen, openMapSettings: this.props.openMapSettings, inspectorAdapters: this.props.inspectorAdapters, + history: this.props.history, }); const { TopNavMenu } = getNavigation().ui; diff --git a/x-pack/plugins/maps/public/routes/map_page/map_page.tsx b/x-pack/plugins/maps/public/routes/map_page/map_page.tsx index 703e60638649e..e3a2af0971355 100644 --- a/x-pack/plugins/maps/public/routes/map_page/map_page.tsx +++ b/x-pack/plugins/maps/public/routes/map_page/map_page.tsx @@ -7,7 +7,7 @@ import React, { Component } from 'react'; import { Provider } from 'react-redux'; -import type { AppMountParameters } from '@kbn/core/public'; +import type { AppMountParameters, ScopedHistory } from '@kbn/core/public'; import type { EmbeddableStateTransfer } from '@kbn/embeddable-plugin/public'; import { MapApp } from './map_app'; import { @@ -25,7 +25,7 @@ interface Props { stateTransfer: EmbeddableStateTransfer; originatingApp?: string; originatingPath?: string; - history: AppMountParameters['history']; + history: ScopedHistory; } interface State { diff --git a/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.test.tsx b/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.test.tsx index 639167eba0e71..a04583270030b 100644 --- a/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.test.tsx +++ b/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.test.tsx @@ -6,6 +6,7 @@ */ import { getBreadcrumbs } from './get_breadcrumbs'; +import { ScopedHistory } from '@kbn/core/public'; jest.mock('../../../kibana_services', () => {}); jest.mock('../../../render_app', () => {}); @@ -14,11 +15,16 @@ const getHasUnsavedChanges = () => { return false; }; +const mockHistory = { + push: () => {}, +} as unknown as ScopedHistory; + test('should get breadcrumbs "Maps / mymap"', () => { const breadcrumbs = getBreadcrumbs({ pageTitle: 'mymap', getHasUnsavedChanges, isByValue: false, + history: mockHistory, }); expect(breadcrumbs.length).toBe(2); expect(breadcrumbs[0].text).toBe('Maps'); @@ -34,6 +40,7 @@ test('should get breadcrumbs "Dashboard / mymap" with originatingApp and by valu getAppNameFromId: (appId) => { return 'Dashboard'; }, + history: mockHistory, }); expect(breadcrumbs.length).toBe(2); expect(breadcrumbs[0].text).toBe('Dashboard'); @@ -49,6 +56,7 @@ test('should get breadcrumbs "Dashboard / Maps / mymap" with originatingApp and getAppNameFromId: (appId) => { return 'Dashboard'; }, + history: mockHistory, }); expect(breadcrumbs.length).toBe(3); expect(breadcrumbs[0].text).toBe('Dashboard'); diff --git a/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.tsx b/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.tsx index 2d1246c40b2e1..ca3022043cd9f 100644 --- a/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.tsx +++ b/x-pack/plugins/maps/public/routes/map_page/saved_map/get_breadcrumbs.tsx @@ -6,8 +6,8 @@ */ import { i18n } from '@kbn/i18n'; +import { ScopedHistory } from '@kbn/core/public'; import { getCoreOverlays, getNavigateToApp } from '../../../kibana_services'; -import { goToSpecifiedPath } from '../../../render_app'; import { getAppTitle } from '../../../../common/i18n_getters'; export const unsavedChangesWarning = i18n.translate( @@ -27,12 +27,14 @@ export function getBreadcrumbs({ getHasUnsavedChanges, originatingApp, getAppNameFromId, + history, }: { pageTitle: string; isByValue: boolean; getHasUnsavedChanges: () => boolean; originatingApp?: string; getAppNameFromId?: (id: string) => string | undefined; + history: ScopedHistory; }) { const breadcrumbs = []; @@ -55,10 +57,10 @@ export function getBreadcrumbs({ 'data-test-subj': 'appLeaveConfirmModal', }); if (confirmed) { - goToSpecifiedPath('/'); + history.push('/'); } } else { - goToSpecifiedPath('/'); + history.push('/'); } }, }); diff --git a/x-pack/plugins/maps/public/routes/map_page/saved_map/saved_map.ts b/x-pack/plugins/maps/public/routes/map_page/saved_map/saved_map.ts index e7adcd0795efb..30ce717b014dc 100644 --- a/x-pack/plugins/maps/public/routes/map_page/saved_map/saved_map.ts +++ b/x-pack/plugins/maps/public/routes/map_page/saved_map/saved_map.ts @@ -9,6 +9,7 @@ import _ from 'lodash'; import { METRIC_TYPE } from '@kbn/analytics'; import { i18n } from '@kbn/i18n'; import { EmbeddableStateTransfer } from '@kbn/embeddable-plugin/public'; +import { ScopedHistory } from '@kbn/core/public'; import { OnSaveProps } from '@kbn/saved-objects-plugin/public'; import { MapSavedObjectAttributes } from '../../../../common/map_saved_object_type'; import { APP_ID, MAP_PATH, MAP_SAVED_OBJECT_TYPE } from '../../../../common/constants'; @@ -45,7 +46,6 @@ import { getTimeFilter, getUsageCollection, } from '../../../kibana_services'; -import { goToSpecifiedPath } from '../../../render_app'; import { LayerDescriptor } from '../../../../common/descriptor_types'; import { copyPersistentState } from '../../../reducers/copy_persistent_state'; import { getBreadcrumbs } from './get_breadcrumbs'; @@ -326,7 +326,7 @@ export class SavedMap { } } - setBreadcrumbs() { + setBreadcrumbs(history: ScopedHistory) { if (!this._attributes) { throw new Error('Invalid usage, must await whenReady before calling hasUnsavedChanges'); } @@ -337,6 +337,7 @@ export class SavedMap { getHasUnsavedChanges: this.hasUnsavedChanges, originatingApp: this._originatingApp, getAppNameFromId: this._getStateTransfer().getAppNameFromId, + history, }); getCoreChrome().setBreadcrumbs(breadcrumbs); } @@ -433,11 +434,13 @@ export class SavedMap { newTags, saveByReference, dashboardId, + history, }: OnSaveProps & { returnToOrigin?: boolean; newTags?: string[]; saveByReference: boolean; dashboardId?: string | null; + history: ScopedHistory; }) { if (!this._attributes) { throw new Error('Invalid usage, must await whenReady before calling save'); @@ -525,8 +528,8 @@ export class SavedMap { }); getCoreChrome().docTitle.change(newTitle); - this.setBreadcrumbs(); - goToSpecifiedPath(`/${MAP_PATH}/${this.getSavedObjectId()}${window.location.hash}`); + this.setBreadcrumbs(history); + history.push(`/${MAP_PATH}/${this.getSavedObjectId()}${window.location.hash}`); if (this._onSaveCallback) { this._onSaveCallback(); diff --git a/x-pack/plugins/maps/public/routes/map_page/top_nav_config.tsx b/x-pack/plugins/maps/public/routes/map_page/top_nav_config.tsx index 2032d78ab46bc..917e411f9790c 100644 --- a/x-pack/plugins/maps/public/routes/map_page/top_nav_config.tsx +++ b/x-pack/plugins/maps/public/routes/map_page/top_nav_config.tsx @@ -18,12 +18,12 @@ import { LazySavedObjectSaveModalDashboard, withSuspense, } from '@kbn/presentation-util-plugin/public'; +import { ScopedHistory } from '@kbn/core/public'; import { getNavigateToApp, getMapsCapabilities, getIsAllowByValueEmbeddables, getInspector, - getCoreI18n, getSavedObjectsClient, getCoreOverlays, getSavedObjectsTagging, @@ -42,6 +42,7 @@ export function getTopNavConfig({ enableFullScreen, openMapSettings, inspectorAdapters, + history, }: { savedMap: SavedMap; isOpenSettingsDisabled: boolean; @@ -49,6 +50,7 @@ export function getTopNavConfig({ enableFullScreen: () => void; openMapSettings: () => void; inspectorAdapters: Adapters; + history: ScopedHistory; }) { const topNavConfigs = []; @@ -197,6 +199,7 @@ export function getTopNavConfig({ ...props, newTags: selectedTags, saveByReference: props.addToLibrary, + history, }); // showSaveModal wrapper requires onSave to return an object with an id to close the modal after successful save return { id: 'id' }; @@ -245,7 +248,7 @@ export function getTopNavConfig({ ); } - showSaveModal(saveModal, getCoreI18n().Context, PresentationUtilContext); + showSaveModal(saveModal, PresentationUtilContext); }, }); @@ -266,6 +269,7 @@ export function getTopNavConfig({ returnToOrigin: true, onTitleDuplicate: () => {}, saveByReference: !savedMap.isByValue(), + history, }); }, testId: 'mapSaveAndReturnButton', diff --git a/x-pack/plugins/maps/public/trigger_actions/visualize_geo_field_action.ts b/x-pack/plugins/maps/public/trigger_actions/visualize_geo_field_action.ts index fb04e98601b19..c1194fec094a3 100644 --- a/x-pack/plugins/maps/public/trigger_actions/visualize_geo_field_action.ts +++ b/x-pack/plugins/maps/public/trigger_actions/visualize_geo_field_action.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import type { Query } from '@kbn/es-query'; import type { SerializableRecord } from '@kbn/utility-types'; @@ -69,11 +69,11 @@ const getMapsLink = async (context: VisualizeFieldContext) => { context?.contextualFields?.length && context?.contextualFields[0] !== '_source'; const initialLayers = [ { - id: uuid(), + id: uuidv4(), visible: true, type: LAYER_TYPE.MVT_VECTOR, sourceDescriptor: { - id: uuid(), + id: uuidv4(), type: SOURCE_TYPES.ES_SEARCH, tooltipProperties: hasTooltips ? context.contextualFields : [], label: dataView.getIndexPattern(), diff --git a/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts b/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts index 421054ac75067..4a55697e0f138 100644 --- a/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts +++ b/x-pack/plugins/maps/server/saved_objects/saved_object_migrations.ts @@ -28,7 +28,7 @@ function logMigrationWarning( errorMsg: string, doc: SavedObjectUnsanitizedDoc ) { - context.log.warning( + context.log.warn( `map migration failed (${context.migrationVersion}). ${errorMsg}. attributes: ${JSON.stringify( doc )}` diff --git a/x-pack/plugins/ml/public/application/jobs/jobs_list/components/datafeed_chart_flyout/datafeed_chart_flyout.tsx b/x-pack/plugins/ml/public/application/jobs/jobs_list/components/datafeed_chart_flyout/datafeed_chart_flyout.tsx index 77f139931986c..1aa9aa699efed 100644 --- a/x-pack/plugins/ml/public/application/jobs/jobs_list/components/datafeed_chart_flyout/datafeed_chart_flyout.tsx +++ b/x-pack/plugins/ml/public/application/jobs/jobs_list/components/datafeed_chart_flyout/datafeed_chart_flyout.tsx @@ -131,7 +131,7 @@ export const DatafeedChartFlyout: FC = ({ const [messageData, setMessageData] = useState([]); const [sourceData, setSourceData] = useState([]); const [showAnnotations, setShowAnnotations] = useState(true); - const [showModelSnapshots, setShowModelSnapshots] = useState(true); + const [showModelSnapshots, setShowModelSnapshots] = useState(false); const [range, setRange] = useState<{ start: string; end: string } | undefined>(); const canUpdateDatafeed = useMemo(() => checkPermission('canUpdateDatafeed'), []); const canCreateJob = useMemo(() => checkPermission('canCreateJob'), []); @@ -443,7 +443,7 @@ export const DatafeedChartFlyout: FC = ({ defaultMessage: 'Count', })} position={Position.Left} - tickFormat={(d) => (d === null ? notAvailableMessage : d)} + tickFormat={(d) => (d === null ? notAvailableMessage : String(d))} /> {showAnnotations ? ( <> diff --git a/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/bucket_span_estimator.tsx b/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/bucket_span_estimator.tsx index 8018c881e3b2e..bd08169f0f288 100644 --- a/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/bucket_span_estimator.tsx +++ b/x-pack/plugins/ml/public/application/jobs/new_job/pages/components/pick_fields_step/components/bucket_span_estimator/bucket_span_estimator.tsx @@ -19,7 +19,7 @@ interface Props { } export const BucketSpanEstimator: FC = ({ setEstimating }) => { - const { jobCreator, jobCreatorUpdate } = useContext(JobCreatorContext); + const { jobCreator, jobCreatorUpdated } = useContext(JobCreatorContext); const { status, estimateBucketSpan } = useEstimateBucketSpan(); const [noDetectors, setNoDetectors] = useState(jobCreator.detectors.length === 0); const [isUsingMlCategory, setIsUsingMlCategory] = useState(checkIsUsingMlCategory()); @@ -33,7 +33,7 @@ export const BucketSpanEstimator: FC = ({ setEstimating }) => { setNoDetectors(jobCreator.detectors.length === 0); setIsUsingMlCategory(checkIsUsingMlCategory()); // eslint-disable-next-line react-hooks/exhaustive-deps - }, [jobCreatorUpdate]); + }, [jobCreatorUpdated]); function checkIsUsingMlCategory() { return ( diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/README.md b/x-pack/plugins/monitoring/server/routes/api/v1/_health/README.md index 09fc9452ae112..f335bef44d012 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/README.md +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/README.md @@ -12,3 +12,4 @@ The response includes sections that can provide useful informations in a debuggi - settings: a subset of the kibana.yml settings relevant to stack monitoring - monitoredClusters: a representation of the monitoring documents available to the running kibana. It exposes which metricsets are collected by what collection mode and when was the last time it was ingested. The query groups the metricsets by products and can help identify missing documents that could explain why a page is not loading or crashing - metricbeatErrors: a list of errors encountered by metricbeat processes when collecting data +- packageErrors: a list of errors encountered by integration package processes when collecting data \ No newline at end of file diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.test.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.test.ts new file mode 100644 index 0000000000000..2424d807aa473 --- /dev/null +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.test.ts @@ -0,0 +1,141 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { buildErrors } from './build_errors'; +import assert from 'assert'; + +describe(__filename, () => { + describe('buildErrors', () => { + test('Metricbeat: it should build an object containing dedup error messages per event.dataset', () => { + const metricbeatErrors = [ + { + key: 'beat', + errors_by_dataset: { + buckets: [ + { + key: 'state', + latest_docs: { + hits: { + hits: [ + { + _source: { + '@timestamp': '2022-07-26T08:43:32.625Z', + error: { + message: + 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', + }, + }, + }, + { + _source: { + '@timestamp': '2022-07-26T08:42:32.625Z', + error: { + message: + 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', + }, + }, + }, + { + _source: { + '@timestamp': '2022-07-26T08:41:32.625Z', + error: { + message: 'Generic random error', + }, + }, + }, + ], + }, + }, + }, + ], + }, + }, + ]; + + const monitoredClusters = buildErrors(metricbeatErrors); + assert.deepEqual(monitoredClusters, { + beat: { + state: [ + { + lastSeen: '2022-07-26T08:43:32.625Z', + message: + 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', + }, + { + lastSeen: '2022-07-26T08:41:32.625Z', + message: 'Generic random error', + }, + ], + }, + }); + }); + + test('Packages: it should build an object containing dedup error messages per event.dataset', () => { + const packageErrors = [ + { + key: 'elasticsearch', + errors_by_dataset: { + buckets: [ + { + key: 'state', + latest_docs: { + hits: { + hits: [ + { + _source: { + '@timestamp': '2023-01-10T14:39:37.114Z', + error: { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + }, + }, + { + _source: { + '@timestamp': '2023-01-10T14:39:27.114Z', + error: { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + }, + }, + { + _source: { + '@timestamp': '2022-07-26T08:41:32.625Z', + error: { + message: 'Generic random error', + }, + }, + }, + ], + }, + }, + }, + ], + }, + }, + ]; + + const monitoredClusters = buildErrors(packageErrors); + assert.deepEqual(monitoredClusters, { + elasticsearch: { + state: [ + { + lastSeen: '2023-01-10T14:39:37.114Z', + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + { + lastSeen: '2022-07-26T08:41:32.625Z', + message: 'Generic random error', + }, + ], + }, + }); + }); + }); +}); diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.ts similarity index 84% rename from x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.ts rename to x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.ts index 44f0df8c067cc..9e9704828548b 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.ts +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/build_errors.ts @@ -5,10 +5,10 @@ * 2.0. */ -import type { MetricbeatMonitoredProduct } from '../types'; +import type { MonitoredProduct } from '../types'; -export type MetricbeatProducts = { - [product in MetricbeatMonitoredProduct]?: ErrorsByMetricset; +export type Products = { + [product in MonitoredProduct]?: ErrorsByMetricset; }; interface ErrorsByMetricset { @@ -21,14 +21,14 @@ interface ErrorDetails { } /** - * builds a normalized representation of the metricbeat errors from the provided + * builds a normalized representation of the metricbeat and integration package errors from the provided * query buckets with a product->metricset hierarchy where * product: the monitored products (eg elasticsearch) * metricset: the collected metricsets for a given entity * * example: * { - * "product": { + * "products": { * "logstash": { * "node": { * "message": "some error message", @@ -38,7 +38,7 @@ interface ErrorDetails { * } * } */ -export const buildMetricbeatErrors = (modulesBucket: any[]): MetricbeatProducts => { +export const buildErrors = (modulesBucket: any[]): Products => { return (modulesBucket ?? []).reduce((module, { key, errors_by_dataset: errorsByDataset }) => { const datasets = buildMetricsets(errorsByDataset.buckets); if (Object.keys(datasets).length === 0) { @@ -49,7 +49,7 @@ export const buildMetricbeatErrors = (modulesBucket: any[]): MetricbeatProducts ...module, [key]: datasets, }; - }, {} as MetricbeatProducts); + }, {} as Products); }; const buildMetricsets = (errorsByDataset: any[]): ErrorsByMetricset => { diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/metricbeat_errors_query.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/errors_query.ts similarity index 53% rename from x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/metricbeat_errors_query.ts rename to x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/errors_query.ts index 28d1b5cc8d227..0c2fd16bf487c 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/metricbeat_errors_query.ts +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/errors_helpers/errors_query.ts @@ -5,7 +5,7 @@ * 2.0. */ -import type { MetricbeatMonitoredProduct, QueryOptions } from '../types'; +import type { MetricbeatMonitoredProduct, PackagesMonitoredProduct, QueryOptions } from '../types'; const MAX_BUCKET_SIZE = 50; @@ -13,16 +13,20 @@ const MAX_BUCKET_SIZE = 50; * Returns a nested aggregation of error messages per event.datasets. * Each module (beats, kibana...) can contain one or multiple metricsets with error messages */ -interface MetricbeatErrorsQueryOptions extends QueryOptions { - products: MetricbeatMonitoredProduct[]; +interface ErrorsQueryOptions extends QueryOptions { + products: MetricbeatMonitoredProduct[] | PackagesMonitoredProduct[]; + errorQueryType: 'metricbeatErrorsQuery' | 'packageErrorsQuery'; + errorQueryIsDataStream?: boolean; } -export const metricbeatErrorsQuery = ({ +export const errorsQuery = ({ timeRange, timeout, products, -}: MetricbeatErrorsQueryOptions) => { - if (!timeRange) throw new Error('metricbeatErrorsQuery: missing timeRange parameter'); + errorQueryType, + errorQueryIsDataStream, +}: ErrorsQueryOptions) => { + if (!timeRange) throw new Error(`${errorQueryType}: missing timeRange parameter`); return { timeout: `${timeout}s`, query: { @@ -37,7 +41,8 @@ export const metricbeatErrorsQuery = ({ }, { terms: { - 'event.module': Object.values(products), + [errorQueryIsDataStream ? 'service.type' : 'event.module']: + Object.values(products), }, }, { @@ -54,7 +59,7 @@ export const metricbeatErrorsQuery = ({ }, }, aggs: { - errors_aggregation: errorsAggregation, + errors_aggregation: errorsAggregation(errorQueryIsDataStream), }, }; }; @@ -82,11 +87,34 @@ const errorsByMetricset = { }, }; -const errorsAggregation = { +const errorsByDataStream = { terms: { - field: 'event.module', + field: 'data_stream.dataset', }, aggs: { - errors_by_dataset: errorsByMetricset, + latest_docs: { + top_hits: { + sort: [ + { + '@timestamp': { + order: 'desc', + }, + }, + ], + size: MAX_BUCKET_SIZE, + _source: { + includes: ['@timestamp', 'error', 'data_stream'], + }, + }, + }, }, }; + +const errorsAggregation = (errorQueryIsDataStream?: boolean) => ({ + terms: { + field: errorQueryIsDataStream ? 'service.type' : 'event.module', + }, + aggs: { + errors_by_dataset: errorQueryIsDataStream ? errorsByDataStream : errorsByMetricset, + }, +}); diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/index.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/index.ts index aa05b442dca1a..1b5f7e7eac294 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/index.ts +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/index.ts @@ -8,13 +8,14 @@ import type { LegacyRequest, MonitoringCore } from '../../../../types'; import type { MonitoringConfig } from '../../../../config'; import { createValidationFunction } from '../../../../lib/create_route_validation_function'; -import { getIndexPatterns } from '../../../../lib/cluster/get_index_patterns'; +import { getIndexPatterns, getDsIndexPattern } from '../../../../lib/cluster/get_index_patterns'; import { getHealthRequestQueryRT } from '../../../../../common/http_api/_health'; import type { TimeRange } from '../../../../../common/http_api/shared'; import { fetchMonitoredClusters } from './monitored_clusters'; import { fetchMetricbeatErrors } from './metricbeat'; import type { FetchParameters } from './types'; +import { fetchPackageErrors } from './package/fetch_package_errors'; const DEFAULT_QUERY_TIMERANGE = { min: 'now-15m', max: 'now' }; const DEFAULT_QUERY_TIMEOUT_SECONDS = 15; @@ -53,6 +54,14 @@ export function registerV1HealthRoute(server: MonitoringCore) { getIndexPatterns({ config, moduleType: 'logstash' }), getIndexPatterns({ config, moduleType: 'beats' }), ].join(','); + + const metricsPackageIndex = [ + getDsIndexPattern({ config, moduleType: 'elasticsearch' }), + getDsIndexPattern({ config, moduleType: 'kibana' }), + getDsIndexPattern({ config, moduleType: 'logstash' }), + getDsIndexPattern({ config, moduleType: 'beats' }), + ].join(','); + const entSearchIndex = getIndexPatterns({ config, moduleType: 'enterprise_search' }); const monitoredClustersFn = () => @@ -74,12 +83,22 @@ export function registerV1HealthRoute(server: MonitoringCore) { return { error: err.message }; }); - const [monitoredClusters, metricbeatErrors] = await Promise.all([ + const packageErrorsFn = () => + fetchPackageErrors({ + ...fetchArgs, + packageIndex: metricsPackageIndex, + }).catch((err: Error) => { + logger.error(`_health: failed to retrieve package data:\n${err.stack}`); + return { error: err.message }; + }); + + const [monitoredClusters, metricbeatErrors, packageErrors] = await Promise.all([ monitoredClustersFn(), metricbeatErrorsFn(), + packageErrorsFn(), ]); - return { monitoredClusters, metricbeatErrors, settings }; + return { monitoredClusters, metricbeatErrors, packageErrors, settings }; }, }); } diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.test.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.test.ts deleted file mode 100644 index ea14de84735ef..0000000000000 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/build_metricbeat_errors.test.ts +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { buildMetricbeatErrors } from './build_metricbeat_errors'; -import assert from 'assert'; - -describe(__filename, () => { - describe('buildMetricbeatErrors', () => { - test('it should build an object containing dedup error messages per event.dataset', () => { - const metricbeatErrors = [ - { - key: 'beat', - errors_by_dataset: { - buckets: [ - { - key: 'state', - latest_docs: { - hits: { - hits: [ - { - _source: { - '@timestamp': '2022-07-26T08:43:32.625Z', - error: { - message: - 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', - }, - }, - }, - { - _source: { - '@timestamp': '2022-07-26T08:42:32.625Z', - error: { - message: - 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', - }, - }, - }, - { - _source: { - '@timestamp': '2022-07-26T08:41:32.625Z', - error: { - message: 'Generic random error', - }, - }, - }, - ], - }, - }, - }, - ], - }, - }, - ]; - - const monitoredClusters = buildMetricbeatErrors(metricbeatErrors); - assert.deepEqual(monitoredClusters, { - beat: { - state: [ - { - lastSeen: '2022-07-26T08:43:32.625Z', - message: - 'error making http request: Get "http://host.docker.internal:5067/state": dial tcp 192.168.65.2:5067: connect: connection refused', - }, - { - lastSeen: '2022-07-26T08:41:32.625Z', - message: 'Generic random error', - }, - ], - }, - }); - }); - }); -}); diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/fetch_metricbeat_errors.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/fetch_metricbeat_errors.ts index ed445c1658c3b..3c864004f783e 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/fetch_metricbeat_errors.ts +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/metricbeat/fetch_metricbeat_errors.ts @@ -7,13 +7,13 @@ import { FetchParameters, FetchExecution, MonitoredProduct } from '../types'; -import type { MetricbeatProducts } from './build_metricbeat_errors'; +import type { Products } from '../errors_helpers/build_errors'; -import { metricbeatErrorsQuery } from './metricbeat_errors_query'; -import { buildMetricbeatErrors } from './build_metricbeat_errors'; +import { errorsQuery } from '../errors_helpers/errors_query'; +import { buildErrors } from '../errors_helpers/build_errors'; interface MetricbeatResponse { - products?: MetricbeatProducts; + products?: Products; execution: FetchExecution; } @@ -29,7 +29,7 @@ export const fetchMetricbeatErrors = async ({ const getMetricbeatErrors = async () => { const { aggregations, timed_out: timedOut } = await search({ index: metricbeatIndex, - body: metricbeatErrorsQuery({ + body: errorsQuery({ timeRange, timeout, products: [ @@ -39,12 +39,13 @@ export const fetchMetricbeatErrors = async ({ MonitoredProduct.Kibana, MonitoredProduct.Logstash, ], + errorQueryType: 'metricbeatErrorsQuery', }), size: 0, ignore_unavailable: true, }); const buckets = aggregations?.errors_aggregation?.buckets ?? []; - return { products: buildMetricbeatErrors(buckets), timedOut: Boolean(timedOut) }; + return { products: buildErrors(buckets), timedOut: Boolean(timedOut) }; }; try { diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.test.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.test.ts new file mode 100644 index 0000000000000..fe2c7dc2f8ac7 --- /dev/null +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.test.ts @@ -0,0 +1,143 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import assert from 'assert'; +import sinon from 'sinon'; +import type { Logger } from '@kbn/core/server'; +import { fetchPackageErrors } from './fetch_package_errors'; + +const getMockLogger = () => + ({ + warn: sinon.spy(), + error: sinon.spy(), + } as unknown as Logger); + +describe(__filename, () => { + describe('fetchPackageErrors', () => { + test('it fetch and build package errors response', async () => { + const response = { + aggregations: { + errors_aggregation: { + doc_count_error_upper_bound: 0, + sum_other_doc_count: 0, + buckets: [ + { + key: 'elasticsearch', + doc_count: 22, + errors_by_dataset: { + doc_count_error_upper_bound: 0, + sum_other_doc_count: 0, + buckets: [ + { + key: 'elasticsearch.stack_monitoring.pending_tasks', + doc_count: 22, + latest_docs: { + hits: { + total: { + value: 22, + relation: 'eq', + }, + max_score: null, + hits: [ + { + _index: + '.ds-metrics-elasticsearch.stack_monitoring.node-default-2023.01.10-000001', + _id: '-oAfnIUB94omKO-pWCeN', + _score: null, + _source: { + '@timestamp': '2023-01-10T14:39:37.114Z', + metricset: { + period: 10000, + name: 'node', + }, + error: { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + }, + }, + ], + }, + }, + }, + { + key: 'elasticsearch.stack_monitoring.node', + doc_count: 22, + latest_docs: { + hits: { + total: { + value: 22, + relation: 'eq', + }, + max_score: null, + hits: [ + { + _index: + '.ds-metrics-elasticsearch.stack_monitoring.node-default-2023.01.10-000001', + _id: '-oAfnIUB94omKO-pWCeN', + _score: null, + _source: { + '@timestamp': '2023-01-10T14:39:37.156Z', + metricset: { + period: 10000, + name: 'node', + }, + error: { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + }, + }, + ], + }, + }, + }, + ], + }, + }, + ], + }, + }, + }; + + const searchFn = jest.fn().mockResolvedValueOnce(response); + + const monitoredClusters = await fetchPackageErrors({ + timeout: 10, + timeRange: { min: 1673361577110, max: 1673361567118 }, + packageIndex: 'metrics-*', + search: searchFn, + logger: getMockLogger(), + }); + + assert.deepEqual(monitoredClusters, { + execution: { + timedOut: false, + errors: [], + }, + products: { + elasticsearch: { + 'elasticsearch.stack_monitoring.node': [ + { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + lastSeen: '2023-01-10T14:39:37.156Z', + }, + ], + 'elasticsearch.stack_monitoring.pending_tasks': [ + { + message: + 'error making http request: Get "https://localhost:9200/_nodes/_local": dial tcp [::1]:9200: connect: cannot assign requested address', + lastSeen: '2023-01-10T14:39:37.114Z', + }, + ], + }, + }, + }); + }); + }); +}); diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.ts new file mode 100644 index 0000000000000..122c375dc9d25 --- /dev/null +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/fetch_package_errors.ts @@ -0,0 +1,69 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FetchParameters, FetchExecution, MonitoredProduct } from '../types'; + +import type { Products } from '../errors_helpers/build_errors'; + +import { errorsQuery } from '../errors_helpers/errors_query'; +import { buildErrors } from '../errors_helpers/build_errors'; + +interface PackageResponse { + products?: Products; + execution: FetchExecution; +} + +export const fetchPackageErrors = async ({ + timeout, + timeRange, + search, + logger, + packageIndex, +}: FetchParameters & { + packageIndex: string; +}): Promise => { + const getPackageErrors = async () => { + const { aggregations, timed_out: timedOut } = await search({ + index: packageIndex, + body: errorsQuery({ + timeRange, + timeout, + products: [ + MonitoredProduct.Beats, + MonitoredProduct.Elasticsearch, + MonitoredProduct.Kibana, + MonitoredProduct.Logstash, + ], + errorQueryType: 'packageErrorsQuery', + errorQueryIsDataStream: true, + }), + size: 0, + ignore_unavailable: true, + }); + const buckets = aggregations?.errors_aggregation?.buckets ?? []; + return { products: buildErrors(buckets), timedOut: Boolean(timedOut) }; + }; + + try { + const { products, timedOut } = await getPackageErrors(); + return { + products, + execution: { + timedOut, + errors: [], + }, + }; + } catch (err) { + logger.error(`fetchPackageErrors: failed to fetch:\n${err.stack}`); + return { + execution: { + timedOut: false, + errors: [err.message], + }, + }; + } +}; diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/index.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/index.ts new file mode 100644 index 0000000000000..84e020965e80c --- /dev/null +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/package/index.ts @@ -0,0 +1,8 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +export { fetchPackageErrors } from './fetch_package_errors'; diff --git a/x-pack/plugins/monitoring/server/routes/api/v1/_health/types.ts b/x-pack/plugins/monitoring/server/routes/api/v1/_health/types.ts index 7d3db44aeac74..df9abf1a0aa6c 100644 --- a/x-pack/plugins/monitoring/server/routes/api/v1/_health/types.ts +++ b/x-pack/plugins/monitoring/server/routes/api/v1/_health/types.ts @@ -18,6 +18,10 @@ export enum MonitoredProduct { EnterpriseSearch = 'enterpriseSearch', } export type MetricbeatMonitoredProduct = Exclude; +export type PackagesMonitoredProduct = Exclude< + MetricbeatMonitoredProduct, + MonitoredProduct.EnterpriseSearch +>; export type SearchFn = (params: any) => Promise; diff --git a/x-pack/plugins/observability/common/guided_onboarding/kubernetes_guide_config.tsx b/x-pack/plugins/observability/common/guided_onboarding/kubernetes_guide_config.tsx index 54d2bf4c0744c..239a5fcb36ed9 100644 --- a/x-pack/plugins/observability/common/guided_onboarding/kubernetes_guide_config.tsx +++ b/x-pack/plugins/observability/common/guided_onboarding/kubernetes_guide_config.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import type { GuideConfig } from '@kbn/guided-onboarding-plugin/common'; +import type { GuideConfig } from '@kbn/guided-onboarding'; import { i18n } from '@kbn/i18n'; export const kubernetesGuideId = 'kubernetes'; diff --git a/x-pack/plugins/observability/common/utils/formatters/duration.ts b/x-pack/plugins/observability/common/utils/formatters/duration.ts index 96486079f3c4f..d37b75cd1cab7 100644 --- a/x-pack/plugins/observability/common/utils/formatters/duration.ts +++ b/x-pack/plugins/observability/common/utils/formatters/duration.ts @@ -109,7 +109,7 @@ function getUnitLabelAndConvertedValue(unitKey: DurationTimeUnit, value: number) /** * Converts a microseconds value into the unit defined. */ -function convertTo({ +export function convertTo({ unit, microseconds, defaultValue = NOT_AVAILABLE_LABEL, diff --git a/x-pack/plugins/observability/kibana.json b/x-pack/plugins/observability/kibana.json index 2b2ea3eea0b79..a49e2ae723da4 100644 --- a/x-pack/plugins/observability/kibana.json +++ b/x-pack/plugins/observability/kibana.json @@ -22,6 +22,7 @@ "requiredPlugins": [ "alerting", "cases", + "charts", "data", "dataViews", "features", diff --git a/x-pack/plugins/observability/public/application/types.ts b/x-pack/plugins/observability/public/application/types.ts index 1bf29be34430d..5e0b0e3199efb 100644 --- a/x-pack/plugins/observability/public/application/types.ts +++ b/x-pack/plugins/observability/public/application/types.ts @@ -25,11 +25,12 @@ import { LensPublicStart } from '@kbn/lens-plugin/public'; import { SharePluginStart } from '@kbn/share-plugin/public'; import { TriggersAndActionsUIPublicPluginStart } from '@kbn/triggers-actions-ui-plugin/public'; import { CasesUiStart } from '@kbn/cases-plugin/public'; -import { UnifiedSearchPublicPluginStart } from '@kbn/unified-search-plugin/public'; +import type { ChartsPluginStart } from '@kbn/charts-plugin/public'; export interface ObservabilityAppServices { application: ApplicationStart; cases: CasesUiStart; + charts: ChartsPluginStart; chrome: ChromeStart; data: DataPublicPluginStart; dataViews: DataViewsPublicPluginStart; @@ -46,6 +47,5 @@ export interface ObservabilityAppServices { theme: ThemeServiceStart; triggersActionsUi: TriggersAndActionsUIPublicPluginStart; uiSettings: IUiSettingsClient; - unifiedSearch: UnifiedSearchPublicPluginStart; isDev?: boolean; } diff --git a/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/kpi_over_time_config.ts b/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/kpi_over_time_config.ts index 8aace1b7a2a1f..f6187e1117f99 100644 --- a/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/kpi_over_time_config.ts +++ b/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/kpi_over_time_config.ts @@ -119,6 +119,18 @@ export function getSyntheticsKPIConfig({ dataView }: ConfigProps): SeriesConfig }, ], }, + { + label: 'Total runs', + id: 'monitor.check_group', + field: 'monitor.check_group', + columnType: OPERATION_COLUMN, + columnFilters: [ + { + language: 'kuery', + query: `summary: *`, + }, + ], + }, { field: SUMMARY_UP, id: SUMMARY_UP, diff --git a/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/single_metric_config.ts b/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/single_metric_config.ts index 41cb58c978ae4..7e19ae43b37bd 100644 --- a/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/single_metric_config.ts +++ b/x-pack/plugins/observability/public/components/shared/exploratory_view/configurations/synthetics/single_metric_config.ts @@ -103,7 +103,7 @@ export function getSyntheticsSingleMetricConfig({ dataView }: ConfigProps): Seri titlePosition: 'bottom', }, columnType: FORMULA_COLUMN, - formula: 'unique_count(monitor.check_group)', + formula: "unique_count(monitor.check_group, kql='summary: *')", format: 'number', }, { diff --git a/x-pack/plugins/observability/public/hooks/use_chart_theme.tsx b/x-pack/plugins/observability/public/hooks/use_chart_theme.tsx index 6b11566b6e5a7..87e9e61036a71 100644 --- a/x-pack/plugins/observability/public/hooks/use_chart_theme.tsx +++ b/x-pack/plugins/observability/public/hooks/use_chart_theme.tsx @@ -22,7 +22,7 @@ export function useChartTheme(): PartialTheme[] { chartMargins: { left: 10, right: 10, - top: 10, + top: 35, bottom: 10, }, background: { diff --git a/x-pack/plugins/observability/public/hooks/use_license.ts b/x-pack/plugins/observability/public/hooks/use_license.ts new file mode 100644 index 0000000000000..f666dcd025bd3 --- /dev/null +++ b/x-pack/plugins/observability/public/hooks/use_license.ts @@ -0,0 +1,35 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useCallback } from 'react'; +import { Observable } from 'rxjs'; +import useObservable from 'react-use/lib/useObservable'; +import type { ILicense, LicenseType } from '@kbn/licensing-plugin/public'; + +import { useKibana } from '../utils/kibana_react'; + +interface UseLicenseReturnValue { + getLicense: () => ILicense | null; + hasAtLeast: (level: LicenseType) => boolean | undefined; +} + +export const useLicense = (): UseLicenseReturnValue => { + const { licensing } = useKibana().services; + const license = useObservable(licensing?.license$ ?? new Observable(), null); + + return { + getLicense: () => license, + hasAtLeast: useCallback( + (level: LicenseType) => { + if (!license) return; + + return !!license && license.isAvailable && license.isActive && license.hasAtLeast(level); + }, + [license] + ), + }; +}; diff --git a/x-pack/plugins/observability/public/index.ts b/x-pack/plugins/observability/public/index.ts index 62f980bfc9d32..b18df5c6cd548 100644 --- a/x-pack/plugins/observability/public/index.ts +++ b/x-pack/plugins/observability/public/index.ts @@ -121,3 +121,4 @@ export { ExploratoryViewContextProvider } from './components/shared/exploratory_ export { fromQuery, toQuery } from './utils/url'; export type { NavigationSection } from './services/navigation_registry'; +export { convertTo } from '../common/utils/formatters/duration'; diff --git a/x-pack/plugins/observability/public/pages/alerts/containers/alerts_page/alerts_page.tsx b/x-pack/plugins/observability/public/pages/alerts/containers/alerts_page/alerts_page.tsx index e2a6915fd79b6..3cb7fcc649960 100644 --- a/x-pack/plugins/observability/public/pages/alerts/containers/alerts_page/alerts_page.tsx +++ b/x-pack/plugins/observability/public/pages/alerts/containers/alerts_page/alerts_page.tsx @@ -5,15 +5,25 @@ * 2.0. */ -import { EuiFlexGroup, EuiFlexItem, EuiFlyoutSize } from '@elastic/eui'; - import React, { useEffect, useState } from 'react'; +import { EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; +import { TimeBuckets, UI_SETTINGS } from '@kbn/data-plugin/common'; import { BoolQuery } from '@kbn/es-query'; import { i18n } from '@kbn/i18n'; import { useKibana } from '@kbn/kibana-react-plugin/public'; -import { loadRuleAggregations } from '@kbn/triggers-actions-ui-plugin/public'; +import { + loadRuleAggregations, + AlertSummaryTimeRange, +} from '@kbn/triggers-actions-ui-plugin/public'; import { AlertConsumers } from '@kbn/rule-data-utils'; -import { ObservabilityAlertSearchbarWithUrlSync } from '../../../../components/shared/alert_search_bar'; +import { useToasts } from '../../../../hooks/use_toast'; +import { + alertSearchBarStateContainer, + Provider, + useAlertSearchBarStateContainer, +} from '../../../../components/shared/alert_search_bar/containers'; +import { getAlertSummaryTimeRange } from '../../../rule_details/helpers'; +import { ObservabilityAlertSearchBar } from '../../../../components/shared/alert_search_bar'; import { observabilityAlertFeatureIds } from '../../../../config'; import { useGetUserCasesPermissions } from '../../../../hooks/use_get_user_cases_permissions'; import { observabilityFeatureId } from '../../../../../common'; @@ -33,16 +43,33 @@ import { } from './constants'; import { RuleStatsState } from './types'; -export function AlertsPage() { +function InternalAlertsPage() { const { ObservabilityPageTemplate, observabilityRuleTypeRegistry } = usePluginContext(); const { cases, + charts, + data: { + query: { + timefilter: { timefilter: timeFilterService }, + }, + }, docLinks, http, notifications: { toasts }, - triggersActionsUi: { alertsTableConfigurationRegistry, getAlertsStateTable: AlertsStateTable }, + triggersActionsUi: { + alertsTableConfigurationRegistry, + getAlertsSearchBar: AlertsSearchBar, + getAlertsStateTable: AlertsStateTable, + getAlertSummaryWidget: AlertSummaryWidget, + }, + uiSettings, } = useKibana().services; + const alertSearchBarStateProps = useAlertSearchBarStateContainer(URL_STORAGE_KEY); + const chartThemes = { + theme: charts.theme.useChartsTheme(), + baseTheme: charts.theme.useChartsBaseTheme(), + }; const [ruleStatsLoading, setRuleStatsLoading] = useState(false); const [ruleStats, setRuleStats] = useState({ total: 0, @@ -53,6 +80,19 @@ export function AlertsPage() { }); const { hasAnyData, isAllRequestsComplete } = useHasData(); const [esQuery, setEsQuery] = useState<{ bool: BoolQuery }>(); + const timeBuckets = new TimeBuckets({ + 'histogram:maxBars': uiSettings.get(UI_SETTINGS.HISTOGRAM_MAX_BARS), + 'histogram:barTarget': uiSettings.get(UI_SETTINGS.HISTOGRAM_BAR_TARGET), + dateFormat: uiSettings.get('dateFormat'), + 'dateFormat:scaled': uiSettings.get('dateFormat:scaled'), + }); + const alertSummaryTimeRange: AlertSummaryTimeRange = getAlertSummaryTimeRange( + { + from: alertSearchBarStateProps.rangeFrom, + to: alertSearchBarStateProps.rangeTo, + }, + timeBuckets + ); useBreadcrumbs([ { @@ -132,15 +172,24 @@ export function AlertsPage() { rightSideItems: renderRuleStats(ruleStats, manageRulesHref, ruleStatsLoading), }} > - + - + + + - ); } + +export function AlertsPage() { + return ( + + + + ); +} diff --git a/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.test.tsx b/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.test.tsx index 9c437f5f5da64..d63cce34755c1 100644 --- a/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.test.tsx +++ b/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.test.tsx @@ -6,14 +6,63 @@ */ import moment from 'moment'; -import { getAlertSummaryWidgetTimeRange } from '.'; +import { TimeBuckets } from '@kbn/data-plugin/common'; +import { getAlertSummaryTimeRange, getDefaultAlertSummaryTimeRange } from '.'; -describe('getDefaultAlertSummaryTimeRange', () => { - it('should return default time in UTC format', () => { - const defaultTimeRange = getAlertSummaryWidgetTimeRange(); - const utcFormat = 'YYYY-MM-DDTHH:mm:ss.SSSZ'; +describe('AlertSummaryTimeRange', () => { + describe('getDefaultAlertSummaryTimeRange', () => { + it('should return default time in UTC format', () => { + const defaultTimeRange = getDefaultAlertSummaryTimeRange(); + const utcFormat = 'YYYY-MM-DDTHH:mm:ss.SSSZ'; - expect(moment(defaultTimeRange.utcFrom, utcFormat, true).isValid()).toBeTruthy(); - expect(moment(defaultTimeRange.utcTo, utcFormat, true).isValid()).toBeTruthy(); + expect(moment(defaultTimeRange.utcFrom, utcFormat, true).isValid()).toBeTruthy(); + expect(moment(defaultTimeRange.utcTo, utcFormat, true).isValid()).toBeTruthy(); + }); + }); + + describe('getAlertSummaryTimeRange', () => { + const timeBucketConfig = { + 'histogram:maxBars': 4, + 'histogram:barTarget': 3, + dateFormat: 'YYYY-MM-DD', + 'dateFormat:scaled': [ + ['', 'HH:mm:ss.SSS'], + ['PT1S', 'HH:mm:ss'], + ['PT1M', 'HH:mm'], + ['PT1H', 'YYYY-MM-DD HH:mm'], + ['P1DT', 'YYYY-MM-DD'], + ['P1YT', 'YYYY'], + ], + }; + const timeBuckets = new TimeBuckets(timeBucketConfig); + + it.each([ + // 15 minutes + ['2023-01-09T12:07:54.441Z', '2023-01-09T12:22:54.441Z', '30s', 'HH:mm:ss'], + // 30 minutes + ['2023-01-09T11:53:43.605Z', '2023-01-09T12:23:43.605Z', '30s', 'HH:mm:ss'], + // 1 hour + ['2023-01-09T11:22:05.728Z', '2023-01-09T12:22:05.728Z', '60s', 'HH:mm'], + // 24 hours + ['2023-01-08T12:00:00.000Z', '2023-01-09T12:24:30.853Z', '1800s', 'HH:mm'], + // 7 days + ['2023-01-01T23:00:00.000Z', '2023-01-09T12:29:38.101Z', '10800s', 'YYYY-MM-DD HH:mm'], + // 30 days + ['2022-12-09T23:00:00.000Z', '2023-01-09T12:30:13.717Z', '43200s', 'YYYY-MM-DD HH:mm'], + // 90 days + ['2022-10-10T22:00:00.000Z', '2023-01-09T12:32:11.537Z', '86400s', 'YYYY-MM-DD'], + // 1 year + ['2022-01-08T23:00:00.000Z', '2023-01-09T12:33:09.906Z', '86400s', 'YYYY-MM-DD'], + ])( + `Input: [%s, %s], Output: interval: %s, time format: %s `, + (from, to, fixedInterval, dateFormat) => { + expect(getAlertSummaryTimeRange({ from, to }, timeBuckets)).toEqual({ + utcFrom: from, + utcTo: to, + fixedInterval, + dateFormat, + }); + } + ); }); }); diff --git a/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.tsx b/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.tsx index 973bfc628ea60..decfa03fb6f8c 100644 --- a/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.tsx +++ b/x-pack/plugins/observability/public/pages/rule_details/helpers/get_alert_summary_time_range.tsx @@ -5,12 +5,15 @@ * 2.0. */ -import type { AlertSummaryTimeRange } from '@kbn/triggers-actions-ui-plugin/public/application/hooks/use_load_alert_summary'; import React from 'react'; -import { getAbsoluteTimeRange } from '@kbn/data-plugin/common'; +import { getAbsoluteTimeRange, TimeBuckets } from '@kbn/data-plugin/common'; +import { TimeRange } from '@kbn/es-query'; import { FormattedMessage } from '@kbn/i18n-react'; +import type { AlertSummaryTimeRange } from '@kbn/triggers-actions-ui-plugin/public'; +import { getAbsoluteTime } from '../../../utils/date'; +import { getBucketSize } from '../../../utils/get_bucket_size'; -export const getAlertSummaryWidgetTimeRange = (): AlertSummaryTimeRange => { +export const getDefaultAlertSummaryTimeRange = (): AlertSummaryTimeRange => { const { to, from } = getAbsoluteTimeRange({ from: 'now-30d', to: 'now', @@ -28,3 +31,30 @@ export const getAlertSummaryWidgetTimeRange = (): AlertSummaryTimeRange => { ), }; }; + +export const getAlertSummaryTimeRange = ( + timeRange: TimeRange, + timeBuckets: TimeBuckets +): AlertSummaryTimeRange => { + const { to, from } = getAbsoluteTimeRange(timeRange); + const fixedInterval = getFixedInterval(timeRange); + timeBuckets.setInterval(fixedInterval); + + return { + utcFrom: from, + utcTo: to, + fixedInterval, + dateFormat: timeBuckets.getScaledDateFormat(), + }; +}; + +const getFixedInterval = ({ to, from }: TimeRange) => { + const start = getAbsoluteTime(from); + const end = getAbsoluteTime(to, { roundUp: true }); + + if (start && end) { + return getBucketSize({ start, end, minInterval: '30s', buckets: 60 }).intervalString; + } + + return '1m'; +}; diff --git a/x-pack/plugins/observability/public/pages/rule_details/helpers/index.ts b/x-pack/plugins/observability/public/pages/rule_details/helpers/index.ts index e93f2f4cc5ee0..5ba979bf5a0fe 100644 --- a/x-pack/plugins/observability/public/pages/rule_details/helpers/index.ts +++ b/x-pack/plugins/observability/public/pages/rule_details/helpers/index.ts @@ -5,4 +5,7 @@ * 2.0. */ -export { getAlertSummaryWidgetTimeRange } from './get_alert_summary_time_range'; +export { + getDefaultAlertSummaryTimeRange, + getAlertSummaryTimeRange, +} from './get_alert_summary_time_range'; diff --git a/x-pack/plugins/observability/public/pages/rule_details/index.tsx b/x-pack/plugins/observability/public/pages/rule_details/index.tsx index 420757b7b50bd..6f4f1eefc63ba 100644 --- a/x-pack/plugins/observability/public/pages/rule_details/index.tsx +++ b/x-pack/plugins/observability/public/pages/rule_details/index.tsx @@ -42,7 +42,7 @@ import { fromQuery, toQuery } from '../../utils/url'; import { ObservabilityAlertSearchbarWithUrlSync } from '../../components/shared/alert_search_bar'; import { DeleteModalConfirmation } from './components/delete_modal_confirmation'; import { CenterJustifiedSpinner } from './components/center_justified_spinner'; -import { getAlertSummaryWidgetTimeRange } from './helpers'; +import { getDefaultAlertSummaryTimeRange } from './helpers'; import { EXECUTION_TAB, @@ -68,6 +68,7 @@ import { ObservabilityAppServices } from '../../application/types'; export function RuleDetailsPage() { const { + charts, http, triggersActionsUi: { alertsTableConfigurationRegistry, @@ -91,6 +92,11 @@ export function RuleDetailsPage() { const history = useHistory(); const location = useLocation(); + const chartThemes = { + theme: charts.theme.useChartsTheme(), + baseTheme: charts.theme.useChartsBaseTheme(), + }; + const filteredRuleTypes = useMemo( () => observabilityRuleTypeRegistry.list(), [observabilityRuleTypeRegistry] @@ -112,7 +118,7 @@ export function RuleDetailsPage() { const [isRuleEditPopoverOpen, setIsRuleEditPopoverOpen] = useState(false); const [esQuery, setEsQuery] = useState<{ bool: BoolQuery }>(); const [alertSummaryWidgetTimeRange, setAlertSummaryWidgetTimeRange] = useState( - getAlertSummaryWidgetTimeRange + getDefaultAlertSummaryTimeRange ); const ruleQuery = useRef([ { query: `kibana.alert.rule.uuid: ${ruleId}`, language: 'kuery' }, @@ -125,7 +131,7 @@ export function RuleDetailsPage() { const tabsRef = useRef(null); const onAlertSummaryWidgetClick = async (status: AlertStatus = ALERT_STATUS_ALL) => { - const timeRange = getAlertSummaryWidgetTimeRange(); + const timeRange = getDefaultAlertSummaryTimeRange(); setAlertSummaryWidgetTimeRange(timeRange); await locators.get(ruleDetailsLocatorID)?.navigate( { @@ -390,6 +396,7 @@ export function RuleDetailsPage() { ({ ...jest.requireActual('react-router-dom'), @@ -24,19 +25,25 @@ jest.mock('react-router-dom', () => ({ })); jest.mock('../../utils/kibana_react'); -jest.mock('../../hooks/slo/use_fetch_slo_details'); jest.mock('../../hooks/use_breadcrumbs'); +jest.mock('../../hooks/use_license'); +jest.mock('../../hooks/slo/use_fetch_slo_details'); -const useFetchSloDetailsMock = useFetchSloDetails as jest.Mock; -const useParamsMock = useParams as jest.Mock; const useKibanaMock = useKibana as jest.Mock; +const useParamsMock = useParams as jest.Mock; +const useLicenseMock = useLicense as jest.Mock; +const useFetchSloDetailsMock = useFetchSloDetails as jest.Mock; + +const mockNavigate = jest.fn(); +const mockBasePathPrepend = jest.fn(); + const mockKibana = () => { useKibanaMock.mockReturnValue({ services: { - ...kibanaStartMock.startContract(), + application: { navigateToUrl: mockNavigate }, http: { basePath: { - prepend: jest.fn(), + prepend: mockBasePathPrepend, }, }, }, @@ -55,38 +62,64 @@ describe('SLO Details Page', () => { mockKibana(); }); - it('renders the not found page when the feature flag is not enabled', async () => { - useParamsMock.mockReturnValue(anSLO.id); - useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: anSLO }); - render(, { unsafe: { slo: { enabled: false } } }); + describe('when the feature flag is not enabled', () => { + it('renders the not found page', async () => { + useParamsMock.mockReturnValue(anSLO.id); + useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: anSLO }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + + render(, { unsafe: { slo: { enabled: false } } }); - expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); + expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); + }); }); - it('renders the not found page when the SLO cannot be found', async () => { - useParamsMock.mockReturnValue('inexistant'); - useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: undefined }); - render(, config); + describe('when the feature flag is enabled', () => { + describe('when the incorrect license is found', () => { + it('navigates to the SLO List page', async () => { + useParamsMock.mockReturnValue(anSLO.id); + useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: anSLO }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => false }); - expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); - }); + render(, { unsafe: { slo: { enabled: true } } }); - it('renders the loading spiner when fetching the SLO', async () => { - useParamsMock.mockReturnValue(anSLO.id); - useFetchSloDetailsMock.mockReturnValue({ loading: true, slo: undefined }); - render(, config); + expect(mockNavigate).toBeCalledWith(mockBasePathPrepend(paths.observability.slos)); + }); + }); - expect(screen.queryByTestId('pageNotFound')).toBeFalsy(); - expect(screen.queryByTestId('loadingTitle')).toBeTruthy(); - expect(screen.queryByTestId('loadingDetails')).toBeTruthy(); - }); + describe('when the correct license is found', () => { + it('renders the not found page when the SLO cannot be found', async () => { + useParamsMock.mockReturnValue('inexistant'); + useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: undefined }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + + render(, config); + + expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); + }); + + it('renders the loading spinner when fetching the SLO', async () => { + useParamsMock.mockReturnValue(anSLO.id); + useFetchSloDetailsMock.mockReturnValue({ loading: true, slo: undefined }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + + render(, config); + + expect(screen.queryByTestId('pageNotFound')).toBeFalsy(); + expect(screen.queryByTestId('loadingTitle')).toBeTruthy(); + expect(screen.queryByTestId('loadingDetails')).toBeTruthy(); + }); + + it('renders the SLO details page', async () => { + useParamsMock.mockReturnValue(anSLO.id); + useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: anSLO }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); - it('renders the SLO details page when the feature flag is enabled', async () => { - useParamsMock.mockReturnValue(anSLO.id); - useFetchSloDetailsMock.mockReturnValue({ loading: false, slo: anSLO }); - render(, config); + render(, config); - expect(screen.queryByTestId('sloDetailsPage')).toBeTruthy(); - expect(screen.queryByTestId('sloDetails')).toBeTruthy(); + expect(screen.queryByTestId('sloDetailsPage')).toBeTruthy(); + expect(screen.queryByTestId('sloDetails')).toBeTruthy(); + }); + }); }); }); diff --git a/x-pack/plugins/observability/public/pages/slo_details/index.tsx b/x-pack/plugins/observability/public/pages/slo_details/index.tsx index 9da17bb0ec5f5..8eb5d45f75191 100644 --- a/x-pack/plugins/observability/public/pages/slo_details/index.tsx +++ b/x-pack/plugins/observability/public/pages/slo_details/index.tsx @@ -6,39 +6,51 @@ */ import React from 'react'; - import { useParams } from 'react-router-dom'; -import { IBasePath } from '@kbn/core-http-browser'; import { EuiBreadcrumbProps } from '@elastic/eui/src/components/breadcrumbs/breadcrumb'; import { EuiLoadingSpinner } from '@elastic/eui'; -import { SLOResponse } from '@kbn/slo-schema'; -import { ObservabilityAppServices } from '../../application/types'; -import { paths } from '../../config'; +import { i18n } from '@kbn/i18n'; +import type { IBasePath } from '@kbn/core-http-browser'; +import type { SLOResponse } from '@kbn/slo-schema'; +import { useKibana } from '../../utils/kibana_react'; import { usePluginContext } from '../../hooks/use_plugin_context'; import { useBreadcrumbs } from '../../hooks/use_breadcrumbs'; -import { useKibana } from '../../utils/kibana_react'; +import { useFetchSloDetails } from '../../hooks/slo/use_fetch_slo_details'; +import { useLicense } from '../../hooks/use_license'; import PageNotFound from '../404'; import { isSloFeatureEnabled } from '../slos/helpers/is_slo_feature_enabled'; -import { SLOS_BREADCRUMB_TEXT } from '../slos/translations'; -import { SloDetailsPathParams } from './types'; -import { useFetchSloDetails } from '../../hooks/slo/use_fetch_slo_details'; import { SloDetails } from './components/slo_details'; -import { SLO_DETAILS_BREADCRUMB_TEXT } from './translations'; import { PageTitle } from './components/page_title'; +import { paths } from '../../config'; +import type { SloDetailsPathParams } from './types'; +import type { ObservabilityAppServices } from '../../application/types'; export function SloDetailsPage() { - const { http } = useKibana().services; + const { + application: { navigateToUrl }, + http: { basePath }, + } = useKibana().services; + const { ObservabilityPageTemplate, config } = usePluginContext(); const { sloId } = useParams(); + const { hasAtLeast } = useLicense(); + const hasRightLicense = hasAtLeast('platinum'); + const { loading, slo } = useFetchSloDetails(sloId); - useBreadcrumbs(getBreadcrumbs(http.basePath, slo)); + + useBreadcrumbs(getBreadcrumbs(basePath, slo)); const isSloNotFound = !loading && slo === undefined; + if (!isSloFeatureEnabled(config) || isSloNotFound) { return ; } + if (hasRightLicense === false) { + navigateToUrl(basePath.prepend(paths.observability.slos)); + } + return ( 2", - "good": "http_status: 2xx", - "index": "some-index", - "total": "a query", - }, - "type": "sli.kql.custom", - }, - "name": "irrelevant", - "objective": Object { - "target": 0.98, - }, - "settings": Object { - "frequency": "1m", - "syncDelay": "1m", - "timestampField": "@timestamp", - }, - "timeWindow": Object { - "duration": "30d", - "isRolling": true, - }, - }, - ], - ], - "results": Array [ - Object { - "type": "return", - "value": undefined, - }, - ], -} -`; - -exports[`SLO Edit Page when no sloId route param is provided calls the createSlo hook if all required values are filled in 1`] = ` -[MockFunction] { - "calls": Array [ - Array [ - Object { - "budgetingMethod": "occurrences", - "description": "irrelevant", - "indicator": Object { - "params": Object { - "filter": "irrelevant", - "good": "irrelevant", - "index": "some-index", - "total": "irrelevant", - }, - "type": "sli.kql.custom", - }, - "name": "irrelevant", - "objective": Object { - "target": 0.985, - }, - "timeWindow": Object { - "duration": "7d", - "isRolling": true, - }, - }, - ], - ], - "results": Array [ - Object { - "type": "return", - "value": undefined, - }, - ], -} -`; diff --git a/x-pack/plugins/observability/public/pages/slo_edit/components/slo_edit_form.tsx b/x-pack/plugins/observability/public/pages/slo_edit/components/slo_edit_form.tsx index 97bca4635635a..2d1eb8d64cacc 100644 --- a/x-pack/plugins/observability/public/pages/slo_edit/components/slo_edit_form.tsx +++ b/x-pack/plugins/observability/public/pages/slo_edit/components/slo_edit_form.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import React from 'react'; +import React, { useEffect } from 'react'; import { EuiAvatar, EuiButton, @@ -73,28 +73,31 @@ export function SloEditForm({ slo }: Props) { } }; - if (success) { - toasts.addSuccess( - isEditMode - ? i18n.translate('xpack.observability.slos.sloEdit.update.success', { - defaultMessage: 'Successfully updated {name}', - values: { name: getValues().name }, - }) - : i18n.translate('xpack.observability.slos.sloEdit.creation.success', { - defaultMessage: 'Successfully created {name}', - values: { name: getValues().name }, - }) - ); - navigateToUrl(basePath.prepend(paths.observability.slos)); - } - - if (error) { - toasts.addError(new Error(error), { - title: i18n.translate('xpack.observability.slos.sloEdit.creation.error', { - defaultMessage: 'Something went wrong', - }), - }); - } + useEffect(() => { + if (success) { + toasts.addSuccess( + isEditMode + ? i18n.translate('xpack.observability.slos.sloEdit.update.success', { + defaultMessage: 'Successfully updated {name}', + values: { name: getValues().name }, + }) + : i18n.translate('xpack.observability.slos.sloEdit.creation.success', { + defaultMessage: 'Successfully created {name}', + values: { name: getValues().name }, + }) + ); + + navigateToUrl(basePath.prepend(paths.observability.slos)); + } + + if (error) { + toasts.addError(new Error(error), { + title: i18n.translate('xpack.observability.slos.sloEdit.creation.error', { + defaultMessage: 'Something went wrong', + }), + }); + } + }, [success, error, toasts, isEditMode, getValues, navigateToUrl, basePath]); return ( diff --git a/x-pack/plugins/observability/public/pages/slo_edit/index.test.tsx b/x-pack/plugins/observability/public/pages/slo_edit/index.test.tsx index 2fb53fb8a5096..0175f4e5677a9 100644 --- a/x-pack/plugins/observability/public/pages/slo_edit/index.test.tsx +++ b/x-pack/plugins/observability/public/pages/slo_edit/index.test.tsx @@ -8,12 +8,12 @@ import React from 'react'; import Router from 'react-router-dom'; import { waitFor, fireEvent, screen } from '@testing-library/dom'; -import { BasePath } from '@kbn/core-http-server-internal'; import { cleanup } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import { render } from '../../utils/test_helper'; import { useKibana } from '../../utils/kibana_react'; +import { useLicense } from '../../hooks/use_license'; import { useFetchIndices } from '../../hooks/use_fetch_indices'; import { useFetchSloDetails } from '../../hooks/slo/use_fetch_slo_details'; import { useCreateOrUpdateSlo } from '../../hooks/slo/use_create_slo'; @@ -31,6 +31,7 @@ jest.mock('react-router-dom', () => ({ })); jest.mock('../../hooks/use_breadcrumbs'); +jest.mock('../../hooks/use_license'); jest.mock('../../hooks/use_fetch_indices'); jest.mock('../../hooks/slo/use_fetch_slo_details'); jest.mock('../../hooks/slo/use_create_slo'); @@ -41,6 +42,8 @@ jest.mock('../../utils/kibana_react', () => ({ useKibana: jest.fn(() => mockUseKibanaReturnValue), })); +const useKibanaMock = useKibana as jest.Mock; +const useLicenseMock = useLicense as jest.Mock; const useFetchIndicesMock = useFetchIndices as jest.Mock; const useFetchSloMock = useFetchSloDetails as jest.Mock; const useCreateOrUpdateSloMock = useCreateOrUpdateSlo as jest.Mock; @@ -48,21 +51,26 @@ const useCreateOrUpdateSloMock = useCreateOrUpdateSlo as jest.Mock; const mockAddSuccess = jest.fn(); const mockAddError = jest.fn(); const mockNavigate = jest.fn(); - -(useKibana as jest.Mock).mockReturnValue({ - services: { - application: { navigateToUrl: mockNavigate }, - http: { - basePath: new BasePath('', undefined), - }, - notifications: { - toasts: { - addSuccess: mockAddSuccess, - addError: mockAddError, +const mockBasePathPrepend = jest.fn(); + +const mockKibana = () => { + useKibanaMock.mockReturnValue({ + services: { + application: { navigateToUrl: mockNavigate }, + http: { + basePath: { + prepend: mockBasePathPrepend, + }, + }, + notifications: { + toasts: { + addSuccess: mockAddSuccess, + addError: mockAddError, + }, }, }, - }, -}); + }); +}; const config: Subset = { unsafe: { @@ -73,6 +81,7 @@ const config: Subset = { describe('SLO Edit Page', () => { beforeEach(() => { jest.clearAllMocks(); + mockKibana(); // Silence all the ref errors in Eui components. jest.spyOn(console, 'error').mockImplementation(() => {}); @@ -84,6 +93,7 @@ describe('SLO Edit Page', () => { it('renders the not found page when no sloId param is passed', async () => { jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: undefined }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => false }); useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); render(, { unsafe: { slo: { enabled: false } } }); @@ -94,6 +104,7 @@ describe('SLO Edit Page', () => { it('renders the not found page when sloId param is passed', async () => { jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '1234' }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => false }); useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); render(, { unsafe: { slo: { enabled: false } } }); @@ -102,270 +113,387 @@ describe('SLO Edit Page', () => { }); }); - describe('when no sloId route param is provided', () => { - it('renders the SLO Edit page in pristine state', async () => { - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: undefined }); - - useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: false, - error: '', - createSlo: jest.fn(), - updateSlo: jest.fn(), - }); - - render(, config); - - expect(screen.queryByTestId('slosEditPage')).toBeTruthy(); - expect(screen.queryByTestId('sloForm')).toBeTruthy(); - - expect(screen.queryByTestId('sloFormIndicatorTypeSelect')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type - ); - - expect(screen.queryByTestId('sloFormCustomKqlIndexInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.index - ); - expect(screen.queryByTestId('sloFormCustomKqlFilterQueryInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' - ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.filter - : '' - ); - expect(screen.queryByTestId('sloFormCustomKqlGoodQueryInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' - ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.good - : '' - ); - expect(screen.queryByTestId('sloFormCustomKqlTotalQueryInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' - ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.total - : '' - ); - - expect(screen.queryByTestId('sloFormBudgetingMethodSelect')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.budgetingMethod - ); - expect(screen.queryByTestId('sloFormTimeWindowDurationSelect')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.timeWindow.duration as any - ); - expect(screen.queryByTestId('sloFormObjectiveTargetInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.objective.target - ); - - expect(screen.queryByTestId('sloFormNameInput')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.name - ); - expect(screen.queryByTestId('sloFormDescriptionTextArea')).toHaveValue( - SLO_EDIT_FORM_DEFAULT_VALUES.description - ); - }); - - it.skip('calls the createSlo hook if all required values are filled in', async () => { - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: undefined }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); - const mockCreate = jest.fn(); - const mockUpdate = jest.fn(); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: false, - error: '', - createSlo: mockCreate, - updateSlo: mockUpdate, - }); - - render(, config); - - userEvent.type(screen.getByTestId('sloFormCustomKqlIndexInput'), 'some-index'); - userEvent.type(screen.getByTestId('sloFormCustomKqlFilterQueryInput'), 'irrelevant'); - userEvent.type(screen.getByTestId('sloFormCustomKqlGoodQueryInput'), 'irrelevant'); - userEvent.type(screen.getByTestId('sloFormCustomKqlTotalQueryInput'), 'irrelevant'); - userEvent.selectOptions(screen.getByTestId('sloFormBudgetingMethodSelect'), 'occurrences'); - userEvent.selectOptions(screen.getByTestId('sloFormTimeWindowDurationSelect'), '7d'); - userEvent.clear(screen.getByTestId('sloFormObjectiveTargetInput')); - userEvent.type(screen.getByTestId('sloFormObjectiveTargetInput'), '98.5'); - userEvent.type(screen.getByTestId('sloFormNameInput'), 'irrelevant'); - userEvent.type(screen.getByTestId('sloFormDescriptionTextArea'), 'irrelevant'); - - const t = Date.now(); - await waitFor(() => expect(screen.getByTestId('sloFormSubmitButton')).toBeEnabled()); - console.log('end waiting for submit button: ', Math.ceil(Date.now() - t)); - - fireEvent.click(screen.getByTestId('sloFormSubmitButton')!); - - expect(mockCreate).toMatchSnapshot(); - }); - }); - - describe('when a sloId route param is provided', () => { - it('renders the SLO Edit page with prefilled form values', async () => { - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - - useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], + describe('when the feature flag is enabled', () => { + describe('when the incorrect license is found', () => { + it('navigates to the SLO List page', async () => { + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '1234' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => false }); + useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: '', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + + render(, config); + + expect(mockNavigate).toBeCalledWith(mockBasePathPrepend(paths.observability.slos)); }); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: false, - error: '', - createSlo: jest.fn(), - updateSlo: jest.fn(), - }); - render(, config); - - expect(screen.queryByTestId('slosEditPage')).toBeTruthy(); - expect(screen.queryByTestId('sloForm')).toBeTruthy(); - - expect(screen.queryByTestId('sloFormIndicatorTypeSelect')).toHaveValue(anSLO.indicator.type); - - expect(screen.queryByTestId('sloFormCustomKqlIndexInput')).toHaveValue( - anSLO.indicator.params.index - ); - expect(screen.queryByTestId('sloFormCustomKqlFilterQueryInput')).toHaveValue( - anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.filter : '' - ); - expect(screen.queryByTestId('sloFormCustomKqlGoodQueryInput')).toHaveValue( - anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.good : '' - ); - expect(screen.queryByTestId('sloFormCustomKqlTotalQueryInput')).toHaveValue( - anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.total : '' - ); - - expect(screen.queryByTestId('sloFormBudgetingMethodSelect')).toHaveValue( - anSLO.budgetingMethod - ); - expect(screen.queryByTestId('sloFormTimeWindowDurationSelect')).toHaveValue( - anSLO.timeWindow.duration - ); - expect(screen.queryByTestId('sloFormObjectiveTargetInput')).toHaveValue( - anSLO.objective.target * 100 - ); - - expect(screen.queryByTestId('sloFormNameInput')).toHaveValue(anSLO.name); - expect(screen.queryByTestId('sloFormDescriptionTextArea')).toHaveValue(anSLO.description); - }); - - it('calls the updateSlo hook if all required values are filled in', async () => { - // Note: the `anSLO` object is considered to have (at least) - // values for all required fields. - - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); - const mockCreate = jest.fn(); - const mockUpdate = jest.fn(); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: false, - error: '', - createSlo: mockCreate, - updateSlo: mockUpdate, - }); - - render(, config); - - await waitFor(() => expect(screen.queryByTestId('sloFormSubmitButton')).toBeEnabled()); - - fireEvent.click(screen.queryByTestId('sloFormSubmitButton')!); - - expect(mockUpdate).toMatchSnapshot(); }); - it('blocks submitting if not all required values are filled in', async () => { - // Note: the `anSLO` object is considered to have (at least) - // values for all required fields. - - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [], + describe('when the correct license is found', () => { + describe('when no sloId route param is provided', () => { + it('renders the SLO Edit page in pristine state', async () => { + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: undefined }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: '', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + + render(, config); + + expect(screen.queryByTestId('slosEditPage')).toBeTruthy(); + expect(screen.queryByTestId('sloForm')).toBeTruthy(); + + expect(screen.queryByTestId('sloFormIndicatorTypeSelect')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type + ); + + expect(screen.queryByTestId('sloFormCustomKqlIndexInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.index + ); + expect(screen.queryByTestId('sloFormCustomKqlFilterQueryInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' + ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.filter + : '' + ); + expect(screen.queryByTestId('sloFormCustomKqlGoodQueryInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' + ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.good + : '' + ); + expect(screen.queryByTestId('sloFormCustomKqlTotalQueryInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.indicator.type === 'sli.kql.custom' + ? SLO_EDIT_FORM_DEFAULT_VALUES.indicator.params.total + : '' + ); + + expect(screen.queryByTestId('sloFormBudgetingMethodSelect')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.budgetingMethod + ); + expect(screen.queryByTestId('sloFormTimeWindowDurationSelect')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.timeWindow.duration as any + ); + expect(screen.queryByTestId('sloFormObjectiveTargetInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.objective.target + ); + + expect(screen.queryByTestId('sloFormNameInput')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.name + ); + expect(screen.queryByTestId('sloFormDescriptionTextArea')).toHaveValue( + SLO_EDIT_FORM_DEFAULT_VALUES.description + ); + }); + + it.skip('calls the createSlo hook if all required values are filled in', async () => { + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: undefined }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useFetchSloMock.mockReturnValue({ loading: false, slo: undefined }); + const mockCreate = jest.fn(); + const mockUpdate = jest.fn(); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: '', + createSlo: mockCreate, + updateSlo: mockUpdate, + }); + + render(, config); + + userEvent.type(screen.getByTestId('sloFormCustomKqlIndexInput'), 'some-index'); + userEvent.type(screen.getByTestId('sloFormCustomKqlFilterQueryInput'), 'irrelevant'); + userEvent.type(screen.getByTestId('sloFormCustomKqlGoodQueryInput'), 'irrelevant'); + userEvent.type(screen.getByTestId('sloFormCustomKqlTotalQueryInput'), 'irrelevant'); + userEvent.selectOptions( + screen.getByTestId('sloFormBudgetingMethodSelect'), + 'occurrences' + ); + userEvent.selectOptions(screen.getByTestId('sloFormTimeWindowDurationSelect'), '7d'); + userEvent.clear(screen.getByTestId('sloFormObjectiveTargetInput')); + userEvent.type(screen.getByTestId('sloFormObjectiveTargetInput'), '98.5'); + userEvent.type(screen.getByTestId('sloFormNameInput'), 'irrelevant'); + userEvent.type(screen.getByTestId('sloFormDescriptionTextArea'), 'irrelevant'); + + const t = Date.now(); + await waitFor(() => expect(screen.getByTestId('sloFormSubmitButton')).toBeEnabled()); + console.log('end waiting for submit button: ', Math.ceil(Date.now() - t)); + + fireEvent.click(screen.getByTestId('sloFormSubmitButton')!); + + expect(mockCreate).toMatchInlineSnapshot(` + [MockFunction] { + "calls": Array [ + Array [ + Object { + "budgetingMethod": "occurrences", + "description": "irrelevant", + "indicator": Object { + "params": Object { + "filter": "irrelevant", + "good": "irrelevant", + "index": "some-index", + "total": "irrelevant", + }, + "type": "sli.kql.custom", + }, + "name": "irrelevant", + "objective": Object { + "target": 0.985, + }, + "timeWindow": Object { + "duration": "7d", + "isRolling": true, + }, + }, + ], + ], + "results": Array [ + Object { + "type": "return", + "value": undefined, + }, + ], + } + `); + }); }); - useFetchSloMock.mockReturnValue({ loading: false, slo: { ...anSLO, name: '' } }); - - render(, config); - - await waitFor(() => { - expect(screen.queryByTestId('sloFormSubmitButton')).toBeDisabled(); + describe('when a sloId route param is provided', () => { + it('renders the SLO Edit page with prefilled form values', async () => { + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: '', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + render(, config); + + expect(screen.queryByTestId('slosEditPage')).toBeTruthy(); + expect(screen.queryByTestId('sloForm')).toBeTruthy(); + + expect(screen.queryByTestId('sloFormIndicatorTypeSelect')).toHaveValue( + anSLO.indicator.type + ); + + expect(screen.queryByTestId('sloFormCustomKqlIndexInput')).toHaveValue( + anSLO.indicator.params.index + ); + expect(screen.queryByTestId('sloFormCustomKqlFilterQueryInput')).toHaveValue( + anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.filter : '' + ); + expect(screen.queryByTestId('sloFormCustomKqlGoodQueryInput')).toHaveValue( + anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.good : '' + ); + expect(screen.queryByTestId('sloFormCustomKqlTotalQueryInput')).toHaveValue( + anSLO.indicator.type === 'sli.kql.custom' ? anSLO.indicator.params.total : '' + ); + + expect(screen.queryByTestId('sloFormBudgetingMethodSelect')).toHaveValue( + anSLO.budgetingMethod + ); + expect(screen.queryByTestId('sloFormTimeWindowDurationSelect')).toHaveValue( + anSLO.timeWindow.duration + ); + expect(screen.queryByTestId('sloFormObjectiveTargetInput')).toHaveValue( + anSLO.objective.target * 100 + ); + + expect(screen.queryByTestId('sloFormNameInput')).toHaveValue(anSLO.name); + expect(screen.queryByTestId('sloFormDescriptionTextArea')).toHaveValue(anSLO.description); + }); + + it('calls the updateSlo hook if all required values are filled in', async () => { + // Note: the `anSLO` object is considered to have (at least) + // values for all required fields. + + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); + const mockCreate = jest.fn(); + const mockUpdate = jest.fn(); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: '', + createSlo: mockCreate, + updateSlo: mockUpdate, + }); + + render(, config); + + await waitFor(() => expect(screen.queryByTestId('sloFormSubmitButton')).toBeEnabled()); + + fireEvent.click(screen.queryByTestId('sloFormSubmitButton')!); + + expect(mockUpdate).toMatchInlineSnapshot(` + [MockFunction] { + "calls": Array [ + Array [ + "2f17deb0-725a-11ed-ab7c-4bb641cfc57e", + Object { + "budgetingMethod": "occurrences", + "description": "irrelevant", + "indicator": Object { + "params": Object { + "filter": "baz: foo and bar > 2", + "good": "http_status: 2xx", + "index": "some-index", + "total": "a query", + }, + "type": "sli.kql.custom", + }, + "name": "irrelevant", + "objective": Object { + "target": 0.98, + }, + "settings": Object { + "frequency": "1m", + "syncDelay": "1m", + "timestampField": "@timestamp", + }, + "timeWindow": Object { + "duration": "30d", + "isRolling": true, + }, + }, + ], + ], + "results": Array [ + Object { + "type": "return", + "value": undefined, + }, + ], + } + `); + }); + + it('blocks submitting if not all required values are filled in', async () => { + // Note: the `anSLO` object is considered to have (at least) + // values for all required fields. + + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [], + }); + useFetchSloMock.mockReturnValue({ loading: false, slo: { ...anSLO, name: '' } }); + + render(, config); + + await waitFor(() => { + expect(screen.queryByTestId('sloFormSubmitButton')).toBeDisabled(); + }); + }); }); - }); - }); - describe('if submitting has completed successfully', () => { - it('renders a success toast', async () => { - // Note: the `anSLO` object is considered to have (at least) - // values for all required fields. - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: true, - error: '', - createSlo: jest.fn(), - updateSlo: jest.fn(), + describe('when submitting has completed successfully', () => { + it('renders a success toast', async () => { + // Note: the `anSLO` object is considered to have (at least) + // values for all required fields. + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: true, + error: '', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + render(, config); + expect(mockAddSuccess).toBeCalled(); + }); + + it('navigates to the SLO List page', async () => { + // Note: the `anSLO` object is considered to have (at least) + // values for all required fields. + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: true, + error: '', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + render(, config); + expect(mockNavigate).toBeCalledWith(mockBasePathPrepend(paths.observability.slos)); + }); }); - render(, config); - expect(mockAddSuccess).toBeCalled(); - }); - it('navigates to the SLO List page', async () => { - // Note: the `anSLO` object is considered to have (at least) - // values for all required fields. - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: true, - error: '', - createSlo: jest.fn(), - updateSlo: jest.fn(), - }); - render(, config); - expect(mockNavigate).toBeCalledWith(paths.observability.slos); - }); - }); - - describe('if submitting has not completed successfully', () => { - it('renders an error toast', async () => { - // Note: the `anSLO` object is considered to have (at least) - // values for all required fields. - jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); - useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); - useFetchIndicesMock.mockReturnValue({ - loading: false, - indices: [{ name: 'some-index' }], - }); - useCreateOrUpdateSloMock.mockReturnValue({ - loading: false, - success: false, - error: 'Argh, API died', - createSlo: jest.fn(), - updateSlo: jest.fn(), + describe('when submitting has not completed successfully', () => { + it('renders an error toast', async () => { + // Note: the `anSLO` object is considered to have (at least) + // values for all required fields. + jest.spyOn(Router, 'useParams').mockReturnValue({ sloId: '123' }); + + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + useFetchSloMock.mockReturnValue({ loading: false, slo: anSLO }); + useFetchIndicesMock.mockReturnValue({ + loading: false, + indices: [{ name: 'some-index' }], + }); + useCreateOrUpdateSloMock.mockReturnValue({ + loading: false, + success: false, + error: 'Argh, API died', + createSlo: jest.fn(), + updateSlo: jest.fn(), + }); + render(, config); + expect(mockAddError).toBeCalled(); + }); }); - render(, config); - expect(mockAddError).toBeCalled(); }); }); }); diff --git a/x-pack/plugins/observability/public/pages/slo_edit/index.tsx b/x-pack/plugins/observability/public/pages/slo_edit/index.tsx index d27390d2447fe..312c64f911916 100644 --- a/x-pack/plugins/observability/public/pages/slo_edit/index.tsx +++ b/x-pack/plugins/observability/public/pages/slo_edit/index.tsx @@ -9,25 +9,31 @@ import React from 'react'; import { useParams } from 'react-router-dom'; import { i18n } from '@kbn/i18n'; -import { ObservabilityAppServices } from '../../application/types'; import { paths } from '../../config'; +import { useKibana } from '../../utils/kibana_react'; import { usePluginContext } from '../../hooks/use_plugin_context'; import { useBreadcrumbs } from '../../hooks/use_breadcrumbs'; -import { useKibana } from '../../utils/kibana_react'; import { useFetchSloDetails } from '../../hooks/slo/use_fetch_slo_details'; +import { useLicense } from '../../hooks/use_license'; import { SloEditForm } from './components/slo_edit_form'; import PageNotFound from '../404'; import { isSloFeatureEnabled } from '../slos/helpers/is_slo_feature_enabled'; export function SloEditPage() { - const { http } = useKibana().services; + const { + application: { navigateToUrl }, + http: { basePath }, + } = useKibana().services; const { ObservabilityPageTemplate, config } = usePluginContext(); const { sloId } = useParams<{ sloId: string | undefined }>(); + const { hasAtLeast } = useLicense(); + const hasRightLicense = hasAtLeast('platinum'); + useBreadcrumbs([ { - href: http.basePath.prepend(paths.observability.slos), + href: basePath.prepend(paths.observability.slos), text: i18n.translate('xpack.observability.breadcrumbs.sloEditLinkText', { defaultMessage: 'SLOs', }), @@ -40,6 +46,10 @@ export function SloEditPage() { return ; } + if (hasRightLicense === false) { + navigateToUrl(basePath.prepend(paths.observability.slos)); + } + if (loading) { return null; } diff --git a/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.stories.tsx b/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.stories.tsx new file mode 100644 index 0000000000000..89ee6435543c6 --- /dev/null +++ b/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.stories.tsx @@ -0,0 +1,22 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { ComponentStory } from '@storybook/react'; + +import { KibanaReactStorybookDecorator } from '../../../utils/kibana_react.storybook_decorator'; +import { SloListWelcomePrompt as Component } from './slo_list_welcome_prompt'; + +export default { + component: Component, + title: 'app/SLO/ListPage/SloListWelcomePrompt', + decorators: [KibanaReactStorybookDecorator], +}; + +const Template: ComponentStory = () => ; + +export const SloListWelcomePrompt = Template.bind({}); diff --git a/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.tsx b/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.tsx index 995146379cf9a..c78a7f2455518 100644 --- a/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.tsx +++ b/x-pack/plugins/observability/public/pages/slos/components/slo_list_welcome_prompt.tsx @@ -6,11 +6,21 @@ */ import React from 'react'; -import { EuiPageTemplate, EuiButton, EuiTitle, EuiLink, EuiImage } from '@elastic/eui'; +import { + EuiPageTemplate, + EuiButton, + EuiTitle, + EuiLink, + EuiImage, + EuiSpacer, + EuiFlexGroup, + EuiFlexItem, +} from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { paths } from '../../../config'; import { useKibana } from '../../../utils/kibana_react'; +import { useLicense } from '../../../hooks/use_license'; +import { paths } from '../../../config'; import illustration from './assets/illustration.svg'; export function SloListWelcomePrompt() { @@ -19,6 +29,10 @@ export function SloListWelcomePrompt() { http: { basePath }, } = useKibana().services; + const { hasAtLeast } = useLicense(); + + const hasRightLicense = hasAtLeast('platinum'); + const handleClickCreateSlo = () => { navigateToUrl(basePath.prepend(paths.observability.sloCreate)); }; @@ -58,20 +72,92 @@ export function SloListWelcomePrompt() { 'Easily report the uptime and reliability of your services to stakeholders with real-time insights.', })}

    - -

    - {i18n.translate('xpack.observability.slos.sloList.welcomePrompt.messageParagraph3', { - defaultMessage: 'To get started, create your first SLO.', - })} -

    + } actions={ - - {i18n.translate('xpack.observability.slos.sloList.welcomePrompt.buttonLabel', { - defaultMessage: 'Create first SLO', - })} - + <> + {hasRightLicense ? ( + + + + + {i18n.translate( + 'xpack.observability.slos.sloList.welcomePrompt.getStartedMessage', + { + defaultMessage: 'To get started, create your first SLO.', + } + )} + + + + + + + + {i18n.translate( + 'xpack.observability.slos.sloList.welcomePrompt.buttonLabel', + { + defaultMessage: 'Create SLO', + } + )} + + + + + ) : ( + + + + + {i18n.translate( + 'xpack.observability.slos.sloList.welcomePrompt.needLicenseMessage', + { + defaultMessage: + 'You need an Elastic Cloud subscription or Platinum license to use SLOs.', + } + )} + + + + + + + + + {i18n.translate( + 'xpack.observability.slos.sloList.welcomePrompt.signupForCloud', + { + defaultMessage: 'Sign up for Elastic Cloud', + } + )} + + + + + + {i18n.translate( + 'xpack.observability.slos.sloList.welcomePrompt.signupForLicense', + { + defaultMessage: 'Sign up for license', + } + )} + + + + + + )} + } footer={ <> diff --git a/x-pack/plugins/observability/public/pages/slos/index.test.tsx b/x-pack/plugins/observability/public/pages/slos/index.test.tsx index ec9533922b5e3..4808eed9af5d2 100644 --- a/x-pack/plugins/observability/public/pages/slos/index.test.tsx +++ b/x-pack/plugins/observability/public/pages/slos/index.test.tsx @@ -8,29 +8,44 @@ import React from 'react'; import { screen } from '@testing-library/react'; -import { ConfigSchema } from '../../plugin'; -import { Subset } from '../../typings'; -import { kibanaStartMock } from '../../utils/kibana_react.mock'; import { render } from '../../utils/test_helper'; +import { useKibana } from '../../utils/kibana_react'; +import { useFetchSloList } from '../../hooks/slo/use_fetch_slo_list'; +import { useLicense } from '../../hooks/use_license'; import { SlosPage } from '.'; import { emptySloList, sloList } from '../../data/slo'; -import { useFetchSloList } from '../../hooks/slo/use_fetch_slo_list'; +import type { ConfigSchema } from '../../plugin'; +import type { Subset } from '../../typings'; jest.mock('react-router-dom', () => ({ ...jest.requireActual('react-router-dom'), useParams: jest.fn(), })); -jest.mock('../../hooks/slo/use_fetch_slo_list'); -jest.mock('../../hooks/use_breadcrumbs'); - -const mockUseKibanaReturnValue = kibanaStartMock.startContract(); -jest.mock('../../utils/kibana_react', () => ({ - useKibana: jest.fn(() => mockUseKibanaReturnValue), -})); +jest.mock('../../utils/kibana_react'); +jest.mock('../../hooks/use_breadcrumbs'); +jest.mock('../../hooks/use_license'); +jest.mock('../../hooks/slo/use_fetch_slo_list'); +const useKibanaMock = useKibana as jest.Mock; +const useLicenseMock = useLicense as jest.Mock; const useFetchSloListMock = useFetchSloList as jest.Mock; +const mockNavigate = jest.fn(); + +const mockKibana = () => { + useKibanaMock.mockReturnValue({ + services: { + application: { navigateToUrl: mockNavigate }, + http: { + basePath: { + prepend: jest.fn(), + }, + }, + }, + }); +}; + const config: Subset = { unsafe: { slo: { enabled: true }, @@ -40,38 +55,62 @@ const config: Subset = { describe('SLOs Page', () => { beforeEach(() => { jest.clearAllMocks(); + mockKibana(); }); - it('renders the not found page when the feature flag is not enabled', async () => { - useFetchSloListMock.mockReturnValue({ loading: false, sloList: emptySloList }); + describe('when the feature flag is not enabled', () => { + it('renders the not found page ', async () => { + useFetchSloListMock.mockReturnValue({ loading: false, sloList: emptySloList }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); - render(, { unsafe: { slo: { enabled: false } } }); + render(, { unsafe: { slo: { enabled: false } } }); - expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); + expect(screen.queryByTestId('pageNotFound')).toBeTruthy(); + }); }); describe('when the feature flag is enabled', () => { - it('renders nothing when the API is loading', async () => { - useFetchSloListMock.mockReturnValue({ loading: true, sloList: emptySloList }); + describe('when the incorrect license is found', () => { + it('renders the welcome prompt with subscription buttons', async () => { + useFetchSloListMock.mockReturnValue({ loading: false, sloList: emptySloList }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => false }); - const { container } = render(, config); + render(, config); - expect(container).toBeEmptyDOMElement(); + expect(screen.queryByTestId('slosPageWelcomePrompt')).toBeTruthy(); + expect(screen.queryByTestId('slosPageWelcomePromptSignupForCloudButton')).toBeTruthy(); + expect(screen.queryByTestId('slosPageWelcomePromptSignupForLicenseButton')).toBeTruthy(); + }); }); - it('renders the SLOs Welcome Prompt when the API has finished loading and there are no results', async () => { - useFetchSloListMock.mockReturnValue({ loading: false, sloList: emptySloList }); - render(, config); + describe('when the correct license is found', () => { + it('renders nothing when the API is loading', async () => { + useFetchSloListMock.mockReturnValue({ loading: true, sloList: emptySloList }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); - expect(screen.queryByTestId('slosPageWelcomePrompt')).toBeTruthy(); - }); + const { container } = render(, config); + + expect(container).toBeEmptyDOMElement(); + }); + + it('renders the SLOs Welcome Prompt when the API has finished loading and there are no results', async () => { + useFetchSloListMock.mockReturnValue({ loading: false, sloList: emptySloList }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); + + render(, config); + + expect(screen.queryByTestId('slosPageWelcomePrompt')).toBeTruthy(); + }); + + it('renders the SLOs page when the API has finished loading and there are results', async () => { + useFetchSloListMock.mockReturnValue({ loading: false, sloList }); + useLicenseMock.mockReturnValue({ hasAtLeast: () => true }); - it('renders the SLOs page when the API has finished loading and there are results', async () => { - useFetchSloListMock.mockReturnValue({ loading: false, sloList }); - render(, config); + render(, config); - expect(screen.queryByTestId('slosPage')).toBeTruthy(); - expect(screen.queryByTestId('sloList')).toBeTruthy(); + expect(screen.queryByTestId('slosPage')).toBeTruthy(); + expect(screen.queryByTestId('sloList')).toBeTruthy(); + }); }); }); }); diff --git a/x-pack/plugins/observability/public/pages/slos/index.tsx b/x-pack/plugins/observability/public/pages/slos/index.tsx index 749413f1ac243..17a069dfc885f 100644 --- a/x-pack/plugins/observability/public/pages/slos/index.tsx +++ b/x-pack/plugins/observability/public/pages/slos/index.tsx @@ -9,17 +9,17 @@ import React from 'react'; import { EuiButton } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { ObservabilityAppServices } from '../../application/types'; -import { paths } from '../../config'; +import { useKibana } from '../../utils/kibana_react'; import { usePluginContext } from '../../hooks/use_plugin_context'; +import { useLicense } from '../../hooks/use_license'; import { useBreadcrumbs } from '../../hooks/use_breadcrumbs'; -import { useKibana } from '../../utils/kibana_react'; -import { isSloFeatureEnabled } from './helpers/is_slo_feature_enabled'; -import { SLOS_BREADCRUMB_TEXT, SLOS_PAGE_TITLE } from './translations'; import { useFetchSloList } from '../../hooks/slo/use_fetch_slo_list'; import { SloList } from './components/slo_list'; import { SloListWelcomePrompt } from './components/slo_list_welcome_prompt'; import PageNotFound from '../404'; +import { paths } from '../../config'; +import { isSloFeatureEnabled } from './helpers/is_slo_feature_enabled'; +import type { ObservabilityAppServices } from '../../application/types'; export function SlosPage() { const { @@ -28,6 +28,8 @@ export function SlosPage() { } = useKibana().services; const { ObservabilityPageTemplate, config } = usePluginContext(); + const { hasAtLeast } = useLicense(); + const { loading, sloList: { total }, @@ -36,7 +38,9 @@ export function SlosPage() { useBreadcrumbs([ { href: basePath.prepend(paths.observability.slos), - text: SLOS_BREADCRUMB_TEXT, + text: i18n.translate('xpack.observability.breadcrumbs.slosLinkText', { + defaultMessage: 'SLOs', + }), }, ]); @@ -52,14 +56,16 @@ export function SlosPage() { return null; } - if (total === 0) { + if (total === 0 || !hasAtLeast('platinum')) { return ; } return ( {i18n.translate('xpack.observability.slos.sloList.pageHeader.createNewButtonLabel', { diff --git a/x-pack/plugins/observability/public/plugin.ts b/x-pack/plugins/observability/public/plugin.ts index 0cb24f0495cde..8838457b3a344 100644 --- a/x-pack/plugins/observability/public/plugin.ts +++ b/x-pack/plugins/observability/public/plugin.ts @@ -25,6 +25,7 @@ import type { DataViewsPublicPluginStart } from '@kbn/data-views-plugin/public'; import type { DiscoverStart } from '@kbn/discover-plugin/public'; import type { EmbeddableStart } from '@kbn/embeddable-plugin/public'; import type { HomePublicPluginSetup, HomePublicPluginStart } from '@kbn/home-plugin/public'; +import type { ChartsPluginStart } from '@kbn/charts-plugin/public'; import { CasesDeepLinkId, CasesUiStart, getCasesDeepLinks } from '@kbn/cases-plugin/public'; import type { LensPublicStart } from '@kbn/lens-plugin/public'; import { @@ -40,6 +41,7 @@ import { import { SecurityPluginStart } from '@kbn/security-plugin/public'; import { GuidedOnboardingPluginStart } from '@kbn/guided-onboarding-plugin/public'; import { SpacesPluginStart } from '@kbn/spaces-plugin/public'; +import { LicensingPluginStart } from '@kbn/licensing-plugin/public'; import { RuleDetailsLocatorDefinition } from './locators/rule_details'; import { observabilityAppId, observabilityFeatureId, casesPath } from '../common'; import { createLazyObservabilityPageTemplate } from './components/shared'; @@ -89,21 +91,23 @@ export interface ObservabilityPublicPluginsSetup { } export interface ObservabilityPublicPluginsStart { - usageCollection: UsageCollectionSetup; + actionTypeRegistry: ActionTypeRegistryContract; cases: CasesUiStart; - embeddable: EmbeddableStart; - home?: HomePublicPluginStart; - share: SharePluginStart; - triggersActionsUi: TriggersAndActionsUIPublicPluginStart; + charts: ChartsPluginStart; data: DataPublicPluginStart; dataViews: DataViewsPublicPluginStart; - lens: LensPublicStart; discover: DiscoverStart; + embeddable: EmbeddableStart; + guidedOnboarding: GuidedOnboardingPluginStart; + lens: LensPublicStart; + licensing: LicensingPluginStart; ruleTypeRegistry: RuleTypeRegistryContract; - actionTypeRegistry: ActionTypeRegistryContract; security: SecurityPluginStart; - guidedOnboarding: GuidedOnboardingPluginStart; + share: SharePluginStart; spaces: SpacesPluginStart; + triggersActionsUi: TriggersAndActionsUIPublicPluginStart; + usageCollection: UsageCollectionSetup; + home?: HomePublicPluginStart; } export type ObservabilityPublicStart = ReturnType; diff --git a/x-pack/plugins/observability/public/utils/get_bucket_size/index.ts b/x-pack/plugins/observability/public/utils/get_bucket_size/index.ts index 495fc766cd62f..ca1afaf41c1a6 100644 --- a/x-pack/plugins/observability/public/utils/get_bucket_size/index.ts +++ b/x-pack/plugins/observability/public/utils/get_bucket_size/index.ts @@ -14,13 +14,15 @@ export function getBucketSize({ start, end, minInterval, + buckets = 100, }: { start: number; end: number; minInterval: string; + buckets?: number; }) { const duration = moment.duration(end - start, 'ms'); - const bucketSize = Math.max(calculateAuto.near(100, duration)?.asSeconds() ?? 0, 1); + const bucketSize = Math.max(calculateAuto.near(buckets, duration)?.asSeconds() ?? 0, 1); const intervalString = `${bucketSize}s`; const matches = minInterval && minInterval.match(/^([\d]+)([shmdwMy]|ms)$/); const minBucketSize = matches ? Number(matches[1]) * unitToSeconds(matches[2]) : 0; diff --git a/x-pack/plugins/observability/server/assets/component_templates/slo_mappings_template.ts b/x-pack/plugins/observability/server/assets/component_templates/slo_mappings_template.ts index 96d3564f18ca9..faf415a3d91e8 100644 --- a/x-pack/plugins/observability/server/assets/component_templates/slo_mappings_template.ts +++ b/x-pack/plugins/observability/server/assets/component_templates/slo_mappings_template.ts @@ -29,6 +29,9 @@ export const getSLOMappingsTemplate = (name: string) => ({ denominator: { type: 'long', }, + isGoodSlice: { + type: 'byte', + }, context: { type: 'flattened', }, diff --git a/x-pack/plugins/observability/server/domain/models/indicators.ts b/x-pack/plugins/observability/server/domain/models/indicators.ts index 6df394b031ce5..88c0e2dd8e5ae 100644 --- a/x-pack/plugins/observability/server/domain/models/indicators.ts +++ b/x-pack/plugins/observability/server/domain/models/indicators.ts @@ -9,6 +9,7 @@ import * as t from 'io-ts'; import { apmTransactionDurationIndicatorSchema, apmTransactionErrorRateIndicatorSchema, + historicalSummarySchema, indicatorDataSchema, indicatorSchema, indicatorTypesSchema, @@ -21,6 +22,7 @@ type KQLCustomIndicator = t.TypeOf; type Indicator = t.TypeOf; type IndicatorTypes = t.TypeOf; type IndicatorData = t.TypeOf; +type HistoricalSummary = t.TypeOf; export type { Indicator, @@ -29,4 +31,5 @@ export type { APMTransactionDurationIndicator, KQLCustomIndicator, IndicatorData, + HistoricalSummary, }; diff --git a/x-pack/plugins/observability/server/domain/services/compute_error_budget.ts b/x-pack/plugins/observability/server/domain/services/compute_error_budget.ts index 3b7e5e9d57812..61da9597c2db9 100644 --- a/x-pack/plugins/observability/server/domain/services/compute_error_budget.ts +++ b/x-pack/plugins/observability/server/domain/services/compute_error_budget.ts @@ -8,11 +8,13 @@ import moment from 'moment'; import { calendarAlignedTimeWindowSchema, + Duration, occurrencesBudgetingMethodSchema, rollingTimeWindowSchema, timeslicesBudgetingMethodSchema, } from '@kbn/slo-schema'; -import { ErrorBudget, IndicatorData, SLO, toMomentUnitOfTime } from '../models'; + +import { DateRange, ErrorBudget, IndicatorData, SLO, toMomentUnitOfTime } from '../models'; import { toHighPrecision } from '../../utils/number'; // More details about calculus: https://github.com/elastic/kibana/issues/143980 @@ -48,7 +50,7 @@ function computeForRolling(slo: SLO, sliData: IndicatorData) { } function computeForCalendarAlignedWithOccurrences(slo: SLO, sliData: IndicatorData) { - const { good, total, dateRange: dateRange } = sliData; + const { good, total, dateRange } = sliData; const initialErrorBudget = 1 - slo.objective.target; const now = moment(); @@ -67,20 +69,25 @@ function computeForCalendarAlignedWithOccurrences(slo: SLO, sliData: IndicatorDa } function computeForCalendarAlignedWithTimeslices(slo: SLO, sliData: IndicatorData) { - const { good, total, dateRange: dateRange } = sliData; + const { good, total, dateRange } = sliData; const initialErrorBudget = 1 - slo.objective.target; - const dateRangeDurationInUnit = moment(dateRange.to).diff( - dateRange.from, - toMomentUnitOfTime(slo.objective.timesliceWindow!.unit) - ); - const totalSlices = Math.ceil(dateRangeDurationInUnit / slo.objective.timesliceWindow!.value); + const totalSlices = computeTotalSlicesFromDateRange(dateRange, slo.objective.timesliceWindow!); const consumedErrorBudget = (total - good) / (totalSlices * initialErrorBudget); return toErrorBudget(initialErrorBudget, consumedErrorBudget); } -function toErrorBudget( +export function computeTotalSlicesFromDateRange(dateRange: DateRange, timesliceWindow: Duration) { + const dateRangeDurationInUnit = moment(dateRange.to).diff( + dateRange.from, + toMomentUnitOfTime(timesliceWindow.unit) + ); + const totalSlices = Math.ceil(dateRangeDurationInUnit / timesliceWindow!.value); + return totalSlices; +} + +export function toErrorBudget( initial: number, consumed: number, isEstimated: boolean = false diff --git a/x-pack/plugins/observability/server/domain/services/compute_sli.test.ts b/x-pack/plugins/observability/server/domain/services/compute_sli.test.ts index 131ac5ad17c9a..5ecb7cafc805e 100644 --- a/x-pack/plugins/observability/server/domain/services/compute_sli.test.ts +++ b/x-pack/plugins/observability/server/domain/services/compute_sli.test.ts @@ -5,24 +5,22 @@ * 2.0. */ -import { DateRange } from '../models'; import { computeSLI } from './compute_sli'; -const DATE_RANGE: DateRange = { from: new Date(), to: new Date() }; describe('computeSLI', () => { it('returns -1 when no total events', () => { - expect(computeSLI({ good: 100, total: 0, dateRange: DATE_RANGE })).toEqual(-1); + expect(computeSLI({ good: 100, total: 0 })).toEqual(-1); }); it('returns the sli value', () => { - expect(computeSLI({ good: 100, total: 1000, dateRange: DATE_RANGE })).toEqual(0.1); + expect(computeSLI({ good: 100, total: 1000 })).toEqual(0.1); }); it('returns 1 when good is greater than total events', () => { - expect(computeSLI({ good: 9999, total: 9, dateRange: DATE_RANGE })).toEqual(1); + expect(computeSLI({ good: 9999, total: 9 })).toEqual(1); }); it('returns rounds the value to 6 digits', () => { - expect(computeSLI({ good: 33, total: 90, dateRange: DATE_RANGE })).toEqual(0.366667); + expect(computeSLI({ good: 33, total: 90 })).toEqual(0.366667); }); }); diff --git a/x-pack/plugins/observability/server/domain/services/compute_sli.ts b/x-pack/plugins/observability/server/domain/services/compute_sli.ts index bbb011f783bc2..d944e427564fa 100644 --- a/x-pack/plugins/observability/server/domain/services/compute_sli.ts +++ b/x-pack/plugins/observability/server/domain/services/compute_sli.ts @@ -10,7 +10,7 @@ import { toHighPrecision } from '../../utils/number'; const NO_DATA = -1; -export function computeSLI(sliData: IndicatorData): number { +export function computeSLI(sliData: Pick): number { const { good, total } = sliData; if (total === 0) { return NO_DATA; diff --git a/x-pack/plugins/observability/server/lib/rules/slo_burn_rate/executor.test.ts b/x-pack/plugins/observability/server/lib/rules/slo_burn_rate/executor.test.ts index dd6637d86960a..2004fbb8428c0 100644 --- a/x-pack/plugins/observability/server/lib/rules/slo_burn_rate/executor.test.ts +++ b/x-pack/plugins/observability/server/lib/rules/slo_burn_rate/executor.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { IUiSettingsClient, SavedObjectsClientContract } from '@kbn/core/server'; import { ElasticsearchClientMock, @@ -257,7 +257,7 @@ describe('BurnRateRuleExecutor', () => { function someRuleParams(params: Partial = {}): BurnRateRuleParams { return { - sloId: uuid(), + sloId: uuidv4(), burnRateThreshold: 2, maxBurnRateThreshold: 720, longWindow: { value: 1, unit: 'h' }, diff --git a/x-pack/plugins/observability/server/routes/slo/route.ts b/x-pack/plugins/observability/server/routes/slo/route.ts index 78a254ce7fc06..50716135e653d 100644 --- a/x-pack/plugins/observability/server/routes/slo/route.ts +++ b/x-pack/plugins/observability/server/routes/slo/route.ts @@ -5,9 +5,11 @@ * 2.0. */ +import { badRequest } from '@hapi/boom'; import { createSLOParamsSchema, deleteSLOParamsSchema, + fetchHistoricalSummaryParamsSchema, findSLOParamsSchema, getSLOParamsSchema, updateSLOParamsSchema, @@ -29,8 +31,11 @@ import { KQLCustomTransformGenerator, TransformGenerator, } from '../../services/slo/transform_generators'; -import { IndicatorTypes } from '../../domain/models'; import { createObservabilityServerRoute } from '../create_observability_server_route'; +import { DefaultHistoricalSummaryClient } from '../../services/slo/historical_summary_client'; +import { FetchHistoricalSummary } from '../../services/slo/fetch_historical_summary'; +import type { IndicatorTypes } from '../../domain/models'; +import type { ObservabilityRequestHandlerContext } from '../../types'; const transformGenerators: Record = { 'sli.apm.transactionDuration': new ApmTransactionDurationTransformGenerator(), @@ -38,6 +43,10 @@ const transformGenerators: Record = { 'sli.kql.custom': new KQLCustomTransformGenerator(), }; +const isLicenseAtLeastPlatinum = async (context: ObservabilityRequestHandlerContext) => { + return (await context.licensing).license.hasAtLeast('platinum'); +}; + const createSLORoute = createObservabilityServerRoute({ endpoint: 'POST /api/observability/slos', options: { @@ -45,6 +54,10 @@ const createSLORoute = createObservabilityServerRoute({ }, params: createSLOParamsSchema, handler: async ({ context, params, logger }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const esClient = (await context.core).elasticsearch.client.asCurrentUser; const soClient = (await context.core).savedObjects.client; @@ -66,6 +79,10 @@ const updateSLORoute = createObservabilityServerRoute({ }, params: updateSLOParamsSchema, handler: async ({ context, params, logger }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const esClient = (await context.core).elasticsearch.client.asCurrentUser; const soClient = (await context.core).savedObjects.client; @@ -86,6 +103,10 @@ const deleteSLORoute = createObservabilityServerRoute({ }, params: deleteSLOParamsSchema, handler: async ({ context, params, logger }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const esClient = (await context.core).elasticsearch.client.asCurrentUser; const soClient = (await context.core).savedObjects.client; @@ -105,6 +126,10 @@ const getSLORoute = createObservabilityServerRoute({ }, params: getSLOParamsSchema, handler: async ({ context, params }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const soClient = (await context.core).savedObjects.client; const esClient = (await context.core).elasticsearch.client.asCurrentUser; const repository = new KibanaSavedObjectsSLORepository(soClient); @@ -124,6 +149,10 @@ const findSLORoute = createObservabilityServerRoute({ }, params: findSLOParamsSchema, handler: async ({ context, params }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const soClient = (await context.core).savedObjects.client; const esClient = (await context.core).elasticsearch.client.asCurrentUser; const repository = new KibanaSavedObjectsSLORepository(soClient); @@ -136,10 +165,34 @@ const findSLORoute = createObservabilityServerRoute({ }, }); +const fetchHistoricalSummary = createObservabilityServerRoute({ + endpoint: 'POST /internal/observability/slos/_historical_summary', + options: { + tags: [], + }, + params: fetchHistoricalSummaryParamsSchema, + handler: async ({ context, params }) => { + if (!isLicenseAtLeastPlatinum(context)) { + throw badRequest('Platinum license or higher is needed to make use of this feature.'); + } + const soClient = (await context.core).savedObjects.client; + const esClient = (await context.core).elasticsearch.client.asCurrentUser; + const repository = new KibanaSavedObjectsSLORepository(soClient); + const historicalSummaryClient = new DefaultHistoricalSummaryClient(esClient); + + const fetchSummaryData = new FetchHistoricalSummary(repository, historicalSummaryClient); + + const response = await fetchSummaryData.execute(params.body); + + return response; + }, +}); + export const slosRouteRepository = { ...createSLORoute, - ...updateSLORoute, - ...getSLORoute, ...deleteSLORoute, ...findSLORoute, + ...getSLORoute, + ...fetchHistoricalSummary, + ...updateSLORoute, }; diff --git a/x-pack/plugins/observability/server/saved_objects/slo.ts b/x-pack/plugins/observability/server/saved_objects/slo.ts index 417a9508a8e6f..9c64616b8e393 100644 --- a/x-pack/plugins/observability/server/saved_objects/slo.ts +++ b/x-pack/plugins/observability/server/saved_objects/slo.ts @@ -19,6 +19,7 @@ export const slo: SavedObjectsType = { mappings: { dynamic: false, properties: { + id: { type: 'keyword' }, name: { type: 'keyword' }, description: { type: 'text' }, indicator: { diff --git a/x-pack/plugins/observability/server/services/slo/__snapshots__/historical_summary_client.test.ts.snap b/x-pack/plugins/observability/server/services/slo/__snapshots__/historical_summary_client.test.ts.snap new file mode 100644 index 0000000000000..a8950a810a9b7 --- /dev/null +++ b/x-pack/plugins/observability/server/services/slo/__snapshots__/historical_summary_client.test.ts.snap @@ -0,0 +1,1345 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 1`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.004019, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.995981, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 2`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.023374, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.976626, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 3`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.042725, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.957275, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 4`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.06208, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.93792, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 5`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.081433, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.918567, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 6`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.100784, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.899216, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 7`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.120137, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.879863, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 8`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.139494, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.860506, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 9`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.15887, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.84113, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 10`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.1782, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.8218, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 11`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.197546, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.802454, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 12`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.216933, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.783067, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 13`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.236292, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.763708, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 14`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.25563, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.74437, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 15`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.274977, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.725023, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 16`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.294298, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.705702, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 17`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.313653, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.686347, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Occurrences SLOs returns the summary 18`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.333025, + "initial": 0.05, + "isEstimated": true, + "remaining": 0.666975, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 1`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.001344, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.998656, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 2`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.002688, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.997312, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 3`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.004032, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.995968, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 4`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.005376, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.994624, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 5`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.00672, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.99328, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 6`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.008065, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.991935, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 7`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.009409, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.990591, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 8`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.010753, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.989247, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 9`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.012097, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.987903, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 10`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.013441, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.986559, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 11`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.014785, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.985215, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 12`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.016129, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.983871, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 13`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.017473, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.982527, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 14`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.018817, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.981183, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 15`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.020161, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.979839, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 16`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.021505, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.978495, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 17`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.022849, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.977151, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Calendar Aligned and Timeslices SLOs returns the summary 18`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.024194, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.975806, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 1`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 2`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 3`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 4`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 5`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 6`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 7`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 8`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 9`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 10`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 11`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 12`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 13`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 14`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 15`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 16`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 17`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 18`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 19`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 20`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 21`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 22`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 23`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 24`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 25`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 26`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 27`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 28`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 29`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Occurrences SLOs returns the summary 30`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 1`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 2`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 3`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 4`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 5`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 6`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 7`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 8`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 9`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 10`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 11`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 12`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 13`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 14`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 15`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 16`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 17`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 18`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 19`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 20`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 21`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 22`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 23`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 24`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 25`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 26`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 27`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 28`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 29`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; + +exports[`FetchHistoricalSummary Rolling and Timeslices SLOs returns the summary 30`] = ` +Object { + "date": Any, + "errorBudget": Object { + "consumed": 0.6, + "initial": 0.05, + "isEstimated": false, + "remaining": 0.4, + }, + "sliValue": 0.97, + "status": "HEALTHY", +} +`; diff --git a/x-pack/plugins/observability/server/services/slo/create_slo.ts b/x-pack/plugins/observability/server/services/slo/create_slo.ts index cdae0a7e858ab..cc92b8c0bd5e7 100644 --- a/x-pack/plugins/observability/server/services/slo/create_slo.ts +++ b/x-pack/plugins/observability/server/services/slo/create_slo.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { CreateSLOParams, CreateSLOResponse } from '@kbn/slo-schema'; @@ -55,7 +55,7 @@ export class CreateSLO { const now = new Date(); return { ...params, - id: uuid.v1(), + id: uuidv1(), settings: { timestampField: params.settings?.timestampField ?? '@timestamp', syncDelay: params.settings?.syncDelay ?? new Duration(1, DurationUnit.Minute), diff --git a/x-pack/plugins/observability/server/services/slo/fetch_historical_summary.ts b/x-pack/plugins/observability/server/services/slo/fetch_historical_summary.ts new file mode 100644 index 0000000000000..e79c89c99ea63 --- /dev/null +++ b/x-pack/plugins/observability/server/services/slo/fetch_historical_summary.ts @@ -0,0 +1,29 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + FetchHistoricalSummaryParams, + FetchHistoricalSummaryResponse, + fetchHistoricalSummaryResponseSchema, +} from '@kbn/slo-schema'; +import { HistoricalSummaryClient } from './historical_summary_client'; +import { SLORepository } from './slo_repository'; + +export class FetchHistoricalSummary { + constructor( + private repository: SLORepository, + private historicalSummaryClient: HistoricalSummaryClient + ) {} + + public async execute({ + sloIds, + }: FetchHistoricalSummaryParams): Promise { + const sloList = await this.repository.findAllByIds(sloIds); + const historicalSummaryBySlo = await this.historicalSummaryClient.fetch(sloList); + return fetchHistoricalSummaryResponseSchema.encode(historicalSummaryBySlo); + } +} diff --git a/x-pack/plugins/observability/server/services/slo/fixtures/duration.ts b/x-pack/plugins/observability/server/services/slo/fixtures/duration.ts index 0086754150e8d..facc03bcad9df 100644 --- a/x-pack/plugins/observability/server/services/slo/fixtures/duration.ts +++ b/x-pack/plugins/observability/server/services/slo/fixtures/duration.ts @@ -7,6 +7,14 @@ import { Duration, DurationUnit } from '../../../domain/models'; +export function thirtyDays(): Duration { + return new Duration(30, DurationUnit.Day); +} + +export function oneMonth(): Duration { + return new Duration(1, DurationUnit.Month); +} + export function sevenDays(): Duration { return new Duration(7, DurationUnit.Day); } @@ -22,3 +30,11 @@ export function sixHours(): Duration { export function oneMinute(): Duration { return new Duration(1, DurationUnit.Minute); } + +export function twoMinute(): Duration { + return new Duration(2, DurationUnit.Minute); +} + +export function fiveMinute(): Duration { + return new Duration(5, DurationUnit.Minute); +} diff --git a/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts b/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts index b040254d570b2..9d68ad174f127 100644 --- a/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts +++ b/x-pack/plugins/observability/server/services/slo/fixtures/slo.ts @@ -6,7 +6,7 @@ */ import { cloneDeep } from 'lodash'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { SavedObject } from '@kbn/core-saved-objects-common'; import { sloSchema, CreateSLOParams } from '@kbn/slo-schema'; @@ -22,7 +22,7 @@ import { StoredSLO, } from '../../../domain/models'; import { Paginated } from '../slo_repository'; -import { sevenDays } from './duration'; +import { sevenDays, twoMinute } from './duration'; import { sevenDaysRolling } from './time_window'; export const createAPMTransactionErrorRateIndicator = ( @@ -100,7 +100,7 @@ export const createSLO = (params: Partial = {}): SLO => { const now = new Date(); return cloneDeep({ ...defaultSLO, - id: uuid.v1(), + id: uuidv1(), revision: 1, createdAt: now, updatedAt: now, @@ -108,6 +108,18 @@ export const createSLO = (params: Partial = {}): SLO => { }); }; +export const createSLOWithTimeslicesBudgetingMethod = (params: Partial = {}): SLO => { + return createSLO({ + budgetingMethod: 'timeslices', + objective: { + target: 0.98, + timesliceTarget: 0.95, + timesliceWindow: twoMinute(), + }, + ...params, + }); +}; + export const createSLOWithCalendarTimeWindow = (params: Partial = {}): SLO => { return createSLO({ timeWindow: { diff --git a/x-pack/plugins/observability/server/services/slo/historical_summary_client.test.ts b/x-pack/plugins/observability/server/services/slo/historical_summary_client.test.ts new file mode 100644 index 0000000000000..b55ca69ed3bb2 --- /dev/null +++ b/x-pack/plugins/observability/server/services/slo/historical_summary_client.test.ts @@ -0,0 +1,192 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { ElasticsearchClientMock, elasticsearchServiceMock } from '@kbn/core/server/mocks'; +import moment from 'moment'; +import { oneMinute, oneMonth, thirtyDays } from './fixtures/duration'; +import { createSLO } from './fixtures/slo'; +import { DefaultHistoricalSummaryClient } from './historical_summary_client'; + +const commonEsResponse = { + took: 100, + timed_out: false, + _shards: { + total: 0, + successful: 0, + skipped: 0, + failed: 0, + }, + hits: { + hits: [], + }, +}; + +const generateEsResponseForRollingSLO = ( + rollingDays: number = 30, + good: number = 97, + total: number = 100 +) => { + const numberOfBuckets = rollingDays * 2; + const day = moment.utc().subtract(numberOfBuckets, 'day').startOf('day'); + return { + ...commonEsResponse, + responses: [ + { + ...commonEsResponse, + aggregations: { + daily: { + buckets: Array(numberOfBuckets) + .fill(0) + .map((_, index) => ({ + key_as_string: day.clone().add(index, 'day').toISOString(), + key: day.clone().add(index, 'day').format('x'), + doc_count: 1440, + total: { + value: total, + }, + good: { + value: good, + }, + cumulative_good: { + value: good * (index + 1), + }, + cumulative_total: { + value: total * (index + 1), + }, + })), + }, + }, + }, + ], + }; +}; + +const generateEsResponseForCalendarAlignedSLO = (good: number = 97, total: number = 100) => { + const day = moment.utc().startOf('month'); + return { + ...commonEsResponse, + responses: [ + { + ...commonEsResponse, + aggregations: { + daily: { + buckets: Array(18) + .fill(0) + .map((_, index) => ({ + key_as_string: day.clone().add(index, 'day').toISOString(), + key: day.clone().add(index, 'day').format('x'), + doc_count: 1440, + total: { + value: total, + }, + good: { + value: good, + }, + cumulative_good: { + value: good * (index + 1), + }, + cumulative_total: { + value: total * (index + 1), + }, + })), + }, + }, + }, + ], + }; +}; + +describe('FetchHistoricalSummary', () => { + let esClientMock: ElasticsearchClientMock; + + beforeEach(() => { + esClientMock = elasticsearchServiceMock.createElasticsearchClient(); + }); + + describe('Rolling and Occurrences SLOs', () => { + it('returns the summary', async () => { + const slo = createSLO({ + timeWindow: { isRolling: true, duration: thirtyDays() }, + objective: { target: 0.95 }, + }); + esClientMock.msearch.mockResolvedValueOnce(generateEsResponseForRollingSLO(30)); + const client = new DefaultHistoricalSummaryClient(esClientMock); + + const results = await client.fetch([slo]); + results[slo.id].forEach((dailyResult) => + expect(dailyResult).toMatchSnapshot({ date: expect.any(Date) }) + ); + + expect(results[slo.id]).toHaveLength(30); + }); + }); + + describe('Rolling and Timeslices SLOs', () => { + it('returns the summary', async () => { + const slo = createSLO({ + timeWindow: { isRolling: true, duration: thirtyDays() }, + budgetingMethod: 'timeslices', + objective: { target: 0.95, timesliceTarget: 0.9, timesliceWindow: oneMinute() }, + }); + esClientMock.msearch.mockResolvedValueOnce(generateEsResponseForRollingSLO(30)); + const client = new DefaultHistoricalSummaryClient(esClientMock); + + const results = await client.fetch([slo]); + + results[slo.id].forEach((dailyResult) => + expect(dailyResult).toMatchSnapshot({ date: expect.any(Date) }) + ); + expect(results[slo.id]).toHaveLength(30); + }); + }); + + describe('Calendar Aligned and Timeslices SLOs', () => { + it('returns the summary', async () => { + const slo = createSLO({ + timeWindow: { + duration: oneMonth(), + calendar: { startTime: new Date('2023-01-01T00:00:00.000Z') }, + }, + budgetingMethod: 'timeslices', + objective: { target: 0.95, timesliceTarget: 0.9, timesliceWindow: oneMinute() }, + }); + esClientMock.msearch.mockResolvedValueOnce(generateEsResponseForCalendarAlignedSLO()); + const client = new DefaultHistoricalSummaryClient(esClientMock); + + const results = await client.fetch([slo]); + + results[slo.id].forEach((dailyResult) => + expect(dailyResult).toMatchSnapshot({ date: expect.any(Date) }) + ); + + expect(results[slo.id]).toHaveLength(18); + }); + }); + + describe('Calendar Aligned and Occurrences SLOs', () => { + it('returns the summary', async () => { + const slo = createSLO({ + timeWindow: { + duration: oneMonth(), + calendar: { startTime: new Date('2023-01-01T00:00:00.000Z') }, + }, + budgetingMethod: 'occurrences', + objective: { target: 0.95 }, + }); + esClientMock.msearch.mockResolvedValueOnce(generateEsResponseForCalendarAlignedSLO()); + const client = new DefaultHistoricalSummaryClient(esClientMock); + + const results = await client.fetch([slo]); + + results[slo.id].forEach((dailyResult) => + expect(dailyResult).toMatchSnapshot({ date: expect.any(Date) }) + ); + + expect(results[slo.id]).toHaveLength(18); + }); + }); +}); diff --git a/x-pack/plugins/observability/server/services/slo/historical_summary_client.ts b/x-pack/plugins/observability/server/services/slo/historical_summary_client.ts new file mode 100644 index 0000000000000..ac1aa73e3a3eb --- /dev/null +++ b/x-pack/plugins/observability/server/services/slo/historical_summary_client.ts @@ -0,0 +1,302 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { MsearchMultisearchBody } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; +import { ElasticsearchClient } from '@kbn/core/server'; +import { + calendarAlignedTimeWindowSchema, + occurrencesBudgetingMethodSchema, + rollingTimeWindowSchema, + timeslicesBudgetingMethodSchema, + toMomentUnitOfTime, +} from '@kbn/slo-schema'; +import { assertNever } from '@kbn/std'; +import moment from 'moment'; + +import { SLO_DESTINATION_INDEX_NAME } from '../../assets/constants'; +import { DateRange, HistoricalSummary, SLO, SLOId } from '../../domain/models'; +import { + computeSLI, + computeSummaryStatus, + computeTotalSlicesFromDateRange, + toDateRange, + toErrorBudget, +} from '../../domain/services'; + +interface DailyAggBucket { + key_as_string: string; + key: number; + doc_count: number; + total: { + value: number; + }; + good: { + value: number; + }; + cumulative_good?: { + value: number; + }; + cumulative_total?: { + value: number; + }; +} + +export interface HistoricalSummaryClient { + fetch(sloList: SLO[]): Promise>; +} + +export class DefaultHistoricalSummaryClient implements HistoricalSummaryClient { + constructor(private esClient: ElasticsearchClient) {} + + async fetch(sloList: SLO[]): Promise> { + const dateRangeBySlo: Record = sloList.reduce( + (acc, slo) => ({ [slo.id]: getDateRange(slo), ...acc }), + {} + ); + + const searches = sloList.flatMap((slo) => [ + { index: `${SLO_DESTINATION_INDEX_NAME}*` }, + generateSearchQuery(slo, dateRangeBySlo[slo.id]), + ]); + + const historicalSummaryBySlo: Record = {}; + if (searches.length === 0) { + return historicalSummaryBySlo; + } + + const result = await this.esClient.msearch({ searches }); + + for (let i = 0; i < result.responses.length; i++) { + const slo = sloList[i]; + if ('error' in result.responses[i]) { + // handle errorneous responses with an empty historical summary + historicalSummaryBySlo[slo.id] = []; + continue; + } + + // @ts-ignore typing msearch is hard, we cast the response to what it is supposed to be. + const buckets = (result.responses[i].aggregations?.daily?.buckets as DailyAggBucket[]) || []; + + if (rollingTimeWindowSchema.is(slo.timeWindow)) { + historicalSummaryBySlo[slo.id] = handleResultForRolling(slo, buckets); + continue; + } + + if (calendarAlignedTimeWindowSchema.is(slo.timeWindow)) { + if (timeslicesBudgetingMethodSchema.is(slo.budgetingMethod)) { + const dateRange = dateRangeBySlo[slo.id]; + historicalSummaryBySlo[slo.id] = handleResultForCalendarAlignedAndTimeslices( + slo, + buckets, + dateRange + ); + continue; + } + + if (occurrencesBudgetingMethodSchema.is(slo.budgetingMethod)) { + const dateRange = dateRangeBySlo[slo.id]; + historicalSummaryBySlo[slo.id] = handleResultForCalendarAlignedAndOccurrences( + slo, + buckets, + dateRange + ); + continue; + } + + assertNever(slo.budgetingMethod); + } + + assertNever(slo.timeWindow); + } + + return historicalSummaryBySlo; + } +} + +function handleResultForCalendarAlignedAndOccurrences( + slo: SLO, + buckets: DailyAggBucket[], + dateRange: DateRange +): HistoricalSummary[] { + const initialErrorBudget = 1 - slo.objective.target; + + return buckets.map((bucket: DailyAggBucket): HistoricalSummary => { + const good = bucket.cumulative_good?.value ?? 0; + const total = bucket.cumulative_total?.value ?? 0; + const sliValue = computeSLI({ good, total }); + + const durationCalendarPeriod = moment(dateRange.to).diff(dateRange.from, 'minutes'); + const bucketDate = moment(bucket.key_as_string).endOf('day'); + const durationSinceBeginning = bucketDate.isAfter(dateRange.to) + ? durationCalendarPeriod + : moment(bucketDate).diff(dateRange.from, 'minutes'); + + const totalEventsEstimatedAtPeriodEnd = Math.round( + (total / durationSinceBeginning) * durationCalendarPeriod + ); + + const consumedErrorBudget = + (total - good) / (totalEventsEstimatedAtPeriodEnd * initialErrorBudget); + + const errorBudget = toErrorBudget(initialErrorBudget, consumedErrorBudget, true); + + return { + date: new Date(bucket.key_as_string), + errorBudget, + sliValue, + status: computeSummaryStatus(slo, sliValue, errorBudget), + }; + }); +} + +function handleResultForCalendarAlignedAndTimeslices( + slo: SLO, + buckets: DailyAggBucket[], + dateRange: DateRange +): HistoricalSummary[] { + const initialErrorBudget = 1 - slo.objective.target; + + return buckets.map((bucket: DailyAggBucket): HistoricalSummary => { + const good = bucket.cumulative_good?.value ?? 0; + const total = bucket.cumulative_total?.value ?? 0; + const sliValue = computeSLI({ good, total }); + const totalSlices = computeTotalSlicesFromDateRange(dateRange, slo.objective.timesliceWindow!); + const consumedErrorBudget = (total - good) / (totalSlices * initialErrorBudget); + const errorBudget = toErrorBudget(initialErrorBudget, consumedErrorBudget); + + return { + date: new Date(bucket.key_as_string), + errorBudget, + sliValue, + status: computeSummaryStatus(slo, sliValue, errorBudget), + }; + }); +} + +function handleResultForRolling(slo: SLO, buckets: DailyAggBucket[]): HistoricalSummary[] { + const initialErrorBudget = 1 - slo.objective.target; + const rollingWindowDurationInDays = moment + .duration(slo.timeWindow.duration.value, toMomentUnitOfTime(slo.timeWindow.duration.unit)) + .asDays(); + + return buckets + .slice(-rollingWindowDurationInDays) + .map((bucket: DailyAggBucket): HistoricalSummary => { + const good = bucket.cumulative_good?.value ?? 0; + const total = bucket.cumulative_total?.value ?? 0; + const sliValue = computeSLI({ good, total }); + const consumedErrorBudget = total === 0 ? 0 : (total - good) / (total * initialErrorBudget); + const errorBudget = toErrorBudget(initialErrorBudget, consumedErrorBudget); + + return { + date: new Date(bucket.key_as_string), + errorBudget, + sliValue, + status: computeSummaryStatus(slo, sliValue, errorBudget), + }; + }); +} + +function generateSearchQuery(slo: SLO, dateRange: DateRange): MsearchMultisearchBody { + const unit = toMomentUnitOfTime(slo.timeWindow.duration.unit); + const timeWindowDurationInDays = moment.duration(slo.timeWindow.duration.value, unit).asDays(); + + return { + size: 0, + query: { + bool: { + filter: [ + { term: { 'slo.id': slo.id } }, + { term: { 'slo.revision': slo.revision } }, + { + range: { + '@timestamp': { + gte: dateRange.from.toISOString(), + lte: dateRange.to.toISOString(), + }, + }, + }, + ], + }, + }, + aggs: { + daily: { + date_histogram: { + field: '@timestamp', + fixed_interval: '1d', + extended_bounds: { + min: dateRange.from.toISOString(), + max: 'now/d', + }, + }, + aggs: { + ...(occurrencesBudgetingMethodSchema.is(slo.budgetingMethod) && { + good: { + sum: { + field: 'slo.numerator', + }, + }, + total: { + sum: { + field: 'slo.denominator', + }, + }, + }), + ...(timeslicesBudgetingMethodSchema.is(slo.budgetingMethod) && { + good: { + sum: { + field: 'slo.isGoodSlice', + }, + }, + total: { + value_count: { + field: 'slo.isGoodSlice', + }, + }, + }), + cumulative_good: { + moving_fn: { + buckets_path: 'good', + window: timeWindowDurationInDays, + shift: 1, + script: 'MovingFunctions.sum(values)', + }, + }, + cumulative_total: { + moving_fn: { + buckets_path: 'total', + window: timeWindowDurationInDays, + shift: 1, + script: 'MovingFunctions.sum(values)', + }, + }, + }, + }, + }, + }; +} + +function getDateRange(slo: SLO) { + const unit = toMomentUnitOfTime(slo.timeWindow.duration.unit); + + if (rollingTimeWindowSchema.is(slo.timeWindow)) { + const now = moment(); + return { + from: now + .clone() + .subtract(slo.timeWindow.duration.value * 2, unit) + .startOf('day') + .toDate(), + to: now.startOf('minute').toDate(), + }; + } + if (calendarAlignedTimeWindowSchema.is(slo.timeWindow)) { + return toDateRange(slo.timeWindow); + } + + assertNever(slo.timeWindow); +} diff --git a/x-pack/plugins/observability/server/services/slo/index.ts b/x-pack/plugins/observability/server/services/slo/index.ts index b47881545e867..a4d186db813f9 100644 --- a/x-pack/plugins/observability/server/services/slo/index.ts +++ b/x-pack/plugins/observability/server/services/slo/index.ts @@ -7,8 +7,10 @@ export * from './create_slo'; export * from './delete_slo'; +export * from './fetch_historical_summary'; export * from './find_slo'; export * from './get_slo'; +export * from './historical_summary_client'; export * from './resource_installer'; export * from './sli_client'; export * from './slo_repository'; diff --git a/x-pack/plugins/observability/server/services/slo/mocks/index.ts b/x-pack/plugins/observability/server/services/slo/mocks/index.ts index 2acce436a2402..5781553f91e05 100644 --- a/x-pack/plugins/observability/server/services/slo/mocks/index.ts +++ b/x-pack/plugins/observability/server/services/slo/mocks/index.ts @@ -29,6 +29,7 @@ const createSLORepositoryMock = (): jest.Mocked => { return { save: jest.fn(), findById: jest.fn(), + findAllByIds: jest.fn(), deleteById: jest.fn(), find: jest.fn(), }; diff --git a/x-pack/plugins/observability/server/services/slo/sli_client.test.ts b/x-pack/plugins/observability/server/services/slo/sli_client.test.ts index 163e239748050..d942cea0335d0 100644 --- a/x-pack/plugins/observability/server/services/slo/sli_client.test.ts +++ b/x-pack/plugins/observability/server/services/slo/sli_client.test.ts @@ -10,7 +10,6 @@ import moment from 'moment'; import { SLO_DESTINATION_INDEX_NAME } from '../../assets/constants'; import { toDateRange } from '../../domain/services'; -import { InternalQueryError } from '../../errors'; import { Duration, DurationUnit } from '../../domain/models'; import { createSLO } from './fixtures/slo'; import { DefaultSLIClient } from './sli_client'; @@ -52,24 +51,6 @@ describe('SLIClient', () => { describe('fetchCurrentSLIData', () => { describe('with occurrences budgeting method', () => { - it('throws when aggregations failed', async () => { - const slo = createSLO({ timeWindow: sevenDaysRolling() }); - esClientMock.msearch.mockResolvedValueOnce({ - ...commonEsResponse, - responses: [ - { - ...commonEsResponse, - aggregations: {}, - }, - ], - }); - const sliClient = new DefaultSLIClient(esClientMock); - - await expect(sliClient.fetchCurrentSLIData([slo])).rejects.toThrowError( - new InternalQueryError('SLI aggregation query') - ); - }); - describe('with a rolling time window', () => { it('returns the aggregated good and total values', async () => { const slo = createSLO({ timeWindow: sevenDaysRolling() }); @@ -158,32 +139,6 @@ describe('SLIClient', () => { }); describe('with timeslices budgeting method', () => { - it('throws when aggregations failed', async () => { - const slo = createSLO({ - budgetingMethod: 'timeslices', - objective: { - target: 0.95, - timesliceTarget: 0.95, - timesliceWindow: new Duration(10, DurationUnit.Minute), - }, - }); - - esClientMock.msearch.mockResolvedValueOnce({ - ...commonEsResponse, - responses: [ - { - ...commonEsResponse, - aggregations: {}, - }, - ], - }); - const sliClient = new DefaultSLIClient(esClientMock); - - await expect(sliClient.fetchCurrentSLIData([slo])).rejects.toThrowError( - new InternalQueryError('SLI aggregation query') - ); - }); - describe('with a calendar aligned time window', () => { it('returns the aggregated good and total values', async () => { const slo = createSLO({ @@ -226,47 +181,14 @@ describe('SLIClient', () => { }, }, aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: '10m', - }, - aggs: { - good: { - sum: { - field: 'slo.numerator', - }, - }, - total: { - sum: { - field: 'slo.denominator', - }, - }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: `params.good / params.total >= ${slo.objective.timesliceTarget} ? 1 : 0`, - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -314,47 +236,14 @@ describe('SLIClient', () => { }, }, aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: '10m', - }, - aggs: { - good: { - sum: { - field: 'slo.numerator', - }, - }, - total: { - sum: { - field: 'slo.denominator', - }, - }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: `params.good / params.total >= ${slo.objective.timesliceTarget} ? 1 : 0`, - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -519,47 +408,14 @@ describe('SLIClient', () => { ranges: [{ from: 'now-1h/m', to: 'now/m' }], }, aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: '10m', - }, - aggs: { - good: { - sum: { - field: 'slo.numerator', - }, - }, - total: { - sum: { - field: 'slo.denominator', - }, - }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: 'params.good / params.total >= 0.9 ? 1 : 0', - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -570,47 +426,14 @@ describe('SLIClient', () => { ranges: [{ from: 'now-5m/m', to: 'now/m' }], }, aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: '10m', - }, - aggs: { - good: { - sum: { - field: 'slo.numerator', - }, - }, - total: { - sum: { - field: 'slo.denominator', - }, - }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: 'params.good / params.total >= 0.9 ? 1 : 0', - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -636,6 +459,7 @@ expect.extend({ }; }, }); + declare global { // eslint-disable-next-line @typescript-eslint/no-namespace namespace jest { diff --git a/x-pack/plugins/observability/server/services/slo/sli_client.ts b/x-pack/plugins/observability/server/services/slo/sli_client.ts index d229d6fb66a6c..6386b101e8207 100644 --- a/x-pack/plugins/observability/server/services/slo/sli_client.ts +++ b/x-pack/plugins/observability/server/services/slo/sli_client.ts @@ -10,7 +10,6 @@ import { AggregationsDateRangeAggregate, AggregationsSumAggregate, MsearchMultisearchBody, - MsearchResponseItem, } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; import { ElasticsearchClient } from '@kbn/core/server'; import { assertNever } from '@kbn/std'; @@ -35,7 +34,6 @@ interface LookbackWindow { duration: Duration; } -type AggKey = 'good' | 'total'; type EsAggregations = Record; export class DefaultSLIClient implements SLIClient { @@ -56,9 +54,7 @@ export class DefaultSLIClient implements SLIClient { return indicatorDataBySlo; } - const result = await this.esClient.msearch>({ - searches, - }); + const result = await this.esClient.msearch({ searches }); for (let i = 0; i < result.responses.length; i++) { const slo = sloList[i]; @@ -68,7 +64,11 @@ export class DefaultSLIClient implements SLIClient { continue; } - indicatorDataBySlo[slo.id] = handleResult(dateRangeBySlo[slo.id], result.responses[i]); + // @ts-ignore + const { aggregations } = result.responses[i]; + const good = aggregations?.good?.value || 0; + const total = aggregations?.total?.value || 0; + indicatorDataBySlo[slo.id] = { dateRange: dateRangeBySlo[slo.id], good, total }; } return indicatorDataBySlo; @@ -126,39 +126,14 @@ function generateSearchQuery(slo: SLO, dateRange: DateRange): MsearchMultisearch return { ...commonQuery(slo, dateRange), aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: toInterval(slo.objective.timesliceWindow), - }, - aggs: { - good: { sum: { field: 'slo.numerator' } }, - total: { sum: { field: 'slo.denominator' } }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: `params.good / params.total >= ${slo.objective.timesliceTarget} ? 1 : 0`, - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -190,22 +165,6 @@ function commonQuery( }; } -function handleResult(dateRange: DateRange, response: MsearchResponseItem): IndicatorData { - // @ts-ignore - const { aggregations } = response; - const good = aggregations?.good; - const total = aggregations?.total; - if (good === undefined || good.value === null || total === undefined || total.value === null) { - throw new InternalQueryError('SLI aggregation query'); - } - - return { - dateRange, - good: good.value, - total: total.value, - }; -} - function toLookbackWindowsAggregationsQuery(sortedLookbackWindow: LookbackWindow[]) { return sortedLookbackWindow.reduce>( (acc, lookbackWindow) => ({ @@ -240,47 +199,14 @@ function toLookbackWindowsSlicedAggregationsQuery(slo: SLO, lookbackWindows: Loo ], }, aggs: { - slices: { - date_histogram: { - field: '@timestamp', - fixed_interval: toInterval(slo.objective.timesliceWindow), - }, - aggs: { - good: { - sum: { - field: 'slo.numerator', - }, - }, - total: { - sum: { - field: 'slo.denominator', - }, - }, - good_slice: { - bucket_script: { - buckets_path: { - good: 'good', - total: 'total', - }, - script: `params.good / params.total >= ${slo.objective.timesliceTarget} ? 1 : 0`, - }, - }, - count_slice: { - bucket_script: { - buckets_path: {}, - script: '1', - }, - }, - }, - }, good: { - sum_bucket: { - buckets_path: 'slices>good_slice.value', + sum: { + field: 'slo.isGoodSlice', }, }, total: { - sum_bucket: { - buckets_path: 'slices>count_slice.value', + value_count: { + field: 'slo.isGoodSlice', }, }, }, @@ -320,9 +246,3 @@ function handleWindowedResult( return indicatorDataPerLookbackWindow; } - -function toInterval(duration: Duration | undefined): string { - if (duration === undefined) return '1m'; - - return duration.format(); -} diff --git a/x-pack/plugins/observability/server/services/slo/slo_repository.test.ts b/x-pack/plugins/observability/server/services/slo/slo_repository.test.ts index f93590f82d8a3..238c6dbc5dac0 100644 --- a/x-pack/plugins/observability/server/services/slo/slo_repository.test.ts +++ b/x-pack/plugins/observability/server/services/slo/slo_repository.test.ts @@ -26,21 +26,20 @@ import { createAPMTransactionDurationIndicator, createSLO, aStoredSLO } from './ import { SLONotFound } from '../../errors'; const SOME_SLO = createSLO({ indicator: createAPMTransactionDurationIndicator() }); +const ANOTHER_SLO = createSLO(); -function aFindResponse(slo: SLO): SavedObjectsFindResponse { +function createFindResponse(sloList: SLO[]): SavedObjectsFindResponse { return { page: 1, per_page: 25, - total: 1, - saved_objects: [ - { - id: slo.id, - attributes: sloSchema.encode(slo), - type: SO_SLO_TYPE, - references: [], - score: 1, - }, - ], + total: sloList.length, + saved_objects: sloList.map((slo) => ({ + id: slo.id, + attributes: sloSchema.encode(slo), + type: SO_SLO_TYPE, + references: [], + score: 1, + })), }; } @@ -96,6 +95,21 @@ describe('KibanaSavedObjectsSLORepository', () => { expect(soClientMock.get).toHaveBeenCalledWith(SO_SLO_TYPE, SOME_SLO.id); }); + it('finds all SLOs by ids', async () => { + const repository = new KibanaSavedObjectsSLORepository(soClientMock); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO, ANOTHER_SLO])); + + const results = await repository.findAllByIds([SOME_SLO.id, ANOTHER_SLO.id]); + + expect(results).toEqual([SOME_SLO, ANOTHER_SLO]); + expect(soClientMock.find).toHaveBeenCalledWith({ + type: SO_SLO_TYPE, + page: 1, + perPage: 2, + filter: `slo.attributes.id:(${SOME_SLO.id} or ${ANOTHER_SLO.id})`, + }); + }); + it('deletes an SLO', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); @@ -114,7 +128,7 @@ describe('KibanaSavedObjectsSLORepository', () => { describe('Name filter', () => { it('includes the filter on name with wildcard when provided', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find( { name: 'availability*' }, @@ -140,7 +154,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('includes the filter on name with added wildcard when not provided', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find( { name: 'availa' }, @@ -168,7 +182,7 @@ describe('KibanaSavedObjectsSLORepository', () => { describe('indicatorTypes filter', () => { it('includes the filter on indicator types when provided', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find( { indicatorTypes: ['sli.kql.custom'] }, @@ -194,7 +208,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('includes the filter on indicator types as logical OR when provided', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find( { indicatorTypes: ['sli.kql.custom', 'sli.apm.transactionDuration'] }, @@ -221,7 +235,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('includes filter on name and indicator types', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find( { name: 'latency', indicatorTypes: ['sli.kql.custom', 'sli.apm.transactionDuration'] }, @@ -247,7 +261,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('does not include the filter when no criteria provided', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); const result = await repository.find({}, DEFAULT_SORTING, DEFAULT_PAGINATION); @@ -268,7 +282,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('sorts by name ascending', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); await repository.find({}, DEFAULT_SORTING, DEFAULT_PAGINATION); @@ -283,7 +297,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('sorts by name descending', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); await repository.find( {}, @@ -302,7 +316,7 @@ describe('KibanaSavedObjectsSLORepository', () => { it('sorts by indicator type', async () => { const repository = new KibanaSavedObjectsSLORepository(soClientMock); - soClientMock.find.mockResolvedValueOnce(aFindResponse(SOME_SLO)); + soClientMock.find.mockResolvedValueOnce(createFindResponse([SOME_SLO])); await repository.find( {}, diff --git a/x-pack/plugins/observability/server/services/slo/slo_repository.ts b/x-pack/plugins/observability/server/services/slo/slo_repository.ts index d9463f808000c..ac639bd383a2f 100644 --- a/x-pack/plugins/observability/server/services/slo/slo_repository.ts +++ b/x-pack/plugins/observability/server/services/slo/slo_repository.ts @@ -57,6 +57,7 @@ export interface Paginated { export interface SLORepository { save(slo: SLO): Promise; + findAllByIds(ids: string[]): Promise; findById(id: string): Promise; deleteById(id: string): Promise; find(criteria: Criteria, sort: Sort, pagination: Pagination): Promise>; @@ -116,6 +117,25 @@ export class KibanaSavedObjectsSLORepository implements SLORepository { results: response.saved_objects.map((slo) => toSLO(slo.attributes)), }; } + + async findAllByIds(ids: string[]): Promise { + if (ids.length === 0) return []; + + try { + const response = await this.soClient.find({ + type: SO_SLO_TYPE, + page: 1, + perPage: ids.length, + filter: `slo.attributes.id:(${ids.join(' or ')})`, + }); + return response.saved_objects.map((slo) => toSLO(slo.attributes)); + } catch (err) { + if (SavedObjectsErrorHelpers.isNotFoundError(err)) { + throw new SLONotFound(`SLOs [${ids.join(',')}] not found`); + } + throw err; + } + } } function buildFilterKuery(criteria: Criteria): string | undefined { diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_duration.test.ts.snap b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_duration.test.ts.snap index 3b30834d985c9..3802416f29ff5 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_duration.test.ts.snap +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_duration.test.ts.snap @@ -21,7 +21,194 @@ Object { } `; -exports[`APM Transaction Duration Transform Generator returns the correct transform params with every specified indicator params 1`] = ` +exports[`APM Transaction Duration Transform Generator returns the expected transform params for timeslices slo 1`] = ` +Object { + "_meta": Object { + "version": 1, + }, + "dest": Object { + "index": "slo-observability.sli-v1", + "pipeline": "slo-observability.sli.monthly", + }, + "frequency": "1m", + "pivot": Object { + "aggregations": Object { + "_numerator": Object { + "range": Object { + "field": "transaction.duration.histogram", + "ranges": Array [ + Object { + "to": 500000, + }, + ], + }, + }, + "slo.denominator": Object { + "value_count": Object { + "field": "transaction.duration.histogram", + }, + }, + "slo.isGoodSlice": Object { + "bucket_script": Object { + "buckets_path": Object { + "goodEvents": "slo.numerator.value", + "totalEvents": "slo.denominator.value", + }, + "script": "params.goodEvents / params.totalEvents >= 0.95 ? 1 : 0", + }, + }, + "slo.numerator": Object { + "bucket_script": Object { + "buckets_path": Object { + "numerator": "_numerator['*-500000.0']>_count", + }, + "script": "params.numerator", + }, + }, + }, + "group_by": Object { + "@timestamp": Object { + "date_histogram": Object { + "field": "@timestamp", + "fixed_interval": "2m", + }, + }, + "slo._internal.budgeting_method": Object { + "terms": Object { + "field": "slo._internal.budgeting_method", + }, + }, + "slo._internal.name": Object { + "terms": Object { + "field": "slo._internal.name", + }, + }, + "slo._internal.objective.target": Object { + "terms": Object { + "field": "slo._internal.objective.target", + }, + }, + "slo._internal.time_window.duration": Object { + "terms": Object { + "field": "slo._internal.time_window.duration", + }, + }, + "slo._internal.time_window.is_rolling": Object { + "terms": Object { + "field": "slo._internal.time_window.is_rolling", + }, + }, + "slo.id": Object { + "terms": Object { + "field": "slo.id", + }, + }, + "slo.revision": Object { + "terms": Object { + "field": "slo.revision", + }, + }, + }, + }, + "settings": Object { + "deduce_mappings": false, + }, + "source": Object { + "index": "metrics-apm*", + "query": Object { + "bool": Object { + "filter": Array [ + Object { + "match": Object { + "transaction.root": true, + }, + }, + Object { + "range": Object { + "@timestamp": Object { + "gte": "now-7d", + }, + }, + }, + Object { + "match": Object { + "service.name": "irrelevant", + }, + }, + Object { + "match": Object { + "service.environment": "irrelevant", + }, + }, + Object { + "match": Object { + "transaction.name": "irrelevant", + }, + }, + Object { + "match": Object { + "transaction.type": "irrelevant", + }, + }, + ], + }, + }, + "runtime_mappings": Object { + "slo._internal.budgeting_method": Object { + "script": Object { + "source": "emit('timeslices')", + }, + "type": "keyword", + }, + "slo._internal.name": Object { + "script": Object { + "source": "emit('irrelevant')", + }, + "type": "keyword", + }, + "slo._internal.objective.target": Object { + "script": Object { + "source": "emit(0.98)", + }, + "type": "double", + }, + "slo._internal.time_window.duration": Object { + "script": Object { + "source": "emit('7d')", + }, + "type": "keyword", + }, + "slo._internal.time_window.is_rolling": Object { + "script": Object { + "source": "emit(true)", + }, + "type": "boolean", + }, + "slo.id": Object { + "script": Object { + "source": Any, + }, + "type": "keyword", + }, + "slo.revision": Object { + "script": Object { + "source": "emit(1)", + }, + "type": "long", + }, + }, + }, + "sync": Object { + "time": Object { + "delay": "1m", + "field": "@timestamp", + }, + }, + "transform_id": Any, +} +`; + +exports[`APM Transaction Duration Transform Generator returns the expected transform params with every specified indicator params 1`] = ` Object { "_meta": Object { "version": 1, @@ -60,8 +247,8 @@ Object { "group_by": Object { "@timestamp": Object { "date_histogram": Object { - "calendar_interval": "1m", "field": "@timestamp", + "fixed_interval": "1m", }, }, "slo._internal.budgeting_method": Object { diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_error_rate.test.ts.snap b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_error_rate.test.ts.snap index acd7770c32746..3a87b3031fdc0 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_error_rate.test.ts.snap +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/apm_transaction_error_rate.test.ts.snap @@ -21,7 +21,199 @@ Object { } `; -exports[`APM Transaction Error Rate Transform Generator returns the correct transform params with every specified indicator params 1`] = ` +exports[`APM Transaction Error Rate Transform Generator returns the expected transform params for timeslices slo 1`] = ` +Object { + "_meta": Object { + "version": 1, + }, + "dest": Object { + "index": "slo-observability.sli-v1", + "pipeline": "slo-observability.sli.monthly", + }, + "frequency": "1m", + "pivot": Object { + "aggregations": Object { + "slo.denominator": Object { + "value_count": Object { + "field": "transaction.duration.histogram", + }, + }, + "slo.isGoodSlice": Object { + "bucket_script": Object { + "buckets_path": Object { + "goodEvents": "slo.numerator>_count", + "totalEvents": "slo.denominator.value", + }, + "script": "params.goodEvents / params.totalEvents >= 0.95 ? 1 : 0", + }, + }, + "slo.numerator": Object { + "filter": Object { + "bool": Object { + "should": Array [ + Object { + "match": Object { + "transaction.result": "HTTP 2xx", + }, + }, + Object { + "match": Object { + "transaction.result": "HTTP 3xx", + }, + }, + Object { + "match": Object { + "transaction.result": "HTTP 4xx", + }, + }, + ], + }, + }, + }, + }, + "group_by": Object { + "@timestamp": Object { + "date_histogram": Object { + "field": "@timestamp", + "fixed_interval": "2m", + }, + }, + "slo._internal.budgeting_method": Object { + "terms": Object { + "field": "slo._internal.budgeting_method", + }, + }, + "slo._internal.name": Object { + "terms": Object { + "field": "slo._internal.name", + }, + }, + "slo._internal.objective.target": Object { + "terms": Object { + "field": "slo._internal.objective.target", + }, + }, + "slo._internal.time_window.duration": Object { + "terms": Object { + "field": "slo._internal.time_window.duration", + }, + }, + "slo._internal.time_window.is_rolling": Object { + "terms": Object { + "field": "slo._internal.time_window.is_rolling", + }, + }, + "slo.id": Object { + "terms": Object { + "field": "slo.id", + }, + }, + "slo.revision": Object { + "terms": Object { + "field": "slo.revision", + }, + }, + }, + }, + "settings": Object { + "deduce_mappings": false, + }, + "source": Object { + "index": "metrics-apm*", + "query": Object { + "bool": Object { + "filter": Array [ + Object { + "match": Object { + "transaction.root": true, + }, + }, + Object { + "range": Object { + "@timestamp": Object { + "gte": "now-7d", + }, + }, + }, + Object { + "match": Object { + "service.name": "irrelevant", + }, + }, + Object { + "match": Object { + "service.environment": "irrelevant", + }, + }, + Object { + "match": Object { + "transaction.name": "irrelevant", + }, + }, + Object { + "match": Object { + "transaction.type": "irrelevant", + }, + }, + ], + }, + }, + "runtime_mappings": Object { + "slo._internal.budgeting_method": Object { + "script": Object { + "source": "emit('timeslices')", + }, + "type": "keyword", + }, + "slo._internal.name": Object { + "script": Object { + "source": "emit('irrelevant')", + }, + "type": "keyword", + }, + "slo._internal.objective.target": Object { + "script": Object { + "source": "emit(0.98)", + }, + "type": "double", + }, + "slo._internal.time_window.duration": Object { + "script": Object { + "source": "emit('7d')", + }, + "type": "keyword", + }, + "slo._internal.time_window.is_rolling": Object { + "script": Object { + "source": "emit(true)", + }, + "type": "boolean", + }, + "slo.id": Object { + "script": Object { + "source": Any, + }, + "type": "keyword", + }, + "slo.revision": Object { + "script": Object { + "source": "emit(1)", + }, + "type": "long", + }, + }, + }, + "sync": Object { + "time": Object { + "delay": "1m", + "field": "@timestamp", + }, + }, + "transform_id": Any, +} +`; + +exports[`APM Transaction Error Rate Transform Generator returns the expected transform params with every specified indicator params 1`] = ` Object { "_meta": Object { "version": 1, @@ -65,8 +257,8 @@ Object { "group_by": Object { "@timestamp": Object { "date_histogram": Object { - "calendar_interval": "1m", "field": "@timestamp", + "fixed_interval": "1m", }, }, "slo._internal.budgeting_method": Object { diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/kql_custom.test.ts.snap b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/kql_custom.test.ts.snap index 1aa05dfb2cf3b..f984620b8eefb 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/kql_custom.test.ts.snap +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/__snapshots__/kql_custom.test.ts.snap @@ -100,7 +100,166 @@ Object { } `; -exports[`KQL Custom Transform Generator returns the correct transform params with every specified indicator params 1`] = ` +exports[`KQL Custom Transform Generator returns the expected transform params for timeslices slo 1`] = ` +Object { + "_meta": Object { + "version": 1, + }, + "dest": Object { + "index": "slo-observability.sli-v1", + "pipeline": "slo-observability.sli.monthly", + }, + "frequency": "1m", + "pivot": Object { + "aggregations": Object { + "slo.denominator": Object { + "filter": Object { + "match_all": Object {}, + }, + }, + "slo.isGoodSlice": Object { + "bucket_script": Object { + "buckets_path": Object { + "goodEvents": "slo.numerator>_count", + "totalEvents": "slo.denominator>_count", + }, + "script": "params.goodEvents / params.totalEvents >= 0.95 ? 1 : 0", + }, + }, + "slo.numerator": Object { + "filter": Object { + "bool": Object { + "minimum_should_match": 1, + "should": Array [ + Object { + "range": Object { + "latency": Object { + "lt": "300", + }, + }, + }, + ], + }, + }, + }, + }, + "group_by": Object { + "@timestamp": Object { + "date_histogram": Object { + "field": "@timestamp", + "fixed_interval": "2m", + }, + }, + "slo._internal.budgeting_method": Object { + "terms": Object { + "field": "slo._internal.budgeting_method", + }, + }, + "slo._internal.name": Object { + "terms": Object { + "field": "slo._internal.name", + }, + }, + "slo._internal.objective.target": Object { + "terms": Object { + "field": "slo._internal.objective.target", + }, + }, + "slo._internal.time_window.duration": Object { + "terms": Object { + "field": "slo._internal.time_window.duration", + }, + }, + "slo._internal.time_window.is_rolling": Object { + "terms": Object { + "field": "slo._internal.time_window.is_rolling", + }, + }, + "slo.id": Object { + "terms": Object { + "field": "slo.id", + }, + }, + "slo.revision": Object { + "terms": Object { + "field": "slo.revision", + }, + }, + }, + }, + "settings": Object { + "deduce_mappings": false, + }, + "source": Object { + "index": "my-index*", + "query": Object { + "bool": Object { + "minimum_should_match": 1, + "should": Array [ + Object { + "match": Object { + "labels.groupId": "group-3", + }, + }, + ], + }, + }, + "runtime_mappings": Object { + "slo._internal.budgeting_method": Object { + "script": Object { + "source": "emit('timeslices')", + }, + "type": "keyword", + }, + "slo._internal.name": Object { + "script": Object { + "source": "emit('irrelevant')", + }, + "type": "keyword", + }, + "slo._internal.objective.target": Object { + "script": Object { + "source": "emit(0.98)", + }, + "type": "double", + }, + "slo._internal.time_window.duration": Object { + "script": Object { + "source": "emit('7d')", + }, + "type": "keyword", + }, + "slo._internal.time_window.is_rolling": Object { + "script": Object { + "source": "emit(true)", + }, + "type": "boolean", + }, + "slo.id": Object { + "script": Object { + "source": Any, + }, + "type": "keyword", + }, + "slo.revision": Object { + "script": Object { + "source": "emit(1)", + }, + "type": "long", + }, + }, + }, + "sync": Object { + "time": Object { + "delay": "1m", + "field": "@timestamp", + }, + }, + "transform_id": Any, +} +`; + +exports[`KQL Custom Transform Generator returns the expected transform params with every specified indicator params 1`] = ` Object { "_meta": Object { "version": 1, @@ -137,8 +296,8 @@ Object { "group_by": Object { "@timestamp": Object { "date_histogram": Object { - "calendar_interval": "1m", "field": "@timestamp", + "fixed_interval": "1m", }, }, "slo._internal.budgeting_method": Object { diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.test.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.test.ts index a1fb9476d1882..16a788888cc09 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.test.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.test.ts @@ -5,13 +5,17 @@ * 2.0. */ -import { createAPMTransactionDurationIndicator, createSLO } from '../fixtures/slo'; +import { + createAPMTransactionDurationIndicator, + createSLO, + createSLOWithTimeslicesBudgetingMethod, +} from '../fixtures/slo'; import { ApmTransactionDurationTransformGenerator } from './apm_transaction_duration'; const generator = new ApmTransactionDurationTransformGenerator(); describe('APM Transaction Duration Transform Generator', () => { - it('returns the correct transform params with every specified indicator params', async () => { + it('returns the expected transform params with every specified indicator params', async () => { const anSLO = createSLO({ indicator: createAPMTransactionDurationIndicator() }); const transform = generator.getTransformParams(anSLO); @@ -28,6 +32,18 @@ describe('APM Transaction Duration Transform Generator', () => { }); }); + it('returns the expected transform params for timeslices slo', async () => { + const anSLO = createSLOWithTimeslicesBudgetingMethod({ + indicator: createAPMTransactionDurationIndicator(), + }); + const transform = generator.getTransformParams(anSLO); + + expect(transform).toMatchSnapshot({ + transform_id: expect.any(String), + source: { runtime_mappings: { 'slo.id': { script: { source: expect.any(String) } } } }, + }); + }); + it("does not include the query filter when params are '*'", async () => { const anSLO = createSLO({ indicator: createAPMTransactionDurationIndicator({ diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.ts index 4f06315c4c2d8..89e8b962d61af 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_duration.ts @@ -6,7 +6,11 @@ */ import { TransformPutTransformRequest } from '@elastic/elasticsearch/lib/api/types'; -import { ALL_VALUE, apmTransactionDurationIndicatorSchema } from '@kbn/slo-schema'; +import { + ALL_VALUE, + apmTransactionDurationIndicatorSchema, + timeslicesBudgetingMethodSchema, +} from '@kbn/slo-schema'; import { InvalidTransformError } from '../../../errors'; import { SLO_DESTINATION_INDEX_NAME, @@ -30,7 +34,7 @@ export class ApmTransactionDurationTransformGenerator extends TransformGenerator this.buildSource(slo, slo.indicator), this.buildDestination(), this.buildCommonGroupBy(slo), - this.buildAggregations(slo.indicator), + this.buildAggregations(slo, slo.indicator), this.buildSettings(slo) ); } @@ -106,7 +110,7 @@ export class ApmTransactionDurationTransformGenerator extends TransformGenerator }; } - private buildAggregations(indicator: APMTransactionDurationIndicator) { + private buildAggregations(slo: SLO, indicator: APMTransactionDurationIndicator) { const truncatedThreshold = Math.trunc(indicator.params['threshold.us']); return { @@ -133,6 +137,17 @@ export class ApmTransactionDurationTransformGenerator extends TransformGenerator field: 'transaction.duration.histogram', }, }, + ...(timeslicesBudgetingMethodSchema.is(slo.budgetingMethod) && { + 'slo.isGoodSlice': { + bucket_script: { + buckets_path: { + goodEvents: 'slo.numerator.value', + totalEvents: 'slo.denominator.value', + }, + script: `params.goodEvents / params.totalEvents >= ${slo.objective.timesliceTarget} ? 1 : 0`, + }, + }, + }), }; } } diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.test.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.test.ts index 2998c09efe84e..1763cff5fab6d 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.test.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.test.ts @@ -5,13 +5,17 @@ * 2.0. */ -import { createAPMTransactionErrorRateIndicator, createSLO } from '../fixtures/slo'; +import { + createAPMTransactionErrorRateIndicator, + createSLO, + createSLOWithTimeslicesBudgetingMethod, +} from '../fixtures/slo'; import { ApmTransactionErrorRateTransformGenerator } from './apm_transaction_error_rate'; const generator = new ApmTransactionErrorRateTransformGenerator(); describe('APM Transaction Error Rate Transform Generator', () => { - it('returns the correct transform params with every specified indicator params', async () => { + it('returns the expected transform params with every specified indicator params', async () => { const anSLO = createSLO({ indicator: createAPMTransactionErrorRateIndicator() }); const transform = generator.getTransformParams(anSLO); @@ -28,6 +32,18 @@ describe('APM Transaction Error Rate Transform Generator', () => { }); }); + it('returns the expected transform params for timeslices slo', async () => { + const anSLO = createSLOWithTimeslicesBudgetingMethod({ + indicator: createAPMTransactionErrorRateIndicator(), + }); + const transform = generator.getTransformParams(anSLO); + + expect(transform).toMatchSnapshot({ + transform_id: expect.any(String), + source: { runtime_mappings: { 'slo.id': { script: { source: expect.any(String) } } } }, + }); + }); + it("uses default values when 'good_status_codes' is not specified", async () => { const anSLO = createSLO({ indicator: createAPMTransactionErrorRateIndicator({ goodStatusCodes: [] }), diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.ts index 18cb0cd60298a..8adcbcdfc9622 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/apm_transaction_error_rate.ts @@ -6,7 +6,11 @@ */ import { TransformPutTransformRequest } from '@elastic/elasticsearch/lib/api/types'; -import { ALL_VALUE, apmTransactionErrorRateIndicatorSchema } from '@kbn/slo-schema'; +import { + ALL_VALUE, + apmTransactionErrorRateIndicatorSchema, + timeslicesBudgetingMethodSchema, +} from '@kbn/slo-schema'; import { InvalidTransformError } from '../../../errors'; import { getSLOTransformTemplate } from '../../../assets/transform_templates/slo_transform_template'; @@ -127,6 +131,17 @@ export class ApmTransactionErrorRateTransformGenerator extends TransformGenerato field: 'transaction.duration.histogram', }, }, + ...(timeslicesBudgetingMethodSchema.is(slo.budgetingMethod) && { + 'slo.isGoodSlice': { + bucket_script: { + buckets_path: { + goodEvents: 'slo.numerator>_count', + totalEvents: 'slo.denominator.value', + }, + script: `params.goodEvents / params.totalEvents >= ${slo.objective.timesliceTarget} ? 1 : 0`, + }, + }, + }), }; } diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.test.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.test.ts index 5056cd3562657..df27929b5bf6b 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.test.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.test.ts @@ -5,7 +5,11 @@ * 2.0. */ -import { createKQLCustomIndicator, createSLO } from '../fixtures/slo'; +import { + createKQLCustomIndicator, + createSLO, + createSLOWithTimeslicesBudgetingMethod, +} from '../fixtures/slo'; import { KQLCustomTransformGenerator } from './kql_custom'; const generator = new KQLCustomTransformGenerator(); @@ -32,7 +36,7 @@ describe('KQL Custom Transform Generator', () => { }); }); - it('returns the correct transform params with every specified indicator params', async () => { + it('returns the expected transform params with every specified indicator params', async () => { const anSLO = createSLO({ indicator: createKQLCustomIndicator() }); const transform = generator.getTransformParams(anSLO); @@ -49,6 +53,18 @@ describe('KQL Custom Transform Generator', () => { }); }); + it('returns the expected transform params for timeslices slo', async () => { + const anSLO = createSLOWithTimeslicesBudgetingMethod({ + indicator: createKQLCustomIndicator(), + }); + const transform = generator.getTransformParams(anSLO); + + expect(transform).toMatchSnapshot({ + transform_id: expect.any(String), + source: { runtime_mappings: { 'slo.id': { script: { source: expect.any(String) } } } }, + }); + }); + it('filters the source using the kql query', async () => { const anSLO = createSLO({ indicator: createKQLCustomIndicator({ filter: 'labels.groupId: group-4' }), diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.ts index 1b776a552fbe9..2b69c02e9d2c5 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/kql_custom.ts @@ -7,7 +7,7 @@ import { TransformPutTransformRequest } from '@elastic/elasticsearch/lib/api/types'; import { fromKueryExpression, toElasticsearchQuery } from '@kbn/es-query'; -import { kqlCustomIndicatorSchema } from '@kbn/slo-schema'; +import { kqlCustomIndicatorSchema, timeslicesBudgetingMethodSchema } from '@kbn/slo-schema'; import { InvalidTransformError } from '../../../errors'; import { getSLOTransformTemplate } from '../../../assets/transform_templates/slo_transform_template'; @@ -58,6 +58,7 @@ export class KQLCustomTransformGenerator extends TransformGenerator { private buildAggregations(slo: SLO, indicator: KQLCustomIndicator) { const numerator = getElastichsearchQueryOrThrow(indicator.params.good); const denominator = getElastichsearchQueryOrThrow(indicator.params.total); + return { 'slo.numerator': { filter: numerator, @@ -65,6 +66,17 @@ export class KQLCustomTransformGenerator extends TransformGenerator { 'slo.denominator': { filter: denominator, }, + ...(timeslicesBudgetingMethodSchema.is(slo.budgetingMethod) && { + 'slo.isGoodSlice': { + bucket_script: { + buckets_path: { + goodEvents: 'slo.numerator>_count', + totalEvents: 'slo.denominator>_count', + }, + script: `params.goodEvents / params.totalEvents >= ${slo.objective.timesliceTarget} ? 1 : 0`, + }, + }, + }), }; } } diff --git a/x-pack/plugins/observability/server/services/slo/transform_generators/transform_generator.ts b/x-pack/plugins/observability/server/services/slo/transform_generators/transform_generator.ts index 1e009ea874b35..a62c81b165dbe 100644 --- a/x-pack/plugins/observability/server/services/slo/transform_generators/transform_generator.ts +++ b/x-pack/plugins/observability/server/services/slo/transform_generators/transform_generator.ts @@ -6,11 +6,8 @@ */ import { MappingRuntimeFieldType } from '@elastic/elasticsearch/lib/api/types'; -import { - AggregationsCalendarInterval, - TransformPutTransformRequest, -} from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; -import { calendarAlignedTimeWindowSchema } from '@kbn/slo-schema'; +import { TransformPutTransformRequest } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; +import { calendarAlignedTimeWindowSchema, timeslicesBudgetingMethodSchema } from '@kbn/slo-schema'; import { TransformSettings } from '../../../assets/transform_templates/slo_transform_template'; import { SLO } from '../../../domain/models'; @@ -66,6 +63,11 @@ export abstract class TransformGenerator { } public buildCommonGroupBy(slo: SLO) { + let fixedInterval = '1m'; + if (timeslicesBudgetingMethodSchema.is(slo.budgetingMethod)) { + fixedInterval = slo.objective.timesliceWindow!.format(); + } + return { 'slo.id': { terms: { @@ -106,7 +108,7 @@ export abstract class TransformGenerator { '@timestamp': { date_histogram: { field: slo.settings.timestampField, - calendar_interval: '1m' as AggregationsCalendarInterval, + fixed_interval: fixedInterval, }, }, }; diff --git a/x-pack/plugins/observability/server/services/slo/update_slo.test.ts b/x-pack/plugins/observability/server/services/slo/update_slo.test.ts index 166ed2a319c77..a100ece244b19 100644 --- a/x-pack/plugins/observability/server/services/slo/update_slo.test.ts +++ b/x-pack/plugins/observability/server/services/slo/update_slo.test.ts @@ -7,9 +7,15 @@ import { ElasticsearchClient } from '@kbn/core/server'; import { elasticsearchServiceMock } from '@kbn/core/server/mocks'; + import { getSLOTransformId } from '../../assets/constants'; import { SLO } from '../../domain/models'; -import { createAPMTransactionErrorRateIndicator, createSLO } from './fixtures/slo'; +import { fiveMinute, oneMinute } from './fixtures/duration'; +import { + createAPMTransactionErrorRateIndicator, + createSLO, + createSLOWithTimeslicesBudgetingMethod, +} from './fixtures/slo'; import { createSLORepositoryMock, createTransformManagerMock } from './mocks'; import { SLORepository } from './slo_repository'; import { TransformManager } from './transform_manager'; @@ -67,6 +73,55 @@ describe('UpdateSLO', () => { expectInstallationOfNewSLOTransform(); }); + it('consideres a budgeting method change as a breaking change', async () => { + const slo = createSLO({ budgetingMethod: 'occurrences' }); + mockRepository.findById.mockResolvedValueOnce(slo); + + await updateSLO.execute(slo.id, { + budgetingMethod: 'timeslices', + objective: { + target: slo.objective.target, + timesliceTarget: 0.9, + timesliceWindow: oneMinute(), + }, + }); + + expectDeletionOfObsoleteSLOData(slo); + expectInstallationOfNewSLOTransform(); + }); + + it('consideres a timeslice target change as a breaking change', async () => { + const slo = createSLOWithTimeslicesBudgetingMethod(); + mockRepository.findById.mockResolvedValueOnce(slo); + + await updateSLO.execute(slo.id, { + objective: { + target: slo.objective.target, + timesliceTarget: 0.1, + timesliceWindow: slo.objective.timesliceWindow, + }, + }); + + expectDeletionOfObsoleteSLOData(slo); + expectInstallationOfNewSLOTransform(); + }); + + it('consideres a timeslice window change as a breaking change', async () => { + const slo = createSLOWithTimeslicesBudgetingMethod(); + mockRepository.findById.mockResolvedValueOnce(slo); + + await updateSLO.execute(slo.id, { + objective: { + target: slo.objective.target, + timesliceTarget: slo.objective.timesliceTarget, + timesliceWindow: fiveMinute(), + }, + }); + + expectDeletionOfObsoleteSLOData(slo); + expectInstallationOfNewSLOTransform(); + }); + it('removes the obsolete data from the SLO previous revision', async () => { const slo = createSLO({ indicator: createAPMTransactionErrorRateIndicator({ environment: 'development' }), diff --git a/x-pack/plugins/observability/server/services/slo/update_slo.ts b/x-pack/plugins/observability/server/services/slo/update_slo.ts index 02b3055fb0bf1..9f03b12137ccb 100644 --- a/x-pack/plugins/observability/server/services/slo/update_slo.ts +++ b/x-pack/plugins/observability/server/services/slo/update_slo.ts @@ -49,6 +49,19 @@ export class UpdateSLO { hasBreakingChange = true; } + if (originalSlo.budgetingMethod !== updatedSlo.budgetingMethod) { + hasBreakingChange = true; + } + + if ( + originalSlo.budgetingMethod === 'timeslices' && + updatedSlo.budgetingMethod === 'timeslices' && + (originalSlo.objective.timesliceTarget !== updatedSlo.objective.timesliceTarget || + !deepEqual(originalSlo.objective.timesliceWindow, updatedSlo.objective.timesliceWindow)) + ) { + hasBreakingChange = true; + } + if (!deepEqual(originalSlo.settings, updatedSlo.settings)) { hasBreakingChange = true; } diff --git a/x-pack/plugins/observability/tsconfig.json b/x-pack/plugins/observability/tsconfig.json index dbb01d971f9a3..9a2dc1ab3016c 100644 --- a/x-pack/plugins/observability/tsconfig.json +++ b/x-pack/plugins/observability/tsconfig.json @@ -67,7 +67,8 @@ "@kbn/share-plugin", "@kbn/core-notifications-browser", "@kbn/slo-schema", - "@kbn/core-http-server-internal", + "@kbn/guided-onboarding", + "@kbn/charts-plugin", ], "exclude": [ "target/**/*", diff --git a/x-pack/plugins/osquery/common/schemas/types/default_uuid.ts b/x-pack/plugins/osquery/common/schemas/types/default_uuid.ts index f19884aca0d25..1b686ed58d06f 100644 --- a/x-pack/plugins/osquery/common/schemas/types/default_uuid.ts +++ b/x-pack/plugins/osquery/common/schemas/types/default_uuid.ts @@ -7,19 +7,19 @@ import * as t from 'io-ts'; import type { Either } from 'fp-ts/lib/Either'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { NonEmptyString } from './non_empty_string'; /** * Types the DefaultUuid as: - * - If null or undefined, then a default string uuid.v4() will be + * - If null or undefined, then a default string uuidv4() will be * created otherwise it will be checked just against an empty string */ export const DefaultUuid = new t.Type( 'DefaultUuid', t.string.is, (input, context): Either => - input == null ? t.success(uuid.v4()) : NonEmptyString.validate(input, context), + input == null ? t.success(uuidv4()) : NonEmptyString.validate(input, context), t.identity ); diff --git a/x-pack/plugins/osquery/public/agents/agent_grouper.test.ts b/x-pack/plugins/osquery/public/agents/agent_grouper.test.ts index 337d1b98fa4ba..802282d5da8e6 100644 --- a/x-pack/plugins/osquery/public/agents/agent_grouper.test.ts +++ b/x-pack/plugins/osquery/public/agents/agent_grouper.test.ts @@ -8,7 +8,7 @@ import { AgentGrouper } from './agent_grouper'; import type { Group, GroupedAgent, GroupOptionValue } from './types'; import { AGENT_GROUP_KEY } from './types'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ALL_AGENTS_LABEL } from './translations'; type GroupData = { @@ -17,7 +17,7 @@ type GroupData = { export function genGroup(name: string) { return { name, - id: uuid.v4(), + id: uuidv4(), size: 5, }; } @@ -119,10 +119,10 @@ describe('AgentGrouper', () => { describe('agents', () => { it('should generate agent options', () => { const agentGrouper = new AgentGrouper(); - const policyId = uuid.v4(); + const policyId = uuidv4(); const agentData: GroupedAgent[] = [ - genAgent(policyId, `agent host 1`, uuid.v4()), - genAgent(policyId, `agent host 2`, uuid.v4()), + genAgent(policyId, `agent host 1`, uuidv4()), + genAgent(policyId, `agent host 2`, uuidv4()), ]; agentGrouper.updateGroup(AGENT_GROUP_KEY.Agent, agentData); diff --git a/x-pack/plugins/osquery/public/agents/helpers.test.ts b/x-pack/plugins/osquery/public/agents/helpers.test.ts index 610810082ccc1..c69805b6f0dd7 100644 --- a/x-pack/plugins/osquery/public/agents/helpers.test.ts +++ b/x-pack/plugins/osquery/public/agents/helpers.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { generateGroupOption } from './agent_grouper'; import { getNumOverlapped, @@ -37,13 +37,13 @@ describe('generateAgentSelection', () => { const options: GroupOption[] = []; const policyOptions = generateGroupOption('policy', AGENT_GROUP_KEY.Policy, [ { name: 'policy 1', id: 'policy 1', size: 5 }, - { name: 'policy 2', id: uuid.v4(), size: 5 }, + { name: 'policy 2', id: uuidv4(), size: 5 }, ]).options; options.push(...policyOptions); const platformOptions = generateGroupOption('platform', AGENT_GROUP_KEY.Platform, [ { name: 'platform 1', id: 'platform 1', size: 5 }, - { name: 'platform 2', id: uuid.v4(), size: 5 }, + { name: 'platform 2', id: uuidv4(), size: 5 }, ]).options; options.push(...platformOptions); diff --git a/x-pack/plugins/osquery/server/handlers/action/create_action_handler.ts b/x-pack/plugins/osquery/server/handlers/action/create_action_handler.ts index a38f8eb08b57b..a26bc88a0d29f 100644 --- a/x-pack/plugins/osquery/server/handlers/action/create_action_handler.ts +++ b/x-pack/plugins/osquery/server/handlers/action/create_action_handler.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import moment from 'moment'; import { filter, flatten, isEmpty, map, omit, pick, pickBy, some } from 'lodash'; import { AGENT_ACTIONS_INDEX } from '@kbn/fleet-plugin/common'; @@ -67,7 +67,7 @@ export const createActionHandler = async ( } const osqueryAction = { - action_id: uuid.v4(), + action_id: uuidv4(), '@timestamp': moment().toISOString(), expiration: moment().add(5, 'minutes').toISOString(), type: 'INPUT_ACTION', @@ -91,7 +91,7 @@ export const createActionHandler = async ( ? map(convertSOQueriesToPack(packSO.attributes.queries), (packQuery, packQueryId) => pickBy( { - action_id: uuid.v4(), + action_id: uuidv4(), id: packQueryId, query: packQuery.query, ecs_mapping: packQuery.ecs_mapping, diff --git a/x-pack/plugins/osquery/server/handlers/action/create_queries.ts b/x-pack/plugins/osquery/server/handlers/action/create_queries.ts index f9f918a7ea623..74b954935c1b6 100644 --- a/x-pack/plugins/osquery/server/handlers/action/create_queries.ts +++ b/x-pack/plugins/osquery/server/handlers/action/create_queries.ts @@ -6,7 +6,7 @@ */ import { isEmpty, map, pickBy } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Ecs } from '@kbn/core/server'; import { i18n } from '@kbn/i18n'; @@ -25,7 +25,7 @@ export const createQueries = async ( pickBy( { ...query, - action_id: uuid.v4(), + action_id: uuidv4(), agents, }, (value) => !isEmpty(value) || value === true @@ -34,8 +34,8 @@ export const createQueries = async ( : [ pickBy( { - action_id: uuid.v4(), - id: uuid.v4(), + action_id: uuidv4(), + id: uuidv4(), query: params.query, saved_query_id: params.saved_query_id, saved_query_prebuilt: params.saved_query_id @@ -64,7 +64,7 @@ export const createDynamicQueries = async ( { ...replacedQuery, ...restQuery, - action_id: uuid.v4(), + action_id: uuidv4(), alert_ids: params.alert_ids, agents: params.agent_ids, }, @@ -74,8 +74,8 @@ export const createDynamicQueries = async ( : [ pickBy( { - action_id: uuid.v4(), - id: uuid.v4(), + action_id: uuidv4(), + id: uuidv4(), ...replacedQueries(params.query, alert), // just for single queries - we need to overwrite the error property error: undefined, diff --git a/x-pack/plugins/profiling/common/columnar_view_model.ts b/x-pack/plugins/profiling/common/columnar_view_model.ts index cc20bd9ca9a0e..20bf2b2761855 100644 --- a/x-pack/plugins/profiling/common/columnar_view_model.ts +++ b/x-pack/plugins/profiling/common/columnar_view_model.ts @@ -8,52 +8,7 @@ import { ColumnarViewModel } from '@elastic/charts'; import { ElasticFlameGraph } from './flamegraph'; - -/* - * Helper to calculate the color of a given block to be drawn. The desirable outcomes of this are: - * Each of the following frame types should get a different set of color hues: - * - * 0 = Unsymbolized frame - * 1 = Python - * 2 = PHP - * 3 = Native - * 4 = Kernel - * 5 = JVM/Hotspot - * 6 = Ruby - * 7 = Perl - * 8 = JavaScript - * 9 = PHP JIT - * - * This is most easily achieved by mapping frame types to different color variations, using - * the x-position we can use different colors for adjacent blocks while keeping a similar hue - * - * Taken originally from prodfiler_ui/src/helpers/Pixi/frameTypeToColors.tsx - */ -const frameTypeToColors = [ - [0xfd8484, 0xfd9d9d, 0xfeb5b5, 0xfecece], - [0xfcae6b, 0xfdbe89, 0xfdcea6, 0xfedfc4], - [0xfcdb82, 0xfde29b, 0xfde9b4, 0xfef1cd], - [0x6dd0dc, 0x8ad9e3, 0xa7e3ea, 0xc5ecf1], - [0x7c9eff, 0x96b1ff, 0xb0c5ff, 0xcbd8ff], - [0x65d3ac, 0x84dcbd, 0xa3e5cd, 0xc1edde], - [0xd79ffc, 0xdfb2fd, 0xe7c5fd, 0xefd9fe], - [0xf98bb9, 0xfaa2c7, 0xfbb9d5, 0xfdd1e3], - [0xcbc3e3, 0xd5cfe8, 0xdfdbee, 0xeae7f3], - [0xccfc82, 0xd1fc8e, 0xd6fc9b, 0xdbfca7], -]; - -function frameTypeToRGB(frameType: number, x: number): number { - return frameTypeToColors[frameType][x % 4]; -} - -export function rgbToRGBA(rgb: number): number[] { - return [ - Math.floor(rgb / 65536) / 255, - (Math.floor(rgb / 256) % 256) / 255, - (rgb % 256) / 255, - 1.0, - ]; -} +import { frameTypeToRGB, rgbToRGBA } from './frame_type_colors'; function normalize(n: number, lower: number, upper: number): number { return (n - lower) / (upper - lower); diff --git a/x-pack/plugins/profiling/common/frame_type_colors.ts b/x-pack/plugins/profiling/common/frame_type_colors.ts new file mode 100644 index 0000000000000..11c8cbaca9f30 --- /dev/null +++ b/x-pack/plugins/profiling/common/frame_type_colors.ts @@ -0,0 +1,54 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FrameType } from './profiling'; + +/* + * Helper to calculate the color of a given block to be drawn. The desirable outcomes of this are: + * Each of the following frame types should get a different set of color hues: + * + * 0 = Unsymbolized frame + * 1 = Python + * 2 = PHP + * 3 = Native + * 4 = Kernel + * 5 = JVM/Hotspot + * 6 = Ruby + * 7 = Perl + * 8 = JavaScript + * 9 = PHP JIT + * + * This is most easily achieved by mapping frame types to different color variations, using + * the x-position we can use different colors for adjacent blocks while keeping a similar hue + * + * Taken originally from prodfiler_ui/src/helpers/Pixi/frameTypeToColors.tsx + */ +export const FRAME_TYPE_COLOR_MAP = { + [FrameType.Unsymbolized]: [0xfd8484, 0xfd9d9d, 0xfeb5b5, 0xfecece], + [FrameType.Python]: [0xfcae6b, 0xfdbe89, 0xfdcea6, 0xfedfc4], + [FrameType.PHP]: [0xfcdb82, 0xfde29b, 0xfde9b4, 0xfef1cd], + [FrameType.Native]: [0x6dd0dc, 0x8ad9e3, 0xa7e3ea, 0xc5ecf1], + [FrameType.Kernel]: [0x7c9eff, 0x96b1ff, 0xb0c5ff, 0xcbd8ff], + [FrameType.JVM]: [0x65d3ac, 0x84dcbd, 0xa3e5cd, 0xc1edde], + [FrameType.Ruby]: [0xd79ffc, 0xdfb2fd, 0xe7c5fd, 0xefd9fe], + [FrameType.Perl]: [0xf98bb9, 0xfaa2c7, 0xfbb9d5, 0xfdd1e3], + [FrameType.JavaScript]: [0xcbc3e3, 0xd5cfe8, 0xdfdbee, 0xeae7f3], + [FrameType.PHPJIT]: [0xccfc82, 0xd1fc8e, 0xd6fc9b, 0xdbfca7], +}; + +export function frameTypeToRGB(frameType: FrameType, x: number): number { + return FRAME_TYPE_COLOR_MAP[frameType][x % 4]; +} + +export function rgbToRGBA(rgb: number): number[] { + return [ + Math.floor(rgb / 65536) / 255, + (Math.floor(rgb / 256) % 256) / 255, + (rgb % 256) / 255, + 1.0, + ]; +} diff --git a/x-pack/plugins/profiling/common/profiling.ts b/x-pack/plugins/profiling/common/profiling.ts index a7a5a890c6b5b..aa0c114e51210 100644 --- a/x-pack/plugins/profiling/common/profiling.ts +++ b/x-pack/plugins/profiling/common/profiling.ts @@ -59,6 +59,7 @@ export enum FrameType { Ruby, Perl, JavaScript, + PHPJIT, } const frameTypeDescriptions = { @@ -71,6 +72,7 @@ const frameTypeDescriptions = { [FrameType.Ruby]: 'Ruby', [FrameType.Perl]: 'Perl', [FrameType.JavaScript]: 'JavaScript', + [FrameType.PHPJIT]: 'PHP JIT', }; export function describeFrameType(ft: FrameType): string { diff --git a/x-pack/plugins/profiling/public/components/flame_graphs_view/flame_graph_legend.tsx b/x-pack/plugins/profiling/public/components/flame_graphs_view/flame_graph_legend.tsx new file mode 100644 index 0000000000000..7f63ecb9337f9 --- /dev/null +++ b/x-pack/plugins/profiling/public/components/flame_graphs_view/flame_graph_legend.tsx @@ -0,0 +1,91 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { EuiFlexGroup, EuiFlexItem, EuiText } from '@elastic/eui'; +import React from 'react'; +import { i18n } from '@kbn/i18n'; +import { asPercentage } from '../../utils/formatters/as_percentage'; +import { Legend, LegendItem } from '../legend'; + +export function FlameGraphLegend({ + legendItems, + asScale, +}: { + legendItems: LegendItem[]; + asScale: boolean; +}) { + if (asScale) { + return ( + + + + + + + + {i18n.translate('xpack.profiling.flameGraphLegend.improvement', { + defaultMessage: 'Improvement', + })} + + + + + {i18n.translate('xpack.profiling.flameGraphLegend.regression', { + defaultMessage: 'Regression', + })} + + + + + + + + + + +{asPercentage(1)} + + + + {legendItems.map(({ color, label }) => { + return ( + + {label ? ( + + {label} + + ) : ( + '' + )} + + ); + })} + + + + {asPercentage(-1)} + + + + + + + + + ); + } + + return ; +} diff --git a/x-pack/plugins/profiling/public/components/flamegraph.tsx b/x-pack/plugins/profiling/public/components/flamegraph.tsx index 09eba11eb6cd2..82eded53e62b1 100644 --- a/x-pack/plugins/profiling/public/components/flamegraph.tsx +++ b/x-pack/plugins/profiling/public/components/flamegraph.tsx @@ -24,6 +24,7 @@ import { ElasticFlameGraph, FlameGraphComparisonMode } from '../../common/flameg import { asPercentage } from '../utils/formatters/as_percentage'; import { getFlamegraphModel } from '../utils/get_flamegraph_model'; import { FlamegraphInformationWindow } from './flame_graphs_view/flamegraph_information_window'; +import { FlameGraphLegend } from './flame_graphs_view/flame_graph_legend'; function TooltipRow({ value, @@ -321,6 +322,9 @@ export const FlameGraph: React.FC = ({ ) : undefined}
    + + +
    ); }; diff --git a/x-pack/plugins/profiling/public/components/legend.tsx b/x-pack/plugins/profiling/public/components/legend.tsx new file mode 100644 index 0000000000000..c69f84ee7031b --- /dev/null +++ b/x-pack/plugins/profiling/public/components/legend.tsx @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { EuiFlexGroup, EuiFlexItem, EuiIcon, EuiText } from '@elastic/eui'; +import React from 'react'; + +export interface LegendItem { + color: string; + label: string; +} + +export function Legend({ legendItems }: { legendItems: LegendItem[] }) { + return ( + + {legendItems.map(({ color, label }) => { + return ( + + + + + + + {label} + + + + ); + })} + + ); +} diff --git a/x-pack/plugins/profiling/public/utils/get_flamegraph_model/index.ts b/x-pack/plugins/profiling/public/utils/get_flamegraph_model/index.ts index 4cda7befe44c9..7609b724e0547 100644 --- a/x-pack/plugins/profiling/public/utils/get_flamegraph_model/index.ts +++ b/x-pack/plugins/profiling/public/utils/get_flamegraph_model/index.ts @@ -4,10 +4,14 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ +import { ColumnarViewModel } from '@elastic/charts'; import d3 from 'd3'; -import { sum, uniqueId } from 'lodash'; -import { createColumnarViewModel, rgbToRGBA } from '../../../common/columnar_view_model'; +import { compact, sum, uniqueId, range } from 'lodash'; +import { i18n } from '@kbn/i18n'; +import { createColumnarViewModel } from '../../../common/columnar_view_model'; import { ElasticFlameGraph, FlameGraphComparisonMode } from '../../../common/flamegraph'; +import { FRAME_TYPE_COLOR_MAP, rgbToRGBA } from '../../../common/frame_type_colors'; +import { describeFrameType, FrameType } from '../../../common/profiling'; import { getInterpolationValue } from './get_interpolation_value'; const nullColumnarViewModel = { @@ -34,17 +38,72 @@ export function getFlamegraphModel({ colorDanger: string; colorNeutral: string; comparisonMode: FlameGraphComparisonMode; -}) { +}): { + key: string; + viewModel: ColumnarViewModel; + comparisonNodesById: Record; + legendItems: Array<{ label: string; color: string }>; +} { const comparisonNodesById: Record = {}; if (!primaryFlamegraph || !primaryFlamegraph.Label || primaryFlamegraph.Label.length === 0) { - return { key: uniqueId(), viewModel: nullColumnarViewModel, comparisonNodesById }; + return { + key: uniqueId(), + viewModel: nullColumnarViewModel, + comparisonNodesById, + legendItems: [], + }; } const viewModel = createColumnarViewModel(primaryFlamegraph, comparisonFlamegraph === undefined); - if (comparisonFlamegraph) { + let legendItems: Array<{ label: string; color: string }>; + + if (!comparisonFlamegraph) { + const usedFrameTypes = new Set([...primaryFlamegraph.FrameType]); + legendItems = compact( + Object.entries(FRAME_TYPE_COLOR_MAP).map(([frameTypeKey, colors]) => { + const frameType = Number(frameTypeKey) as FrameType; + + return usedFrameTypes.has(frameType) + ? { + color: `#${colors[0].toString(16)}`, + label: describeFrameType(frameType), + } + : undefined; + }) + ); + } else { + const positiveChangeInterpolator = d3.interpolateRgb(colorNeutral, colorSuccess); + + const negativeChangeInterpolator = d3.interpolateRgb(colorNeutral, colorDanger); + + function getColor(interpolationValue: number) { + const nodeColor = + interpolationValue >= 0 + ? positiveChangeInterpolator(interpolationValue) + : negativeChangeInterpolator(Math.abs(interpolationValue)); + + return nodeColor; + } + + legendItems = range(1, -1, -0.2) + .concat(-1) + .map((value) => { + const rounded = Math.round(value * 100) / 100; + const color = getColor(rounded); + return { + color, + label: + rounded === 0 + ? i18n.translate('xpack.profiling.flamegraphModel.noChange', { + defaultMessage: 'No change', + }) + : '', + }; + }); + comparisonFlamegraph.ID.forEach((nodeID, index) => { comparisonNodesById[nodeID] = { CountInclusive: comparisonFlamegraph.CountInclusive[index], @@ -52,10 +111,6 @@ export function getFlamegraphModel({ }; }); - const positiveChangeInterpolator = d3.interpolateRgb(colorNeutral, colorSuccess); - - const negativeChangeInterpolator = d3.interpolateRgb(colorNeutral, colorDanger); - // per @thomasdullien: // In "relative" mode: Take the percentage of CPU time consumed by block A and subtract // the percentage of CPU time consumed by block B. If the number is positive, linearly @@ -100,10 +155,7 @@ export function getFlamegraphModel({ denominator ); - const nodeColor = - interpolationValue >= 0 - ? positiveChangeInterpolator(interpolationValue) - : negativeChangeInterpolator(Math.abs(interpolationValue)); + const nodeColor = getColor(interpolationValue); const rgba = rgbToRGBA(Number(nodeColor.replace('#', '0x'))); viewModel.color.set(rgba, 4 * index); @@ -114,5 +166,6 @@ export function getFlamegraphModel({ key: uniqueId(), viewModel, comparisonNodesById, + legendItems, }; } diff --git a/x-pack/plugins/reporting/server/lib/tasks/execute_report.ts b/x-pack/plugins/reporting/server/lib/tasks/execute_report.ts index ca3ba4445f940..abebdef58fe33 100644 --- a/x-pack/plugins/reporting/server/lib/tasks/execute_report.ts +++ b/x-pack/plugins/reporting/server/lib/tasks/execute_report.ts @@ -10,8 +10,9 @@ import type { Logger } from '@kbn/core/server'; import moment from 'moment'; import * as Rx from 'rxjs'; import { timeout } from 'rxjs/operators'; -import { finished, Writable } from 'stream'; -import { promisify } from 'util'; +import { Writable } from 'stream'; +import { finished } from 'stream/promises'; +import { setTimeout } from 'timers/promises'; import type { RunContext, TaskManagerStartContract, @@ -59,6 +60,22 @@ function reportFromTask(task: ReportTaskParams) { return new Report({ ...task, _id: task.id, _index: task.index }); } +async function finishedWithNoPendingCallbacks(stream: Writable) { + await finished(stream, { readable: false }); + + // Race condition workaround: + // `finished(...)` will resolve while there's still pending callbacks in the writable part of the `stream`. + // This introduces a race condition where the code continues before the writable part has completely finished. + // The `pendingCallbacks` function is a hack to ensure that all pending callbacks have been called before continuing. + // For more information, see: https://github.com/nodejs/node/issues/46170 + await (async function pendingCallbacks(delay = 1) { + if ((stream as any)._writableState.pendingcb > 0) { + await setTimeout(delay); + await pendingCallbacks(delay < 32 ? delay * 2 : delay); + } + })(); +} + export class ExecuteReportTask implements ReportingTask { public TYPE = REPORTING_EXECUTE_TYPE; @@ -377,7 +394,7 @@ export class ExecuteReportTask implements ReportingTask { stream.end(); - await promisify(finished)(stream, { readable: false }); + await finishedWithNoPendingCallbacks(stream); report._seq_no = stream.getSeqNo()!; report._primary_term = stream.getPrimaryTerm()!; diff --git a/x-pack/plugins/rule_registry/common/schemas/8.7.0/index.ts b/x-pack/plugins/rule_registry/common/schemas/8.7.0/index.ts new file mode 100644 index 0000000000000..48bad2a31f2a8 --- /dev/null +++ b/x-pack/plugins/rule_registry/common/schemas/8.7.0/index.ts @@ -0,0 +1,54 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { Values } from '@kbn/utility-types'; +import { + ALERT_INSTANCE_ID, + ALERT_UUID, + ALERT_RULE_CATEGORY, + ALERT_RULE_CONSUMER, + ALERT_RULE_EXECUTION_UUID, + ALERT_RULE_NAME, + ALERT_RULE_PRODUCER, + ALERT_RULE_TYPE_ID, + ALERT_RULE_UUID, + SPACE_IDS, + ALERT_RULE_TAGS, + TIMESTAMP, + ALERT_RULE_PARAMETERS, +} from '@kbn/rule-data-utils'; + +/* DO NOT MODIFY THIS SCHEMA TO ADD NEW FIELDS. These types represent the alerts that shipped in 8.7.0. +Any changes to these types should be bug fixes so the types more accurately represent the alerts from 8.7.0. + +If you are adding new fields for a new release of Kibana, create a new sibling folder to this one +for the version to be released and add the field(s) to the schema in that folder. + +Then, update `../index.ts` to import from the new folder that has the latest schemas, add the +new schemas to the union of all alert schemas, and re-export the new schemas as the `*Latest` schemas. +*/ + +const commonAlertIdFieldNames = [ALERT_INSTANCE_ID, ALERT_UUID]; +export type CommonAlertIdFieldName870 = Values; + +export interface CommonAlertFields870 { + [ALERT_RULE_PARAMETERS]: Record; + [ALERT_RULE_CATEGORY]: string; + [ALERT_RULE_CONSUMER]: string; + [ALERT_RULE_EXECUTION_UUID]: string; + [ALERT_RULE_NAME]: string; + [ALERT_RULE_PRODUCER]: string; + [ALERT_RULE_TYPE_ID]: string; + [ALERT_RULE_UUID]: string; + [SPACE_IDS]: string[]; + [ALERT_RULE_TAGS]: string[]; + [TIMESTAMP]: string; +} + +export type CommonAlertFieldName870 = keyof CommonAlertFields870; + +export type AlertWithCommonFields870 = T & CommonAlertFields870; diff --git a/x-pack/plugins/rule_registry/common/schemas/index.ts b/x-pack/plugins/rule_registry/common/schemas/index.ts index e12c59617fd00..0b90b6a7acb72 100644 --- a/x-pack/plugins/rule_registry/common/schemas/index.ts +++ b/x-pack/plugins/rule_registry/common/schemas/index.ts @@ -6,15 +6,15 @@ */ import type { - CommonAlertFieldName800, - CommonAlertIdFieldName800, - CommonAlertFields800, - AlertWithCommonFields800, -} from './8.0.0'; + CommonAlertFieldName870, + CommonAlertIdFieldName870, + CommonAlertFields870, + AlertWithCommonFields870, +} from './8.7.0'; export type { - CommonAlertFieldName800 as CommonAlertFieldNameLatest, - CommonAlertIdFieldName800 as CommonAlertIdFieldNameLatest, - CommonAlertFields800 as CommonAlertFieldsLatest, - AlertWithCommonFields800 as AlertWithCommonFieldsLatest, + CommonAlertFieldName870 as CommonAlertFieldNameLatest, + CommonAlertIdFieldName870 as CommonAlertIdFieldNameLatest, + CommonAlertFields870 as CommonAlertFieldsLatest, + AlertWithCommonFields870 as AlertWithCommonFieldsLatest, }; diff --git a/x-pack/plugins/rule_registry/common/types.ts b/x-pack/plugins/rule_registry/common/types.ts index fd238b66c82bb..3c0816763e220 100644 --- a/x-pack/plugins/rule_registry/common/types.ts +++ b/x-pack/plugins/rule_registry/common/types.ts @@ -185,14 +185,6 @@ const bucketAggsTempsSchemas: t.Type = t.exact( }) ); -export const bucketAggsSchemas = t.intersection([ - bucketAggsTempsSchemas, - t.partial({ - aggs: t.union([t.record(t.string, bucketAggsTempsSchemas), t.undefined]), - aggregations: t.union([t.record(t.string, bucketAggsTempsSchemas), t.undefined]), - }), -]); - /** * Schemas for the metrics Aggregations * @@ -287,11 +279,22 @@ export const metricsAggsSchemas = t.exact( }), }) ), - aggs: t.undefined, - aggregations: t.undefined, }) ); +export const bucketAggsSchemas = t.intersection([ + bucketAggsTempsSchemas, + t.exact( + t.partial({ + aggs: t.record(t.string, t.intersection([bucketAggsTempsSchemas, metricsAggsSchemas])), + aggregations: t.record( + t.string, + t.intersection([bucketAggsTempsSchemas, metricsAggsSchemas]) + ), + }) + ), +]); + export type PutIndexTemplateRequest = estypes.IndicesPutIndexTemplateRequest & { body?: { composed_of?: string[] }; }; diff --git a/x-pack/plugins/rule_registry/server/routes/find.ts b/x-pack/plugins/rule_registry/server/routes/find.ts index 5cdaad09503c8..b2ba28fdda5da 100644 --- a/x-pack/plugins/rule_registry/server/routes/find.ts +++ b/x-pack/plugins/rule_registry/server/routes/find.ts @@ -26,11 +26,7 @@ export const findAlertsByQueryRoute = (router: IRouter t.partial({ index: t.string, query: t.object, - aggs: t.union([ - t.record(t.string, bucketAggsSchemas), - t.record(t.string, metricsAggsSchemas), - t.undefined, - ]), + aggs: t.record(t.string, t.intersection([metricsAggsSchemas, bucketAggsSchemas])), sort: t.union([t.array(t.object), t.undefined]), search_after: t.union([t.array(t.number), t.array(t.string), t.undefined]), size: t.union([PositiveInteger, t.undefined]), @@ -49,7 +45,6 @@ export const findAlertsByQueryRoute = (router: IRouter // eslint-disable-next-line @typescript-eslint/naming-convention const { query, aggs, _source, track_total_hits, size, index, sort, search_after } = request.body; - const racContext = await context.rac; const alertsClient = await racContext.getAlertsClient(); const alerts = await alertsClient.find({ diff --git a/x-pack/plugins/rule_registry/server/routes/get_alert_summary.test.ts b/x-pack/plugins/rule_registry/server/routes/get_alert_summary.test.ts index 3496b8f342e2c..e15f2d40dc826 100644 --- a/x-pack/plugins/rule_registry/server/routes/get_alert_summary.test.ts +++ b/x-pack/plugins/rule_registry/server/routes/get_alert_summary.test.ts @@ -88,7 +88,7 @@ describe('getAlertSummaryRoute', () => { "attributes": Object { "success": false, }, - "message": "fixed_interval is not following the expected format 1m, 1h, 1d, 1w", + "message": "fixed_interval (value: xx) is not following the expected format 1s, 1m, 1h, 1d with at most 6 digits", } `); }); diff --git a/x-pack/plugins/rule_registry/server/routes/get_alert_summary.ts b/x-pack/plugins/rule_registry/server/routes/get_alert_summary.ts index 6125c2a39b845..838bf06e7e768 100644 --- a/x-pack/plugins/rule_registry/server/routes/get_alert_summary.ts +++ b/x-pack/plugins/rule_registry/server/routes/get_alert_summary.ts @@ -57,9 +57,9 @@ export const getAlertSummaryRoute = (router: IRouter) throw Boom.badRequest('gte and/or lte are not following the UTC format'); } - if (fixedInterval && fixedInterval?.match(/^\d{1,2}['m','h','d','w']$/) == null) { + if (fixedInterval && fixedInterval?.match(/^\d{1,6}['s','m','h','d']$/) == null) { throw Boom.badRequest( - 'fixed_interval is not following the expected format 1m, 1h, 1d, 1w' + `fixed_interval (value: ${fixedInterval}) is not following the expected format 1s, 1m, 1h, 1d with at most 6 digits` ); } diff --git a/x-pack/plugins/rule_registry/server/utils/create_lifecycle_rule_type.test.ts b/x-pack/plugins/rule_registry/server/utils/create_lifecycle_rule_type.test.ts index 287f09421f2ad..de164dd07c0b3 100644 --- a/x-pack/plugins/rule_registry/server/utils/create_lifecycle_rule_type.test.ts +++ b/x-pack/plugins/rule_registry/server/utils/create_lifecycle_rule_type.test.ts @@ -101,7 +101,7 @@ function createRule(shouldWriteAlerts: boolean = true) { executionId: 'b33f65d7-6e8b-4aae-8d20-c93613dec9f9', logger: loggerMock.create(), namespace: 'namespace', - params: {}, + params: { threshold: 1, operator: '>' }, previousStartedAt, rule: { id: 'alertId', @@ -246,6 +246,10 @@ describe('createLifecycleRuleTypeFactory', () => { "kibana.alert.rule.consumer": "consumer", "kibana.alert.rule.execution.uuid": "b33f65d7-6e8b-4aae-8d20-c93613dec9f9", "kibana.alert.rule.name": "name", + "kibana.alert.rule.parameters": Object { + "operator": ">", + "threshold": 1, + }, "kibana.alert.rule.producer": "producer", "kibana.alert.rule.rule_type_id": "ruleTypeId", "kibana.alert.rule.tags": Array [ @@ -278,6 +282,10 @@ describe('createLifecycleRuleTypeFactory', () => { "kibana.alert.rule.consumer": "consumer", "kibana.alert.rule.execution.uuid": "b33f65d7-6e8b-4aae-8d20-c93613dec9f9", "kibana.alert.rule.name": "name", + "kibana.alert.rule.parameters": Object { + "operator": ">", + "threshold": 1, + }, "kibana.alert.rule.producer": "producer", "kibana.alert.rule.rule_type_id": "ruleTypeId", "kibana.alert.rule.tags": Array [ diff --git a/x-pack/plugins/rule_registry/server/utils/get_common_alert_fields.ts b/x-pack/plugins/rule_registry/server/utils/get_common_alert_fields.ts index 7401186fa59e7..5d7d105571c84 100644 --- a/x-pack/plugins/rule_registry/server/utils/get_common_alert_fields.ts +++ b/x-pack/plugins/rule_registry/server/utils/get_common_alert_fields.ts @@ -16,6 +16,7 @@ import { SPACE_IDS, ALERT_RULE_TAGS, TIMESTAMP, + ALERT_RULE_PARAMETERS, } from '@kbn/rule-data-utils'; import { RuleExecutorOptions } from '@kbn/alerting-plugin/server'; @@ -25,6 +26,7 @@ export const getCommonAlertFields = ( options: RuleExecutorOptions ): CommonAlertFieldsLatest => { return { + [ALERT_RULE_PARAMETERS]: options.params, [ALERT_RULE_CATEGORY]: options.rule.ruleTypeName, [ALERT_RULE_CONSUMER]: options.rule.consumer, [ALERT_RULE_EXECUTION_UUID]: options.executionId, diff --git a/x-pack/plugins/screenshotting/server/screenshots/event_logger/index.ts b/x-pack/plugins/screenshotting/server/screenshots/event_logger/index.ts index 64027ffbd3cf2..96fcb092155fb 100644 --- a/x-pack/plugins/screenshotting/server/screenshots/event_logger/index.ts +++ b/x-pack/plugins/screenshotting/server/screenshots/event_logger/index.ts @@ -7,7 +7,7 @@ import { Logger, LogMeta } from '@kbn/core/server'; import apm from 'elastic-apm-node'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { CaptureResult } from '..'; import { PLUGIN_ID } from '../../../common'; import { ConfigType } from '../../config'; @@ -151,7 +151,7 @@ export class EventLogger { private timings: Partial> = {}; constructor(private readonly logger: Logger, private readonly config: ConfigType) { - this.sessionId = uuid.v4(); + this.sessionId = uuidv4(); this.logEvent = logAdapter(logger.get('events'), this.sessionId); } diff --git a/x-pack/plugins/searchprofiler/public/application/components/profile_tree/use_highlight_tree_node.ts b/x-pack/plugins/searchprofiler/public/application/components/profile_tree/use_highlight_tree_node.ts index 84e6011981c58..f667210a0bfc5 100644 --- a/x-pack/plugins/searchprofiler/public/application/components/profile_tree/use_highlight_tree_node.ts +++ b/x-pack/plugins/searchprofiler/public/application/components/profile_tree/use_highlight_tree_node.ts @@ -6,12 +6,12 @@ */ import { useRef } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { useHighlightContext, OnHighlightChangeArgs } from './highlight_context'; export const useHighlightTreeNode = () => { - const idRef = useRef(uuid.v4()); + const idRef = useRef(uuidv4()); const { selectedRow, setStore } = useHighlightContext(); const highlight = (value: OnHighlightChangeArgs) => { diff --git a/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts b/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts index f33b8659fb27f..b69e09aa7bff7 100644 --- a/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts +++ b/x-pack/plugins/security/public/management/roles/__fixtures__/kibana_features.ts @@ -11,7 +11,7 @@ import { KibanaFeature } from '@kbn/features-plugin/public'; export const createFeature = ( config: Pick< KibanaFeatureConfig, - 'id' | 'name' | 'subFeatures' | 'reserved' | 'privilegesTooltip' + 'id' | 'name' | 'subFeatures' | 'reserved' | 'privilegesTooltip' | 'description' > & { excludeFromBaseAll?: boolean; excludeFromBaseRead?: boolean; diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.scss b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.scss index e5c026d317034..f03a4582598ee 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.scss +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.scss @@ -1,5 +1,11 @@ -.subFeaturePrivilegeExpandedRegion { - background-color: $euiColorLightestShade; - padding-left: $euiSizeXXL; - padding-top: $euiSizeS; -} \ No newline at end of file +.euiAccordionWithDescription:hover, .euiAccordionWithDescription:focus { + text-decoration: none; +} + +.subFeaturePanel { + margin-left: $euiSizeL + $euiSizeXS; +} + +.noSubFeaturePrivileges { + margin-left: $euiSizeL + $euiSizeXS; +} diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.test.tsx b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.test.tsx index 7f5ac97e41edf..0383e857adda4 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.test.tsx +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.test.tsx @@ -837,6 +837,63 @@ describe('FeatureTable', () => { expect(findTestSubject(wrapper, 'primaryFeaturePrivilegeControl')).toHaveLength(0); }); + it('renders subtext for features that define an optional description', () => { + const role = createRole([ + { + spaces: ['foo'], + base: [], + feature: { + my_feature: ['all'], + }, + }, + ]); + const featureWithDescription = createFeature({ + id: 'my_feature', + name: 'Some Feature', + description: 'a description of my feature', + }); + + const { wrapper } = setup({ + role, + features: [featureWithDescription], + privilegeIndex: 0, + calculateDisplayedPrivileges: false, + canCustomizeSubFeaturePrivileges: false, + }); + + expect(findTestSubject(wrapper, 'featurePrivilegeDescriptionText').exists()).toEqual(true); + + expect( + findTestSubject(wrapper, 'featurePrivilegeDescriptionText').text() + ).toMatchInlineSnapshot(`"a description of my feature"`); + }); + + it('does not render subtext for features without a description', () => { + const role = createRole([ + { + spaces: ['foo'], + base: [], + feature: { + my_feature: ['all'], + }, + }, + ]); + const featureWithDescription = createFeature({ + id: 'my_feature', + name: 'Some Feature', + }); + + const { wrapper } = setup({ + role, + features: [featureWithDescription], + privilegeIndex: 0, + calculateDisplayedPrivileges: false, + canCustomizeSubFeaturePrivileges: false, + }); + + expect(findTestSubject(wrapper, 'featurePrivilegeDescriptionText').exists()).toEqual(false); + }); + it('renders renders the primary feature controls when both primary and reserved privileges are specified', () => { const role = createRole([ { @@ -1315,4 +1372,100 @@ describe('FeatureTable', () => { expect(type).toBe('empty'); }); }); + describe('Optional description for sub-features', () => { + const role = createRole([ + { + spaces: ['foo'], + base: [], + feature: { + unit_test: ['minimal_read', 'sub-toggle-1', 'sub-toggle-2'], + }, + }, + ]); + + it('renders description subtext if defined', () => { + const feature = createFeature({ + id: 'unit_test', + name: 'Unit Test Feature', + subFeatures: [ + { + name: 'Some Sub Feature', + description: 'some sub feature description', + privilegeGroups: [ + { + groupType: 'independent', + privileges: [ + { + id: 'sub-toggle-1', + name: 'Sub Toggle 1', + includeIn: 'all', + savedObject: { all: [], read: [] }, + ui: ['sub-toggle-1'], + }, + ], + }, + ], + }, + ] as SubFeatureConfig[], + }); + const { wrapper } = setup({ + role, + features: [feature], + privilegeIndex: 0, + calculateDisplayedPrivileges: false, + canCustomizeSubFeaturePrivileges: true, + }); + + const categoryExpander = findTestSubject(wrapper, 'featureCategoryButton_foo'); + categoryExpander.simulate('click'); + + const featureExpander = findTestSubject(wrapper, 'featureTableCell'); + featureExpander.simulate('click'); + + expect(findTestSubject(wrapper, 'subFeatureDescription').exists()).toEqual(true); + expect(findTestSubject(wrapper, 'subFeatureDescription').text()).toMatchInlineSnapshot( + `"some sub feature description"` + ); + }); + it('should not render description subtext if undefined', () => { + const feature = createFeature({ + id: 'unit_test', + name: 'Unit Test Feature', + subFeatures: [ + { + name: 'Some Sub Feature', + privilegeGroups: [ + { + groupType: 'independent', + privileges: [ + { + id: 'sub-toggle-1', + name: 'Sub Toggle 1', + includeIn: 'all', + savedObject: { all: [], read: [] }, + ui: ['sub-toggle-1'], + }, + ], + }, + ], + }, + ] as SubFeatureConfig[], + }); + const { wrapper } = setup({ + role, + features: [feature], + privilegeIndex: 0, + calculateDisplayedPrivileges: false, + canCustomizeSubFeaturePrivileges: true, + }); + + const categoryExpander = findTestSubject(wrapper, 'featureCategoryButton_foo'); + categoryExpander.simulate('click'); + + const featureExpander = findTestSubject(wrapper, 'featureTableCell'); + featureExpander.simulate('click'); + + expect(findTestSubject(wrapper, 'subFeatureDescription').exists()).toEqual(false); + }); + }); }); diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.tsx b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.tsx index 33f9f2879b4f7..d2a5625b724a6 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.tsx +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table.tsx @@ -17,10 +17,12 @@ import { EuiHorizontalRule, EuiIcon, EuiIconTip, + EuiPanel, EuiSpacer, EuiText, EuiTitle, } from '@elastic/eui'; +import classNames from 'classnames'; import type { ReactElement } from 'react'; import React, { Component } from 'react'; @@ -221,11 +223,12 @@ export class FeatureTable extends Component { return ( {infoIcon} - + { }); }} > -
    + + { this.props.canCustomizeSubFeaturePrivileges } /> -
    +
    @@ -267,9 +271,7 @@ export class FeatureTable extends Component { if (feature.reserved && primaryFeaturePrivileges.length === 0) { const buttonContent = ( - <> - {} - + ); const extraAction = ( @@ -336,10 +338,10 @@ export class FeatureTable extends Component { const hasSubFeaturePrivileges = feature.getSubFeaturePrivileges().length > 0; const buttonContent = ( - <> - {!hasSubFeaturePrivileges && }{' '} - - + ); const extraAction = ( diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table_expanded_row.tsx b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table_expanded_row.tsx index e5e28c4547374..e89102e62ca8d 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table_expanded_row.tsx +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table/feature_table_expanded_row.tsx @@ -70,7 +70,7 @@ export const FeatureTableExpandedRow = ({ }; return ( - +
    { if (groupsWithPrivileges.length === 0) { return null; } - return ( - - - - {props.subFeature.name} {getTooltip()} - + + + + + + {props.subFeature.name} {getTooltip()} + + + {props.subFeature.description && ( + + + {props.subFeature.description} + + + )} + - {groupsWithPrivileges.map(renderPrivilegeGroup)} + {groupsWithPrivileges.map(renderPrivilegeGroup)} ); @@ -157,6 +172,7 @@ export const SubFeatureForm = (props: Props) => { key={index} buttonSize="compressed" data-test-subj="mutexSubFeaturePrivilegeControl" + isFullWidth options={options} idSelected={firstSelectedPrivilege?.id ?? NO_PRIVILEGE_VALUE} isDisabled={props.disabled} diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.scss b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.scss new file mode 100644 index 0000000000000..8a002996b67ed --- /dev/null +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.scss @@ -0,0 +1,3 @@ +.featurePrivilegeName:hover, .featurePrivilegeName:focus { + text-decoration: underline; +} diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.test.tsx b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.test.tsx index 006ae053940d8..c503ef35ae06c 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.test.tsx +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.test.tsx @@ -25,7 +25,7 @@ describe('FeatureTableCell', () => { ); - expect(wrapper.text()).toMatchInlineSnapshot(`"Test Feature "`); + expect(wrapper.text()).toMatchInlineSnapshot(`"Test Feature"`); expect(wrapper.find(EuiIconTip)).toHaveLength(0); }); @@ -40,7 +40,7 @@ describe('FeatureTableCell', () => { ); - expect(wrapper.text()).toMatchInlineSnapshot(`"Test Feature Info"`); + expect(wrapper.text()).toMatchInlineSnapshot(`"Test FeatureInfo"`); expect(wrapper.find(EuiIconTip).props().content).toMatchInlineSnapshot(` diff --git a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.tsx b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.tsx index 507416b51f9b6..062597ce46ad2 100644 --- a/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.tsx +++ b/x-pack/plugins/security/public/management/roles/edit_role/privileges/kibana/feature_table_cell/feature_table_cell.tsx @@ -5,16 +5,19 @@ * 2.0. */ -import { EuiIconTip, EuiText } from '@elastic/eui'; +import './feature_table_cell.scss'; + +import { EuiFlexGroup, EuiFlexItem, EuiIconTip, EuiText } from '@elastic/eui'; import React from 'react'; import type { SecuredFeature } from '../../../../model'; interface Props { feature: SecuredFeature; + className?: string; } -export const FeatureTableCell = ({ feature }: Props) => { +export const FeatureTableCell = ({ feature, className }: Props) => { let tooltipElement = null; if (feature.getPrivilegesTooltip()) { const tooltipContent = ( @@ -35,8 +38,27 @@ export const FeatureTableCell = ({ feature }: Props) => { } return ( - - {feature.name} {tooltipElement} - + + + + + {feature.name} + + {tooltipElement} + + + {feature.description && ( + + + {feature.description} + + + )} + ); }; diff --git a/x-pack/plugins/security/public/management/roles/model/secured_sub_feature.ts b/x-pack/plugins/security/public/management/roles/model/secured_sub_feature.ts index 8c312ee7ea772..79e98625cb06f 100644 --- a/x-pack/plugins/security/public/management/roles/model/secured_sub_feature.ts +++ b/x-pack/plugins/security/public/management/roles/model/secured_sub_feature.ts @@ -44,4 +44,8 @@ export class SecuredSubFeature extends SubFeature { .filter((privilege) => predicate(privilege, this)); } } + + public getDescription() { + return this.description; + } } diff --git a/x-pack/plugins/security/server/audit/audit_events.test.ts b/x-pack/plugins/security/server/audit/audit_events.test.ts index fb246569fcf81..8edd22e915c7c 100644 --- a/x-pack/plugins/security/server/audit/audit_events.test.ts +++ b/x-pack/plugins/security/server/audit/audit_events.test.ts @@ -15,11 +15,13 @@ import { AuthenticationResult } from '../authentication'; import { httpRequestEvent, savedObjectEvent, + sessionCleanupConcurrentLimitEvent, sessionCleanupEvent, SpaceAuditAction, spaceAuditEvent, userLoginEvent, userLogoutEvent, + userSessionConcurrentLimitLogoutEvent, } from './audit_events'; describe('#savedObjectEvent', () => { @@ -360,6 +362,63 @@ describe('#userLogoutEvent', () => { }); }); +describe('#userSessionConcurrentLimitLogoutEvent', () => { + test('creates event with `unknown` outcome', () => { + expect( + userSessionConcurrentLimitLogoutEvent({ + username: 'elastic', + provider: { name: 'basic1', type: 'basic' }, + userProfileId: 'uid', + }) + ).toMatchInlineSnapshot(` + Object { + "event": Object { + "action": "user_logout", + "category": Array [ + "authentication", + ], + "outcome": "unknown", + }, + "kibana": Object { + "authentication_provider": "basic1", + "authentication_type": "basic", + }, + "message": "User [elastic] is logging out due to exceeded concurrent sessions limit for basic provider [name=basic1]", + "user": Object { + "id": "uid", + "name": "elastic", + }, + } + `); + + expect( + userSessionConcurrentLimitLogoutEvent({ + username: 'elastic', + provider: { name: 'basic1', type: 'basic' }, + }) + ).toMatchInlineSnapshot(` + Object { + "event": Object { + "action": "user_logout", + "category": Array [ + "authentication", + ], + "outcome": "unknown", + }, + "kibana": Object { + "authentication_provider": "basic1", + "authentication_type": "basic", + }, + "message": "User [elastic] is logging out due to exceeded concurrent sessions limit for basic provider [name=basic1]", + "user": Object { + "id": undefined, + "name": "elastic", + }, + } + `); + }); +}); + describe('#sessionCleanupEvent', () => { test('creates event with `unknown` outcome', () => { expect( @@ -391,6 +450,37 @@ describe('#sessionCleanupEvent', () => { }); }); +describe('#sessionCleanupConcurrentLimitEvent', () => { + test('creates event with `unknown` outcome', () => { + expect( + sessionCleanupConcurrentLimitEvent({ + usernameHash: 'abcdef', + sessionId: 'sid', + provider: { name: 'basic1', type: 'basic' }, + }) + ).toMatchInlineSnapshot(` + Object { + "event": Object { + "action": "session_cleanup", + "category": Array [ + "authentication", + ], + "outcome": "unknown", + }, + "kibana": Object { + "authentication_provider": "basic1", + "authentication_type": "basic", + "session_id": "sid", + }, + "message": "Removing session for user [hash=abcdef] due to exceeded concurrent sessions limit", + "user": Object { + "hash": "abcdef", + }, + } + `); + }); +}); + describe('#httpRequestEvent', () => { test('creates event with `unknown` outcome', () => { expect( diff --git a/x-pack/plugins/security/server/audit/audit_events.ts b/x-pack/plugins/security/server/audit/audit_events.ts index 0ba0530b04585..26cfec1a6c420 100644 --- a/x-pack/plugins/security/server/audit/audit_events.ts +++ b/x-pack/plugins/security/server/audit/audit_events.ts @@ -215,6 +215,32 @@ export function userLogoutEvent({ }; } +export function userSessionConcurrentLimitLogoutEvent({ + username, + provider, + userProfileId, +}: UserLogoutParams): AuditEvent { + return { + message: `User [${username}] is logging out due to exceeded concurrent sessions limit for ${provider.type} provider [name=${provider.name}]`, + event: { + action: 'user_logout', + category: ['authentication'], + outcome: 'unknown', + }, + user: + userProfileId || username + ? { + id: userProfileId, + name: username, + } + : undefined, + kibana: { + authentication_provider: provider.name, + authentication_type: provider.type, + }, + }; +} + export interface SessionCleanupParams { sessionId: string; usernameHash?: string; @@ -244,6 +270,29 @@ export function sessionCleanupEvent({ }; } +export function sessionCleanupConcurrentLimitEvent({ + usernameHash, + sessionId, + provider, +}: SessionCleanupParams): AuditEvent { + return { + message: `Removing session for user [hash=${usernameHash}] due to exceeded concurrent sessions limit`, + event: { + action: 'session_cleanup', + category: ['authentication'], + outcome: 'unknown', + }, + user: { + hash: usernameHash, + }, + kibana: { + session_id: sessionId, + authentication_provider: provider.name, + authentication_type: provider.type, + }, + }; +} + export interface AccessAgreementAcknowledgedParams { username: string; provider: AuthenticationProvider; diff --git a/x-pack/plugins/security/server/audit/index.ts b/x-pack/plugins/security/server/audit/index.ts index 15d91168c6aca..c21a9625ca6cf 100644 --- a/x-pack/plugins/security/server/audit/index.ts +++ b/x-pack/plugins/security/server/audit/index.ts @@ -11,7 +11,9 @@ export type { AuditEvent, AuditHttp, AuditKibana, AuditRequest } from './audit_e export { userLoginEvent, userLogoutEvent, + userSessionConcurrentLimitLogoutEvent, sessionCleanupEvent, + sessionCleanupConcurrentLimitEvent, accessAgreementAcknowledgedEvent, httpRequestEvent, savedObjectEvent, diff --git a/x-pack/plugins/security/server/authentication/authenticator.ts b/x-pack/plugins/security/server/authentication/authenticator.ts index 0ebc418fdd7d4..d984783df4c02 100644 --- a/x-pack/plugins/security/server/authentication/authenticator.ts +++ b/x-pack/plugins/security/server/authentication/authenticator.ts @@ -800,7 +800,7 @@ export class Authenticator { await this.invalidateSessionValue({ request, sessionValue: existingSessionValue, - skipAuditEvent: true, // Skip writing an audit event when we are replacing an intermediate session with a fullly authenticated session + skipAuditEvent: true, // Skip writing an audit event when we are replacing an intermediate session with a fully authenticated session }); existingSessionValue = null; } else if (usernameHasChanged) { diff --git a/x-pack/plugins/security/server/config.test.ts b/x-pack/plugins/security/server/config.test.ts index 1c50c82d3a0f6..8b7324e70d646 100644 --- a/x-pack/plugins/security/server/config.test.ts +++ b/x-pack/plugins/security/server/config.test.ts @@ -1412,6 +1412,40 @@ describe('config schema', () => { '[session.cleanupInterval]: the value must be greater or equal to 10 seconds.' ); }); + + it('should throw error if xpack.security.session.concurrentSessions.maxSessions is less than 1 or greater than 1000', () => { + expect(() => + ConfigSchema.validate({ session: { concurrentSessions: { maxSessions: -1 } } }) + ).toThrow( + '[session.concurrentSessions.maxSessions]: Value must be equal to or greater than [1].' + ); + + expect(() => + ConfigSchema.validate({ session: { concurrentSessions: { maxSessions: 0 } } }) + ).toThrow( + '[session.concurrentSessions.maxSessions]: Value must be equal to or greater than [1].' + ); + + expect(() => + ConfigSchema.validate({ session: { concurrentSessions: { maxSessions: 1001 } } }) + ).toThrow( + '[session.concurrentSessions.maxSessions]: Value must be equal to or lower than [1000].' + ); + }); + + it('can be successfully validate valid xpack.security.session.concurrentSessions.maxSessions', () => { + expect(ConfigSchema.validate({ session: { concurrentSessions: { maxSessions: 3 } } }).session) + .toMatchInlineSnapshot(` + Object { + "cleanupInterval": "PT1H", + "concurrentSessions": Object { + "maxSessions": 3, + }, + "idleTimeout": "PT8H", + "lifespan": "P30D", + } + `); + }); }); }); @@ -1465,6 +1499,40 @@ describe('createConfig()', () => { `); }); + it('should log a warning if both concurrent sessions limit and HTTP authentication are configured', async () => { + const logger = loggingSystemMock.create(); + const config = createConfig( + ConfigSchema.validate({ session: { concurrentSessions: { maxSessions: 3 } } }), + logger.get(), + { isTLSEnabled: true } + ); + expect(config.session.concurrentSessions?.maxSessions).toBe(3); + expect(config.authc.http.enabled).toBe(true); + + expect(loggingSystemMock.collect(logger).warn).toMatchInlineSnapshot(` + Array [ + Array [ + "Both concurrent user sessions limit and HTTP authentication are configured. The limit does not apply to HTTP authentication.", + ], + ] + `); + + loggingSystemMock.clear(logger); + + const configWithoutHTTPAuth = createConfig( + ConfigSchema.validate({ + session: { concurrentSessions: { maxSessions: 3 } }, + authc: { http: { enabled: false } }, + }), + logger.get(), + { isTLSEnabled: true } + ); + expect(configWithoutHTTPAuth.session.concurrentSessions?.maxSessions).toBe(3); + expect(configWithoutHTTPAuth.authc.http.enabled).toBe(false); + + expect(loggingSystemMock.collect(logger).warn).toHaveLength(0); + }); + it('should set xpack.security.secureCookies if SSL is configured', async () => { const logger = loggingSystemMock.create().get(); const config = createConfig(ConfigSchema.validate({}), logger, { isTLSEnabled: true }); diff --git a/x-pack/plugins/security/server/config.ts b/x-pack/plugins/security/server/config.ts index aa7e3c0964ba8..e3584427964f3 100644 --- a/x-pack/plugins/security/server/config.ts +++ b/x-pack/plugins/security/server/config.ts @@ -226,6 +226,11 @@ export const ConfigSchema = schema.object({ } }, }), + concurrentSessions: schema.maybe( + schema.object({ + maxSessions: schema.number({ min: 1, max: 1000 }), + }) + ), }), secureCookies: schema.boolean({ defaultValue: false }), sameSiteCookies: schema.maybe( @@ -400,6 +405,13 @@ export function createConfig( }, } as AppenderConfigType); + const session = getSessionConfig(config.session, providers); + if (session.concurrentSessions?.maxSessions != null && config.authc.http.enabled) { + logger.warn( + 'Both concurrent user sessions limit and HTTP authentication are configured. The limit does not apply to HTTP authentication.' + ); + } + return { ...config, audit: { @@ -412,7 +424,7 @@ export function createConfig( sortedProviders: Object.freeze(sortedProviders), http: config.authc.http, }, - session: getSessionConfig(config.session, providers), + session, encryptionKey, secureCookies, }; @@ -420,6 +432,7 @@ export function createConfig( function getSessionConfig(session: RawConfigType['session'], providers: ProvidersConfigType) { return { + concurrentSessions: session.concurrentSessions, cleanupInterval: session.cleanupInterval, getExpirationTimeouts(provider: AuthenticationProvider | undefined) { // Both idle timeout and lifespan from the provider specific session config can have three diff --git a/x-pack/plugins/security/server/plugin.ts b/x-pack/plugins/security/server/plugin.ts index 573af8dbb7b67..ff3a5c3efaf3c 100644 --- a/x-pack/plugins/security/server/plugin.ts +++ b/x-pack/plugins/security/server/plugin.ts @@ -8,7 +8,7 @@ import type { Subscription } from 'rxjs'; import { map } from 'rxjs/operators'; -import type { CloudStart } from '@kbn/cloud-plugin/public'; +import type { CloudStart } from '@kbn/cloud-plugin/server'; import type { TypeOf } from '@kbn/config-schema'; import type { CoreSetup, @@ -370,7 +370,7 @@ export class SecurityPlugin const clusterClient = core.elasticsearch.client; const { watchOnlineStatus$ } = this.elasticsearchService.start(); const { session } = this.sessionManagementService.start({ - auditLogger: this.auditSetup!.withoutRequest, + audit: this.auditSetup!, elasticsearchClient: clusterClient.asInternalUser, kibanaIndexName: this.getKibanaIndexName(), online$: watchOnlineStatus$(), diff --git a/x-pack/plugins/security/server/session_management/session.test.ts b/x-pack/plugins/security/server/session_management/session.test.ts index 29e63141aaad8..d5ad9ce3b31d4 100644 --- a/x-pack/plugins/security/server/session_management/session.test.ts +++ b/x-pack/plugins/security/server/session_management/session.test.ts @@ -11,7 +11,10 @@ import crypto from 'crypto'; import { httpServerMock, loggingSystemMock } from '@kbn/core/server/mocks'; import type { PublicMethodsOf } from '@kbn/utility-types'; +import type { AuditLogger } from '..'; import { mockAuthenticatedUser } from '../../common/model/authenticated_user.mock'; +import { userSessionConcurrentLimitLogoutEvent } from '../audit'; +import { auditLoggerMock, auditServiceMock } from '../audit/mocks'; import { ConfigSchema, createConfig } from '../config'; import { sessionCookieMock, sessionIndexMock, sessionMock } from './index.mock'; import { getPrintableSessionId, Session, type SessionValueContentToEncrypt } from './session'; @@ -27,6 +30,7 @@ describe('Session', () => { let mockSessionIndex: jest.Mocked>; let mockSessionCookie: jest.Mocked>; + let mockScopedAuditLogger: jest.Mocked; let session: Session; beforeEach(() => { jest.spyOn(Date, 'now').mockImplementation(() => now); @@ -43,6 +47,10 @@ describe('Session', () => { mockSessionCookie = sessionCookieMock.create(); mockSessionIndex = sessionIndexMock.create(); + mockScopedAuditLogger = auditLoggerMock.create(); + + const mockAuditServiceSetup = auditServiceMock.create(); + mockAuditServiceSetup.asScoped.mockReturnValue(mockScopedAuditLogger); session = new Session({ logger: loggingSystemMock.createLogger(), @@ -56,6 +64,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: mockAuditServiceSetup, }); }); @@ -205,6 +214,40 @@ describe('Session', () => { expect(mockSessionIndex.invalidate).toHaveBeenCalledTimes(1); }); + it('clears session value if the session is outside the concurrent session limit', async () => { + mockSessionCookie.get.mockResolvedValue( + sessionCookieMock.createValue({ + aad: mockAAD, + idleTimeoutExpiration: now + 1, + lifespanExpiration: now + 1, + }) + ); + mockSessionIndex.get.mockResolvedValue( + sessionIndexMock.createValue({ + content: await encryptContent( + { username: 'some-user', state: 'some-state', userProfileId: 'uid' }, + mockAAD + ), + }) + ); + mockSessionIndex.isWithinConcurrentSessionLimit.mockResolvedValue(false); + + await expect(session.get(httpServerMock.createKibanaRequest())).resolves.toEqual({ + error: expect.any(SessionUnexpectedError), + value: null, + }); + expect(mockSessionCookie.clear).toHaveBeenCalledTimes(1); + expect(mockSessionIndex.invalidate).toHaveBeenCalledTimes(1); + expect(mockScopedAuditLogger.log).toHaveBeenCalledTimes(1); + expect(mockScopedAuditLogger.log).toHaveBeenCalledWith( + userSessionConcurrentLimitLogoutEvent({ + username: 'some-user', + userProfileId: 'uid', + provider: { name: 'basic1', type: 'basic' }, + }) + ); + }); + it('returns session value with decrypted content', async () => { mockSessionCookie.get.mockResolvedValue( sessionCookieMock.createValue({ @@ -596,6 +639,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); const mockRequest = httpServerMock.createKibanaRequest(); @@ -636,6 +680,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); const mockRequest = httpServerMock.createKibanaRequest(); @@ -711,6 +756,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); const mockRequest = httpServerMock.createKibanaRequest(); @@ -767,6 +813,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); }); @@ -912,6 +959,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); const mockRequest = httpServerMock.createKibanaRequest(); @@ -958,6 +1006,7 @@ describe('Session', () => { ), sessionCookie: mockSessionCookie, sessionIndex: mockSessionIndex, + audit: auditServiceMock.create(), }); const mockRequest = httpServerMock.createKibanaRequest(); diff --git a/x-pack/plugins/security/server/session_management/session.ts b/x-pack/plugins/security/server/session_management/session.ts index f805ff9517ba2..8969cc5939082 100644 --- a/x-pack/plugins/security/server/session_management/session.ts +++ b/x-pack/plugins/security/server/session_management/session.ts @@ -13,7 +13,9 @@ import { promisify } from 'util'; import type { KibanaRequest, Logger } from '@kbn/core/server'; import type { PublicMethodsOf } from '@kbn/utility-types'; +import type { AuditServiceSetup } from '..'; import type { AuthenticationProvider } from '../../common'; +import { userSessionConcurrentLimitLogoutEvent } from '../audit'; import type { ConfigType } from '../config'; import type { SessionCookie } from './session_cookie'; import { SessionExpiredError, SessionMissingError, SessionUnexpectedError } from './session_errors'; @@ -85,6 +87,7 @@ export interface SessionOptions { readonly sessionIndex: PublicMethodsOf; readonly sessionCookie: PublicMethodsOf; readonly config: Pick; + readonly audit: AuditServiceSetup; } export interface SessionValueContentToEncrypt { @@ -194,6 +197,26 @@ export class Session { return { error: new SessionUnexpectedError(), value: null }; } + // The only reason why we check if the session is within the concurrent session limit _after_ decryption + // is to record decrypted username and profile id in the audit logs. + const isSessionWithinConcurrentSessionLimit = + await this.options.sessionIndex.isWithinConcurrentSessionLimit(sessionIndexValue); + if (!isSessionWithinConcurrentSessionLimit) { + this.options.audit.asScoped(request).log( + userSessionConcurrentLimitLogoutEvent({ + username: decryptedContent.username, + userProfileId: decryptedContent.userProfileId, + provider: sessionIndexValue.provider, + }) + ); + + sessionLogger.warn( + 'Session is outside the concurrent session limit and will be invalidated.' + ); + await this.invalidate(request, { match: 'current' }); + return { error: new SessionUnexpectedError(), value: null }; + } + return { error: null, value: { diff --git a/x-pack/plugins/security/server/session_management/session_index.mock.ts b/x-pack/plugins/security/server/session_management/session_index.mock.ts index 41aa0d3ee60f9..6389bc67eac00 100644 --- a/x-pack/plugins/security/server/session_management/session_index.mock.ts +++ b/x-pack/plugins/security/server/session_management/session_index.mock.ts @@ -17,6 +17,7 @@ export const sessionIndexMock = { invalidate: jest.fn(), initialize: jest.fn(), cleanUp: jest.fn(), + isWithinConcurrentSessionLimit: jest.fn().mockResolvedValue(true), }), createValue: (sessionValue: Partial = {}): SessionIndexValue => ({ diff --git a/x-pack/plugins/security/server/session_management/session_index.test.ts b/x-pack/plugins/security/server/session_management/session_index.test.ts index 3b8005bcde21f..2178abc064179 100644 --- a/x-pack/plugins/security/server/session_management/session_index.test.ts +++ b/x-pack/plugins/security/server/session_management/session_index.test.ts @@ -10,6 +10,7 @@ import type { BulkResponse, ClosePointInTimeResponse, DeleteByQueryResponse, + MsearchMultiSearchResult, OpenPointInTimeResponse, SearchResponse, } from '@elastic/elasticsearch/lib/api/types'; @@ -18,6 +19,7 @@ import { elasticsearchServiceMock, loggingSystemMock } from '@kbn/core/server/mo import type { AuditLogger } from '../audit'; import { auditLoggerMock } from '../audit/mocks'; +import { AnonymousAuthenticationProvider } from '../authentication'; import { ConfigSchema, createConfig } from '../config'; import { securityMock } from '../mocks'; import { @@ -36,20 +38,23 @@ describe('Session index', () => { const indexName = '.kibana_some_tenant_security_session_1'; const aliasName = '.kibana_some_tenant_security_session'; const indexTemplateName = '.kibana_some_tenant_security_session_index_template_1'; + + const createSessionIndexOptions = ( + config: Record = { session: { idleTimeout: null, lifespan: null } } + ) => ({ + logger: loggingSystemMock.createLogger(), + kibanaIndexName: '.kibana_some_tenant', + config: createConfig(ConfigSchema.validate(config), loggingSystemMock.createLogger(), { + isTLSEnabled: false, + }), + elasticsearchClient: mockElasticsearchClient, + auditLogger, + }); + beforeEach(() => { mockElasticsearchClient = elasticsearchServiceMock.createElasticsearchClient(); auditLogger = auditLoggerMock.create(); - sessionIndex = new SessionIndex({ - logger: loggingSystemMock.createLogger(), - kibanaIndexName: '.kibana_some_tenant', - config: createConfig( - ConfigSchema.validate({ session: { idleTimeout: null, lifespan: null } }), - loggingSystemMock.createLogger(), - { isTLSEnabled: false } - ), - elasticsearchClient: mockElasticsearchClient, - auditLogger, - }); + sessionIndex = new SessionIndex(createSessionIndexOptions()); }); describe('#initialize', () => { @@ -947,6 +952,318 @@ describe('Session index', () => { }) ); }); + + describe('concurrent session limit', () => { + const expectedSearchParameters = () => ({ + index: '.kibana_some_tenant_security_session', + query: { + bool: { + filter: [ + { exists: { field: 'usernameHash' } }, + { + bool: { + must_not: [{ term: { 'provider.type': AnonymousAuthenticationProvider.type } }], + }, + }, + ], + }, + }, + aggs: { + sessions_grouped_by_user: { + multi_terms: { + size: 10000, + terms: [ + { field: 'usernameHash' }, + { field: 'provider.type' }, + { field: 'provider.name' }, + ], + min_doc_count: 3, + }, + }, + }, + size: 0, + filter_path: [ + 'aggregations.sessions_grouped_by_user.sum_other_doc_count', + 'aggregations.sessions_grouped_by_user.buckets.key', + 'aggregations.sessions_grouped_by_user.buckets.doc_count', + ], + track_total_hits: false, + }); + + const expectedMultiSearchParameters = ( + usernameHash: string, + providerType: string, + providerName: string + ) => ({ + query: { + bool: { + must: [ + { term: { usernameHash } }, + { term: { 'provider.type': providerType } }, + { term: { 'provider.name': providerName } }, + ], + }, + }, + sort: [{ createdAt: { order: 'desc' } }], + from: 2, + size: 9998, + _source: false, + track_total_hits: false, + }); + + beforeEach(() => { + // The first search call is used by the invalid/expired sessions cleanup routine. + mockElasticsearchClient.search.mockResolvedValueOnce({ + hits: { hits: [] }, + } as unknown as SearchResponse); + + sessionIndex = new SessionIndex( + createSessionIndexOptions({ + session: { idleTimeout: null, lifespan: null, concurrentSessions: { maxSessions: 2 } }, + }) + ); + }); + + it('when concurrent session limit is not configured', async () => { + sessionIndex = new SessionIndex(createSessionIndexOptions()); + + await sessionIndex.cleanUp(); + + // Only search call for the invalid sessions (use `pit` as marker, since concurrent session limit cleanup + // routine doesn't rely on PIT). + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith( + expect.objectContaining({ pit: { id: 'PIT_ID', keep_alive: '5m' } }) + ); + expect(mockElasticsearchClient.msearch).not.toHaveBeenCalled(); + expect(mockElasticsearchClient.bulk).not.toHaveBeenCalled(); + expect(mockElasticsearchClient.indices.refresh).not.toHaveBeenCalled(); + }); + + it('when the concurrent session limit is not exceeded', async () => { + mockElasticsearchClient.search.mockResolvedValueOnce({ + aggregations: { sessions_grouped_by_user: { sum_other_doc_count: 1 } }, + } as unknown as SearchResponse); + + await sessionIndex.cleanUp(); + + // Only search call for the invalid sessions (use `pit` as marker, since concurrent session limit cleanup + // routine doesn't rely on PIT). + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(2); + expect(mockElasticsearchClient.search).toHaveBeenNthCalledWith( + 2, + expectedSearchParameters() + ); + expect(mockElasticsearchClient.msearch).not.toHaveBeenCalled(); + expect(mockElasticsearchClient.bulk).not.toHaveBeenCalled(); + expect(mockElasticsearchClient.indices.refresh).not.toHaveBeenCalled(); + }); + + it('when the concurrent session limit is exceeded', async () => { + mockElasticsearchClient.search.mockResolvedValueOnce({ + aggregations: { + sessions_grouped_by_user: { + sum_other_doc_count: 1, + buckets: [{ key: ['user-hash-name', 'basic', 'basic1'], doc_count: 10 }], + }, + }, + } as unknown as SearchResponse); + mockElasticsearchClient.msearch.mockResolvedValue({ + responses: [{ status: 200, hits: { hits: [{ _id: 'some-id' }, { _id: 'some-id-2' }] } }], + } as MsearchMultiSearchResult); + + await sessionIndex.cleanUp(); + + // Only search call for the invalid sessions (use `pit` as marker, since concurrent session limit cleanup + // routine doesn't rely on PIT). + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(2); + expect(mockElasticsearchClient.search).toHaveBeenNthCalledWith( + 2, + expectedSearchParameters() + ); + + expect(mockElasticsearchClient.msearch).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.msearch).toHaveBeenCalledWith({ + index: '.kibana_some_tenant_security_session', + searches: [{}, expectedMultiSearchParameters('user-hash-name', 'basic', 'basic1')], + filter_path: ['responses.status', 'responses.hits.hits._id'], + }); + expect(mockElasticsearchClient.bulk).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.bulk).toHaveBeenCalledWith( + { + index: '.kibana_some_tenant_security_session', + operations: [{ delete: { _id: 'some-id' } }, { delete: { _id: 'some-id-2' } }], + refresh: false, + require_alias: true, + }, + { ignore: [409, 404] } + ); + expect(mockElasticsearchClient.indices.refresh).toHaveBeenCalledTimes(1); + }); + + it('when the concurrent session limit is exceeded for multiple providers', async () => { + mockElasticsearchClient.search.mockResolvedValueOnce({ + aggregations: { + sessions_grouped_by_user: { + sum_other_doc_count: 1, + buckets: [ + { key: ['user-hash-name', 'basic', 'basic1'], doc_count: 10 }, + // For this we simulate a race condition, when the limit is exceeded during aggregation, but not during + // `msearch` query. + { key: ['user-hash-name-2', 'basic', 'basic1'], doc_count: 1 }, + { key: ['user-hash-name-3', 'saml', 'saml1'], doc_count: 10 }, + ], + }, + }, + } as unknown as SearchResponse); + mockElasticsearchClient.msearch.mockResolvedValue({ + responses: [ + { status: 200, hits: { hits: [{ _id: 'some-id' }, { _id: 'some-id-2' }] } }, + { status: 200 }, + { status: 200, hits: { hits: [{ _id: 'some-id-3' }] } }, + ], + } as MsearchMultiSearchResult); + + await sessionIndex.cleanUp(); + + // Only search call for the invalid sessions (use `pit` as marker, since concurrent session limit cleanup + // routine doesn't rely on PIT). + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(2); + expect(mockElasticsearchClient.search).toHaveBeenNthCalledWith( + 2, + expectedSearchParameters() + ); + + expect(mockElasticsearchClient.msearch).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.msearch).toHaveBeenCalledWith({ + index: '.kibana_some_tenant_security_session', + searches: [ + {}, + expectedMultiSearchParameters('user-hash-name', 'basic', 'basic1'), + {}, + expectedMultiSearchParameters('user-hash-name-2', 'basic', 'basic1'), + {}, + expectedMultiSearchParameters('user-hash-name-3', 'saml', 'saml1'), + ], + filter_path: ['responses.status', 'responses.hits.hits._id'], + }); + expect(mockElasticsearchClient.bulk).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.bulk).toHaveBeenCalledWith( + { + index: '.kibana_some_tenant_security_session', + operations: [ + { delete: { _id: 'some-id' } }, + { delete: { _id: 'some-id-2' } }, + { delete: { _id: 'some-id-3' } }, + ], + refresh: false, + require_alias: true, + }, + { ignore: [409, 404] } + ); + expect(mockElasticsearchClient.indices.refresh).toHaveBeenCalledTimes(1); + }); + + it('should call bulk_delete in multiple chunks if total number of session to delete exceeds 10_000', async () => { + mockElasticsearchClient.search.mockResolvedValueOnce({ + aggregations: { + sessions_grouped_by_user: { + sum_other_doc_count: 1, + buckets: [{ key: ['user-hash-name', 'basic', 'basic1'], doc_count: 10 }], + }, + }, + } as unknown as SearchResponse); + mockElasticsearchClient.msearch.mockResolvedValue({ + responses: [ + { + status: 200, + hits: { + hits: Array.from({ length: 10002 }).map((_, index) => ({ + _id: `some-id-${index}`, + })), + }, + }, + ], + } as MsearchMultiSearchResult); + + await sessionIndex.cleanUp(); + + expect(mockElasticsearchClient.bulk).toHaveBeenCalledTimes(2); + expect(mockElasticsearchClient.bulk).toHaveBeenNthCalledWith( + 1, + { + index: '.kibana_some_tenant_security_session', + operations: expect.arrayContaining([ + { delete: { _id: 'some-id-0' } }, + { delete: { _id: 'some-id-9999' } }, + ]), + refresh: false, + require_alias: true, + }, + { ignore: [409, 404] } + ); + expect(mockElasticsearchClient.bulk).toHaveBeenNthCalledWith( + 2, + { + index: '.kibana_some_tenant_security_session', + operations: [ + { delete: { _id: 'some-id-10000' } }, + { delete: { _id: 'some-id-10001' } }, + ], + refresh: false, + require_alias: true, + }, + { ignore: [409, 404] } + ); + expect(mockElasticsearchClient.indices.refresh).toHaveBeenCalledTimes(1); + }); + + it('should log audit event', async () => { + mockElasticsearchClient.search.mockResolvedValueOnce({ + aggregations: { + sessions_grouped_by_user: { + sum_other_doc_count: 1, + buckets: [ + { key: ['user-hash-name', 'basic', 'basic1'], doc_count: 3 }, + { key: ['user-hash-name-2', 'saml', 'saml1'], doc_count: 3 }, + ], + }, + }, + } as unknown as SearchResponse); + mockElasticsearchClient.msearch.mockResolvedValue({ + responses: [ + { status: 200, hits: { hits: [{ _id: 'some-id' }] } }, + { status: 200, hits: { hits: [{ _id: 'some-id-2' }] } }, + ], + } as MsearchMultiSearchResult); + + await sessionIndex.cleanUp(); + + expect(auditLogger.log).toHaveBeenCalledTimes(2); + expect(auditLogger.log).toHaveBeenCalledWith( + expect.objectContaining({ + event: { action: 'session_cleanup', category: ['authentication'], outcome: 'unknown' }, + user: { hash: 'user-hash-name' }, + kibana: { + session_id: 'some-id', + authentication_provider: 'basic1', + authentication_type: 'basic', + }, + }) + ); + expect(auditLogger.log).toHaveBeenCalledWith( + expect.objectContaining({ + event: { action: 'session_cleanup', category: ['authentication'], outcome: 'unknown' }, + user: { hash: 'user-hash-name-2' }, + kibana: { + session_id: 'some-id-2', + authentication_provider: 'saml1', + authentication_type: 'saml', + }, + }) + ); + }); + }); }); describe('#get', () => { @@ -1480,4 +1797,167 @@ describe('Session index', () => { }); }); }); + + describe('#isWithinConcurrentSessionLimit', () => { + const expectedSearchParameters = () => ({ + index: '.kibana_some_tenant_security_session', + query: { + bool: { + filter: [ + { term: { usernameHash: 'some-username-hash' } }, + { term: { 'provider.type': 'basic' } }, + { term: { 'provider.name': 'basic1' } }, + ], + }, + }, + sort: [{ createdAt: { order: 'desc' } }], + _source_includes: 'createdAt', + filter_path: 'hits.hits._source', + from: 2, + size: 1, + track_total_hits: false, + }); + + beforeEach(() => { + sessionIndex = new SessionIndex( + createSessionIndexOptions({ + session: { idleTimeout: null, lifespan: null, concurrentSessions: { maxSessions: 2 } }, + }) + ); + }); + + it('throws if call to Elasticsearch fails', async () => { + const failureReason = new errors.ResponseError( + securityMock.createApiResponse(securityMock.createApiResponse({ body: { type: 'Uh oh.' } })) + ); + mockElasticsearchClient.search.mockRejectedValue(failureReason); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit(sessionIndexMock.createValue()) + ).rejects.toBe(failureReason); + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + + it('returns `true` if concurrent session limit is not configured', async () => { + sessionIndex = new SessionIndex(createSessionIndexOptions()); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit(sessionIndexMock.createValue()) + ).resolves.toBe(true); + expect(mockElasticsearchClient.search).not.toHaveBeenCalled(); + }); + + it('returns `true` for unauthenticated sessions', async () => { + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ usernameHash: undefined }) + ) + ).resolves.toBe(true); + expect(mockElasticsearchClient.search).not.toHaveBeenCalled(); + }); + + it('returns `true` if session belongs to the anonymous user', async () => { + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ + createdAt: 100, + provider: { type: AnonymousAuthenticationProvider.type, name: 'anonymous1' }, + }) + ) + ).resolves.toBe(true); + expect(mockElasticsearchClient.search).not.toHaveBeenCalled(); + }); + + it('returns `true` if session is within limit', async () => { + for (const value of [ + {} as SearchResponse, + { hits: { hits: [] } } as unknown as SearchResponse, + ]) { + mockElasticsearchClient.search.mockResolvedValue(value); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit(sessionIndexMock.createValue()) + ).resolves.toBe(true); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + + mockElasticsearchClient.search.mockClear(); + } + }); + + it('returns `true` if the specified session is not a legacy session, but the first session that is outside the limit is a legacy one', async () => { + mockElasticsearchClient.search.mockResolvedValue({ + hits: { hits: [{ _source: {} }] }, + } as SearchResponse); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit(sessionIndexMock.createValue()) + ).resolves.toBe(true); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + + it('returns `true` if the first session that is outside the limit is older than the specified session', async () => { + mockElasticsearchClient.search.mockResolvedValue({ + hits: { hits: [{ _source: { createdAt: 100 } }] }, + } as SearchResponse); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ createdAt: 200 }) + ) + ).resolves.toBe(true); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + + it('returns `false` if the limit is exceeded and specified session is a legacy session', async () => { + mockElasticsearchClient.search.mockResolvedValue({ + hits: { hits: [{ _source: { createdAt: 100 } }] }, + } as SearchResponse); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ createdAt: undefined }) + ) + ).resolves.toBe(false); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + + it('returns `false` if the first session that is outside the limit was created at the same time as the specified session', async () => { + mockElasticsearchClient.search.mockResolvedValue({ + hits: { hits: [{ _source: { createdAt: 100 } }] }, + } as SearchResponse); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ createdAt: 100 }) + ) + ).resolves.toBe(false); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + + it('returns `false` if the specified session is older than the first session that is outside the limit', async () => { + mockElasticsearchClient.search.mockResolvedValue({ + hits: { hits: [{ _source: { createdAt: 200 } }] }, + } as SearchResponse); + + await expect( + sessionIndex.isWithinConcurrentSessionLimit( + sessionIndexMock.createValue({ createdAt: 100 }) + ) + ).resolves.toBe(false); + + expect(mockElasticsearchClient.search).toHaveBeenCalledTimes(1); + expect(mockElasticsearchClient.search).toHaveBeenCalledWith(expectedSearchParameters()); + }); + }); }); diff --git a/x-pack/plugins/security/server/session_management/session_index.ts b/x-pack/plugins/security/server/session_management/session_index.ts index ab8882cbc4b0d..9041745c7d625 100644 --- a/x-pack/plugins/security/server/session_management/session_index.ts +++ b/x-pack/plugins/security/server/session_management/session_index.ts @@ -5,7 +5,14 @@ * 2.0. */ -import type { CreateRequest, IndicesCreateRequest } from '@elastic/elasticsearch/lib/api/types'; +import type { + AggregateName, + AggregationsMultiTermsAggregate, + CreateRequest, + IndicesCreateRequest, + MsearchRequestItem, + SearchHit, +} from '@elastic/elasticsearch/lib/api/types'; import type { BulkOperationContainer, SortResults, @@ -16,8 +23,10 @@ import type { ElasticsearchClient, Logger } from '@kbn/core/server'; import type { AuthenticationProvider } from '../../common/model'; import type { AuditLogger } from '../audit'; -import { sessionCleanupEvent } from '../audit'; +import { sessionCleanupConcurrentLimitEvent, sessionCleanupEvent } from '../audit'; +import { AnonymousAuthenticationProvider } from '../authentication'; import type { ConfigType } from '../config'; +import { getDetailedErrorMessage } from '../errors'; export interface SessionIndexOptions { readonly elasticsearchClient: ElasticsearchClient; @@ -166,6 +175,11 @@ export interface SessionIndexValue { metadata: SessionIndexValueMetadata; } +/** + * Subset of the `SessionIndexValue` fields required for session cleanup. + */ +type SessionIndexValueDescriptor = Pick; + /** * Additional index specific information about the session value. */ @@ -453,71 +467,153 @@ export class SessionIndex { * Trigger a removal of any outdated session values. */ async cleanUp() { - const { auditLogger, elasticsearchClient, logger } = this.options; - logger.debug(`Running cleanup routine.`); + const { auditLogger, logger } = this.options; + logger.debug('Running cleanup routine.'); let error: Error | undefined; let indexNeedsRefresh = false; try { for await (const sessionValues of this.getSessionValuesInBatches()) { - const operations: Array>> = []; - sessionValues.forEach(({ _id, _source }) => { + const operations = sessionValues.map(({ _id, _source }) => { const { usernameHash, provider } = _source!; auditLogger.log(sessionCleanupEvent({ sessionId: _id, usernameHash, provider })); - operations.push({ delete: { _id } }); + return { delete: { _id } }; }); - if (operations.length > 0) { - const bulkResponse = await elasticsearchClient.bulk( - { - index: this.aliasName, - operations, - refresh: false, - // delete operations do not respect `require_alias`, but we include it here for consistency. - require_alias: true, - }, - { ignore: [409, 404] } - ); - if (bulkResponse.errors) { - const errorCount = bulkResponse.items.reduce( - (count, item) => (item.delete!.error ? count + 1 : count), - 0 - ); - if (errorCount < bulkResponse.items.length) { - logger.warn( - `Failed to clean up ${errorCount} of ${bulkResponse.items.length} invalid or expired sessions. The remaining sessions were cleaned up successfully.` - ); - indexNeedsRefresh = true; - } else { - logger.error( - `Failed to clean up ${bulkResponse.items.length} invalid or expired sessions.` - ); - } - } else { - logger.debug(`Cleaned up ${bulkResponse.items.length} invalid or expired sessions.`); - indexNeedsRefresh = true; - } - } + + indexNeedsRefresh = (await this.bulkDeleteSessions(operations)) || indexNeedsRefresh; } } catch (err) { logger.error(`Failed to clean up sessions: ${err.message}`); error = err; } + // Only refresh the index if we have actually deleted one or more sessions. The index will auto-refresh eventually anyway, this just + // ensures that searches after the cleanup process are accurate, and this only impacts integration tests. if (indexNeedsRefresh) { - // Only refresh the index if we have actually deleted one or more sessions. The index will auto-refresh eventually anyway, this just - // ensures that searches after the cleanup process are accurate, and this only impacts integration tests. - try { - await elasticsearchClient.indices.refresh({ index: this.aliasName }); - logger.debug(`Refreshed session index.`); - } catch (err) { - logger.error(`Failed to refresh session index: ${err.message}`); + await this.refreshSessionIndex(); + } + + // Once index refresh is complete we can check if there are sessions left that exceed concurrent sessions limit. + try { + indexNeedsRefresh = false; + + const operations = (await this.getSessionsOutsideConcurrentSessionLimit()).map((session) => { + auditLogger.log( + sessionCleanupConcurrentLimitEvent({ + sessionId: session.sid, + usernameHash: session.usernameHash, + provider: session.provider, + }) + ); + return { delete: { _id: session.sid } }; + }); + + if (operations.length > 0) { + // Limit max number of documents to delete to 10_000 to avoid massively large delete request payloads (10k batch + // delete request payload is about 700kb). + const batchSize = SESSION_INDEX_CLEANUP_BATCH_SIZE; + for (let i = 0; i < operations.length; i += batchSize) { + indexNeedsRefresh = + (await this.bulkDeleteSessions(operations.slice(i, i + batchSize))) || + indexNeedsRefresh; + } } + } catch (err) { + logger.error( + `Failed to clean up sessions that exceeded concurrent sessions limit: ${err.message}` + ); + error = err; + } + + if (indexNeedsRefresh) { + await this.refreshSessionIndex(); } if (error) { + logger.error(`Cleanup routine failed: ${getDetailedErrorMessage(error)}.`); // If we couldn't fetch or delete sessions, throw an error so the task will be retried. throw error; } + + logger.debug('Cleanup routine successfully completed.'); + } + + /** + * Checks whether specific session is within a concurrent sessions limit. + * @param sessionValue Session index value to check against concurrent sessions limit. + */ + async isWithinConcurrentSessionLimit(sessionValue: Readonly) { + // Concurrent user sessions limit doesn't apply if it's not configured, or session isn't authenticated, or session + // belongs to the anonymous user. + const maxConcurrentSessions = this.options.config.session.concurrentSessions?.maxSessions; + if ( + maxConcurrentSessions == null || + !sessionValue.usernameHash || + sessionValue.provider.type === AnonymousAuthenticationProvider.type + ) { + return true; + } + + let sessionsOutsideLimit: Array>; + try { + const searchResponse = await this.options.elasticsearchClient.search({ + index: this.aliasName, + + // Find all sessions created for the same user by the same authentication provider. + query: { + bool: { + filter: [ + { term: { usernameHash: sessionValue.usernameHash } }, + { term: { 'provider.type': sessionValue.provider.type } }, + { term: { 'provider.name': sessionValue.provider.name } }, + ], + }, + }, + + // Sort sessions by creation date in descending order to get the most recent session that's also outside the + // limit. This query relies on a default value for `missing` sort parameter which is `_last`, meaning that + // sessions without `createdAt` field ("legacy" sessions) are always considered older than the ones that have + // this field populated. For example, if the limit is 2 the resulting set might look like this: + // { createdAt: 3 } <-- the most recent session (within the limit, not returned because of `from`) + // { createdAt: 2 } <-- the second most recent session (within the limit, not returned because of `from`) + // { createdAt: 1 } <-- the third most recent session (outside the limit, *returned*) + // { createdAt: undefined } <--- the oldest "legacy" session (outside the limit, not returned because of `size`) + sort: [{ createdAt: { order: 'desc' } }], + + // Improve performance by fetching just one field of one outside-the-limit session and not tracking total hits. + _source_includes: 'createdAt', + filter_path: 'hits.hits._source', + from: maxConcurrentSessions, + size: 1, + track_total_hits: false, + }); + sessionsOutsideLimit = searchResponse.hits?.hits ?? []; + } catch (err) { + this.options.logger.error( + `Failed to fetch user sessions to check concurrent sessions limit: ${err.message}.` + ); + throw err; + } + + // If all sessions are within the limit, then the provided one should be within the limit as well. + if (sessionsOutsideLimit.length === 0) { + return true; + } + + // If there is any session that is outside the limit and the provided session is "legacy" session (doesn't have a + // `createdAt` field populated), then we can safely treat it as outside-the-limit session (all "legacy" sessions are + // treated equally). + if (!sessionValue.createdAt) { + return false; + } + + // If the first outside-the-limit session doesn't have `createdAt` then all other sessions with `createdAt` are + // within the limit, otherwise the specified session is outside the limit only if it was created before or at the + // same time as the first outside-the-limit session. + const [{ _source: sessionOutsideLimit }] = sessionsOutsideLimit; + return ( + !sessionOutsideLimit?.createdAt || sessionValue.createdAt > sessionOutsideLimit.createdAt + ); } /** @@ -766,4 +862,231 @@ export class SessionIndex { }); } } + + private async getSessionsOutsideConcurrentSessionLimit(): Promise { + const maxConcurrentSessions = this.options.config.session.concurrentSessions?.maxSessions; + if (maxConcurrentSessions == null) { + return []; + } + + // 1. We need to figure out what users have sessions that exceed the concurrent session limit. For that, we group + // existing sessions by username and authentication provider. + const aggResponse = await this.options.elasticsearchClient.search< + unknown, + Record + >({ + index: this.aliasName, + + // Exclude unauthenticated sessions and sessions of the anonymous users that shouldn't be affected by the + // concurrent user sessions limit. + query: { + bool: { + filter: [ + { exists: { field: 'usernameHash' } }, + { + bool: { + must_not: [{ term: { 'provider.type': AnonymousAuthenticationProvider.type } }], + }, + }, + ], + }, + }, + + aggs: { + sessions_grouped_by_user: { + multi_terms: { + // If we have more than 10_000 users that all exceeded the limit (highly unlikely), then the rest of the + // sessions will be cleaned up during the next run. It doesn't expose Kibana to any security risks since the + // concurrent sessions limits is enforced on fetch. The `size` is limited by `search.max_buckets` setting + // which is 65,536 by default, but we don't want to load Elasticsearch too much (response size for 10000 + // buckets is around 1mb). + size: SESSION_INDEX_CLEANUP_BATCH_SIZE, + terms: [ + { field: 'usernameHash' }, + { field: 'provider.type' }, + { field: 'provider.name' }, + ], + // Return only those groups that exceed the limit. + min_doc_count: maxConcurrentSessions + 1, + }, + }, + }, + + // Improve performance by not tracking total hits, not returning hits themselves (size=0), and fetching only buckets keys. + size: 0, + filter_path: [ + 'aggregations.sessions_grouped_by_user.sum_other_doc_count', + 'aggregations.sessions_grouped_by_user.buckets.key', + 'aggregations.sessions_grouped_by_user.buckets.doc_count', + ], + track_total_hits: false, + }); + + // The reason we check if buckets is an array is to narrow down the type of the response since ES can return buckets as + // either an array OR a dictionary (aggregation has keys configured for the different buckets, that's not the case here). + const sessionsGroupedByUser = aggResponse.aggregations?.sessions_grouped_by_user; + const sessionBuckets = sessionsGroupedByUser?.buckets ?? []; + if (sessionBuckets.length === 0 || !Array.isArray(sessionBuckets)) { + return []; + } + + // Log a warning if we didn't fetch buckets for all users that exceeded the limit. + const ungroupedSessions = sessionsGroupedByUser?.sum_other_doc_count ?? 0; + if (ungroupedSessions > 0) { + this.options.logger.warn( + `Unable to check if remaining ${ungroupedSessions} sessions exceed the concurrent session limit. Sessions will be checked during the next cleanup job run.` + ); + } + + // 2. Once we know what users within what authentication providers exceed the concurrent sessions limit, we can + // fetch specific sessions documents that are outside the limit. + const { sessionGroups, sessionQueries, skippedSessions } = sessionBuckets.reduce( + (result, sessionGroup) => { + // The keys are arrays of values ordered the same ways as expression in the terms parameter of the aggregation. + const [usernameHash, providerType, providerName] = sessionGroup.key as string[]; + + // Record a number of session documents that won't be included in the batch during this run. + if (sessionGroup.doc_count > SESSION_INDEX_CLEANUP_BATCH_SIZE) { + result.skippedSessions += sessionGroup.doc_count - SESSION_INDEX_CLEANUP_BATCH_SIZE; + } + + result.sessionGroups.push({ + usernameHash, + provider: { type: providerType, name: providerName }, + }); + + result.sessionQueries.push( + {}, + { + query: { + bool: { + must: [ + { term: { usernameHash } }, + { term: { 'provider.type': providerType } }, + { term: { 'provider.name': providerName } }, + ], + }, + }, + + // Sort sessions by creation date in descending order to get the most recent session that's also outside the + // limit. Refer to comment in `isWithinConcurrentSessionLimit` for the explanation and example. + sort: [{ createdAt: { order: 'desc' } }], + + // We only need to fetch sessions that exceed the limit. + from: maxConcurrentSessions, + size: SESSION_INDEX_CLEANUP_BATCH_SIZE - maxConcurrentSessions, + + // Improve performance by not tracking total hits and not fetching _source since we already have all necessary + // data returned within aggregation buckets (`usernameHash` and `provider`). + _source: false, + track_total_hits: false, + } + ); + + return result; + }, + { sessionGroups: [], sessionQueries: [], skippedSessions: 0 } as { + sessionGroups: Array>; + sessionQueries: MsearchRequestItem[]; + skippedSessions: number; + } + ); + + // Log a warning if we didn't fetch all sessions that exceeded the limit. + if (skippedSessions > 0) { + this.options.logger.warn( + `Unable to fetch ${skippedSessions} sessions that exceed the concurrent session limit. Sessions will be fetched and invalidated during the next cleanup job run.` + ); + } + + const { responses } = await this.options.elasticsearchClient.msearch({ + index: this.aliasName, + searches: sessionQueries, + filter_path: ['responses.status', 'responses.hits.hits._id'], + }); + + const sessionValueDescriptors = responses.flatMap( + (response, index) => { + if ('error' in response) { + this.options.logger.error( + `Failed to fetch sessions that exceed the concurrent session limit: ${ + getDetailedErrorMessage(response.error) ?? + response.error.reason ?? + response.error.type + }.` + ); + return []; + } + + return response.hits?.hits?.map((hit) => ({ sid: hit._id, ...sessionGroups[index] })) ?? []; + } + ); + + this.options.logger.debug( + `Preparing to delete ${sessionValueDescriptors.length} sessions of ${sessionBuckets.length} unique users due to exceeded concurrent sessions limit.` + ); + + return sessionValueDescriptors; + } + + /** + * Performs a bulk delete operation on the Kibana session index. + * @param deleteOperations Bulk delete operations. + * @returns Returns `true` if the bulk delete affected any session document. + */ + private async bulkDeleteSessions( + deleteOperations: Array>> + ) { + if (deleteOperations.length === 0) { + return false; + } + + const bulkResponse = await this.options.elasticsearchClient.bulk( + { + index: this.aliasName, + operations: deleteOperations, + refresh: false, + // delete operations do not respect `require_alias`, but we include it here for consistency. + require_alias: true, + }, + { ignore: [409, 404] } + ); + + if (!bulkResponse.errors) { + this.options.logger.debug( + `Cleaned up ${bulkResponse.items.length} invalid or expired sessions.` + ); + return true; + } + + const errorCount = bulkResponse.items.reduce( + (count, item) => (item.delete!.error ? count + 1 : count), + 0 + ); + if (errorCount < bulkResponse.items.length) { + this.options.logger.warn( + `Failed to clean up ${errorCount} of ${bulkResponse.items.length} invalid or expired sessions. The remaining sessions were cleaned up successfully.` + ); + return true; + } + + this.options.logger.error( + `Failed to clean up ${bulkResponse.items.length} invalid or expired sessions.` + ); + + return false; + } + + /** + * Refreshes Kibana session index. This is used as a part of the session index cleanup job only and hence doesn't + * throw even if the operation fails. + */ + private async refreshSessionIndex() { + try { + await this.options.elasticsearchClient.indices.refresh({ index: this.aliasName }); + this.options.logger.debug(`Refreshed session index.`); + } catch (err) { + this.options.logger.error(`Failed to refresh session index: ${err.message}`); + } + } } diff --git a/x-pack/plugins/security/server/session_management/session_management_service.test.ts b/x-pack/plugins/security/server/session_management/session_management_service.test.ts index 000d9151d9fdc..267f99b3761c4 100644 --- a/x-pack/plugins/security/server/session_management/session_management_service.test.ts +++ b/x-pack/plugins/security/server/session_management/session_management_service.test.ts @@ -15,8 +15,8 @@ import type { import { taskManagerMock } from '@kbn/task-manager-plugin/server/mocks'; import { nextTick } from '@kbn/test-jest-helpers'; -import type { AuditLogger } from '../audit'; -import { auditLoggerMock } from '../audit/mocks'; +import type { AuditServiceSetup } from '../audit'; +import { auditServiceMock } from '../audit/mocks'; import { ConfigSchema, createConfig } from '../config'; import type { OnlineStatusRetryScheduler } from '../elasticsearch'; import { Session } from './session'; @@ -34,10 +34,10 @@ mockSessionIndexCleanUp.mockResolvedValue(); describe('SessionManagementService', () => { let service: SessionManagementService; - let auditLogger: AuditLogger; + let auditSetupMock: AuditServiceSetup; beforeEach(() => { service = new SessionManagementService(loggingSystemMock.createLogger()); - auditLogger = auditLoggerMock.create(); + auditSetupMock = auditServiceMock.create(); }); afterEach(() => { @@ -100,7 +100,7 @@ describe('SessionManagementService', () => { const mockStatusSubject = new Subject(); expect( service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -112,7 +112,7 @@ describe('SessionManagementService', () => { it('registers proper session index cleanup task runner', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -132,7 +132,7 @@ describe('SessionManagementService', () => { it('initializes session index and schedules session index cleanup task when Elasticsearch goes online', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -170,7 +170,7 @@ describe('SessionManagementService', () => { it('removes old cleanup task if cleanup interval changes', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -206,7 +206,7 @@ describe('SessionManagementService', () => { it('does not remove old cleanup task if cleanup interval does not change', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -233,7 +233,7 @@ describe('SessionManagementService', () => { it('schedules retry if index initialization fails', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -270,7 +270,7 @@ describe('SessionManagementService', () => { it('schedules retry if cleanup task registration fails', async () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), @@ -323,7 +323,7 @@ describe('SessionManagementService', () => { it('properly unsubscribes from status updates', () => { const mockStatusSubject = new Subject(); service.start({ - auditLogger, + audit: auditSetupMock, elasticsearchClient: elasticsearchServiceMock.createElasticsearchClient(), kibanaIndexName: '.kibana', online$: mockStatusSubject.asObservable(), diff --git a/x-pack/plugins/security/server/session_management/session_management_service.ts b/x-pack/plugins/security/server/session_management/session_management_service.ts index ee79e2eb0f1d3..289f60aa973c0 100644 --- a/x-pack/plugins/security/server/session_management/session_management_service.ts +++ b/x-pack/plugins/security/server/session_management/session_management_service.ts @@ -14,7 +14,7 @@ import type { TaskManagerStartContract, } from '@kbn/task-manager-plugin/server'; -import type { AuditLogger } from '../audit'; +import type { AuditServiceSetup } from '../audit'; import type { ConfigType } from '../config'; import type { OnlineStatusRetryScheduler } from '../elasticsearch'; import { Session } from './session'; @@ -32,7 +32,7 @@ export interface SessionManagementServiceStartParams { readonly kibanaIndexName: string; readonly online$: Observable; readonly taskManager: TaskManagerStartContract; - readonly auditLogger: AuditLogger; + readonly audit: AuditServiceSetup; } export interface SessionManagementServiceStart { @@ -80,14 +80,14 @@ export class SessionManagementService { kibanaIndexName, online$, taskManager, - auditLogger, + audit, }: SessionManagementServiceStartParams): SessionManagementServiceStart { this.sessionIndex = new SessionIndex({ config: this.config, elasticsearchClient, kibanaIndexName, logger: this.logger.get('index'), - auditLogger, + auditLogger: audit.withoutRequest, }); this.statusSubscription = online$.subscribe(async ({ scheduleRetry }) => { @@ -104,6 +104,7 @@ export class SessionManagementService { sessionCookie: this.sessionCookie, sessionIndex: this.sessionIndex, config: this.config, + audit, }), }; } diff --git a/x-pack/plugins/security/server/usage_collector/security_usage_collector.test.ts b/x-pack/plugins/security/server/usage_collector/security_usage_collector.test.ts index 286aed84527af..8f74d62b64c68 100644 --- a/x-pack/plugins/security/server/usage_collector/security_usage_collector.test.ts +++ b/x-pack/plugins/security/server/usage_collector/security_usage_collector.test.ts @@ -49,6 +49,7 @@ describe('Security UsageCollector', () => { sessionIdleTimeoutInMinutes: 480, sessionLifespanInMinutes: 43200, sessionCleanupInMinutes: 60, + sessionConcurrentSessionsMaxSessions: 0, anonymousCredentialType: undefined, }; @@ -110,6 +111,7 @@ describe('Security UsageCollector', () => { sessionIdleTimeoutInMinutes: 0, sessionLifespanInMinutes: 0, sessionCleanupInMinutes: 0, + sessionConcurrentSessionsMaxSessions: 0, anonymousCredentialType: undefined, }); }); @@ -476,10 +478,15 @@ describe('Security UsageCollector', () => { describe('session', () => { // Note: can't easily test deprecated 'sessionTimeout' value here because of the way that config deprecation renaming works - it('reports customized session idleTimeout, lifespan, and cleanupInterval', async () => { + it('reports customized session idleTimeout, lifespan, cleanupInterval, and max concurrent sessions', async () => { const config = createSecurityConfig( ConfigSchema.validate({ - session: { idleTimeout: '123m', lifespan: '456m', cleanupInterval: '789m' }, + session: { + idleTimeout: '123m', + lifespan: '456m', + cleanupInterval: '789m', + concurrentSessions: { maxSessions: 321 }, + }, }) ); const usageCollection = usageCollectionPluginMock.createSetupContract(); @@ -495,6 +502,7 @@ describe('Security UsageCollector', () => { sessionIdleTimeoutInMinutes: 123, sessionLifespanInMinutes: 456, sessionCleanupInMinutes: 789, + sessionConcurrentSessionsMaxSessions: 321, }); }); }); diff --git a/x-pack/plugins/security/server/usage_collector/security_usage_collector.ts b/x-pack/plugins/security/server/usage_collector/security_usage_collector.ts index d33ff8617e453..f73ac0bbb25a3 100644 --- a/x-pack/plugins/security/server/usage_collector/security_usage_collector.ts +++ b/x-pack/plugins/security/server/usage_collector/security_usage_collector.ts @@ -20,6 +20,7 @@ interface Usage { sessionIdleTimeoutInMinutes: number; sessionLifespanInMinutes: number; sessionCleanupInMinutes: number; + sessionConcurrentSessionsMaxSessions: number; anonymousCredentialType: string | undefined; } @@ -123,6 +124,12 @@ export function registerSecurityUsageCollector({ usageCollection, config, licens 'The session cleanup interval that is configured, in minutes (0 if disabled).', }, }, + sessionConcurrentSessionsMaxSessions: { + type: 'long', + _meta: { + description: 'The maximum number of the concurrent user sessions (0 if not configured).', + }, + }, anonymousCredentialType: { type: 'keyword', _meta: { @@ -144,6 +151,7 @@ export function registerSecurityUsageCollector({ usageCollection, config, licens sessionIdleTimeoutInMinutes: 0, sessionLifespanInMinutes: 0, sessionCleanupInMinutes: 0, + sessionConcurrentSessionsMaxSessions: 0, anonymousCredentialType: undefined, }; } @@ -172,6 +180,8 @@ export function registerSecurityUsageCollector({ usageCollection, config, licens const sessionIdleTimeoutInMinutes = sessionExpirations.idleTimeout?.asMinutes() ?? 0; const sessionLifespanInMinutes = sessionExpirations.lifespan?.asMinutes() ?? 0; const sessionCleanupInMinutes = config.session.cleanupInterval?.asMinutes() ?? 0; + const sessionConcurrentSessionsMaxSessions = + config.session.concurrentSessions?.maxSessions ?? 0; const anonProviders = config.authc.providers.anonymous ?? ({} as Record); const foundProvider = Object.entries(anonProviders).find( @@ -201,6 +211,7 @@ export function registerSecurityUsageCollector({ usageCollection, config, licens sessionIdleTimeoutInMinutes, sessionLifespanInMinutes, sessionCleanupInMinutes, + sessionConcurrentSessionsMaxSessions, anonymousCredentialType, }; }, diff --git a/x-pack/plugins/security_solution/common/endpoint/data_generators/base_data_generator.ts b/x-pack/plugins/security_solution/common/endpoint/data_generators/base_data_generator.ts index 01ecc95524b27..27ea555cf7270 100644 --- a/x-pack/plugins/security_solution/common/endpoint/data_generators/base_data_generator.ts +++ b/x-pack/plugins/security_solution/common/endpoint/data_generators/base_data_generator.ts @@ -6,7 +6,7 @@ */ import seedrandom from 'seedrandom'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; const OS_FAMILY = ['windows', 'macos', 'linux']; @@ -160,12 +160,12 @@ export class BaseDataGenerator { /** generate a UUID (v4) */ protected randomUUID(): string { - return uuid.v4(); + return uuidv4(); } /** generate a seeded random UUID v4 */ protected seededUUIDv4(): string { - return uuid.v4({ random: [...this.randomNGenerator(255, 16)] }); + return uuidv4({ random: [...this.randomNGenerator(255, 16)] }); } /** Generate a random number up to the max provided */ diff --git a/x-pack/plugins/security_solution/common/endpoint/data_loaders/index_endpoint_hosts.ts b/x-pack/plugins/security_solution/common/endpoint/data_loaders/index_endpoint_hosts.ts index 18b59998b0745..f9f96e650c056 100644 --- a/x-pack/plugins/security_solution/common/endpoint/data_loaders/index_endpoint_hosts.ts +++ b/x-pack/plugins/security_solution/common/endpoint/data_loaders/index_endpoint_hosts.ts @@ -8,7 +8,7 @@ import type { Client } from '@elastic/elasticsearch'; import { cloneDeep } from 'lodash'; import type { AxiosResponse } from 'axios'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { KbnClient } from '@kbn/test'; import type { DeleteByQueryResponse } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; import type { Agent, CreatePackagePolicyResponse, GetInfoResponse } from '@kbn/fleet-plugin/common'; @@ -133,7 +133,7 @@ export async function indexEndpointHostDocs({ if (enrollFleet) { const { id: appliedPolicyId, name: appliedPolicyName } = hostMetadata.Endpoint.policy.applied; - const uniqueAppliedPolicyName = `${appliedPolicyName}-${uuid.v4()}`; + const uniqueAppliedPolicyName = `${appliedPolicyName}-${uuidv4()}`; // If we don't yet have a "real" policy record, then create it now in ingest (package config) if (!realPolicies[appliedPolicyId]) { diff --git a/x-pack/plugins/security_solution/common/endpoint/schema/actions.test.ts b/x-pack/plugins/security_solution/common/endpoint/schema/actions.test.ts index 1d7943bdefa1b..02988be98c4bf 100644 --- a/x-pack/plugins/security_solution/common/endpoint/schema/actions.test.ts +++ b/x-pack/plugins/security_solution/common/endpoint/schema/actions.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { EndpointActionListRequestSchema, @@ -29,20 +29,20 @@ describe('actions schemas', () => { it('should accept an agent ID if not in an array', () => { expect(() => { - EndpointActionListRequestSchema.query.validate({ agentIds: uuid.v4() }); + EndpointActionListRequestSchema.query.validate({ agentIds: uuidv4() }); }).not.toThrow(); }); it('should accept an agent ID in an array', () => { expect(() => { - EndpointActionListRequestSchema.query.validate({ agentIds: [uuid.v4()] }); + EndpointActionListRequestSchema.query.validate({ agentIds: [uuidv4()] }); }).not.toThrow(); }); it('should accept multiple agent IDs in an array', () => { expect(() => { EndpointActionListRequestSchema.query.validate({ - agentIds: [uuid.v4(), uuid.v4(), uuid.v4()], + agentIds: [uuidv4(), uuidv4(), uuidv4()], }); }).not.toThrow(); }); @@ -52,7 +52,7 @@ describe('actions schemas', () => { EndpointActionListRequestSchema.query.validate({ agentIds: Array(255) .fill(1) - .map(() => uuid.v4()), + .map(() => uuidv4()), }); }).not.toThrow(); }); diff --git a/x-pack/plugins/security_solution/common/endpoint/service/artifacts/utils.ts b/x-pack/plugins/security_solution/common/endpoint/service/artifacts/utils.ts index 465460563e3fa..725a13e618b6d 100644 --- a/x-pack/plugins/security_solution/common/endpoint/service/artifacts/utils.ts +++ b/x-pack/plugins/security_solution/common/endpoint/service/artifacts/utils.ts @@ -9,7 +9,7 @@ import type { ExceptionListItemSchema, CreateExceptionListItemSchema, } from '@kbn/securitysolution-io-ts-list-types'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { BY_POLICY_ARTIFACT_TAG_PREFIX, GLOBAL_ARTIFACT_TAG } from './constants'; const POLICY_ID_START_POSITION = BY_POLICY_ARTIFACT_TAG_PREFIX.length; @@ -43,7 +43,7 @@ export const createExceptionListItemForCreate = (listId: string): CreateExceptio item_id: undefined, list_id: listId, meta: { - temporaryUuid: uuid.v4(), + temporaryUuid: uuidv4(), }, name: '', namespace_type: 'agnostic', diff --git a/x-pack/plugins/security_solution/common/guided_onboarding/siem_guide_config.ts b/x-pack/plugins/security_solution/common/guided_onboarding/siem_guide_config.ts index a317971b2b7fe..6d47988af1d92 100644 --- a/x-pack/plugins/security_solution/common/guided_onboarding/siem_guide_config.ts +++ b/x-pack/plugins/security_solution/common/guided_onboarding/siem_guide_config.ts @@ -5,7 +5,7 @@ * 2.0. */ -import type { GuideConfig } from '@kbn/guided-onboarding-plugin/common'; +import type { GuideConfig } from '@kbn/guided-onboarding'; import { i18n } from '@kbn/i18n'; export const siemGuideId = 'siem'; diff --git a/x-pack/plugins/security_solution/cypress/e2e/detection_rules/rules_table_auto_refresh.cy.ts b/x-pack/plugins/security_solution/cypress/e2e/detection_rules/rules_table_auto_refresh.cy.ts index ca5ce2b2bfebd..c54c77c63d67b 100644 --- a/x-pack/plugins/security_solution/cypress/e2e/detection_rules/rules_table_auto_refresh.cy.ts +++ b/x-pack/plugins/security_solution/cypress/e2e/detection_rules/rules_table_auto_refresh.cy.ts @@ -24,7 +24,7 @@ import { checkAutoRefreshIsDisabled, checkAutoRefreshIsEnabled, } from '../../tasks/alerts_detection_rules'; -import { login, visit } from '../../tasks/login'; +import { login, visit, visitWithoutDateRange } from '../../tasks/login'; import { DETECTIONS_RULE_MANAGEMENT_URL } from '../../urls/navigation'; import { createCustomRule } from '../../tasks/api_calls/rules'; @@ -43,36 +43,36 @@ describe('Alerts detection rules table auto-refresh', () => { }); it('Auto refreshes rules', () => { - visit(DETECTIONS_RULE_MANAGEMENT_URL); + visitWithoutDateRange(DETECTIONS_RULE_MANAGEMENT_URL); - mockGlobalClock(); waitForRulesTableToBeLoaded(); // ensure rules have rendered. As there is no user interaction in this test, // rules were not rendered before test completes cy.get(RULE_CHECKBOX).should('have.length', 6); - // mock 1 minute passing to make sure refresh is conducted + // // mock 1 minute passing to make sure refresh is conducted + mockGlobalClock(); checkAutoRefresh(DEFAULT_RULE_REFRESH_INTERVAL_VALUE, 'be.visible'); cy.contains(REFRESH_RULES_STATUS, 'Updated now'); }); it('should prevent table from rules refetch if any rule selected', () => { - visit(DETECTIONS_RULE_MANAGEMENT_URL); + visitWithoutDateRange(DETECTIONS_RULE_MANAGEMENT_URL); - mockGlobalClock(); waitForRulesTableToBeLoaded(); selectNumberOfRules(1); // mock 1 minute passing to make sure refresh is not conducted + mockGlobalClock(); checkAutoRefresh(DEFAULT_RULE_REFRESH_INTERVAL_VALUE, 'not.exist'); // ensure rule is still selected cy.get(RULE_CHECKBOX).first().should('be.checked'); - cy.contains(REFRESH_RULES_STATUS, 'Updated 1 minute ago'); + cy.get(REFRESH_RULES_STATUS).should('have.not.text', 'Updated now'); }); it('should disable auto refresh when any rule selected and enable it after rules unselected', () => { diff --git a/x-pack/plugins/security_solution/cypress/screens/create_new_rule.ts b/x-pack/plugins/security_solution/cypress/screens/create_new_rule.ts index 98c5df0bc8ea0..146f5d68d70e9 100644 --- a/x-pack/plugins/security_solution/cypress/screens/create_new_rule.ts +++ b/x-pack/plugins/security_solution/cypress/screens/create_new_rule.ts @@ -142,7 +142,7 @@ export const RISK_OVERRIDE = export const RULES_CREATION_FORM = '[data-test-subj="stepDefineRule"]'; -export const RULES_CREATION_PREVIEW_BUTTON = '[data-test-subj="preview-flyout"]'; +export const RULES_CREATION_PREVIEW_BUTTON = '[data-test-subj="preview-container"]'; export const RULES_CREATION_PREVIEW_REFRESH_BUTTON = '[data-test-subj="previewSubmitButton"]'; diff --git a/x-pack/plugins/security_solution/public/app/home/global_header/index.test.tsx b/x-pack/plugins/security_solution/public/app/home/global_header/index.test.tsx index bd5049909c95d..abd7712a6073f 100644 --- a/x-pack/plugins/security_solution/public/app/home/global_header/index.test.tsx +++ b/x-pack/plugins/security_solution/public/app/home/global_header/index.test.tsx @@ -32,16 +32,7 @@ jest.mock('react-router-dom', () => { return { ...actual, useLocation: jest.fn().mockReturnValue({ pathname: '' }) }; }); -jest.mock('../../../common/lib/kibana', () => { - const originalModule = jest.requireActual('../../../common/lib/kibana'); - return { - ...originalModule, - useKibana: jest.fn().mockReturnValue({ - services: { theme: { theme$: {} }, http: { basePath: { prepend: jest.fn((href) => href) } } }, - }), - useUiSetting$: jest.fn().mockReturnValue([]), - }; -}); +jest.mock('../../../common/lib/kibana'); jest.mock('../../../common/containers/source', () => ({ useFetchIndex: () => [false, { indicesExist: true, indexPatterns: mockIndexPattern }], diff --git a/x-pack/plugins/security_solution/public/common/components/alerts_treemap/lib/legend/index.ts b/x-pack/plugins/security_solution/public/common/components/alerts_treemap/lib/legend/index.ts index 5f705e4f0c9fd..a47245e70389f 100644 --- a/x-pack/plugins/security_solution/public/common/components/alerts_treemap/lib/legend/index.ts +++ b/x-pack/plugins/security_solution/public/common/components/alerts_treemap/lib/legend/index.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { LegendItem } from '../../../charts/draggable_legend_item'; import { getFillColor } from '../chart_palette'; @@ -34,7 +34,7 @@ export const getLegendItemFromRawBucket = ({ : undefined, count: bucket.doc_count, dataProviderId: escapeDataProviderId( - `draggable-legend-item-treemap-${stackByField0}-${bucket.key}-${uuid.v4()}` + `draggable-legend-item-treemap-${stackByField0}-${bucket.key}-${uuidv4()}` ), render: () => getLabel({ @@ -64,7 +64,7 @@ export const getLegendItemFromFlattenedBucket = ({ }), count: stackByField1DocCount, dataProviderId: escapeDataProviderId( - `draggable-legend-item-treemap-${key}-${stackByField1Key}-${uuid.v4()}` + `draggable-legend-item-treemap-${key}-${stackByField1Key}-${uuidv4()}` ), render: () => `${stackByField1Key}`, field: `${stackByField1}`, diff --git a/x-pack/plugins/security_solution/public/common/components/alerts_treemap_panel/index.tsx b/x-pack/plugins/security_solution/public/common/components/alerts_treemap_panel/index.tsx index 75c78a3be8641..a3ba582b3c974 100644 --- a/x-pack/plugins/security_solution/public/common/components/alerts_treemap_panel/index.tsx +++ b/x-pack/plugins/security_solution/public/common/components/alerts_treemap_panel/index.tsx @@ -11,7 +11,7 @@ import { EuiProgress } from '@elastic/eui'; import type { Filter, Query } from '@kbn/es-query'; import { buildEsQuery } from '@kbn/es-query'; import React, { useEffect, useMemo } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { useGlobalTime } from '../../containers/use_global_time'; import { AlertsTreemap, DEFAULT_MIN_CHART_HEIGHT } from '../alerts_treemap'; @@ -83,7 +83,7 @@ const AlertsTreemapPanelComponent: React.FC = ({ const { to, from, deleteQuery, setQuery } = useGlobalTime(false); // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `${ALERTS_TREEMAP_ID}-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `${ALERTS_TREEMAP_ID}-${uuidv4()}`, []); const additionalFilters = useMemo(() => { try { diff --git a/x-pack/plugins/security_solution/public/common/components/charts/barchart.tsx b/x-pack/plugins/security_solution/public/common/components/charts/barchart.tsx index 207aa4236ed09..7e9b6b3bd01dc 100644 --- a/x-pack/plugins/security_solution/public/common/components/charts/barchart.tsx +++ b/x-pack/plugins/security_solution/public/common/components/charts/barchart.tsx @@ -10,7 +10,7 @@ import React, { useMemo } from 'react'; import { Chart, BarSeries, Axis, Position, ScaleType, Settings } from '@elastic/charts'; import { getOr, get, isNumber } from 'lodash/fp'; import deepmerge from 'deepmerge'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import styled from 'styled-components'; import deepEqual from 'fast-deep-equal'; @@ -189,7 +189,7 @@ export const BarChartComponent: React.FC = ({ ? barChart.map((d, i) => ({ color: d.color ?? (i < defaultLegendColors.length ? defaultLegendColors[i] : undefined), dataProviderId: escapeDataProviderId( - `draggable-legend-item-${uuid.v4()}-${stackByField}-${d.key}` + `draggable-legend-item-${uuidv4()}-${stackByField}-${d.key}` ), scopeId, field: stackByField, diff --git a/x-pack/plugins/security_solution/public/common/components/charts/donutchart.test.tsx b/x-pack/plugins/security_solution/public/common/components/charts/donutchart.test.tsx index 69b1f478a5cf1..c652daa786567 100644 --- a/x-pack/plugins/security_solution/public/common/components/charts/donutchart.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/charts/donutchart.test.tsx @@ -15,7 +15,7 @@ import { DonutChart } from './donutchart'; import { DraggableLegend } from './draggable_legend'; import { ChartLabel } from '../../../overview/components/detection_response/alerts_by_status/chart_label'; import { escapeDataProviderId } from '../drag_and_drop/helpers'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; jest.mock('@elastic/charts', () => { const actual = jest.requireActual('@elastic/charts'); @@ -75,7 +75,7 @@ describe('DonutChart', () => { totalCount: parsedMockAlertsData?.open?.total, legendItems: (['critical', 'high', 'medium', 'low'] as Severity[]).map((d) => ({ color: testColors[d], - dataProviderId: escapeDataProviderId(`draggable-legend-item-${uuid.v4()}-${d}`), + dataProviderId: escapeDataProviderId(`draggable-legend-item-${uuidv4()}-${d}`), timelineId: undefined, field: 'kibana.alert.severity', value: d, diff --git a/x-pack/plugins/security_solution/public/common/components/charts/donutchart.tsx b/x-pack/plugins/security_solution/public/common/components/charts/donutchart.tsx index de7898b2e7296..949ab19e4ef1d 100644 --- a/x-pack/plugins/security_solution/public/common/components/charts/donutchart.tsx +++ b/x-pack/plugins/security_solution/public/common/components/charts/donutchart.tsx @@ -56,7 +56,7 @@ export interface DonutChartProps { export interface DonutChartWrapperProps { children?: React.ReactElement; dataExists: boolean; - label: React.ReactElement | string; + label?: React.ReactElement | string; title: React.ReactElement | string | number | null; isChartEmbeddablesEnabled?: boolean; } @@ -111,17 +111,19 @@ const DonutChartWrapperComponent: React.FC = ({ justifyContent="center" > {title} - - - - {label} - - - + {label && ( + + + + {label} + + + + )} {children} diff --git a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/anomaly_table_provider.tsx b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/anomaly_table_provider.tsx index 8516655032620..6fb2e807ccae1 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/anomaly_table_provider.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/anomaly_table_provider.tsx @@ -5,14 +5,15 @@ * 2.0. */ -import React from 'react'; -import { useInstalledSecurityJobsIds } from '../hooks/use_installed_security_jobs'; +import React, { useMemo } from 'react'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; import type { InfluencerInput, Anomalies, CriteriaFields } from '../types'; import { useAnomaliesTableData } from './use_anomalies_table_data'; interface ChildrenArgs { isLoadingAnomaliesData: boolean; anomaliesData: Anomalies | null; + jobNameById: Record; } interface Props { @@ -26,7 +27,9 @@ interface Props { export const AnomalyTableProvider = React.memo( ({ influencers, startDate, endDate, children, criteriaFields, skip }) => { - const { jobIds } = useInstalledSecurityJobsIds(); + const { jobNameById } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); + const [isLoadingAnomaliesData, anomaliesData] = useAnomaliesTableData({ criteriaFields, influencers, @@ -36,7 +39,7 @@ export const AnomalyTableProvider = React.memo( jobIds, aggregationInterval: 'auto', }); - return <>{children({ isLoadingAnomaliesData, anomaliesData })}; + return <>{children({ isLoadingAnomaliesData, anomaliesData, jobNameById })}; } ); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.test.ts b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.test.ts index 430fddcd36fc6..8c90b66b9b1b6 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.test.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.test.ts @@ -50,7 +50,7 @@ describe('useNotableAnomaliesSearch', () => { wrapper: TestProviders, }); - expect(result.current.data.length).toEqual(6); + expect(result.current.data.length).toEqual(0); }); it('calls notableAnomaliesSearch when skip is false', async () => { @@ -116,10 +116,43 @@ describe('useNotableAnomaliesSearch', () => { }); }); - it('does not throw error when aggregations is undefined', async () => { + it('returns jobs sorted by name', async () => { await act(async () => { - mockNotableAnomaliesSearch.mockResolvedValue({}); - const { waitForNextUpdate } = renderHook( + const firstJobId = 'v3_windows_anomalous_script'; + const secondJobId = 'auth_rare_source_ip_for_a_user'; + const fistJobCount = { key: firstJobId, doc_count: 99 }; + const secondJobCount = { key: secondJobId, doc_count: 99 }; + const firstJobSecurityName = '0000001'; + const secondJobSecurityName = '0000002'; + const firstJob = { + id: firstJobId, + jobState: 'started', + datafeedState: 'started', + customSettings: { + security_app_display_name: firstJobSecurityName, + }, + }; + const secondJob = { + id: secondJobId, + jobState: 'started', + datafeedState: 'started', + customSettings: { + security_app_display_name: secondJobSecurityName, + }, + }; + + mockNotableAnomaliesSearch.mockResolvedValue({ + aggregations: { number_of_anomalies: { buckets: [fistJobCount, secondJobCount] } }, + }); + + mockUseSecurityJobs.mockReturnValue({ + loading: false, + isMlAdmin: true, + jobs: [firstJob, secondJob], + refetch: useSecurityJobsRefetch, + }); + + const { result, waitForNextUpdate } = renderHook( () => useNotableAnomaliesSearch({ skip: false, from, to }), { wrapper: TestProviders, @@ -128,23 +161,22 @@ describe('useNotableAnomaliesSearch', () => { await waitForNextUpdate(); await waitForNextUpdate(); - expect(mockAddToastError).not.toBeCalled(); + const names = result.current.data.map(({ name }) => name); + expect(names).toEqual([ + firstJobSecurityName, + secondJobSecurityName, + 'packetbeat_dns_tunneling', + 'packetbeat_rare_dns_question', + 'packetbeat_rare_server_domain', + 'suspicious_login_activity', + ]); }); }); - it('returns uninstalled jobs', async () => { - mockUseSecurityJobs.mockReturnValue({ - loading: false, - isMlAdmin: true, - jobs: [], - refetch: useSecurityJobsRefetch, - }); - + it('does not throw error when aggregations is undefined', async () => { await act(async () => { - mockNotableAnomaliesSearch.mockResolvedValue({ - aggregations: { number_of_anomalies: { buckets: [] } }, - }); - const { result, waitForNextUpdate } = renderHook( + mockNotableAnomaliesSearch.mockResolvedValue({}); + const { waitForNextUpdate } = renderHook( () => useNotableAnomaliesSearch({ skip: false, from, to }), { wrapper: TestProviders, @@ -153,16 +185,7 @@ describe('useNotableAnomaliesSearch', () => { await waitForNextUpdate(); await waitForNextUpdate(); - expect(result.current.data).toEqual( - expect.arrayContaining([ - { - count: 0, - name: job.id, - job: undefined, - entity: AnomalyEntity.Host, - }, - ]) - ); + expect(mockAddToastError).not.toBeCalled(); }); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.ts b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.ts index 5f2ba01532fb5..92ff169323d55 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/anomaly/use_anomalies_search.ts @@ -6,7 +6,7 @@ */ import { useState, useEffect, useMemo } from 'react'; -import { filter, head, orderBy, pipe, has } from 'lodash/fp'; +import { filter, head, orderBy, pipe, has, sortBy } from 'lodash/fp'; import { DEFAULT_ANOMALY_SCORE } from '../../../../../common/constants'; import * as i18n from './translations'; @@ -26,7 +26,7 @@ export enum AnomalyEntity { } export interface AnomaliesCount { - name: NotableAnomaliesJobId; + name: NotableAnomaliesJobId | string; count: number; entity: AnomalyEntity; job?: SecurityJob; @@ -47,7 +47,7 @@ export const useNotableAnomaliesSearch = ({ data: AnomaliesCount[]; refetch: inputsModel.Refetch; } => { - const [data, setData] = useState(formatResultData([], [])); + const [data, setData] = useState([]); const { loading: jobsLoading, @@ -131,18 +131,20 @@ function formatResultData( }>, notableAnomaliesJobs: SecurityJob[] ): AnomaliesCount[] { - return NOTABLE_ANOMALIES_IDS.map((notableJobId) => { + const unsortedAnomalies: AnomaliesCount[] = NOTABLE_ANOMALIES_IDS.map((notableJobId) => { const job = findJobWithId(notableJobId)(notableAnomaliesJobs); const bucket = buckets.find(({ key }) => key === job?.id); const hasUserName = has("entity.hits.hits[0]._source['user.name']", bucket); return { - name: notableJobId, + name: job?.customSettings?.security_app_display_name ?? notableJobId, count: bucket?.doc_count ?? 0, entity: hasUserName ? AnomalyEntity.User : AnomalyEntity.Host, job, }; }); + + return sortBy(['name'], unsortedAnomalies); } /** diff --git a/x-pack/plugins/security_solution/public/common/components/ml/hooks/use_installed_security_jobs.ts b/x-pack/plugins/security_solution/public/common/components/ml/hooks/use_installed_security_jobs.ts index 1834db13e7fb2..fbc1a02fb53d1 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/hooks/use_installed_security_jobs.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/hooks/use_installed_security_jobs.ts @@ -72,3 +72,18 @@ export const useInstalledSecurityJobsIds = () => { return { jobIds, loading }; }; + +export const useInstalledSecurityJobNameById = () => { + const { jobs, loading } = useInstalledSecurityJobs(); + + const jobNameById = useMemo( + () => + jobs.reduce>((acc, job) => { + acc[job.id] = job.customSettings?.security_app_display_name; + return acc; + }, {}), + [jobs] + ); + + return { jobNameById, loading }; +}; diff --git a/x-pack/plugins/security_solution/public/common/components/ml/links/create_explorer_link.tsx b/x-pack/plugins/security_solution/public/common/components/ml/links/create_explorer_link.tsx index 25f5f61b68ba8..9f7ed8a526e12 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/links/create_explorer_link.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/links/create_explorer_link.tsx @@ -48,7 +48,7 @@ export const ExplorerLink: React.FC = ({ if (!explorerUrl) return null; return ( - + {linkName} ); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/__snapshots__/anomaly_scores.test.tsx.snap b/x-pack/plugins/security_solution/public/common/components/ml/score/__snapshots__/anomaly_scores.test.tsx.snap index b9e4a76363a40..d911e3706c309 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/__snapshots__/anomaly_scores.test.tsx.snap +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/__snapshots__/anomaly_scores.test.tsx.snap @@ -11,6 +11,7 @@ exports[`anomaly_scores renders correctly against snapshot 1`] = ` index={0} interval="day" jobKey="job-1-16.193669439507826-process.name-du" + jobName="job-1" key="job-1-16.193669439507826-process.name-du" narrowDateRange={[MockFunction]} score={ @@ -86,6 +87,7 @@ exports[`anomaly_scores renders correctly against snapshot 1`] = ` index={1} interval="day" jobKey="job-2-16.193669439507826-process.name-ls" + jobName="job-2" key="job-2-16.193669439507826-process.name-ls" narrowDateRange={[MockFunction]} score={ diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx index 0039c7ecad203..4a639da633021 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx @@ -40,6 +40,7 @@ describe('anomaly_scores', () => { score={anomalies.anomalies[0]} interval="day" narrowDateRange={narrowDateRange} + jobName={'job-1'} /> ); expect(wrapper).toMatchSnapshot(); @@ -55,6 +56,7 @@ describe('anomaly_scores', () => { score={anomalies.anomalies[0]} interval="day" narrowDateRange={narrowDateRange} + jobName={'job-1'} /> ); @@ -71,6 +73,7 @@ describe('anomaly_scores', () => { score={anomalies.anomalies[0]} interval="day" narrowDateRange={narrowDateRange} + jobName={'job-1'} /> ); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.tsx index 5b2a5929c5782..28fff36fb2fe5 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.tsx @@ -21,6 +21,7 @@ interface Args { index?: number; score: Anomaly; interval: string; + jobName: string; } const Icon = styled(EuiIcon)` @@ -38,6 +39,7 @@ export const AnomalyScoreComponent = ({ score, interval, narrowDateRange, + jobName, }: Args): JSX.Element => { const [isOpen, setIsOpen] = useState(false); return ( @@ -61,7 +63,14 @@ export const AnomalyScoreComponent = ({ > diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx index 7131c47529636..6a72d72a9eb59 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx @@ -39,6 +39,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); expect(wrapper).toMatchSnapshot(); @@ -53,6 +54,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={true} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); @@ -68,6 +70,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); @@ -83,6 +86,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); @@ -99,6 +103,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); @@ -119,6 +124,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); @@ -134,6 +140,7 @@ describe('anomaly_scores', () => { endDate={endDate} isLoading={false} narrowDateRange={narrowDateRange} + jobNameById={{}} /> ); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.tsx index 6f6367fbe8ca8..3cbdec141e221 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.tsx @@ -19,6 +19,7 @@ interface Args { isLoading: boolean; narrowDateRange: NarrowDateRange; limit?: number; + jobNameById: Record; } export const createJobKey = (score: Anomaly): string => @@ -31,6 +32,7 @@ export const AnomalyScoresComponent = ({ isLoading, narrowDateRange, limit, + jobNameById, }: Args): JSX.Element => { if (isLoading) { return ; @@ -50,6 +52,7 @@ export const AnomalyScoresComponent = ({ endDate={endDate} index={index} score={score} + jobName={jobNameById[score.jobId] ?? score.jobId} interval={anomalies.interval} narrowDateRange={narrowDateRange} /> diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/create_description_list.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/create_description_list.tsx index 57434275afa3d..7ca8bf81ed06e 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/create_description_list.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/create_description_list.tsx @@ -29,7 +29,8 @@ export const createDescriptionList = ( startDate: string, endDate: string, interval: string, - narrowDateRange: NarrowDateRange + narrowDateRange: NarrowDateRange, + jobName: string ): DescriptionList[] => { const descriptionList: DescriptionList[] = [ { @@ -50,7 +51,7 @@ export const createDescriptionList = ( ), description: ( - {score.jobId} + {jobName} { startDate, endDate, 'hours', - narrowDateRange + narrowDateRange, + 'job-1' )} /> ); @@ -48,7 +49,8 @@ describe('create_description_list', () => { startDate, endDate, 'hours', - narrowDateRange + narrowDateRange, + 'job-1' )} /> ); @@ -69,7 +71,8 @@ describe('create_description_list', () => { startDate, endDate, 'hours', - narrowDateRange + narrowDateRange, + 'job-1' )} /> ); @@ -129,7 +132,8 @@ describe('create_description_list', () => { startDate, endDate, 'hours', - narrowDateRange + narrowDateRange, + 'job-1' )} /> ); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.test.tsx index a4ca525bd6c24..13139c3a369d4 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.test.tsx @@ -5,7 +5,6 @@ * 2.0. */ -import { mount } from 'enzyme'; import { AnomaliesHostTable } from './anomalies_host_table'; import { TestProviders } from '../../../mock'; import React from 'react'; @@ -13,27 +12,66 @@ import { useQueryToggle } from '../../../containers/query_toggle'; import { useAnomaliesTableData } from '../anomaly/use_anomalies_table_data'; import { HostsType } from '../../../../explore/hosts/store/model'; import { hasMlUserPermissions } from '../../../../../common/machine_learning/has_ml_user_permissions'; +import { fireEvent, render } from '@testing-library/react'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; +import { mockAnomalies } from '../mock'; +import { useMlHref } from '@kbn/ml-plugin/public'; jest.mock('../../../containers/query_toggle'); jest.mock('../anomaly/use_anomalies_table_data'); jest.mock('../../../../../common/machine_learning/has_ml_user_permissions'); +jest.mock('../hooks/use_installed_security_jobs'); +jest.mock('@kbn/ml-plugin/public'); + +const mockUseQueryToggle = useQueryToggle as jest.Mock; +const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; +const mockUseInstalledSecurityJobNameById = useInstalledSecurityJobNameById as jest.Mock; +const mockUseMlHref = useMlHref as jest.Mock; + +const mockSetToggle = jest.fn(); + +(hasMlUserPermissions as jest.Mock).mockReturnValue(true); +mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); +mockUseMlHref.mockReturnValue('http://test'); +mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: {}, +}); +const testProps = { + startDate: '2019-07-17T20:00:00.000Z', + endDate: '2019-07-18T20:00:00.000Z', + narrowDateRange: jest.fn(), + skip: false, + type: HostsType.page, +}; describe('Anomalies host table', () => { + it('renders job name when available', () => { + const anomaly = mockAnomalies.anomalies[0]; + const jobName = 'job_name'; + + mockUseAnomaliesTableData.mockReturnValue([ + false, + { + anomalies: [anomaly], + interval: '10', + }, + ]); + mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: { [anomaly.jobId]: jobName }, + }); + + const { getByTestId } = render(, { + wrapper: TestProviders, + }); + + expect(getByTestId(`explorer-link-${anomaly.jobId}`).textContent).toContain(jobName); + }); + describe('toggle query', () => { - const mockUseQueryToggle = useQueryToggle as jest.Mock; - const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; - const mockSetToggle = jest.fn(); - const testProps = { - startDate: '2019-07-17T20:00:00.000Z', - endDate: '2019-07-18T20:00:00.000Z', - narrowDateRange: jest.fn(), - skip: false, - type: HostsType.page, - }; beforeEach(() => { jest.clearAllMocks(); - (hasMlUserPermissions as jest.Mock).mockReturnValue(true); - mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); mockUseAnomaliesTableData.mockReturnValue([ false, { @@ -44,42 +82,43 @@ describe('Anomalies host table', () => { }); test('toggleQuery updates toggleStatus', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { getByTestId } = render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); - wrapper.find('[data-test-subj="query-toggle-header"]').first().simulate('click'); + fireEvent.click(getByTestId('query-toggle-header')); + expect(mockSetToggle).toBeCalledWith(false); expect(mockUseAnomaliesTableData.mock.calls[1][0].skip).toEqual(true); }); test('toggleStatus=true, do not skip', () => { - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); }); test('toggleStatus=true, render components', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="host-anomalies-table"]').exists()).toBe(true); + expect(queryByTestId('host-anomalies-table')).toBeInTheDocument(); }); test('toggleStatus=false, do not render components', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="host-anomalies-table"]').exists()).toBe(false); + expect(queryByTestId('host-anomalies-table')).not.toBeInTheDocument(); }); test('toggleStatus=false, skip', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(true); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.tsx index 9863d8fdca11d..323d67f566cc8 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_host_table.tsx @@ -22,7 +22,7 @@ import { BasicTable } from './basic_table'; import { getCriteriaFromHostType } from '../criteria/get_criteria_from_host_type'; import { Panel } from '../../panel'; import { useQueryToggle } from '../../../containers/query_toggle'; -import { useInstalledSecurityJobsIds } from '../hooks/use_installed_security_jobs'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; import { useDeepEqualSelector } from '../../../hooks/use_selector'; import type { State } from '../../../store'; import { JobIdFilter } from './job_id_filter'; @@ -59,13 +59,13 @@ const AnomaliesHostTableComponent: React.FC = ({ [setQuerySkip, setToggleStatus] ); - const { jobIds, loading: loadingJobs } = useInstalledSecurityJobsIds(); + const { jobNameById, loading: loadingJobs } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); const getAnomaliesHostsTableFilterQuerySelector = useMemo( () => hostsSelectors.hostsAnomaliesJobIdFilterSelector(), [] ); - const selectedJobIds = useDeepEqualSelector((state: State) => getAnomaliesHostsTableFilterQuerySelector(state, type) ); @@ -115,7 +115,7 @@ const AnomaliesHostTableComponent: React.FC = ({ aggregationInterval: selectedInterval, }); - const hosts = convertAnomaliesToHosts(tableData, hostName); + const hosts = convertAnomaliesToHosts(tableData, jobNameById, hostName); const columns = getAnomaliesHostTableColumnsCurated(type, startDate, endDate); const pagination = { @@ -151,6 +151,7 @@ const AnomaliesHostTableComponent: React.FC = ({ onSelect={onSelectJobId} selectedJobIds={selectedJobIds} jobIds={jobIds} + jobNameById={jobNameById} /> diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.test.tsx index 4af7161b95578..f69d6c212eb55 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.test.tsx @@ -5,7 +5,6 @@ * 2.0. */ -import { mount } from 'enzyme'; import { AnomaliesNetworkTable } from './anomalies_network_table'; import { TestProviders } from '../../../mock'; import React from 'react'; @@ -14,28 +13,72 @@ import { useAnomaliesTableData } from '../anomaly/use_anomalies_table_data'; import { NetworkType } from '../../../../explore/network/store/model'; import { hasMlUserPermissions } from '../../../../../common/machine_learning/has_ml_user_permissions'; import { FlowTarget } from '../../../../../common/search_strategy'; +import { fireEvent, render } from '@testing-library/react'; +import { mockAnomalies } from '../mock'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; +import { useMlHref } from '@kbn/ml-plugin/public'; jest.mock('../../../containers/query_toggle'); jest.mock('../anomaly/use_anomalies_table_data'); jest.mock('../../../../../common/machine_learning/has_ml_user_permissions'); +jest.mock('../hooks/use_installed_security_jobs'); +jest.mock('@kbn/ml-plugin/public'); + +const mockUseQueryToggle = useQueryToggle as jest.Mock; +const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; +const mockUseInstalledSecurityJobNameById = useInstalledSecurityJobNameById as jest.Mock; +const mockUseMlHref = useMlHref as jest.Mock; + +const mockSetToggle = jest.fn(); + +(hasMlUserPermissions as jest.Mock).mockReturnValue(true); +mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); +mockUseMlHref.mockReturnValue('http://test'); +mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: {}, +}); + +const testProps = { + startDate: '2019-07-17T20:00:00.000Z', + endDate: '2019-07-18T20:00:00.000Z', + flowTarget: FlowTarget.destination, + narrowDateRange: jest.fn(), + skip: false, + type: NetworkType.page, +}; describe('Anomalies network table', () => { - describe('toggle query', () => { - const mockUseQueryToggle = useQueryToggle as jest.Mock; - const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; - const mockSetToggle = jest.fn(); - const testProps = { - startDate: '2019-07-17T20:00:00.000Z', - endDate: '2019-07-18T20:00:00.000Z', - flowTarget: FlowTarget.destination, - narrowDateRange: jest.fn(), - skip: false, - type: NetworkType.page, + it('renders job name when available', () => { + const anomaly = { + ...mockAnomalies.anomalies[0], + entityValue: '127.0.0.1', + entityName: 'source.ip', }; + const jobName = 'job_name'; + + mockUseAnomaliesTableData.mockReturnValue([ + false, + { + anomalies: [anomaly], + interval: '10', + }, + ]); + mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: { [anomaly.jobId]: jobName }, + }); + + const { getByTestId } = render(, { + wrapper: TestProviders, + }); + + expect(getByTestId(`explorer-link-${anomaly.jobId}`).textContent).toContain(jobName); + }); + + describe('toggle query', () => { beforeEach(() => { jest.clearAllMocks(); - (hasMlUserPermissions as jest.Mock).mockReturnValue(true); - mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); mockUseAnomaliesTableData.mockReturnValue([ false, { @@ -46,42 +89,42 @@ describe('Anomalies network table', () => { }); test('toggleQuery updates toggleStatus', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { getByTestId } = render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); - wrapper.find('[data-test-subj="query-toggle-header"]').first().simulate('click'); + fireEvent.click(getByTestId('query-toggle-header')); expect(mockSetToggle).toBeCalledWith(false); expect(mockUseAnomaliesTableData.mock.calls[1][0].skip).toEqual(true); }); test('toggleStatus=true, do not skip', () => { - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); }); test('toggleStatus=true, render components', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="network-anomalies-table"]').exists()).toBe(true); + expect(queryByTestId('network-anomalies-table')).toBeInTheDocument(); }); test('toggleStatus=false, do not render components', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="network-anomalies-table"]').exists()).toBe(false); + expect(queryByTestId('network-anomalies-table')).not.toBeInTheDocument(); }); test('toggleStatus=false, skip', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(true); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.tsx index b3937da464fff..292ad69073d52 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_network_table.tsx @@ -22,7 +22,7 @@ import { BasicTable } from './basic_table'; import { getCriteriaFromNetworkType } from '../criteria/get_criteria_from_network_type'; import { Panel } from '../../panel'; import { useQueryToggle } from '../../../containers/query_toggle'; -import { useInstalledSecurityJobsIds } from '../hooks/use_installed_security_jobs'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; import { useDeepEqualSelector } from '../../../hooks/use_selector'; import type { State } from '../../../store'; import { JobIdFilter } from './job_id_filter'; @@ -60,7 +60,8 @@ const AnomaliesNetworkTableComponent: React.FC = ({ [setQuerySkip, setToggleStatus] ); - const { jobIds, loading: loadingJobs } = useInstalledSecurityJobsIds(); + const { jobNameById, loading: loadingJobs } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); const getAnomaliesUserTableFilterQuerySelector = useMemo( () => networkSelectors.networkAnomaliesJobIdFilterSelector(), @@ -113,7 +114,7 @@ const AnomaliesNetworkTableComponent: React.FC = ({ aggregationInterval: selectedInterval, }); - const networks = convertAnomaliesToNetwork(tableData, ip); + const networks = convertAnomaliesToNetwork(tableData, jobNameById, ip); const columns = getAnomaliesNetworkTableColumnsCurated(type, startDate, endDate, flowTarget); const pagination = { initialPageIndex: 0, @@ -148,6 +149,7 @@ const AnomaliesNetworkTableComponent: React.FC = ({ onSelect={onSelectJobId} selectedJobIds={selectedJobIds} jobIds={jobIds} + jobNameById={jobNameById} /> diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.test.tsx index abbfa3d7bd942..c4384979801c2 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.test.tsx @@ -4,8 +4,6 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ - -import { mount } from 'enzyme'; import { AnomaliesUserTable } from './anomalies_user_table'; import { TestProviders } from '../../../mock'; import React from 'react'; @@ -13,28 +11,80 @@ import { useQueryToggle } from '../../../containers/query_toggle'; import { useAnomaliesTableData } from '../anomaly/use_anomalies_table_data'; import { UsersType } from '../../../../explore/users/store/model'; import { hasMlUserPermissions } from '../../../../../common/machine_learning/has_ml_user_permissions'; +import { fireEvent, render } from '@testing-library/react'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; +import { mockAnomalies } from '../mock'; +import { useMlHref } from '@kbn/ml-plugin/public'; jest.mock('../../../containers/query_toggle'); jest.mock('../anomaly/use_anomalies_table_data'); jest.mock('../../../../../common/machine_learning/has_ml_user_permissions'); +jest.mock('../hooks/use_installed_security_jobs'); +jest.mock('@kbn/ml-plugin/public'); + +const mockUseQueryToggle = useQueryToggle as jest.Mock; +const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; +const mockUseInstalledSecurityJobNameById = useInstalledSecurityJobNameById as jest.Mock; +const mockUseMlHref = useMlHref as jest.Mock; + +const mockSetToggle = jest.fn(); + +(hasMlUserPermissions as jest.Mock).mockReturnValue(true); +mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); +mockUseMlHref.mockReturnValue('http://test'); +mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: {}, +}); + +const userName = 'cool_guy'; +const testProps = { + startDate: '2019-07-17T20:00:00.000Z', + endDate: '2019-07-18T20:00:00.000Z', + narrowDateRange: jest.fn(), + userName, + skip: false, + type: UsersType.page, +}; describe('Anomalies user table', () => { - describe('toggle query', () => { - const mockUseQueryToggle = useQueryToggle as jest.Mock; - const mockUseAnomaliesTableData = useAnomaliesTableData as jest.Mock; - const mockSetToggle = jest.fn(); - const testProps = { - startDate: '2019-07-17T20:00:00.000Z', - endDate: '2019-07-18T20:00:00.000Z', - narrowDateRange: jest.fn(), - userName: 'coolguy', - skip: false, - type: UsersType.page, + it('renders job name when available', () => { + const anomaly = { + ...mockAnomalies.anomalies[0], + entityValue: userName, + entityName: 'user.name', }; + const jobName = 'job_name'; + + mockUseAnomaliesTableData.mockReturnValue([ + false, + { + anomalies: [anomaly], + interval: '10', + }, + ]); + + mockUseAnomaliesTableData.mockReturnValue([ + false, + { + anomalies: [anomaly], + interval: '10', + }, + ]); + mockUseInstalledSecurityJobNameById.mockReturnValue({ + loading: false, + jobNameById: { [anomaly.jobId]: jobName }, + }); + + const { getByTestId } = render(, { + wrapper: TestProviders, + }); + + expect(getByTestId(`explorer-link-${anomaly.jobId}`).textContent).toContain(jobName); + }); + describe('toggle query', () => { beforeEach(() => { jest.clearAllMocks(); - (hasMlUserPermissions as jest.Mock).mockReturnValue(true); - mockUseQueryToggle.mockReturnValue({ toggleStatus: true, setToggleStatus: mockSetToggle }); mockUseAnomaliesTableData.mockReturnValue([ false, { @@ -45,42 +95,42 @@ describe('Anomalies user table', () => { }); test('toggleQuery updates toggleStatus', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { getByTestId } = render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); - wrapper.find('[data-test-subj="query-toggle-header"]').first().simulate('click'); + fireEvent.click(getByTestId('query-toggle-header')); expect(mockSetToggle).toBeCalledWith(false); expect(mockUseAnomaliesTableData.mock.calls[1][0].skip).toEqual(true); }); test('toggleStatus=true, do not skip', () => { - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(false); }); test('toggleStatus=true, render components', () => { - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="user-anomalies-table"]').exists()).toBe(true); + expect(queryByTestId('user-anomalies-table')).toBeInTheDocument(); }); test('toggleStatus=false, do not render components', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - const wrapper = mount(, { - wrappingComponent: TestProviders, + const { queryByTestId } = render(, { + wrapper: TestProviders, }); - expect(wrapper.find('[data-test-subj="user-anomalies-table"]').exists()).toBe(false); + expect(queryByTestId('user-anomalies-table')).not.toBeInTheDocument(); }); test('toggleStatus=false, skip', () => { mockUseQueryToggle.mockReturnValue({ toggleStatus: false, setToggleStatus: mockSetToggle }); - mount(, { - wrappingComponent: TestProviders, + render(, { + wrapper: TestProviders, }); expect(mockUseAnomaliesTableData.mock.calls[0][0].skip).toEqual(true); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.tsx index 2ff4f74884865..b93e2037776f1 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/anomalies_user_table.tsx @@ -30,7 +30,7 @@ import { SelectInterval } from './select_interval'; import { useDeepEqualSelector } from '../../../hooks/use_selector'; import { usersActions, usersSelectors } from '../../../../explore/users/store'; import type { State } from '../../../store/types'; -import { useInstalledSecurityJobsIds } from '../hooks/use_installed_security_jobs'; +import { useInstalledSecurityJobNameById } from '../hooks/use_installed_security_jobs'; const sorting = { sort: { @@ -63,7 +63,8 @@ const AnomaliesUserTableComponent: React.FC = ({ [setQuerySkip, setToggleStatus] ); - const { jobIds, loading: loadingJobs } = useInstalledSecurityJobsIds(); + const { jobNameById, loading: loadingJobs } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); const getAnomaliesUserTableFilterQuerySelector = useMemo( () => usersSelectors.usersAnomaliesJobIdFilterSelector(), @@ -119,8 +120,7 @@ const AnomaliesUserTableComponent: React.FC = ({ aggregationInterval: selectedInterval, }); - const users = convertAnomaliesToUsers(tableData, userName); - + const users = convertAnomaliesToUsers(tableData, jobNameById, userName); const columns = getAnomaliesUserTableColumnsCurated(type, startDate, endDate); const pagination = { initialPageIndex: 0, @@ -156,6 +156,7 @@ const AnomaliesUserTableComponent: React.FC = ({ onSelect={onSelectJobId} selectedJobIds={selectedJobIds} jobIds={jobIds} + jobNameById={jobNameById} /> diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.test.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.test.ts index c7e8f8d792340..b29c5476f70b9 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.test.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.test.ts @@ -18,7 +18,7 @@ describe('convert_anomalies_to_hosts', () => { }); test('it returns expected anomalies from a host', () => { - const entities = convertAnomaliesToHosts(anomalies); + const entities = convertAnomaliesToHosts(anomalies, {}); const expected: AnomaliesByHost[] = [ { anomaly: { @@ -61,6 +61,7 @@ describe('convert_anomalies_to_hosts', () => { time: 1560664800000, }, hostName: 'zeek-iowa', + jobName: 'job-1', }, { anomaly: { @@ -103,13 +104,14 @@ describe('convert_anomalies_to_hosts', () => { time: 1560664800000, }, hostName: 'zeek-iowa', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in a null', () => { - const entities = convertAnomaliesToHosts(null); + const entities = convertAnomaliesToHosts(null, {}); const expected: AnomaliesByHost[] = []; expect(entities).toEqual(expected); }); @@ -123,7 +125,7 @@ describe('convert_anomalies_to_hosts', () => { { 'user.name': 'root' }, ]; - const entities = convertAnomaliesToHosts(anomalies, 'zeek-iowa'); + const entities = convertAnomaliesToHosts(anomalies, {}, 'zeek-iowa'); const expected: AnomaliesByHost[] = [ { anomaly: { @@ -166,6 +168,7 @@ describe('convert_anomalies_to_hosts', () => { time: 1560664800000, }, hostName: 'zeek-iowa', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); @@ -182,7 +185,7 @@ describe('convert_anomalies_to_hosts', () => { anomalies.anomalies[1].entityName = 'something-else'; anomalies.anomalies[1].entityValue = 'something-else'; - const entities = convertAnomaliesToHosts(anomalies, 'zeek-iowa'); + const entities = convertAnomaliesToHosts(anomalies, {}, 'zeek-iowa'); const expected: AnomaliesByHost[] = [ { anomaly: { @@ -225,13 +228,14 @@ describe('convert_anomalies_to_hosts', () => { time: 1560664800000, }, hostName: 'zeek-iowa', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in the name of one that does not exist', () => { - const entities = convertAnomaliesToHosts(anomalies, 'some-made-up-name-here-for-you'); + const entities = convertAnomaliesToHosts(anomalies, {}, 'some-made-up-name-here-for-you'); const expected: AnomaliesByHost[] = []; expect(entities).toEqual(expected); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.ts index 00beb18418a7c..021c4c1a413b8 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_hosts.ts @@ -10,6 +10,7 @@ import { getHostNameFromInfluencers } from '../influencers/get_host_name_from_in export const convertAnomaliesToHosts = ( anomalies: Anomalies | null, + jobNameById: Record, hostName?: string ): AnomaliesByHost[] => { if (anomalies == null) { @@ -17,11 +18,25 @@ export const convertAnomaliesToHosts = ( } else { return anomalies.anomalies.reduce((accum, item) => { if (getHostNameFromEntity(item, hostName)) { - return [...accum, { hostName: item.entityValue, anomaly: item }]; + return [ + ...accum, + { + hostName: item.entityValue, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { const hostNameFromInfluencers = getHostNameFromInfluencers(item.influencers, hostName); if (hostNameFromInfluencers != null) { - return [...accum, { hostName: hostNameFromInfluencers, anomaly: item }]; + return [ + ...accum, + { + hostName: hostNameFromInfluencers, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { return accum; } diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.test.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.test.ts index 7137c9762fbfa..b780843e78f45 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.test.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.test.ts @@ -20,7 +20,7 @@ describe('convert_anomalies_to_hosts', () => { test('it returns expected anomalies from a network if is part of the entityName and is a source.ip', () => { anomalies.anomalies[0].entityName = 'source.ip'; anomalies.anomalies[0].entityValue = '127.0.0.1'; - const entities = convertAnomaliesToNetwork(anomalies); + const entities = convertAnomaliesToNetwork(anomalies, {}); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -64,6 +64,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'source.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -72,7 +73,7 @@ describe('convert_anomalies_to_hosts', () => { test('it returns expected anomalies from a network if is part of the entityName and is a destination.ip', () => { anomalies.anomalies[0].entityName = 'destination.ip'; anomalies.anomalies[0].entityValue = '127.0.0.1'; - const entities = convertAnomaliesToNetwork(anomalies); + const entities = convertAnomaliesToNetwork(anomalies, {}); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -116,6 +117,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'destination.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -125,7 +127,7 @@ describe('convert_anomalies_to_hosts', () => { anomalies.anomalies[0].entityName = 'not-an-ip'; anomalies.anomalies[0].entityValue = 'not-an-ip'; anomalies.anomalies[0].influencers = [{ 'source.ip': '127.0.0.1' }]; - const entities = convertAnomaliesToNetwork(anomalies); + const entities = convertAnomaliesToNetwork(anomalies, {}); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -165,6 +167,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'source.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -174,7 +177,7 @@ describe('convert_anomalies_to_hosts', () => { anomalies.anomalies[0].entityName = 'not-an-ip'; anomalies.anomalies[0].entityValue = 'not-an-ip'; anomalies.anomalies[0].influencers = [{ 'destination.ip': '127.0.0.1' }]; - const entities = convertAnomaliesToNetwork(anomalies); + const entities = convertAnomaliesToNetwork(anomalies, {}); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -214,13 +217,14 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'destination.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in a null', () => { - const entities = convertAnomaliesToNetwork(null); + const entities = convertAnomaliesToNetwork(null, {}); const expected: AnomaliesByNetwork[] = []; expect(entities).toEqual(expected); }); @@ -233,7 +237,7 @@ describe('convert_anomalies_to_hosts', () => { { 'process.name': 'du' }, { 'user.name': 'root' }, ]; - const entities = convertAnomaliesToNetwork(anomalies, '127.0.0.1'); + const entities = convertAnomaliesToNetwork(anomalies, {}, '127.0.0.1'); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -277,6 +281,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'source.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -290,7 +295,7 @@ describe('convert_anomalies_to_hosts', () => { { 'process.name': 'du' }, { 'user.name': 'root' }, ]; - const entities = convertAnomaliesToNetwork(anomalies, '127.0.0.1'); + const entities = convertAnomaliesToNetwork(anomalies, {}, '127.0.0.1'); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -334,6 +339,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'destination.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -347,7 +353,7 @@ describe('convert_anomalies_to_hosts', () => { { 'process.name': 'du' }, { 'user.name': 'root' }, ]; - const entities = convertAnomaliesToNetwork(anomalies, '127.0.0.1'); + const entities = convertAnomaliesToNetwork(anomalies, {}, '127.0.0.1'); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -391,6 +397,7 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'source.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); @@ -404,7 +411,7 @@ describe('convert_anomalies_to_hosts', () => { { 'process.name': 'du' }, { 'user.name': 'root' }, ]; - const entities = convertAnomaliesToNetwork(anomalies, '127.0.0.1'); + const entities = convertAnomaliesToNetwork(anomalies, {}, '127.0.0.1'); const expected: AnomaliesByNetwork[] = [ { anomaly: { @@ -448,13 +455,14 @@ describe('convert_anomalies_to_hosts', () => { }, ip: '127.0.0.1', type: 'destination.ip', + jobName: 'job-1', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in the name of one that does not exist', () => { - const entities = convertAnomaliesToNetwork(anomalies, 'some-made-up-name-here-for-you'); + const entities = convertAnomaliesToNetwork(anomalies, {}, 'some-made-up-name-here-for-you'); const expected: AnomaliesByNetwork[] = []; expect(entities).toEqual(expected); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.ts index 8230b0e3ebc01..d99e61c04584c 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_network.ts @@ -11,6 +11,7 @@ import { getNetworkFromInfluencers } from '../influencers/get_network_from_influ export const convertAnomaliesToNetwork = ( anomalies: Anomalies | null, + jobNameById: Record, ip?: string ): AnomaliesByNetwork[] => { if (anomalies == null) { @@ -18,11 +19,27 @@ export const convertAnomaliesToNetwork = ( } else { return anomalies.anomalies.reduce((accum, item) => { if (isDestinationOrSource(item.entityName) && getNetworkFromEntity(item, ip)) { - return [...accum, { ip: item.entityValue, type: item.entityName, anomaly: item }]; + return [ + ...accum, + { + ip: item.entityValue, + type: item.entityName, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { const network = getNetworkFromInfluencers(item.influencers, ip); if (network != null) { - return [...accum, { ip: network.ip, type: network.type, anomaly: item }]; + return [ + ...accum, + { + ip: network.ip, + type: network.type, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { return accum; } diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.test.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.test.ts index 71d2459210ae1..1ce97150357f8 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.test.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.test.ts @@ -11,23 +11,25 @@ import type { AnomaliesByUser } from '../types'; describe('convert_anomalies_to_users', () => { test('it returns expected anomalies from a user', () => { - const entities = convertAnomaliesToUsers(mockAnomalies); + const entities = convertAnomaliesToUsers(mockAnomalies, {}); const expected: AnomaliesByUser[] = [ { anomaly: mockAnomalies.anomalies[0], userName: 'root', + jobName: 'job-1', }, { anomaly: mockAnomalies.anomalies[1], userName: 'root', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in a null', () => { - const entities = convertAnomaliesToUsers(null); + const entities = convertAnomaliesToUsers(null, {}); const expected: AnomaliesByUser[] = []; expect(entities).toEqual(expected); }); @@ -50,11 +52,12 @@ describe('convert_anomalies_to_users', () => { ], }; - const entities = convertAnomaliesToUsers(anomalies, 'root'); + const entities = convertAnomaliesToUsers(anomalies, {}, 'root'); const expected: AnomaliesByUser[] = [ { anomaly: anomalies.anomalies[1], userName: 'root', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); @@ -82,18 +85,19 @@ describe('convert_anomalies_to_users', () => { ], }; - const entities = convertAnomaliesToUsers(anomalies, 'root'); + const entities = convertAnomaliesToUsers(anomalies, {}, 'root'); const expected: AnomaliesByUser[] = [ { anomaly: anomalies.anomalies[1], userName: 'root', + jobName: 'job-2', }, ]; expect(entities).toEqual(expected); }); test('it returns empty anomalies if sent in the name of one that does not exist', () => { - const entities = convertAnomaliesToUsers(mockAnomalies, 'some-made-up-name-here-for-you'); + const entities = convertAnomaliesToUsers(mockAnomalies, {}, 'some-made-up-name-here-for-you'); const expected: AnomaliesByUser[] = []; expect(entities).toEqual(expected); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.ts b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.ts index 6d485ba1a01ea..ad09df846c66e 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/convert_anomalies_to_users.ts @@ -10,6 +10,7 @@ import { getUserNameFromInfluencers } from '../influencers/get_user_name_from_in export const convertAnomaliesToUsers = ( anomalies: Anomalies | null, + jobNameById: Record, userName?: string ): AnomaliesByUser[] => { if (anomalies == null) { @@ -17,11 +18,25 @@ export const convertAnomaliesToUsers = ( } else { return anomalies.anomalies.reduce((accum, item) => { if (getUserNameFromEntity(item, userName)) { - return [...accum, { userName: item.entityValue, anomaly: item }]; + return [ + ...accum, + { + userName: item.entityValue, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { const userNameFromInfluencers = getUserNameFromInfluencers(item.influencers, userName); if (userNameFromInfluencers != null) { - return [...accum, { userName: userNameFromInfluencers, anomaly: item }]; + return [ + ...accum, + { + userName: userNameFromInfluencers, + jobName: jobNameById[item.jobId] ?? item.jobId, + anomaly: item, + }, + ]; } else { return accum; } diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.test.tsx index 97b9657175e21..0e8fbb0794b7c 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.test.tsx @@ -32,6 +32,7 @@ describe('getAnomaliesDefaultTableColumns', () => { AnomaliesBy >; const anomaly: AnomaliesBy = { + jobName: undefined, anomaly: { detectorIndex: 0, entityName: 'entity-name-1', diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.tsx index 043ecd3971f5f..e8d4b13bc1b73 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/get_anomalies_table_columns.tsx @@ -32,14 +32,14 @@ export const getAnomaliesDefaultTableColumns = ( ] => [ { name: i18n.DETECTOR, - field: 'anomaly.jobId', + field: 'jobName', sortable: true, - render: (jobId, anomalyBy) => ( + render: (jobName, anomalyBy) => ( ), }, diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.stories.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.stories.tsx index 5e0e886ec138a..4df4484890da9 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.stories.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.stories.tsx @@ -20,13 +20,20 @@ const withTheme = (storyFn: () => ReactNode) => ( storiesOf('JobIdFilter', module) .addDecorator(withTheme) .add('empty', () => ( - + )) .add('one selected item', () => ( )) @@ -35,6 +42,7 @@ storiesOf('JobIdFilter', module) title="Job id" selectedJobIds={['test_job_2', 'test_job_3']} jobIds={['test_job_1', 'test_job_2', 'test_job_3', 'test_job_4']} + jobNameById={{}} onSelect={action('onSelect')} /> )) @@ -43,6 +51,7 @@ storiesOf('JobIdFilter', module) title="Job id" selectedJobIds={[]} jobIds={['test_job_1', 'test_job_2', 'test_job_3', 'test_job_4']} + jobNameById={{}} onSelect={action('onSelect')} /> )); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.test.tsx index 8a345f9a0f3ae..2f6ef3b6c0c05 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.test.tsx @@ -9,10 +9,18 @@ import { fireEvent, render } from '@testing-library/react'; import React from 'react'; import { JobIdFilter } from './job_id_filter'; +const JOB_IDS = ['test_job_1', 'test_job_2', 'test_job_3', 'test_job_4']; + describe('JobIdFilter', () => { it('is disabled when job id is empty', () => { const { getByTestId } = render( - + ); expect(getByTestId('job-id-filter-button')).toBeDisabled(); }); @@ -23,8 +31,9 @@ describe('JobIdFilter', () => { ); fireEvent.click(getByTestId('job-id-filter-button')); @@ -38,8 +47,9 @@ describe('JobIdFilter', () => { ); @@ -49,4 +59,21 @@ describe('JobIdFilter', () => { getByTestId('job-id-filter-item-test_job_2').querySelector('span[data-euiicon-type=check]') ).toBeInTheDocument(); }); + + it('displays job name when it is available', () => { + const jobName = 'TEST_JOB_NAME'; + const { getByTestId } = render( + + ); + + fireEvent.click(getByTestId('job-id-filter-button')); + + expect(getByTestId('job-id-filter-item-test_job').textContent).toBe(jobName); + }); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.tsx b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.tsx index 379c9b3e0f2af..2f71d7915f2cc 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/tables/job_id_filter.tsx @@ -10,9 +10,10 @@ import { EuiFilterButton, EuiFilterGroup, EuiFilterSelectItem, EuiPopover } from export const JobIdFilter: React.FC<{ selectedJobIds: string[]; jobIds: string[]; + jobNameById: Record; onSelect: (jobIds: string[]) => void; title: string; -}> = ({ selectedJobIds, onSelect, title, jobIds }) => { +}> = ({ selectedJobIds, onSelect, title, jobIds, jobNameById }) => { const [isPopoverOpen, setIsPopoverOpen] = useState(false); const onButtonClick = useCallback(() => { @@ -50,7 +51,7 @@ export const JobIdFilter: React.FC<{ {title} ), - [isPopoverOpen, onButtonClick, title, selectedJobIds.length, jobIds] + [jobIds.length, selectedJobIds.length, isPopoverOpen, onButtonClick, title] ); return ( @@ -69,7 +70,7 @@ export const JobIdFilter: React.FC<{ key={id} onClick={() => updateSelection(id)} > - {id} + {jobNameById[id] ?? id} ))}
    diff --git a/x-pack/plugins/security_solution/public/common/components/ml/types.ts b/x-pack/plugins/security_solution/public/common/components/ml/types.ts index d88f2763056c9..2a969dc3d15cb 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/types.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml/types.ts @@ -65,6 +65,7 @@ export type NarrowDateRange = (score: Anomaly, interval: string) => void; export interface AnomaliesBy { anomaly: Anomaly; + jobName: string | undefined; } export interface AnomaliesByHost extends AnomaliesBy { diff --git a/x-pack/plugins/security_solution/public/common/components/ml_popover/helpers.tsx b/x-pack/plugins/security_solution/public/common/components/ml_popover/helpers.tsx index 45c421eac468f..a64937ea1ae9c 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml_popover/helpers.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml_popover/helpers.tsx @@ -45,12 +45,18 @@ export const filterJobs = ({ * @param jobs to filter * @param filterQuery user-provided search string to filter for occurrence in job names/description */ -export const searchFilter = (jobs: SecurityJob[], filterQuery?: string): SecurityJob[] => - jobs.filter((job) => - filterQuery == null +export const searchFilter = (jobs: SecurityJob[], filterQuery?: string): SecurityJob[] => { + const lowerCaseFilterQuery = filterQuery?.toLowerCase(); + return jobs.filter((job) => + lowerCaseFilterQuery == null ? true - : job.id.includes(filterQuery) || job.description.includes(filterQuery) + : job.id.includes(lowerCaseFilterQuery) || + job.customSettings?.security_app_display_name + ?.toLowerCase() + ?.includes(lowerCaseFilterQuery) || + job.description.toLowerCase().includes(lowerCaseFilterQuery) ); +}; /** * Given an array of titles this will always return the same string for usage within diff --git a/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.test.tsx index ff8ba4db8d3d9..bb72b52c55734 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.test.tsx @@ -49,6 +49,31 @@ describe('useSecurityJobsHelpers', () => { memory_status: '', moduleId: 'security_linux_v3', processed_record_count: 0, + customSettings: { + created_by: 'ml-module-siem-auditbeat', + custom_urls: [ + { + url_name: 'Host Details by process name', + url_value: + "siem#/ml-hosts/$host.name$?kqlQuery=(filterQuery:(expression:'process.name%20:%20%22$process.name$%22',kind:kuery),queryLocation:hosts.details,type:details)&timerange=(global:(linkTo:!(timeline),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')),timeline:(linkTo:!(global),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')))", + }, + { + url_name: 'Host Details by user name', + url_value: + "siem#/ml-hosts/$host.name$?kqlQuery=(filterQuery:(expression:'user.name%20:%20%22$user.name$%22',kind:kuery),queryLocation:hosts.details,type:details)&timerange=(global:(linkTo:!(timeline),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')),timeline:(linkTo:!(global),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')))", + }, + { + url_name: 'Hosts Overview by process name', + url_value: + "siem#/ml-hosts?kqlQuery=(filterQuery:(expression:'process.name%20:%20%22$process.name$%22',kind:kuery),queryLocation:hosts.page,type:page)&timerange=(global:(linkTo:!(timeline),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')),timeline:(linkTo:!(global),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')))", + }, + { + url_name: 'Hosts Overview by user name', + url_value: + "siem#/ml-hosts?kqlQuery=(filterQuery:(expression:'user.name%20:%20%22$user.name$%22',kind:kuery),queryLocation:hosts.page,type:page)&timerange=(global:(linkTo:!(timeline),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')),timeline:(linkTo:!(global),timerange:(from:'$earliest$',kind:absolute,to:'$latest$')))", + }, + ], + }, }); }); diff --git a/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.tsx b/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.tsx index d41a7a8db92f5..8d0b63d8b32fe 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml_popover/hooks/use_security_jobs_helpers.tsx @@ -46,6 +46,7 @@ export const moduleToSecurityJob = ( awaitingNodeAssignment: false, jobTags: {}, bucketSpanSeconds: 900, + customSettings: moduleJob.config.custom_settings, }; }; diff --git a/x-pack/plugins/security_solution/public/common/components/ml_popover/jobs_table/jobs_table.tsx b/x-pack/plugins/security_solution/public/common/components/ml_popover/jobs_table/jobs_table.tsx index 482d334bb8c54..6d11220ccced9 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml_popover/jobs_table/jobs_table.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml_popover/jobs_table/jobs_table.tsx @@ -75,8 +75,12 @@ const getJobsTableColumns = ( ) => [ { name: i18n.COLUMN_JOB_NAME, - render: ({ id, description }: SecurityJob) => ( - + render: ({ id, description, customSettings }: SecurityJob) => ( + ), }, { diff --git a/x-pack/plugins/security_solution/public/common/components/ml_popover/types.ts b/x-pack/plugins/security_solution/public/common/components/ml_popover/types.ts index 65e01e440e6aa..7800ac03169c9 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml_popover/types.ts +++ b/x-pack/plugins/security_solution/public/common/components/ml_popover/types.ts @@ -74,6 +74,7 @@ export interface ModuleJob { custom_settings: { created_by: string; custom_urls: CustomURL[]; + security_app_display_name?: string; }; job_type: string; }; @@ -121,6 +122,9 @@ export interface SecurityJob extends MlSummaryJob { isCompatible: boolean; isInstalled: boolean; isElasticJob: boolean; + customSettings?: { + security_app_display_name?: string; + }; } export interface AugmentedSecurityJobFields { diff --git a/x-pack/plugins/security_solution/public/common/components/news_feed/helpers.ts b/x-pack/plugins/security_solution/public/common/components/news_feed/helpers.ts index 02af551b46d0b..b89c1c762dc87 100644 --- a/x-pack/plugins/security_solution/public/common/components/news_feed/helpers.ts +++ b/x-pack/plugins/security_solution/public/common/components/news_feed/helpers.ts @@ -7,7 +7,7 @@ import { get } from 'lodash/fp'; import moment from 'moment'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import semverCoerce from 'semver/functions/coerce'; import type { NewsItem, RawNewsApiItem, RawNewsApiResponse } from './types'; import { KibanaServices } from '../../lib/kibana'; @@ -73,7 +73,7 @@ export const getNewsItemsFromApiResponse = (response?: RawNewsApiResponse | null description: get(locale, x.description) ?? get(NEWS_FEED_FALLBACK_LANGUAGE, x.description) ?? '', expireOn: new Date(x.expire_on ?? ''), - hash: x.hash ?? uuid.v4(), + hash: x.hash ?? uuidv4(), imageUrl: get(locale, x.image_url) ?? get(NEWS_FEED_FALLBACK_LANGUAGE, x.image_url) ?? null, linkUrl: get(locale, x.link_url) ?? get(NEWS_FEED_FALLBACK_LANGUAGE, x.link_url) ?? '', publishOn: new Date(x.publish_on ?? ''), diff --git a/x-pack/plugins/security_solution/public/common/components/sourcerer/use_pick_index_patterns.tsx b/x-pack/plugins/security_solution/public/common/components/sourcerer/use_pick_index_patterns.tsx index 7be02be6abc37..52f87ccbe06ed 100644 --- a/x-pack/plugins/security_solution/public/common/components/sourcerer/use_pick_index_patterns.tsx +++ b/x-pack/plugins/security_solution/public/common/components/sourcerer/use_pick_index_patterns.tsx @@ -9,12 +9,13 @@ import React, { useCallback, useEffect, useMemo, useState, useRef } from 'react' import type { EuiComboBoxOptionOption, EuiSuperSelectOption } from '@elastic/eui'; import { useDispatch } from 'react-redux'; -import { getSourcererDataView } from '../../containers/sourcerer/api'; import { getScopePatternListSelection } from '../../store/sourcerer/helpers'; import { sourcererActions, sourcererModel } from '../../store/sourcerer'; import { getDataViewSelectOptions, getPatternListWithoutSignals } from './helpers'; import { SourcererScopeName } from '../../store/sourcerer/model'; import { sortWithExcludesAtEnd } from '../../../../common/utils/sourcerer'; +import { useKibana } from '../../lib/kibana'; +import { getSourcererDataView } from '../../containers/sourcerer/get_sourcerer_data_view'; interface UsePickIndexPatternsProps { dataViewId: string | null; @@ -61,6 +62,9 @@ export const usePickIndexPatterns = ({ signalIndexName, }: UsePickIndexPatternsProps): UsePickIndexPatterns => { const dispatch = useDispatch(); + const { + data: { dataViews }, + } = useKibana().services; const isHookAlive = useRef(true); const [loadingIndexPatterns, setLoadingIndexPatterns] = useState(false); const alertsOptions = useMemo( @@ -191,15 +195,12 @@ export const usePickIndexPatterns = ({ try { setLoadingIndexPatterns(true); setSelectedOptions([]); - // TODO We will need to figure out how to pass an abortController, but as right now this hook is - // constantly getting destroy and re-init - const pickedDataViewData = await getSourcererDataView(newSelectedDataViewId); + const dataView = await getSourcererDataView(newSelectedDataViewId, dataViews); + if (isHookAlive.current) { - dispatch(sourcererActions.setDataView(pickedDataViewData)); + dispatch(sourcererActions.setDataView(dataView)); setSelectedOptions( - isOnlyDetectionAlerts - ? alertsOptions - : patternListToOptions(pickedDataViewData.patternList) + isOnlyDetectionAlerts ? alertsOptions : patternListToOptions(dataView.patternList) ); } } catch (err) { @@ -216,6 +217,7 @@ export const usePickIndexPatterns = ({ getDefaultSelectedOptionsByDataView, isOnlyDetectionAlerts, kibanaDataViews, + dataViews, ] ); diff --git a/x-pack/plugins/security_solution/public/common/components/threat_match/helpers.tsx b/x-pack/plugins/security_solution/public/common/components/threat_match/helpers.tsx index 25e4d98761888..693dad3da4255 100644 --- a/x-pack/plugins/security_solution/public/common/components/threat_match/helpers.tsx +++ b/x-pack/plugins/security_solution/public/common/components/threat_match/helpers.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { addIdToItem } from '@kbn/securitysolution-utils'; import type { ThreatMap, ThreatMapping } from '@kbn/securitysolution-io-ts-alerting-types'; @@ -28,7 +28,7 @@ export const getFormattedEntry = ( threatIndexPatterns: DataViewBase, item: Entry, itemIndex: number, - uuidGen: () => string = uuid.v4 + uuidGen: () => string = uuidv4 ): FormattedEntry => { const { fields } = indexPattern; const { fields: threatFields } = threatIndexPatterns; diff --git a/x-pack/plugins/security_solution/public/common/components/toasters/utils.ts b/x-pack/plugins/security_solution/public/common/components/toasters/utils.ts index 69914ed3116bd..5825f9ad18f06 100644 --- a/x-pack/plugins/security_solution/public/common/components/toasters/utils.ts +++ b/x-pack/plugins/security_solution/public/common/components/toasters/utils.ts @@ -6,7 +6,7 @@ */ import type React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { isError } from 'lodash/fp'; import { isAppError } from '@kbn/securitysolution-t-grid'; @@ -24,7 +24,7 @@ export const displayErrorToast = ( errorTitle: string, errorMessages: string[], dispatchToaster: React.Dispatch, - id: string = uuid.v4() + id: string = uuidv4() ): void => { const toast: AppToast = { id, @@ -48,7 +48,7 @@ export const displayErrorToast = ( export const displaySuccessToast = ( title: string, dispatchToaster: React.Dispatch, - id: string = uuid.v4() + id: string = uuidv4() ): void => { const toast: AppToast = { id, @@ -83,7 +83,7 @@ export type ErrorToToasterArgs = Partial & { * @param dispatchToaster provided by useStateToaster() */ export const errorToToaster = ({ - id = uuid.v4(), + id = uuidv4(), title, error, color = 'danger', diff --git a/x-pack/plugins/security_solution/public/common/components/top_n/top_n.test.tsx b/x-pack/plugins/security_solution/public/common/components/top_n/top_n.test.tsx index 1e43949cd26c3..7349f053f8b13 100644 --- a/x-pack/plugins/security_solution/public/common/components/top_n/top_n.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/top_n/top_n.test.tsx @@ -37,8 +37,8 @@ jest.mock('../visualization_actions', () => ({ jest.mock('uuid', () => { return { - v1: jest.fn(() => 'uuid.v1()'), - v4: jest.fn(() => 'uuid.v4()'), + v1: jest.fn(() => 'uuidv1()'), + v4: jest.fn(() => 'uuidv4()'), }; }); diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/__mocks__/alert_donut_embeddable.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/__mocks__/visualization_embeddable.tsx similarity index 74% rename from x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/__mocks__/alert_donut_embeddable.tsx rename to x-pack/plugins/security_solution/public/common/components/visualization_actions/__mocks__/visualization_embeddable.tsx index 62343b498ea3e..9979e829923fc 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/__mocks__/alert_donut_embeddable.tsx +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/__mocks__/visualization_embeddable.tsx @@ -7,4 +7,4 @@ import React from 'react'; -export const AlertDonutEmbeddable = () =>
    ; +export const VisualizationEmbeddable = () =>
    ; diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/__snapshots__/risk_score_donut.test.ts.snap b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/__snapshots__/risk_score_donut.test.ts.snap new file mode 100644 index 0000000000000..2daccdaf1bae5 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/__snapshots__/risk_score_donut.test.ts.snap @@ -0,0 +1,154 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`getRiskScoreDonutAttributes should render 1`] = ` +Object { + "description": "", + "references": Array [], + "state": Object { + "adHocDataViews": Object { + "1dd5663b-f062-43f8-8688-fc8166c2ca8e": Object { + "allowNoIndex": false, + "fieldAttrs": Object {}, + "fieldFormats": Object {}, + "id": "1dd5663b-f062-43f8-8688-fc8166c2ca8e", + "name": "ml_host_risk_score_latest_mockSpaceId", + "runtimeFieldMap": Object {}, + "sourceFilters": Array [], + "timeFieldName": "@timestamp", + "title": "ml_host_risk_score_latest_mockSpaceId", + }, + }, + "datasourceStates": Object { + "formBased": Object { + "layers": Object { + "d594baeb-5eca-480c-8885-ba79eaf41372": Object { + "columnOrder": Array [ + "a2e8541a-c22f-4e43-8a12-caa33edc5de0", + "75179122-96fc-40e1-93b4-8e9310af5f06", + ], + "columns": Object { + "75179122-96fc-40e1-93b4-8e9310af5f06": Object { + "dataType": "number", + "isBucketed": false, + "label": "Count of records", + "operationType": "count", + "params": Object { + "emptyAsNull": true, + }, + "scale": "ratio", + "sourceField": "___records___", + }, + "a2e8541a-c22f-4e43-8a12-caa33edc5de0": Object { + "dataType": "string", + "isBucketed": true, + "label": "Filters", + "operationType": "filters", + "params": Object { + "filters": Array [ + Object { + "input": Object { + "language": "kuery", + "query": "host.risk.calculated_level : \\"Unknown\\"", + }, + "label": "Unknown", + }, + Object { + "input": Object { + "language": "kuery", + "query": "host.risk.calculated_level : \\"Low\\"", + }, + "label": "Low", + }, + Object { + "input": Object { + "language": "kuery", + "query": "host.risk.calculated_level : \\"Moderiate\\"", + }, + "label": "Moderiate", + }, + Object { + "input": Object { + "language": "kuery", + "query": "host.risk.calculated_level : \\"High\\"", + }, + "label": "High", + }, + Object { + "input": Object { + "language": "kuery", + "query": "host.risk.calculated_level : \\"Critical\\"", + }, + "label": "Critical", + }, + ], + }, + "scale": "ordinal", + }, + }, + "incompleteColumns": Object {}, + "sampling": 1, + }, + }, + }, + "textBased": Object { + "layers": Object {}, + }, + }, + "filters": Array [ + Object { + "meta": Object { + "alias": null, + "disabled": false, + "key": "host.id", + "negate": false, + "params": Object { + "query": "123", + }, + "type": "phrase", + }, + "query": Object { + "match_phrase": Object { + "host.id": "123", + }, + }, + }, + ], + "internalReferences": Array [ + Object { + "id": "1dd5663b-f062-43f8-8688-fc8166c2ca8e", + "name": "indexpattern-datasource-layer-d594baeb-5eca-480c-8885-ba79eaf41372", + "type": "index-pattern", + }, + ], + "query": Object { + "language": "kql", + "query": "host.name: *", + }, + "visualization": Object { + "layers": Array [ + Object { + "categoryDisplay": "hide", + "emptySizeRatio": 0.8, + "layerId": "d594baeb-5eca-480c-8885-ba79eaf41372", + "layerType": "data", + "legendDisplay": "hide", + "legendPosition": "right", + "legendSize": "small", + "metrics": Array [ + "75179122-96fc-40e1-93b4-8e9310af5f06", + ], + "nestedLegend": true, + "numberDisplay": "value", + "percentDecimals": 2, + "primaryGroups": Array [ + "a2e8541a-c22f-4e43-8a12-caa33edc5de0", + ], + }, + ], + "shape": "donut", + }, + }, + "title": "host risk donut", + "visualizationType": "lnsPie", +} +`; diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.test.ts b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.test.ts new file mode 100644 index 0000000000000..b7a30e1c02979 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.test.ts @@ -0,0 +1,56 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { renderHook } from '@testing-library/react-hooks'; +import { wrapper } from '../../../mocks'; + +import { useLensAttributes } from '../../../use_lens_attributes'; + +import { getRiskScoreDonutAttributes } from './risk_score_donut'; + +jest.mock('../../../../../containers/sourcerer', () => ({ + useSourcererDataView: jest.fn().mockReturnValue({ + selectedPatterns: ['auditbeat-mytest-*'], + dataViewId: 'security-solution-my-test', + indicesExist: true, + }), +})); + +jest.mock('../../../../../utils/route/use_route_spy', () => ({ + useRouteSpy: jest.fn().mockReturnValue([ + { + detailName: 'undefined', + pageName: 'overview', + tabName: undefined, + }, + ]), +})); + +jest.mock('uuid', () => ({ + v4: jest + .fn() + .mockReturnValueOnce('d594baeb-5eca-480c-8885-ba79eaf41372') + .mockReturnValue('1dd5663b-f062-43f8-8688-fc8166c2ca8e'), +})); + +describe('getRiskScoreDonutAttributes', () => { + it('should render', () => { + const { result } = renderHook( + () => + useLensAttributes({ + getLensAttributes: getRiskScoreDonutAttributes, + stackByField: 'host', + extraOptions: { + spaceId: 'mockSpaceId', + }, + }), + { wrapper } + ); + + expect(result?.current).toMatchSnapshot(); + }); +}); diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.ts b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.ts new file mode 100644 index 0000000000000..167467296a658 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut.ts @@ -0,0 +1,145 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { v4 as uuidv4 } from 'uuid'; +import type { GetLensAttributes } from '../../../types'; + +export const getRiskScoreDonutAttributes: GetLensAttributes = ( + stackByField, + extraOptions = { spaceId: 'default' } +) => { + const layerId = uuidv4(); + const internalReferenceId = uuidv4(); + return { + title: `${stackByField} risk donut`, + description: '', + visualizationType: 'lnsPie', + state: { + visualization: { + shape: 'donut', + layers: [ + { + layerId, + primaryGroups: ['a2e8541a-c22f-4e43-8a12-caa33edc5de0'], + metrics: ['75179122-96fc-40e1-93b4-8e9310af5f06'], + numberDisplay: 'value', + categoryDisplay: 'hide', + legendDisplay: 'hide', + nestedLegend: true, + layerType: 'data', + legendSize: 'small', + legendPosition: 'right', + percentDecimals: 2, + emptySizeRatio: 0.8, + }, + ], + }, + query: { + query: '', + language: 'kuery', + }, + filters: [], + datasourceStates: { + formBased: { + layers: { + [layerId]: { + columns: { + 'a2e8541a-c22f-4e43-8a12-caa33edc5de0': { + label: 'Filters', + dataType: 'string', + operationType: 'filters', + scale: 'ordinal', + isBucketed: true, + params: { + filters: [ + { + label: 'Unknown', + input: { + query: `${stackByField}.risk.calculated_level : \"Unknown\"`, + language: 'kuery', + }, + }, + { + input: { + query: `${stackByField}.risk.calculated_level : \"Low\"`, + language: 'kuery', + }, + label: 'Low', + }, + { + input: { + query: `${stackByField}.risk.calculated_level : \"Moderiate\"`, + language: 'kuery', + }, + label: 'Moderiate', + }, + { + input: { + query: `${stackByField}.risk.calculated_level : \"High\"`, + language: 'kuery', + }, + label: 'High', + }, + { + input: { + query: `${stackByField}.risk.calculated_level : \"Critical\"`, + language: 'kuery', + }, + label: 'Critical', + }, + ], + }, + }, + '75179122-96fc-40e1-93b4-8e9310af5f06': { + label: 'Count of records', + dataType: 'number', + operationType: 'count', + isBucketed: false, + scale: 'ratio', + sourceField: '___records___', + params: { + emptyAsNull: true, + }, + }, + }, + columnOrder: [ + 'a2e8541a-c22f-4e43-8a12-caa33edc5de0', + '75179122-96fc-40e1-93b4-8e9310af5f06', + ], + sampling: 1, + incompleteColumns: {}, + }, + }, + }, + textBased: { + layers: {}, + }, + }, + internalReferences: [ + { + type: 'index-pattern', + id: internalReferenceId, + name: `indexpattern-datasource-layer-${layerId}`, + }, + ], + adHocDataViews: { + [internalReferenceId]: { + id: internalReferenceId, + title: `ml_${stackByField}_risk_score_latest_${extraOptions.spaceId}`, + timeFieldName: '@timestamp', + sourceFilters: [], + fieldFormats: {}, + runtimeFieldMap: {}, + fieldAttrs: {}, + allowNoIndex: false, + name: `ml_${stackByField}_risk_score_latest_${extraOptions.spaceId}`, + }, + }, + }, + references: [], + }; +}; diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_embeddable.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_embeddable.tsx index 5708aee06ecad..985a9881d330b 100644 --- a/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_embeddable.tsx +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/lens_embeddable.tsx @@ -51,6 +51,7 @@ const initVisualizationData: { const style = { height: '100%', minWidth: '100px' }; const LensEmbeddableComponent: React.FC = ({ + applyGlobalQueriesAndFilters = true, extraActions, extraOptions, getLensAttributes, @@ -72,6 +73,7 @@ const LensEmbeddableComponent: React.FC = ({ const getGlobalQuery = inputsSelectors.globalQueryByIdSelector(); const { searchSessionId } = useDeepEqualSelector((state) => getGlobalQuery(state, id)); const attributes = useLensAttributes({ + applyGlobalQueriesAndFilters, extraOptions, getLensAttributes, lensAttributes, diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/types.ts b/x-pack/plugins/security_solution/public/common/components/visualization_actions/types.ts index 8b0a84f084396..ef4830d71bd01 100644 --- a/x-pack/plugins/security_solution/public/common/components/visualization_actions/types.ts +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/types.ts @@ -44,6 +44,7 @@ export type OnEmbeddableLoaded = (data: EmbeddableData) => void; export interface LensEmbeddableComponentProps { adHocDataViews?: string[]; + applyGlobalQueriesAndFilters?: boolean; extraActions?: Action[]; extraOptions?: ExtraOptions; getLensAttributes?: GetLensAttributes; @@ -104,3 +105,9 @@ export interface ExtraOptions { spaceId?: string; status?: Status; } + +export interface VisualizationEmbeddableProps extends LensEmbeddableComponentProps { + isDonut?: boolean; + label?: string; + inputId?: InputsModelId.global | InputsModelId.timeline; +} diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.test.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.test.tsx index c7e0fbfa82195..7451209120e06 100644 --- a/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.test.tsx @@ -21,6 +21,7 @@ import { filterFromSearchBar, queryFromSearchBar, wrapper } from './mocks'; import { useSourcererDataView } from '../../containers/sourcerer'; import { kpiHostMetricLensAttributes } from './lens_attributes/hosts/kpi_host_metric'; import { useRouteSpy } from '../../utils/route/use_route_spy'; +import { SecurityPageName } from '../../../app/types'; jest.mock('../../containers/sourcerer'); jest.mock('../../utils/route/use_route_spy', () => ({ @@ -126,6 +127,32 @@ describe('useLensAttributes', () => { ]); }); + it('should not apply global queries and filters - applyGlobalQueriesAndFilters = false', () => { + (useRouteSpy as jest.Mock).mockReturnValue([ + { + detailName: undefined, + pageName: SecurityPageName.entityAnalytics, + tabName: undefined, + }, + ]); + const { result } = renderHook( + () => + useLensAttributes({ + applyGlobalQueriesAndFilters: false, + getLensAttributes: getExternalAlertLensAttributes, + stackByField: 'event.dataset', + }), + { wrapper } + ); + + expect(result?.current?.state.query.query).toEqual(''); + + expect(result?.current?.state.filters).toEqual([ + ...getExternalAlertLensAttributes().state.filters, + ...getIndexFilters(['auditbeat-*']), + ]); + }); + it('should add data view id to references', () => { const { result } = renderHook( () => diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.tsx index 6ec8370cd168f..1976a743e5fa1 100644 --- a/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.tsx +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/use_lens_attributes.tsx @@ -24,6 +24,7 @@ import { } from './utils'; export const useLensAttributes = ({ + applyGlobalQueriesAndFilters = true, extraOptions, getLensAttributes, lensAttributes, @@ -31,6 +32,7 @@ export const useLensAttributes = ({ stackByField, title, }: { + applyGlobalQueriesAndFilters?: boolean; extraOptions?: ExtraOptions; getLensAttributes?: GetLensAttributes; lensAttributes?: LensAttributes | null; @@ -97,10 +99,10 @@ export const useLensAttributes = ({ ...(title != null ? { title } : {}), state: { ...attrs.state, - query, + ...(applyGlobalQueriesAndFilters ? { query } : {}), filters: [ ...attrs.state.filters, - ...filters, + ...(applyGlobalQueriesAndFilters ? filters : []), ...pageFilters, ...tabsFilters, ...indexFilters, @@ -112,6 +114,7 @@ export const useLensAttributes = ({ })), } as LensAttributes; }, [ + applyGlobalQueriesAndFilters, attrs, dataViewId, filters, diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.test.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.test.tsx new file mode 100644 index 0000000000000..c53835c0f86b9 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.test.tsx @@ -0,0 +1,126 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import type { RenderResult } from '@testing-library/react'; +import { render } from '@testing-library/react'; +import { kpiHostMetricLensAttributes } from './lens_attributes/hosts/kpi_host_metric'; +import { VisualizationEmbeddable } from './visualization_embeddable'; +import * as inputActions from '../../store/inputs/actions'; +import { InputsModelId } from '../../store/inputs/constants'; +import { + createSecuritySolutionStorageMock, + kibanaObservable, + mockGlobalState, + SUB_PLUGINS_REDUCER, + TestProviders, +} from '../../mock'; +import { createStore } from '../../store'; +import type { State } from '../../store'; +import { useRefetchByRestartingSession } from '../page/use_refetch_by_session'; +import { getRiskScoreDonutAttributes } from './lens_attributes/common/risk_scores/risk_score_donut'; +import { TOTAL_LABEL } from '../../../overview/components/entity_analytics/common/translations'; + +jest.mock('./lens_embeddable'); +jest.mock('../page/use_refetch_by_session', () => ({ + useRefetchByRestartingSession: jest.fn(), +})); + +let res: RenderResult; +const mockSearchSessionId = 'mockSearchSessionId'; +const mockSearchSessionIdDefault = 'mockSearchSessionIdDefault'; +const mockRefetchByRestartingSession = jest.fn(); +const mockSetQuery = jest.spyOn(inputActions, 'setQuery'); +const mockDeleteQuery = jest.spyOn(inputActions, 'deleteOneQuery'); +const state: State = { + ...mockGlobalState, +}; +const { storage } = createSecuritySolutionStorageMock(); +const store = createStore(state, SUB_PLUGINS_REDUCER, kibanaObservable, storage); +describe('VisualizationEmbeddable', () => { + describe('when isDonut = false', () => { + beforeEach(() => { + jest.clearAllMocks(); + (useRefetchByRestartingSession as jest.Mock).mockReturnValue({ + session: { + current: { + start: jest + .fn() + .mockReturnValueOnce(mockSearchSessionId) + .mockReturnValue(mockSearchSessionIdDefault), + }, + }, + refetchByRestartingSession: mockRefetchByRestartingSession, + }); + res = render( + + + + ); + }); + + it('should render LensEmbeddable', () => { + expect(res.getByTestId('lens-embeddable')).toBeInTheDocument(); + }); + + it('should set query', () => { + expect(mockSetQuery).toHaveBeenCalledTimes(1); + expect(mockSetQuery).toHaveBeenCalledWith({ + inputId: InputsModelId.global, + id: 'testId', + searchSessionId: mockSearchSessionId, + refetch: mockRefetchByRestartingSession, + loading: false, + inspect: null, + }); + }); + + it('should delete query when unmount', () => { + res.unmount(); + expect(mockDeleteQuery).toHaveBeenCalledWith({ + inputId: InputsModelId.global, + id: 'testId', + }); + }); + }); + + describe('when isDonut = true', () => { + beforeEach(() => { + jest.clearAllMocks(); + (useRefetchByRestartingSession as jest.Mock).mockReturnValue({ + session: { + current: { + start: jest + .fn() + .mockReturnValueOnce(mockSearchSessionId) + .mockReturnValue(mockSearchSessionIdDefault), + }, + }, + refetchByRestartingSession: mockRefetchByRestartingSession, + }); + res = render( + + + + ); + }); + + it('should render donut wrapper ', () => { + expect(res.getByTestId('donut-chart')).toBeInTheDocument(); + }); + }); +}); diff --git a/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.tsx b/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.tsx new file mode 100644 index 0000000000000..c2807d7fd8263 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/components/visualization_actions/visualization_embeddable.tsx @@ -0,0 +1,90 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useCallback, useEffect } from 'react'; +import { useDispatch } from 'react-redux'; +import { ChartLabel } from '../../../overview/components/detection_response/alerts_by_status/chart_label'; +import type { VisualizationAlertsByStatusResponse } from '../../../overview/components/detection_response/alerts_by_status/types'; +import { useDeepEqualSelector } from '../../hooks/use_selector'; +import { inputsActions, inputsSelectors } from '../../store/inputs'; +import { DonutChartWrapper } from '../charts/donutchart'; +import { parseVisualizationData } from './utils'; +import { InputsModelId } from '../../store/inputs/constants'; +import { useRefetchByRestartingSession } from '../page/use_refetch_by_session'; +import { LensEmbeddable } from './lens_embeddable'; +import type { EmbeddableData, VisualizationEmbeddableProps } from './types'; + +const VisualizationEmbeddableComponent: React.FC = (props) => { + const dispatch = useDispatch(); + const { inputId = InputsModelId.global, id, isDonut, label, onLoad, ...lensPorps } = props; + const { session, refetchByRestartingSession } = useRefetchByRestartingSession({ + inputId, + queryId: id, + }); + const getGlobalQuery = inputsSelectors.globalQueryByIdSelector(); + const { inspect } = useDeepEqualSelector((state) => getGlobalQuery(state, id)); + const visualizationData = inspect?.response + ? parseVisualizationData(inspect?.response) + : null; + const dataExists = visualizationData != null && visualizationData[0]?.hits.total !== 0; + + const onEmbeddableLoad = useCallback( + ({ requests, responses, isLoading }: EmbeddableData) => { + dispatch( + inputsActions.setQuery({ + inputId, + id, + searchSessionId: session.current.start(), + refetch: refetchByRestartingSession, + loading: isLoading, + inspect: { dsl: requests, response: responses }, + }) + ); + + if (typeof onLoad === 'function') { + onLoad({ requests, responses, isLoading }); + } + }, + [dispatch, inputId, id, session, refetchByRestartingSession, onLoad] + ); + + useEffect(() => { + dispatch( + inputsActions.setQuery({ + inputId, + id, + searchSessionId: session.current.start(), + refetch: refetchByRestartingSession, + loading: false, + inspect: null, + }) + ); + }, [dispatch, inputId, id, refetchByRestartingSession, session]); + + useEffect(() => { + return () => { + dispatch(inputsActions.deleteOneQuery({ inputId, id })); + }; + }, [dispatch, id, inputId]); + + if (isDonut) { + return ( + : null} + > + + + ); + } + + return ; +}; + +export const VisualizationEmbeddable = React.memo(VisualizationEmbeddableComponent); diff --git a/x-pack/plugins/security_solution/public/common/containers/source/use_data_view.tsx b/x-pack/plugins/security_solution/public/common/containers/source/use_data_view.tsx index a5dd7f10edaab..ef8eac73ba136 100644 --- a/x-pack/plugins/security_solution/public/common/containers/source/use_data_view.tsx +++ b/x-pack/plugins/security_solution/public/common/containers/source/use_data_view.tsx @@ -24,7 +24,7 @@ import { useAppToasts } from '../../hooks/use_app_toasts'; import { sourcererActions } from '../../store/sourcerer'; import * as i18n from './translations'; import { SourcererScopeName } from '../../store/sourcerer/model'; -import { getSourcererDataView } from '../sourcerer/api'; +import { getSourcererDataView } from '../sourcerer/get_sourcerer_data_view'; import { useTrackHttpRequest } from '../../lib/apm/use_track_http_request'; import { APP_UI_ID } from '../../../../common/constants'; @@ -121,11 +121,8 @@ export const useDataView = (): { const { endTracking } = startTracking({ name: `${APP_UI_ID} indexFieldsSearch` }); if (needToBeInit) { - const dataViewToUpdate = await getSourcererDataView( - dataViewId, - abortCtrl.current[dataViewId].signal - ); - dispatch(sourcererActions.setDataView(dataViewToUpdate)); + const dataView = await getSourcererDataView(dataViewId, data.dataViews); + dispatch(sourcererActions.setDataView(dataView)); } return new Promise((resolve) => { @@ -208,7 +205,7 @@ export const useDataView = (): { } return asyncSearch(); }, - [addError, addWarning, data.search, dispatch, setLoading, startTracking] + [addError, addWarning, data.search, dispatch, setLoading, startTracking, data.dataViews] ); useEffect(() => { diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/api.ts b/x-pack/plugins/security_solution/public/common/containers/sourcerer/api.ts deleted file mode 100644 index cfa2f890b9044..0000000000000 --- a/x-pack/plugins/security_solution/public/common/containers/sourcerer/api.ts +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { KibanaServices } from '../../lib/kibana'; -import { SOURCERER_API_URL } from '../../../../common/constants'; -import type { KibanaDataView } from '../../store/sourcerer/model'; - -export interface GetSourcererDataView { - signal: AbortSignal; - body: { - patternList: string[]; - }; -} - -export interface SecurityDataView { - defaultDataView: KibanaDataView; - kibanaDataViews: KibanaDataView[]; -} - -export const postSourcererDataView = async ({ - body, - signal, -}: GetSourcererDataView): Promise => - KibanaServices.get().http.fetch(SOURCERER_API_URL, { - method: 'POST', - body: JSON.stringify(body), - signal, - }); - -export const getSourcererDataView = async ( - dataViewId: string, - signal?: AbortSignal -): Promise => { - return KibanaServices.get().http.fetch(SOURCERER_API_URL, { - method: 'GET', - query: { dataViewId }, - asSystemRequest: true, - signal, - }); -}; diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts b/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts new file mode 100644 index 0000000000000..8f98d6dce141c --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/containers/sourcerer/create_sourcerer_data_view.ts @@ -0,0 +1,102 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { + DataViewListItem, + DataViewsContract, + DataView as DataViewType, +} from '@kbn/data-views-plugin/common'; +import { transformError } from '@kbn/securitysolution-es-utils'; +import { ensurePatternFormat } from '../../../../common/utils/sourcerer'; +import type { KibanaDataView } from '../../store/sourcerer/model'; +import { DEFAULT_TIME_FIELD } from '../../../../common/constants'; +import { getSourcererDataView } from './get_sourcerer_data_view'; + +export interface GetSourcererDataView { + signal?: AbortSignal; + body: { + patternList: string[]; + }; + dataViewService: DataViewsContract; + dataViewId: string | null; +} + +export interface SecurityDataView { + defaultDataView: KibanaDataView; + kibanaDataViews: KibanaDataView[]; +} + +export const createSourcererDataView = async ({ + body, + dataViewService, + dataViewId, +}: GetSourcererDataView): Promise => { + if (dataViewId === null) { + return; + } + let allDataViews: DataViewListItem[] = await dataViewService.getIdsWithTitle(); + const siemDataViewExist = allDataViews.find((dv) => dv.id === dataViewId); + + const { patternList } = body; + const patternListAsTitle = ensurePatternFormat(patternList).join(); + let siemDataView: DataViewType; + if (siemDataViewExist === undefined) { + try { + siemDataView = await dataViewService.createAndSave( + { + allowNoIndex: true, + id: dataViewId, + title: patternListAsTitle, + timeFieldName: DEFAULT_TIME_FIELD, + }, + // Override property - if a data view exists with the security solution pattern + // delete it and replace it with our data view + true + ); + } catch (err) { + const error = transformError(err); + if (err.name === 'DuplicateDataViewError' || error.statusCode === 409) { + siemDataView = await dataViewService.get(dataViewId); + } else { + throw error; + } + } + } else { + const siemDataViewTitle = siemDataViewExist + ? ensurePatternFormat(siemDataViewExist.title.split(',')).join() + : ''; + siemDataView = await dataViewService.get(dataViewId); + + if (patternListAsTitle !== siemDataViewTitle) { + siemDataView.title = patternListAsTitle; + await dataViewService.updateSavedObject(siemDataView); + } + } + + if (allDataViews.some((dv) => dv.id === dataViewId)) { + allDataViews = allDataViews.map((v) => + v.id === dataViewId ? { ...v, title: patternListAsTitle } : v + ); + } else if (siemDataView !== null) { + allDataViews.push({ id: siemDataView.id ?? dataViewId, title: siemDataView?.title }); + } + + const siemSourcererDataView = await getSourcererDataView(dataViewId, dataViewService); + + return { + defaultDataView: siemSourcererDataView, + kibanaDataViews: allDataViews.map((dv) => + dv.id === dataViewId + ? siemSourcererDataView + : { + id: dv.id, + patternList: dv.title.split(','), + title: dv.title, + } + ), + }; +}; diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/get_sourcerer_data_view.ts b/x-pack/plugins/security_solution/public/common/containers/sourcerer/get_sourcerer_data_view.ts new file mode 100644 index 0000000000000..cd100dfdb3b64 --- /dev/null +++ b/x-pack/plugins/security_solution/public/common/containers/sourcerer/get_sourcerer_data_view.ts @@ -0,0 +1,29 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { DataViewsContract } from '@kbn/data-views-plugin/common'; +import { ensurePatternFormat } from '../../../../common/utils/sourcerer'; + +export const getSourcererDataView = async ( + dataViewId: string, + dataViewsService: DataViewsContract +) => { + const dataViewData = await dataViewsService.get(dataViewId); + const defaultPatternsList = ensurePatternFormat(dataViewData.getIndexPattern().split(',')); + const patternList = defaultPatternsList.reduce((res: string[], pattern) => { + if (dataViewData.matchedIndices.find((q) => q.includes(pattern.replaceAll('*', '')))) { + res.push(pattern); + } + return res; + }, []); + + return { + id: dataViewData.id ?? '', + title: dataViewData.getIndexPattern(), + patternList, + }; +}; diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.test.tsx b/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.test.tsx index 634330ea10e91..89d8bc2721f82 100644 --- a/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.test.tsx +++ b/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.test.tsx @@ -33,10 +33,10 @@ import { } from '../../mock'; import type { SelectedDataView } from '../../store/sourcerer/model'; import { SourcererScopeName } from '../../store/sourcerer/model'; -import { postSourcererDataView } from './api'; import * as source from '../source/use_data_view'; import { sourcererActions } from '../../store/sourcerer'; import { useInitializeUrlParam, useUpdateUrlParam } from '../../utils/global_query_string'; +import { createSourcererDataView } from './create_sourcerer_data_view'; const mockRouteSpy: RouteSpyState = { pageName: SecurityPageName.overview, @@ -49,7 +49,7 @@ const mockDispatch = jest.fn(); const mockUseUserInfo = useUserInfo as jest.Mock; jest.mock('../../lib/apm/use_track_http_request'); jest.mock('../../../detections/components/user_info'); -jest.mock('./api'); +jest.mock('./create_sourcerer_data_view'); jest.mock('../../utils/global_query_string'); jest.mock('react-redux', () => { const original = jest.requireActual('react-redux'); @@ -141,7 +141,7 @@ describe('Sourcerer Hooks', () => { defaultDataView: mockSourcererState.defaultDataView, kibanaDataViews: [mockSourcererState.defaultDataView], }; - (postSourcererDataView as jest.Mock).mockResolvedValue(mockNewDataViews); + (createSourcererDataView as jest.Mock).mockResolvedValue(mockNewDataViews); store = createStore( { diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.tsx b/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.tsx index 07dafff7470d7..9e7c14a48026b 100644 --- a/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.tsx +++ b/x-pack/plugins/security_solution/public/common/containers/sourcerer/index.tsx @@ -31,17 +31,21 @@ import { TimelineId } from '../../../../common/types'; import { useDeepEqualSelector } from '../../hooks/use_selector'; import { checkIfIndicesExist, getScopePatternListSelection } from '../../store/sourcerer/helpers'; import { useAppToasts } from '../../hooks/use_app_toasts'; -import { postSourcererDataView } from './api'; +import { createSourcererDataView } from './create_sourcerer_data_view'; import { useDataView } from '../source/use_data_view'; import { useFetchIndex } from '../source'; import { useInitializeUrlParam, useUpdateUrlParam } from '../../utils/global_query_string'; import { URL_PARAM_KEY } from '../../hooks/use_url_state'; import { sortWithExcludesAtEnd } from '../../../../common/utils/sourcerer'; +import { useKibana } from '../../lib/kibana'; export const useInitSourcerer = ( scopeId: SourcererScopeName.default | SourcererScopeName.detections = SourcererScopeName.default ) => { const dispatch = useDispatch(); + const { + data: { dataViews }, + } = useKibana().services; const abortCtrl = useRef(new AbortController()); const initialTimelineSourcerer = useRef(true); const initialDetectionSourcerer = useRef(true); @@ -229,6 +233,7 @@ export const useInitSourcerer = ( signalIndexName, signalIndexNameSourcerer, ]); + const { dataViewId } = useSourcererDataView(scopeId); const updateSourcererDataView = useCallback( (newSignalsIndex: string) => { @@ -236,18 +241,21 @@ export const useInitSourcerer = ( abortCtrl.current = new AbortController(); dispatch(sourcererActions.setSourcererScopeLoading({ loading: true })); + try { - const response = await postSourcererDataView({ + const response = await createSourcererDataView({ body: { patternList: newPatternList }, signal: abortCtrl.current.signal, + dataViewService: dataViews, + dataViewId, }); - if (response.defaultDataView.patternList.includes(newSignalsIndex)) { + if (response?.defaultDataView.patternList.includes(newSignalsIndex)) { // first time signals is defined and validated in the sourcerer // redo indexFieldsSearch indexFieldsSearch({ dataViewId: response.defaultDataView.id }); + dispatch(sourcererActions.setSourcererDataViews(response)); } - dispatch(sourcererActions.setSourcererDataViews(response)); dispatch(sourcererActions.setSourcererScopeLoading({ loading: false })); } catch (err) { addError(err, { @@ -267,7 +275,7 @@ export const useInitSourcerer = ( asyncSearch([...defaultDataView.title.split(','), newSignalsIndex]); } }, - [defaultDataView.title, dispatch, indexFieldsSearch, addError] + [defaultDataView.title, dispatch, dataViews, dataViewId, indexFieldsSearch, addError] ); const onSignalIndexUpdated = useCallback(() => { diff --git a/x-pack/plugins/security_solution/public/common/containers/sourcerer/use_signal_helpers.tsx b/x-pack/plugins/security_solution/public/common/containers/sourcerer/use_signal_helpers.tsx index f330204116f83..8aa9f11e87983 100644 --- a/x-pack/plugins/security_solution/public/common/containers/sourcerer/use_signal_helpers.tsx +++ b/x-pack/plugins/security_solution/public/common/containers/sourcerer/use_signal_helpers.tsx @@ -12,10 +12,11 @@ import { sourcererSelectors } from '../../store'; import { useDeepEqualSelector } from '../../hooks/use_selector'; import { useSourcererDataView } from '.'; import { SourcererScopeName } from '../../store/sourcerer/model'; -import { postSourcererDataView } from './api'; -import { sourcererActions } from '../../store/sourcerer'; import { useDataView } from '../source/use_data_view'; import { useAppToasts } from '../../hooks/use_app_toasts'; +import { useKibana } from '../../lib/kibana'; +import { createSourcererDataView } from './create_sourcerer_data_view'; +import { sourcererActions } from '../../store/sourcerer'; export const useSignalHelpers = (): { /* when defined, signal index has been initiated but does not exist */ @@ -23,11 +24,14 @@ export const useSignalHelpers = (): { /* when false, signal index has been initiated */ signalIndexNeedsInit: boolean; } => { - const { indicesExist } = useSourcererDataView(SourcererScopeName.detections); + const { indicesExist, dataViewId } = useSourcererDataView(SourcererScopeName.detections); const { indexFieldsSearch } = useDataView(); const dispatch = useDispatch(); const { addError } = useAppToasts(); const abortCtrl = useRef(new AbortController()); + const { + data: { dataViews }, + } = useKibana().services; const getDefaultDataViewSelector = useMemo( () => sourcererSelectors.defaultDataViewSelector(), @@ -53,19 +57,21 @@ export const useSignalHelpers = (): { const asyncSearch = async () => { abortCtrl.current = new AbortController(); try { - const response = await postSourcererDataView({ + const sourcererDataView = await createSourcererDataView({ body: { patternList: defaultDataView.title.split(',') }, signal: abortCtrl.current.signal, + dataViewId, + dataViewService: dataViews, }); if ( signalIndexNameSourcerer !== null && - response.defaultDataView.patternList.includes(signalIndexNameSourcerer) + sourcererDataView?.defaultDataView.patternList.includes(signalIndexNameSourcerer) ) { // first time signals is defined and validated in the sourcerer // redo indexFieldsSearch - indexFieldsSearch({ dataViewId: response.defaultDataView.id }); - dispatch(sourcererActions.setSourcererDataViews(response)); + indexFieldsSearch({ dataViewId: sourcererDataView.defaultDataView.id }); + dispatch(sourcererActions.setSourcererDataViews(sourcererDataView)); } } catch (err) { addError(err, { @@ -83,7 +89,15 @@ export const useSignalHelpers = (): { abortCtrl.current.abort(); asyncSearch(); } - }, [addError, defaultDataView.title, dispatch, indexFieldsSearch, signalIndexNameSourcerer]); + }, [ + addError, + dataViewId, + dataViews, + defaultDataView.title, + dispatch, + indexFieldsSearch, + signalIndexNameSourcerer, + ]); return { ...(shouldWePollForIndex ? { pollForSignalIndex } : {}), diff --git a/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_secuirty_packages.test.tsx b/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_secuirty_packages.test.tsx index f40f1dd0fecc0..0352dd03bbcff 100644 --- a/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_secuirty_packages.test.tsx +++ b/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_secuirty_packages.test.tsx @@ -6,7 +6,7 @@ */ import React, { memo } from 'react'; -import { useKibana } from '../lib/kibana'; +import { KibanaServices, useKibana } from '../lib/kibana'; import type { RenderHookResult } from '@testing-library/react-hooks'; import { renderHook as _renderHook } from '@testing-library/react-hooks'; import { useUpgradeSecurityPackages } from './use_upgrade_security_packages'; @@ -23,8 +23,11 @@ jest.mock('../components/user_privileges', () => { }); jest.mock('../lib/kibana'); -// FLAKY: https://github.com/elastic/kibana/issues/112910 -describe.skip('When using the `useUpgradeSecurityPackages()` hook', () => { +describe('When using the `useUpgradeSecurityPackages()` hook', () => { + const mockGetPrebuiltRulesPackageVersion = + KibanaServices.getPrebuiltRulesPackageVersion as jest.Mock; + const mockGetKibanaVersion = KibanaServices.getKibanaVersion as jest.Mock; + const mockGetKibanaBranch = KibanaServices.getKibanaBranch as jest.Mock; let renderResult: RenderHookResult; let renderHook: () => RenderHookResult; let kibana: ReturnType; @@ -43,6 +46,7 @@ describe.skip('When using the `useUpgradeSecurityPackages()` hook', () => { }); afterEach(() => { + jest.clearAllMocks(); if (renderResult) { renderResult.unmount(); } @@ -65,4 +69,104 @@ describe.skip('When using the `useUpgradeSecurityPackages()` hook', () => { }) ); }); + + it('should send upgrade request with prerelease:false if branch is not `main` and build does not include `-SNAPSHOT`', async () => { + mockGetKibanaVersion.mockReturnValue('8.0.0'); + mockGetKibanaBranch.mockReturnValue('release'); + + renderHook(); + + await renderResult.waitFor( + () => (kibana.services.http.post as jest.Mock).mock.calls.length > 0 + ); + + expect(kibana.services.http.post).toHaveBeenCalledWith( + `${epmRouteService.getBulkInstallPath()}`, + expect.objectContaining({ + body: '{"packages":["endpoint","security_detection_engine"]}', + query: expect.objectContaining({ prerelease: false }), + }) + ); + }); + + it('should send upgrade request with prerelease:true if branch is `main` AND build includes `-SNAPSHOT`', async () => { + mockGetKibanaVersion.mockReturnValue('8.0.0-SNAPSHOT'); + mockGetKibanaBranch.mockReturnValue('main'); + + renderHook(); + + await renderResult.waitFor( + () => (kibana.services.http.post as jest.Mock).mock.calls.length > 0 + ); + + expect(kibana.services.http.post).toHaveBeenCalledWith( + `${epmRouteService.getBulkInstallPath()}`, + expect.objectContaining({ + body: '{"packages":["endpoint","security_detection_engine"]}', + query: expect.objectContaining({ prerelease: true }), + }) + ); + }); + + it('should send upgrade request with prerelease:true if branch is `release` and build includes `-SNAPSHOT`', async () => { + mockGetKibanaVersion.mockReturnValue('8.0.0-SNAPSHOT'); + mockGetKibanaBranch.mockReturnValue('release'); + + renderHook(); + + await renderResult.waitFor( + () => (kibana.services.http.post as jest.Mock).mock.calls.length > 0 + ); + + expect(kibana.services.http.post).toHaveBeenCalledWith( + `${epmRouteService.getBulkInstallPath()}`, + expect.objectContaining({ + body: '{"packages":["endpoint","security_detection_engine"]}', + query: expect.objectContaining({ prerelease: true }), + }) + ); + }); + + it('should send upgrade request with prerelease:true if branch is `main` and build does not include `-SNAPSHOT`', async () => { + mockGetKibanaVersion.mockReturnValue('8.0.0'); + mockGetKibanaBranch.mockReturnValue('main'); + + renderHook(); + + await renderResult.waitFor( + () => (kibana.services.http.post as jest.Mock).mock.calls.length > 0 + ); + + expect(kibana.services.http.post).toHaveBeenCalledWith( + `${epmRouteService.getBulkInstallPath()}`, + expect.objectContaining({ + body: '{"packages":["endpoint","security_detection_engine"]}', + query: expect.objectContaining({ prerelease: true }), + }) + ); + }); + + it('should send separate upgrade requests if prebuiltRulesPackageVersion is provided', async () => { + mockGetPrebuiltRulesPackageVersion.mockReturnValue('8.2.1'); + + renderHook(); + + await renderResult.waitFor( + () => (kibana.services.http.post as jest.Mock).mock.calls.length > 0 + ); + + expect(kibana.services.http.post).toHaveBeenNthCalledWith( + 1, + `${epmRouteService.getInstallPath('security_detection_engine', '8.2.1')}`, + expect.objectContaining({ query: { prerelease: true } }) + ); + expect(kibana.services.http.post).toHaveBeenNthCalledWith( + 2, + `${epmRouteService.getBulkInstallPath()}`, + expect.objectContaining({ + body: expect.stringContaining('endpoint'), + query: expect.objectContaining({ prerelease: true }), + }) + ); + }); }); diff --git a/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_security_packages.ts b/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_security_packages.ts index 848f1458502ca..1354770b7384d 100644 --- a/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_security_packages.ts +++ b/x-pack/plugins/security_solution/public/common/hooks/use_upgrade_security_packages.ts @@ -9,7 +9,8 @@ import { useEffect } from 'react'; import type { HttpFetchOptions, HttpStart } from '@kbn/core/public'; import type { BulkInstallPackagesResponse } from '@kbn/fleet-plugin/common'; import { epmRouteService } from '@kbn/fleet-plugin/common'; -import { useKibana } from '../lib/kibana'; +import type { InstallPackageResponse } from '@kbn/fleet-plugin/common/types'; +import { KibanaServices, useKibana } from '../lib/kibana'; import { useUserPrivileges } from '../components/user_privileges'; /** @@ -17,17 +18,44 @@ import { useUserPrivileges } from '../components/user_privileges'; * * @param http an http client for sending the request * @param options an object containing options for the request + * @param prebuiltRulesPackageVersion specific version of the prebuilt rules package to install */ const sendUpgradeSecurityPackages = async ( http: HttpStart, - options: HttpFetchOptions = {} -): Promise => { - return http.post(epmRouteService.getBulkInstallPath(), { - ...options, - body: JSON.stringify({ - packages: ['endpoint', 'security_detection_engine'], - }), - }); + options: HttpFetchOptions = {}, + prebuiltRulesPackageVersion?: string +): Promise => { + const packages = ['endpoint', 'security_detection_engine']; + const requests: Array> = []; + + // If `prebuiltRulesPackageVersion` is provided, try to install that version + // Must be done as two separate requests as bulk API doesn't support versions + if (prebuiltRulesPackageVersion != null) { + packages.splice(packages.indexOf('security_detection_engine'), 1); + requests.push( + http.post( + epmRouteService.getInstallPath('security_detection_engine', prebuiltRulesPackageVersion), + { + ...options, + body: JSON.stringify({ + force: true, + }), + } + ) + ); + } + + // Note: if `prerelease:true` option is provided, endpoint package will also be installed as prerelease + requests.push( + http.post(epmRouteService.getBulkInstallPath(), { + ...options, + body: JSON.stringify({ + packages, + }), + }) + ); + + await Promise.allSettled(requests); }; export const useUpgradeSecurityPackages = () => { @@ -50,8 +78,23 @@ export const useUpgradeSecurityPackages = () => { // Make sure fleet is initialized first await context.services.fleet?.isInitialized(); + // Always install the latest package if in dev env or snapshot build + const isPrerelease = + KibanaServices.getKibanaVersion().includes('-SNAPSHOT') || + KibanaServices.getKibanaBranch() === 'main'; + // ignore the response for now since we aren't notifying the user - await sendUpgradeSecurityPackages(context.services.http, { signal }); + // Note: response would be Promise.allSettled, so must iterate all responses for errors and throw manually + await sendUpgradeSecurityPackages( + context.services.http, + { + query: { + prerelease: isPrerelease, + }, + signal, + }, + KibanaServices.getPrebuiltRulesPackageVersion() + ); } catch (error) { // Ignore Errors, since this should not hinder the user's ability to use the UI diff --git a/x-pack/plugins/security_solution/public/common/lib/kibana/__mocks__/index.ts b/x-pack/plugins/security_solution/public/common/lib/kibana/__mocks__/index.ts index 6b736e3fbb503..2822a48669b32 100644 --- a/x-pack/plugins/security_solution/public/common/lib/kibana/__mocks__/index.ts +++ b/x-pack/plugins/security_solution/public/common/lib/kibana/__mocks__/index.ts @@ -36,6 +36,8 @@ export const KibanaServices = { }; }), getKibanaVersion: jest.fn(() => '8.0.0'), + getKibanaBranch: jest.fn(() => 'main'), + getPrebuiltRulesPackageVersion: jest.fn(() => undefined), }; export const useKibana = jest.fn().mockReturnValue({ services: { diff --git a/x-pack/plugins/security_solution/public/common/lib/kibana/services.ts b/x-pack/plugins/security_solution/public/common/lib/kibana/services.ts index 7b38c7e2a4218..cbd2ddce441ae 100644 --- a/x-pack/plugins/security_solution/public/common/lib/kibana/services.ts +++ b/x-pack/plugins/security_solution/public/common/lib/kibana/services.ts @@ -12,7 +12,9 @@ type GlobalServices = Pick; export class KibanaServices { + private static kibanaBranch?: string; private static kibanaVersion?: string; + private static prebuiltRulesPackageVersion?: string; private static services?: GlobalServices; public static init({ @@ -20,19 +22,20 @@ export class KibanaServices { application, data, unifiedSearch, + kibanaBranch, kibanaVersion, + prebuiltRulesPackageVersion, uiSettings, notifications, - }: GlobalServices & { kibanaVersion: string }) { - this.services = { - application, - data, - http, - uiSettings, - unifiedSearch, - notifications, - }; + }: GlobalServices & { + kibanaBranch: string; + kibanaVersion: string; + prebuiltRulesPackageVersion?: string; + }) { + this.services = { application, data, http, uiSettings, unifiedSearch, notifications }; + this.kibanaBranch = kibanaBranch; this.kibanaVersion = kibanaVersion; + this.prebuiltRulesPackageVersion = prebuiltRulesPackageVersion; } public static get(): GlobalServices { @@ -43,6 +46,14 @@ export class KibanaServices { return this.services; } + public static getKibanaBranch(): string { + if (!this.kibanaBranch) { + this.throwUninitializedError(); + } + + return this.kibanaBranch; + } + public static getKibanaVersion(): string { if (!this.kibanaVersion) { this.throwUninitializedError(); @@ -51,6 +62,10 @@ export class KibanaServices { return this.kibanaVersion; } + public static getPrebuiltRulesPackageVersion(): string | undefined { + return this.prebuiltRulesPackageVersion; + } + private static throwUninitializedError(): never { throw new Error( 'Kibana services not initialized - are you trying to import this module from outside of the SIEM app?' diff --git a/x-pack/plugins/security_solution/public/common/mock/endpoint/app_context_render.tsx b/x-pack/plugins/security_solution/public/common/mock/endpoint/app_context_render.tsx index 2e2cdbdd3eda5..5a9d092ad5097 100644 --- a/x-pack/plugins/security_solution/public/common/mock/endpoint/app_context_render.tsx +++ b/x-pack/plugins/security_solution/public/common/mock/endpoint/app_context_render.tsx @@ -292,6 +292,7 @@ export const createAppRootMockRenderer = (): AppContextTestRender => { const globalKibanaServicesParams = { ...startServices, kibanaVersion: '8.0.0', + kibanaBranch: 'main', }; if (jest.isMockFunction(KibanaServices.get)) { diff --git a/x-pack/plugins/security_solution/public/common/store/sourcerer/actions.ts b/x-pack/plugins/security_solution/public/common/store/sourcerer/actions.ts index db6dcedef8262..0a6ca2dcdfdb2 100644 --- a/x-pack/plugins/security_solution/public/common/store/sourcerer/actions.ts +++ b/x-pack/plugins/security_solution/public/common/store/sourcerer/actions.ts @@ -8,7 +8,7 @@ import actionCreatorFactory from 'typescript-fsa'; import type { SelectedDataView, SourcererDataView, SourcererScopeName } from './model'; -import type { SecurityDataView } from '../../containers/sourcerer/api'; +import type { SecurityDataView } from '../../containers/sourcerer/create_sourcerer_data_view'; const actionCreator = actionCreatorFactory('x-pack/security_solution/local/sourcerer'); diff --git a/x-pack/plugins/security_solution/public/common/store/store.ts b/x-pack/plugins/security_solution/public/common/store/store.ts index 7a00dafedcd20..6307fb556251d 100644 --- a/x-pack/plugins/security_solution/public/common/store/store.ts +++ b/x-pack/plugins/security_solution/public/common/store/store.ts @@ -25,10 +25,10 @@ import type { Storage } from '@kbn/kibana-utils-plugin/public'; import type { CoreStart } from '@kbn/core/public'; import reduceReducers from 'reduce-reducers'; import { + DEFAULT_DATA_VIEW_ID, DEFAULT_INDEX_KEY, DETECTION_ENGINE_INDEX_URL, SERVER_APP_ID, - SOURCERER_API_URL, } from '../../../common/constants'; import { telemetryMiddleware } from '../lib/telemetry'; import { appSelectors } from './app'; @@ -45,8 +45,8 @@ import { dataTableSelectors } from './data_table'; import type { KibanaDataView, SourcererModel } from './sourcerer/model'; import { initDataView } from './sourcerer/model'; import type { AppObservableLibs, StartedSubPlugins, StartPlugins } from '../../types'; -import type { SecurityDataView } from '../containers/sourcerer/api'; import type { ExperimentalFeatures } from '../../../common/experimental_features'; +import { createSourcererDataView } from '../containers/sourcerer/create_sourcerer_data_view'; type ComposeType = typeof compose; declare global { @@ -79,12 +79,17 @@ export const createStoreFactory = async ( let kibanaDataViews: SourcererModel['kibanaDataViews']; try { // check for/generate default Security Solution Kibana data view - const sourcererDataViews: SecurityDataView = await coreStart.http.fetch(SOURCERER_API_URL, { - method: 'POST', - body: JSON.stringify({ + const sourcererDataViews = await createSourcererDataView({ + body: { patternList: [...configPatternList, ...(signal.name != null ? [signal.name] : [])], - }), + }, + dataViewService: startPlugins.data.dataViews, + dataViewId: `${DEFAULT_DATA_VIEW_ID}-${(await startPlugins.spaces?.getActiveSpace())?.id}`, }); + + if (sourcererDataViews === undefined) { + throw new Error(''); + } defaultDataView = { ...initDataView, ...sourcererDataViews.defaultDataView }; kibanaDataViews = sourcererDataViews.kibanaDataViews.map((dataView: KibanaDataView) => ({ ...initDataView, diff --git a/x-pack/plugins/security_solution/public/common/types.ts b/x-pack/plugins/security_solution/public/common/types.ts index 8eced13424255..c639975e499a0 100644 --- a/x-pack/plugins/security_solution/public/common/types.ts +++ b/x-pack/plugins/security_solution/public/common/types.ts @@ -18,6 +18,7 @@ export interface ServerApiError { export interface SecuritySolutionUiConfigType { enableExperimental: string[]; + prebuiltRulesPackageVersion?: string; } /** diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_creation/index.tsx b/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_creation/index.tsx index 9b2ebe46ce2d1..c1cf9ea2beb9c 100644 --- a/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_creation/index.tsx +++ b/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_creation/index.tsx @@ -13,6 +13,7 @@ import { EuiPanel, EuiSpacer, EuiFlexGroup, + EuiResizableContainer, } from '@elastic/eui'; import React, { useCallback, useRef, useState, useMemo, useEffect } from 'react'; import styled from 'styled-components'; @@ -70,7 +71,7 @@ import { } from '../../../../../common/constants'; import { useKibana, useUiSetting$ } from '../../../../common/lib/kibana'; import { HeaderPage } from '../../../../common/components/header_page'; -import { PreviewFlyout } from '../../../../detections/pages/detection_engine/rules/preview'; +import { RulePreview } from '../../../../detections/components/rules/rule_preview'; import { useStartMlJobs } from '../../../rule_management/logic/use_start_ml_jobs'; const formHookNoop = async (): Promise => undefined; @@ -169,7 +170,8 @@ const CreateRulePageComponent: React.FC = () => { const actionMessageParams = useMemo(() => getActionMessageParams(ruleType), [ruleType]); const [dataViewOptions, setDataViewOptions] = useState<{ [x: string]: DataViewListItem }>({}); const [isPreviewDisabled, setIsPreviewDisabled] = useState(false); - const [isRulePreviewVisible, setIsRulePreviewVisible] = useState(false); + const [isRulePreviewVisible, setIsRulePreviewVisible] = useState(true); + const collapseFn = useRef<() => void | undefined>(); const [defineRuleData, setDefineRuleData] = useState({ ...stepDefineDefaultValue, @@ -384,190 +386,214 @@ const CreateRulePageComponent: React.FC = () => { return ( <> - - - - setIsRulePreviewVisible((isVisible) => !isVisible)} - > - {i18n.RULE_PREVIEW_TITLE} - - - - editStep(RuleStep.defineRule)} - > - {i18n.EDIT_RULE} - - ) - } - > - - submitStep(RuleStep.defineRule)} - kibanaDataViews={dataViewOptions} - descriptionColumns="singleSplit" - // We need a key to make this component remount when edit/view mode is toggled - // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 - key={isShouldRerenderStep(RuleStep.defineRule, activeStep)} - indicesConfig={indicesConfig} - threatIndicesConfig={threatIndicesConfig} - onRuleDataChange={updateCurrentDataState} - onPreviewDisabledStateChange={setIsPreviewDisabled} - /> - - - - - editStep(RuleStep.aboutRule)} - > - {i18n.EDIT_RULE} - - ) - } - > - - submitStep(RuleStep.aboutRule)} - // We need a key to make this component remount when edit/view mode is toggled - // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 - key={isShouldRerenderStep(RuleStep.aboutRule, activeStep)} - onRuleDataChange={updateCurrentDataState} - /> - - - - - editStep(RuleStep.scheduleRule)} - > - {i18n.EDIT_RULE} - - ) - } - > - - submitStep(RuleStep.scheduleRule)} - // We need a key to make this component remount when edit/view mode is toggled - // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 - key={isShouldRerenderStep(RuleStep.scheduleRule, activeStep)} - onRuleDataChange={updateCurrentDataState} - /> - - - - - editStep(RuleStep.ruleActions)} - > - {i18n.EDIT_RULE} - - ) - } - > - - submitStep(RuleStep.ruleActions)} - actionMessageParams={actionMessageParams} - // We need a key to make this component remount when edit/view mode is toggled - // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 - key={isShouldRerenderStep(RuleStep.ruleActions, activeStep)} - ruleType={ruleType} - /> - - - {isRulePreviewVisible && ( - setIsRulePreviewVisible(false)} - /> - )} - - + + {(EuiResizablePanel, EuiResizableButton, { togglePanel }) => { + collapseFn.current = () => togglePanel?.('preview', { direction: 'left' }); + return ( + <> + + + + + { + collapseFn.current?.(); + setIsRulePreviewVisible((isVisible) => !isVisible); + }} + > + {i18n.RULE_PREVIEW_TITLE} + + + + editStep(RuleStep.defineRule)} + > + {i18n.EDIT_RULE} + + ) + } + > + + submitStep(RuleStep.defineRule)} + kibanaDataViews={dataViewOptions} + descriptionColumns="singleSplit" + // We need a key to make this component remount when edit/view mode is toggled + // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 + key={isShouldRerenderStep(RuleStep.defineRule, activeStep)} + indicesConfig={indicesConfig} + threatIndicesConfig={threatIndicesConfig} + onRuleDataChange={updateCurrentDataState} + onPreviewDisabledStateChange={setIsPreviewDisabled} + /> + + + + + editStep(RuleStep.aboutRule)} + > + {i18n.EDIT_RULE} + + ) + } + > + + submitStep(RuleStep.aboutRule)} + // We need a key to make this component remount when edit/view mode is toggled + // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 + key={isShouldRerenderStep(RuleStep.aboutRule, activeStep)} + onRuleDataChange={updateCurrentDataState} + /> + + + + + editStep(RuleStep.scheduleRule)} + > + {i18n.EDIT_RULE} + + ) + } + > + + submitStep(RuleStep.scheduleRule)} + // We need a key to make this component remount when edit/view mode is toggled + // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 + key={isShouldRerenderStep(RuleStep.scheduleRule, activeStep)} + onRuleDataChange={updateCurrentDataState} + /> + + + + + editStep(RuleStep.ruleActions)} + > + {i18n.EDIT_RULE} + + ) + } + > + + submitStep(RuleStep.ruleActions)} + actionMessageParams={actionMessageParams} + // We need a key to make this component remount when edit/view mode is toggled + // https://github.com/elastic/kibana/pull/132834#discussion_r881705566 + key={isShouldRerenderStep(RuleStep.ruleActions, activeStep)} + ruleType={ruleType} + /> + + + + + + + + + setIsRulePreviewVisible((isVisible) => !isVisible)} + > + + + + ); + }} + diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_editing/index.tsx b/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_editing/index.tsx index 78b58f95c91a0..63369244cc569 100644 --- a/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_editing/index.tsx +++ b/x-pack/plugins/security_solution/public/detection_engine/rule_creation_ui/pages/rule_editing/index.tsx @@ -11,6 +11,7 @@ import { EuiCallOut, EuiFlexGroup, EuiFlexItem, + EuiResizableContainer, EuiSpacer, EuiTabbedContent, } from '@elastic/eui'; @@ -21,6 +22,7 @@ import { useParams } from 'react-router-dom'; import { noop } from 'lodash'; import type { DataViewListItem } from '@kbn/data-views-plugin/common'; +import { RulePreview } from '../../../../detections/components/rules/rule_preview'; import type { RuleUpdateProps } from '../../../../../common/detection_engine/rule_schema'; import { useRule, useUpdateRule } from '../../../rule_management/logic'; import { useListsConfig } from '../../../../detections/containers/detection_engine/lists/use_lists_config'; @@ -75,7 +77,6 @@ import { import { HeaderPage } from '../../../../common/components/header_page'; import { useStartTransaction } from '../../../../common/lib/apm/use_start_transaction'; import { SINGLE_RULE_ACTIONS } from '../../../../common/lib/apm/user_actions'; -import { PreviewFlyout } from '../../../../detections/pages/detection_engine/rules/preview'; import { useGetSavedQuery } from '../../../../detections/pages/detection_engine/rules/use_get_saved_query'; const formHookNoop = async (): Promise => undefined; @@ -129,7 +130,8 @@ const EditRulePageComponent: FC = () => { const { mutateAsync: updateRule, isLoading } = useUpdateRule(); const [dataViewOptions, setDataViewOptions] = useState<{ [x: string]: DataViewListItem }>({}); const [isPreviewDisabled, setIsPreviewDisabled] = useState(false); - const [isRulePreviewVisible, setIsRulePreviewVisible] = useState(false); + const [isRulePreviewVisible, setIsRulePreviewVisible] = useState(true); + const collapseFn = useRef<() => void | undefined>(); useEffect(() => { const fetchDataViews = async () => { @@ -197,8 +199,6 @@ const EditRulePageComponent: FC = () => { } }, [activeStep]); - const onPreviewClose = useCallback(() => setIsRulePreviewVisible(false), []); - const [indicesConfig] = useUiSetting$(DEFAULT_INDEX_KEY); const [threatIndicesConfig] = useUiSetting$(DEFAULT_THREAT_INDEX_KEY); @@ -464,99 +464,123 @@ const EditRulePageComponent: FC = () => { return ( <> - - - - {defineStep.data && aboutStep.data && scheduleStep.data && ( - setIsRulePreviewVisible((isVisible) => !isVisible)} - > - {ruleI18n.RULE_PREVIEW_TITLE} - - )} - - {invalidSteps.length > 0 && ( - - { - if (t === RuleStep.aboutRule) { - return ruleI18n.ABOUT; - } else if (t === RuleStep.defineRule) { - return ruleI18n.DEFINITION; - } else if (t === RuleStep.scheduleRule) { - return ruleI18n.SCHEDULE; - } else if (t === RuleStep.ruleActions) { - return ruleI18n.RULE_ACTIONS; - } - return t; - }) - .join(', '), - }} - /> - - )} + + {(EuiResizablePanel, EuiResizableButton, { togglePanel }) => { + collapseFn.current = () => togglePanel?.('preview', { direction: 'left' }); + return ( + <> + + + + + { + collapseFn.current?.(); + setIsRulePreviewVisible((isVisible) => !isVisible); + }} + > + {ruleI18n.RULE_PREVIEW_TITLE} + + + {invalidSteps.length > 0 && ( + + { + if (t === RuleStep.aboutRule) { + return ruleI18n.ABOUT; + } else if (t === RuleStep.defineRule) { + return ruleI18n.DEFINITION; + } else if (t === RuleStep.scheduleRule) { + return ruleI18n.SCHEDULE; + } else if (t === RuleStep.ruleActions) { + return ruleI18n.RULE_ACTIONS; + } + return t; + }) + .join(', '), + }} + /> + + )} - t.id === activeStep)} - onTabClick={onTabClick} - tabs={tabs} - /> + t.id === activeStep)} + onTabClick={onTabClick} + tabs={tabs} + /> - + - - - - {i18n.CANCEL} - - + + + + {i18n.CANCEL} + + - - + + {i18n.SAVE_CHANGES} + + + + + + + + + setIsRulePreviewVisible((isVisible) => !isVisible)} > - {i18n.SAVE_CHANGES} - - - - {isRulePreviewVisible && defineStep.data && aboutStep.data && scheduleStep.data && ( - - )} - - + {defineStep.data && aboutStep.data && scheduleStep.data && ( + + )} + + + ); + }} + diff --git a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_count_panel/index.tsx b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_count_panel/index.tsx index 8fceaece8ed2b..d35960cd2777f 100644 --- a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_count_panel/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_count_panel/index.tsx @@ -8,7 +8,7 @@ import type { EuiComboBox } from '@elastic/eui'; import type { MappingRuntimeFields } from '@elastic/elasticsearch/lib/api/types'; import React, { memo, useMemo, useState, useEffect, useCallback } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Filter, Query } from '@kbn/es-query'; import { buildEsQuery } from '@kbn/es-query'; @@ -75,7 +75,7 @@ export const AlertsCountPanel = memo( const { to, from, deleteQuery, setQuery } = useGlobalTime(false); // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `${DETECTIONS_ALERTS_COUNT_ID}-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `${DETECTIONS_ALERTS_COUNT_ID}-${uuidv4()}`, []); // Disabling the fecth method in useQueryAlerts since it is defaulted to the old one // const fetchMethod = fetchQueryRuleRegistryAlerts; diff --git a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_histogram_panel/index.tsx b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_histogram_panel/index.tsx index 688161019732d..535c50057ba53 100644 --- a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_histogram_panel/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_histogram_panel/index.tsx @@ -13,7 +13,7 @@ import numeral from '@elastic/numeral'; import React, { memo, useCallback, useMemo, useState, useEffect } from 'react'; import styled from 'styled-components'; import { isEmpty, noop } from 'lodash/fp'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Filter, Query } from '@kbn/es-query'; import { buildEsQuery } from '@kbn/es-query'; @@ -140,7 +140,7 @@ export const AlertsHistogramPanel = memo( const { to, from, deleteQuery, setQuery } = useGlobalTime(false); // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `${DETECTIONS_HISTOGRAM_ID}-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `${DETECTIONS_HISTOGRAM_ID}-${uuidv4()}`, []); const [isInitialLoading, setIsInitialLoading] = useState(true); const [isInspectDisabled, setIsInspectDisabled] = useState(false); const [defaultNumberFormat] = useUiSetting$(DEFAULT_NUMBER_FORMAT); @@ -229,7 +229,7 @@ export const AlertsHistogramPanel = memo( color: i < defaultLegendColors.length ? defaultLegendColors[i] : undefined, count: showCountsInLegend ? bucket.doc_count : undefined, dataProviderId: escapeDataProviderId( - `draggable-legend-item-${uuid.v4()}-${selectedStackByOption}-${bucket.key}` + `draggable-legend-item-${uuidv4()}-${selectedStackByOption}-${bucket.key}` ), field: selectedStackByOption, timelineId, diff --git a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_summary_charts_panel/index.tsx b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_summary_charts_panel/index.tsx index fa2cd5519103a..b49a91069fce2 100644 --- a/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_summary_charts_panel/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/alerts_kpis/alerts_summary_charts_panel/index.tsx @@ -9,7 +9,7 @@ import { EuiFlexGroup, EuiFlexItem, EuiPanel, EuiTitle } from '@elastic/eui'; import React, { useMemo, useCallback, useState, useEffect } from 'react'; import type { MappingRuntimeFields } from '@elastic/elasticsearch/lib/api/types'; import type { Filter, Query } from '@kbn/es-query'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import * as i18n from './translations'; import { KpiPanel } from '../common/components'; import { HeaderSection } from '../../../../common/components/header_section'; @@ -53,7 +53,7 @@ export const AlertsSummaryChartsPanel: React.FC = ({ title = i18n.CHARTS_TITLE, }: Props) => { // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `${DETECTIONS_ALERTS_CHARTS_ID}-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `${DETECTIONS_ALERTS_CHARTS_ID}-${uuidv4()}`, []); const { toggleStatus, setToggleStatus } = useQueryToggle(DETECTIONS_ALERTS_CHARTS_ID); const [querySkip, setQuerySkip] = useState(!toggleStatus); diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/index.tsx index 64a60af8603c7..55931e74ff9d4 100644 --- a/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/index.tsx +++ b/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/index.tsx @@ -16,6 +16,8 @@ import { EuiSpacer, EuiSuperDatePicker, EuiSuperUpdateButton, + EuiText, + EuiTitle, } from '@elastic/eui'; import moment from 'moment'; import type { List } from '@kbn/securitysolution-io-ts-list-types'; @@ -210,6 +212,13 @@ const RulePreviewComponent: React.FC = ({ return ( <> + +

    {i18n.RULE_PREVIEW_TITLE}

    +
    + + +

    {i18n.RULE_PREVIEW_DESCRIPTION}

    +
    {showInvocationCountWarning && ( <> diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/translations.ts b/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/translations.ts index aff8b7dd37ac7..bd73aa2b3a27d 100644 --- a/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/translations.ts +++ b/x-pack/plugins/security_solution/public/detections/components/rules/rule_preview/translations.ts @@ -163,3 +163,18 @@ export const VIEW_DETAILS_FOR_ROW = ({ defaultMessage: 'View details for the alert or event in row {ariaRowindex}, with columns {columnValues}', }); + +export const RULE_PREVIEW_TITLE = i18n.translate( + 'xpack.securitySolution.detectionEngine.createRule.rulePreviewTitle', + { + defaultMessage: 'Rule preview', + } +); + +export const RULE_PREVIEW_DESCRIPTION = i18n.translate( + 'xpack.securitySolution.detectionEngine.createRule.rulePreviewDescription', + { + defaultMessage: + 'Rule preview reflects the current configuration of your rule settings and exceptions, click refresh icon to see the updated preview.', + } +); diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/index.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/index.tsx deleted file mode 100644 index 405fec71af954..0000000000000 --- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/index.tsx +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { - EuiButton, - EuiSpacer, - EuiFlyout, - EuiFlyoutBody, - EuiFlyoutFooter, - EuiFlyoutHeader, - EuiText, - EuiTitle, -} from '@elastic/eui'; -import React from 'react'; -import styled from 'styled-components'; - -import type { List } from '@kbn/securitysolution-io-ts-list-types'; -import { RulePreview } from '../../../../components/rules/rule_preview'; -import type { AboutStepRule, DefineStepRule, ScheduleStepRule } from '../types'; - -import * as i18n from './translations'; - -const StyledEuiFlyout = styled(EuiFlyout)` - clip-path: none; -`; - -const StyledEuiFlyoutBody = styled(EuiFlyoutBody)` - overflow-y: hidden; - flex: 1; - - .euiFlyoutBody__overflow { - mask-image: none; - } -`; - -interface PreviewFlyoutProps { - isDisabled: boolean; - defineStepData: DefineStepRule; - aboutStepData: AboutStepRule; - scheduleStepData: ScheduleStepRule; - exceptionsList?: List[]; - onClose: () => void; -} - -const PreviewFlyoutComponent: React.FC = ({ - isDisabled, - defineStepData, - aboutStepData, - scheduleStepData, - exceptionsList, - onClose, -}) => { - return ( - - - -

    {i18n.RULE_PREVIEW_TITLE}

    -
    - - -

    {i18n.RULE_PREVIEW_DESCRIPTION}

    -
    -
    - - - - - {i18n.CANCEL_BUTTON_LABEL} - -
    - ); -}; - -export const PreviewFlyout = React.memo(PreviewFlyoutComponent); diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/translations.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/translations.ts deleted file mode 100644 index 9e3e3af9fd6a1..0000000000000 --- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/preview/translations.ts +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { i18n } from '@kbn/i18n'; - -export const RULE_PREVIEW_TITLE = i18n.translate( - 'xpack.securitySolution.detectionEngine.createRule.rulePreviewTitle', - { - defaultMessage: 'Rule preview', - } -); - -export const RULE_PREVIEW_DESCRIPTION = i18n.translate( - 'xpack.securitySolution.detectionEngine.createRule.rulePreviewDescription', - { - defaultMessage: - 'Rule preview reflects the current configuration of your rule settings and exceptions, click refresh icon to see the updated preview.', - } -); - -export const CANCEL_BUTTON_LABEL = i18n.translate( - 'xpack.securitySolution.detectionEngine.createRule.cancelButtonLabel', - { - defaultMessage: 'Cancel', - } -); diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/translations.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/translations.ts index 78d8f9ebee3e6..e734b9b384ff9 100644 --- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/translations.ts +++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/translations.ts @@ -1114,14 +1114,6 @@ export const RULE_PREVIEW_TITLE = i18n.translate( } ); -export const RULE_PREVIEW_DESCRIPTION = i18n.translate( - 'xpack.securitySolution.detectionEngine.createRule.rulePreviewDescription', - { - defaultMessage: - 'Rule preview reflects the current configuration of your rule settings and exceptions, click refresh icon to see the updated preview.', - } -); - export const CANCEL_BUTTON_LABEL = i18n.translate( 'xpack.securitySolution.detectionEngine.createRule.cancelButtonLabel', { diff --git a/x-pack/plugins/security_solution/public/explore/hosts/pages/details/index.tsx b/x-pack/plugins/security_solution/public/explore/hosts/pages/details/index.tsx index 0ef17dab452f8..c8cc59a01f67d 100644 --- a/x-pack/plugins/security_solution/public/explore/hosts/pages/details/index.tsx +++ b/x-pack/plugins/security_solution/public/explore/hosts/pages/details/index.tsx @@ -204,7 +204,7 @@ const HostDetailsComponent: React.FC = ({ detailName, hostDeta endDate={to} skip={isInitializing} > - {({ isLoadingAnomaliesData, anomaliesData }) => ( + {({ isLoadingAnomaliesData, anomaliesData, jobNameById }) => ( = ({ detailName, hostDeta inspect={inspect} hostName={detailName} indexNames={selectedPatterns} + jobNameById={jobNameById} /> )} diff --git a/x-pack/plugins/security_solution/public/explore/network/components/details/__snapshots__/index.test.tsx.snap b/x-pack/plugins/security_solution/public/explore/network/components/details/__snapshots__/index.test.tsx.snap index 191c22f1e7d3a..e8707480b1c66 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/details/__snapshots__/index.test.tsx.snap +++ b/x-pack/plugins/security_solution/public/explore/network/components/details/__snapshots__/index.test.tsx.snap @@ -144,6 +144,7 @@ exports[`IP Overview Component rendering it renders the default IP Overview 1`] ip="10.10.10.10" isInDetailsSidePanel={false} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" @@ -296,6 +297,7 @@ exports[`IP Overview Component rendering it renders the side panel IP overview 1 ip="10.10.10.10" isInDetailsSidePanel={true} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" diff --git a/x-pack/plugins/security_solution/public/explore/network/components/details/index.test.tsx b/x-pack/plugins/security_solution/public/explore/network/components/details/index.test.tsx index 58d2d5b1abc5b..c910a75f42cd3 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/details/index.test.tsx +++ b/x-pack/plugins/security_solution/public/explore/network/components/details/index.test.tsx @@ -55,6 +55,7 @@ describe('IP Overview Component', () => { flowTarget: FlowTargetSourceDest; }>, indexPatterns: [], + jobNameById: {}, }; test('it renders the default IP Overview', () => { diff --git a/x-pack/plugins/security_solution/public/explore/network/components/details/index.tsx b/x-pack/plugins/security_solution/public/explore/network/components/details/index.tsx index 9c67e227ec4db..62c6a6f462d14 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/details/index.tsx +++ b/x-pack/plugins/security_solution/public/explore/network/components/details/index.tsx @@ -56,6 +56,7 @@ export interface IpOverviewProps { startDate: string; type: networkModel.NetworkType; indexPatterns: string[]; + jobNameById: Record; } export const IpOverview = React.memo( @@ -74,6 +75,7 @@ export const IpOverview = React.memo( anomaliesData, narrowDateRange, indexPatterns, + jobNameById, }) => { const capabilities = useMlCapabilities(); const userPermissions = hasMlUserPermissions(capabilities); @@ -109,6 +111,7 @@ export const IpOverview = React.memo( endDate={endDate} isLoading={isLoadingAnomaliesData} narrowDateRange={narrowDateRange} + jobNameById={jobNameById} /> ), }, diff --git a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/__mocks__/mock.ts b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/__mocks__/mock.ts index 1cc0591d29727..af915a63dea31 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/__mocks__/mock.ts +++ b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/__mocks__/mock.ts @@ -19,7 +19,7 @@ export const mockAPMIndexPatternIds: IndexPatternMapping[] = [ ]; export const mockLayerGroup = { - id: 'uuid.v4()', + id: 'uuidv4()', label: 'filebeat-*', sourceDescriptor: null, type: LAYER_TYPE.LAYER_GROUP, @@ -28,7 +28,7 @@ export const mockLayerGroup = { export const mockSourceLayer = { sourceDescriptor: { - id: 'uuid.v4()', + id: 'uuidv4()', type: 'ES_SEARCH', applyGlobalQuery: true, geoField: 'source.geo.location', @@ -71,8 +71,8 @@ export const mockSourceLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `filebeat-* | Source Point`, minZoom: 0, maxZoom: 24, @@ -85,7 +85,7 @@ export const mockSourceLayer = { export const mockDestinationLayer = { sourceDescriptor: { - id: 'uuid.v4()', + id: 'uuidv4()', type: 'ES_SEARCH', applyGlobalQuery: true, geoField: 'destination.geo.location', @@ -129,8 +129,8 @@ export const mockDestinationLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `filebeat-* | Destination Point`, minZoom: 0, maxZoom: 24, @@ -142,7 +142,7 @@ export const mockDestinationLayer = { export const mockClientLayer = { sourceDescriptor: { - id: 'uuid.v4()', + id: 'uuidv4()', type: 'ES_SEARCH', applyGlobalQuery: true, geoField: 'client.geo.location', @@ -185,8 +185,8 @@ export const mockClientLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `apm-* | Client Point`, minZoom: 0, maxZoom: 24, @@ -204,7 +204,7 @@ const mockApmDataStreamClientLayer = { export const mockServerLayer = { sourceDescriptor: { - id: 'uuid.v4()', + id: 'uuidv4()', type: 'ES_SEARCH', applyGlobalQuery: true, geoField: 'server.geo.location', @@ -248,8 +248,8 @@ export const mockServerLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `apm-* | Server Point`, minZoom: 0, maxZoom: 24, @@ -268,7 +268,7 @@ export const mockLineLayer = { sourceDescriptor: { type: 'ES_PEW_PEW', applyGlobalQuery: true, - id: 'uuid.v4()', + id: 'uuidv4()', indexPatternId: '8c7323ac-97ad-4b53-ac0a-40f8f691a918', sourceGeoField: 'source.geo.location', destGeoField: 'destination.geo.location', @@ -318,8 +318,8 @@ export const mockLineLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `filebeat-* | Line`, minZoom: 0, maxZoom: 24, @@ -333,7 +333,7 @@ export const mockClientServerLineLayer = { sourceDescriptor: { type: 'ES_PEW_PEW', applyGlobalQuery: true, - id: 'uuid.v4()', + id: 'uuidv4()', indexPatternId: '8c7323ac-97ad-4b53-ac0a-40f8f691a918', sourceGeoField: 'client.geo.location', destGeoField: 'server.geo.location', @@ -383,8 +383,8 @@ export const mockClientServerLineLayer = { }, }, }, - id: 'uuid.v4()', - parent: 'uuid.v4()', + id: 'uuidv4()', + parent: 'uuidv4()', label: `apm-* | Line`, minZoom: 0, maxZoom: 24, @@ -401,7 +401,7 @@ const mockApmDataStreamClientServerLineLayer = { export const mockLayerList = [ { sourceDescriptor: { type: 'EMS_TMS', isAutoSelect: true }, - id: 'uuid.v4()', + id: 'uuidv4()', label: null, minZoom: 0, maxZoom: 24, @@ -419,7 +419,7 @@ export const mockLayerList = [ export const mockLayerListDouble = [ { sourceDescriptor: { type: 'EMS_TMS', isAutoSelect: true }, - id: 'uuid.v4()', + id: 'uuidv4()', label: null, minZoom: 0, maxZoom: 24, @@ -441,7 +441,7 @@ export const mockLayerListDouble = [ export const mockLayerListMixed = [ { sourceDescriptor: { type: 'EMS_TMS', isAutoSelect: true }, - id: 'uuid.v4()', + id: 'uuidv4()', label: null, minZoom: 0, maxZoom: 24, diff --git a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/create_embeddable.tsx b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/create_embeddable.tsx index 8f4ba98b4ecc5..9b8842650a7e2 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/create_embeddable.tsx +++ b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/create_embeddable.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import React from 'react'; import type { HtmlPortalNode } from 'react-reverse-portal'; import { OutPortal } from 'react-reverse-portal'; @@ -65,7 +65,7 @@ export const createEmbeddable = async ( const input: MapEmbeddableInput = { title: i18n.MAP_TITLE, attributes: { title: '' }, - id: uuid.v4(), + id: uuidv4(), filters, hidePanelTitles: true, query, diff --git a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.test.ts b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.test.ts index d476840e91063..0dc111f44801b 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.test.ts +++ b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.test.ts @@ -23,8 +23,8 @@ import { jest.mock('uuid', () => { return { - v1: jest.fn(() => 'uuid.v1()'), - v4: jest.fn(() => 'uuid.v4()'), + v1: jest.fn(() => 'uuidv1()'), + v4: jest.fn(() => 'uuidv4()'), }; }); diff --git a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.ts b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.ts index 5805cc1aa81db..c56ce2b9d9989 100644 --- a/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.ts +++ b/x-pack/plugins/security_solution/public/explore/network/components/embeddables/map_config.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { euiPaletteColorBlind } from '@elastic/eui'; import { LAYER_TYPE, SCALING_TYPES, SOURCE_TYPES } from '@kbn/maps-plugin/common'; import type { @@ -117,7 +117,7 @@ export const getLayerList = (indexPatternIds: IndexPatternMapping[]) => { return [ { sourceDescriptor: { type: SOURCE_TYPES.EMS_TMS, isAutoSelect: true }, - id: uuid.v4(), + id: uuidv4(), label: null, minZoom: 0, maxZoom: 24, @@ -128,7 +128,7 @@ export const getLayerList = (indexPatternIds: IndexPatternMapping[]) => { }, ...indexPatternIds.reduce((acc: object[], { title, id }) => { const layerGroupDescriptor = { - id: uuid.v4(), + id: uuidv4(), label: title, sourceDescriptor: null, type: LAYER_TYPE.LAYER_GROUP, @@ -171,7 +171,7 @@ export const getSourceLayer = ( layerDetails: LayerMappingDetails ) => ({ sourceDescriptor: { - id: uuid.v4(), + id: uuidv4(), type: 'ES_SEARCH', applyGlobalQuery: true, geoField: layerDetails.geoField, @@ -208,7 +208,7 @@ export const getSourceLayer = ( }, }, }, - id: uuid.v4(), + id: uuidv4(), parent: parentId, label: `${indexPatternTitle} | ${layerDetails.label}`, minZoom: 0, @@ -237,7 +237,7 @@ export const getDestinationLayer = ( layerDetails: LayerMappingDetails ) => ({ sourceDescriptor: { - id: uuid.v4(), + id: uuidv4(), type: 'ES_SEARCH', scalingType: SCALING_TYPES.LIMIT, applyGlobalQuery: true, @@ -275,7 +275,7 @@ export const getDestinationLayer = ( }, }, }, - id: uuid.v4(), + id: uuidv4(), parent: parentId, label: `${indexPatternTitle} | ${layerDetails.label}`, minZoom: 0, @@ -304,7 +304,7 @@ export const getLineLayer = ( sourceDescriptor: { type: SOURCE_TYPES.ES_PEW_PEW, applyGlobalQuery: true, - id: uuid.v4(), + id: uuidv4(), indexPatternId, sourceGeoField: layerDetails.source.geoField, destGeoField: layerDetails.destination.geoField, @@ -362,7 +362,7 @@ export const getLineLayer = ( }, }, }, - id: uuid.v4(), + id: uuidv4(), parent: parentId, label: `${indexPatternTitle} | ${i18n.LINE_LAYER}`, minZoom: 0, diff --git a/x-pack/plugins/security_solution/public/explore/network/pages/details/index.tsx b/x-pack/plugins/security_solution/public/explore/network/pages/details/index.tsx index 21a6db1bf642b..7430a4ece4257 100644 --- a/x-pack/plugins/security_solution/public/explore/network/pages/details/index.tsx +++ b/x-pack/plugins/security_solution/public/explore/network/pages/details/index.tsx @@ -51,7 +51,7 @@ import { useMlCapabilities } from '../../../../common/components/ml/hooks/use_ml import { useAlertsPrivileges } from '../../../../detections/containers/detection_engine/alerts/use_alerts_privileges'; import { navTabsNetworkDetails } from './nav_tabs'; import { NetworkDetailsTabs } from './details_tabs'; -import { useInstalledSecurityJobsIds } from '../../../../common/components/ml/hooks/use_installed_security_jobs'; +import { useInstalledSecurityJobNameById } from '../../../../common/components/ml/hooks/use_installed_security_jobs'; export { getTrailingBreadcrumbs } from './utils'; @@ -137,7 +137,8 @@ const NetworkDetailsComponent: React.FC = () => { ip, }); - const { jobIds } = useInstalledSecurityJobsIds(); + const { jobNameById } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); const [isLoadingAnomaliesData, anomaliesData] = useAnomaliesTableData({ criteriaFields: networkToCriteria(detailName, flowTarget), startDate: from, @@ -202,6 +203,7 @@ const NetworkDetailsComponent: React.FC = () => { endDate={to} narrowDateRange={narrowDateRange} indexPatterns={selectedPatterns} + jobNameById={jobNameById} /> diff --git a/x-pack/plugins/security_solution/public/explore/users/pages/details/index.tsx b/x-pack/plugins/security_solution/public/explore/users/pages/details/index.tsx index 99b20010e80db..725f0edb3ed5a 100644 --- a/x-pack/plugins/security_solution/public/explore/users/pages/details/index.tsx +++ b/x-pack/plugins/security_solution/public/explore/users/pages/details/index.tsx @@ -197,7 +197,7 @@ const UsersDetailsComponent: React.FC = ({ endDate={to} skip={isInitializing} > - {({ isLoadingAnomaliesData, anomaliesData }) => ( + {({ isLoadingAnomaliesData, anomaliesData, jobNameById }) => ( = ({ endDate={to} narrowDateRange={narrowDateRange} indexPatterns={selectedPatterns} + jobNameById={jobNameById} /> )} diff --git a/x-pack/plugins/security_solution/public/management/components/actions_context_menu/actions_context_menu.tsx b/x-pack/plugins/security_solution/public/management/components/actions_context_menu/actions_context_menu.tsx index a21fccea5eade..dc1a8d8790d12 100644 --- a/x-pack/plugins/security_solution/public/management/components/actions_context_menu/actions_context_menu.tsx +++ b/x-pack/plugins/security_solution/public/management/components/actions_context_menu/actions_context_menu.tsx @@ -9,7 +9,7 @@ import React, { memo, useCallback, useMemo, useState } from 'react'; import type { EuiPopoverProps, EuiContextMenuPanelProps, EuiIconProps } from '@elastic/eui'; import { EuiButtonIcon, EuiContextMenuPanel, EuiPopover } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ContextMenuItemNavByRouterProps } from '../context_menu_with_router_support'; import { ContextMenuItemNavByRouter } from '../context_menu_with_router_support'; import { useTestIdGenerator } from '../../hooks/use_test_id_generator'; @@ -41,7 +41,7 @@ export const ActionsContextMenu = memo( return ( { handleCloseMenu(); if (itemProps.onClick) { diff --git a/x-pack/plugins/security_solution/public/management/components/artifact_entry_card/test_utils.ts b/x-pack/plugins/security_solution/public/management/components/artifact_entry_card/test_utils.ts index 24dc06d197274..e42c4e2e66ab1 100644 --- a/x-pack/plugins/security_solution/public/management/components/artifact_entry_card/test_utils.ts +++ b/x-pack/plugins/security_solution/public/management/components/artifact_entry_card/test_utils.ts @@ -6,7 +6,7 @@ */ import { cloneDeep } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ExceptionListItemSchema } from '@kbn/securitysolution-io-ts-list-types'; import { getExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/exception_list_item_schema.mock'; import { TrustedAppGenerator } from '../../../../common/endpoint/data_generators/trusted_app_generator'; @@ -57,7 +57,7 @@ export const getExceptionProviderMock = (): ExceptionListItemSchema => { tags: ['policy:all'], comments: [ { - id: uuid.v4(), + id: uuidv4(), comment: 'test', created_at: new Date().toISOString(), created_by: 'Justa', diff --git a/x-pack/plugins/security_solution/public/management/components/context_menu_with_router_support/context_menu_with_router_support.tsx b/x-pack/plugins/security_solution/public/management/components/context_menu_with_router_support/context_menu_with_router_support.tsx index 6d7549d45605c..26b462b8da570 100644 --- a/x-pack/plugins/security_solution/public/management/components/context_menu_with_router_support/context_menu_with_router_support.tsx +++ b/x-pack/plugins/security_solution/public/management/components/context_menu_with_router_support/context_menu_with_router_support.tsx @@ -9,7 +9,7 @@ import type { CSSProperties, HTMLAttributes } from 'react'; import React, { memo, useCallback, useMemo, useState } from 'react'; import type { CommonProps, EuiContextMenuPanelProps, EuiPopoverProps } from '@elastic/eui'; import { EuiContextMenuPanel, EuiPopover, EuiPopoverTitle, EuiLoadingContent } from '@elastic/eui'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ContextMenuItemNavByRouterProps } from './context_menu_item_nav_by_router'; import { ContextMenuItemNavByRouter } from './context_menu_item_nav_by_router'; import { useTestIdGenerator } from '../../hooks/use_test_id_generator'; @@ -78,7 +78,7 @@ export const ContextMenuWithRouterSupport = memo ); @@ -87,7 +87,7 @@ export const ContextMenuWithRouterSupport = memo => { const endpointActionGenerator = new EndpointActionGenerator('seed'); - const agentIds = _agentIds ?? [uuid.v4()]; + const agentIds = _agentIds ?? [uuidv4()]; const data: ActionListApiResponse['data'] = agentIds.map((id) => { const actionIds = Array(actionCount) .fill(1) - .map(() => uuid.v4()); + .map(() => uuidv4()); const actionDetails: ActionListApiResponse['data'] = actionIds.map((actionId) => { return endpointActionGenerator.generateActionDetails({ diff --git a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.test.tsx b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.test.tsx index 9f54eeadaf804..0327c7c356966 100644 --- a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.test.tsx +++ b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.test.tsx @@ -22,7 +22,7 @@ import type { import { MANAGEMENT_PATH } from '../../../../common/constants'; import { getActionListMock } from './mocks'; import { useGetEndpointsList } from '../../hooks/endpoint/use_get_endpoints_list'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { RESPONSE_ACTION_API_COMMANDS_NAMES } from '../../../../common/endpoint/service/response_actions/constants'; import { useUserPrivileges as _useUserPrivileges } from '../../../common/components/user_privileges'; import { responseActionsHttpMocks } from '../../mocks/response_actions_http_mocks'; @@ -179,7 +179,7 @@ describe.skip('Response actions history', () => { mockUseGetEndpointsList.mockReturnValue({ data: Array.from({ length: 50 }).map(() => { - const id = uuid.v4(); + const id = uuidv4(); return { id, name: `Host-${id.slice(0, 8)}`, diff --git a/x-pack/plugins/security_solution/public/management/pages/event_filters/view/utils.ts b/x-pack/plugins/security_solution/public/management/pages/event_filters/view/utils.ts index 23eb18768390c..7c423b9e5abfe 100644 --- a/x-pack/plugins/security_solution/public/management/pages/event_filters/view/utils.ts +++ b/x-pack/plugins/security_solution/public/management/pages/event_filters/view/utils.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { CreateExceptionListItemSchema } from '@kbn/securitysolution-io-ts-list-types'; import type { Ecs } from '../../../../../common/ecs'; import { ENDPOINT_EVENT_FILTERS_LIST_ID } from '../constants'; @@ -48,7 +48,7 @@ export const getInitialExceptionFromEvent = (data?: Ecs): CreateExceptionListIte item_id: undefined, list_id: ENDPOINT_EVENT_FILTERS_LIST_ID, meta: { - temporaryUuid: uuid.v4(), + temporaryUuid: uuidv4(), }, name: '', namespace_type: 'agnostic', diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/models/advanced_policy_schema.ts b/x-pack/plugins/security_solution/public/management/pages/policy/models/advanced_policy_schema.ts index 979bd12b78c20..21239f4db4ca2 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/models/advanced_policy_schema.ts +++ b/x-pack/plugins/security_solution/public/management/pages/policy/models/advanced_policy_schema.ts @@ -1048,4 +1048,15 @@ export const AdvancedPolicySchema: AdvancedPolicySchemaType[] = [ } ), }, + { + key: 'linux.advanced.host_isolation.allowed', + first_supported_version: '8.6.1', + documentation: i18n.translate( + 'xpack.securitySolution.endpoint.policy.advanced.linux.advanced.host_isolation.allowed', + { + defaultMessage: + 'A value of false disallows host isolation activity on Linux endpoints, regardless of whether host isolation is supported. Note that if a host is currently not isolated, it will refuse to isolate, and likewise, a host will refuse to release if it is currently isolated. A value of true will allow Linux endpoints to isolate if supported. Default: true', + } + ), + }, ]; diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/delete_modal/policy_artifacts_delete_modal.test.tsx b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/delete_modal/policy_artifacts_delete_modal.test.tsx index b8f7a8c19fbcd..034c723c1111f 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/delete_modal/policy_artifacts_delete_modal.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/delete_modal/policy_artifacts_delete_modal.test.tsx @@ -12,7 +12,7 @@ import type { import { act, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/exception_list_item_schema.mock'; import type { AppContextTestRender } from '../../../../../../common/mock/endpoint'; import { createAppRootMockRenderer } from '../../../../../../common/mock/endpoint'; @@ -41,7 +41,7 @@ describe.each(listType)('Policy details %s artifact delete modal', (type) => { let onCloseMock: () => jest.Mock; beforeEach(() => { - policyId = uuid.v4(); + policyId = uuidv4(); mockedContext = createAppRootMockRenderer(); exception = getExceptionListItemSchemaMock(); onCloseMock = jest.fn(); diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/flyout/policy_artifacts_flyout.test.tsx b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/flyout/policy_artifacts_flyout.test.tsx index 11cfd4b6aa792..c93776ef0abac 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/flyout/policy_artifacts_flyout.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/flyout/policy_artifacts_flyout.test.tsx @@ -8,7 +8,7 @@ import { act, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getFoundExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/found_exception_list_item_schema.mock'; import { getExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/exception_list_item_schema.mock'; import type { AppContextTestRender } from '../../../../../../common/mock/endpoint'; @@ -178,8 +178,8 @@ describe('Policy details artifacts flyout', () => { }); describe('when submitting the form', () => { - const FIRST_ONE_NAME = uuid.v4(); - const SECOND_ONE_NAME = uuid.v4(); + const FIRST_ONE_NAME = uuidv4(); + const SECOND_ONE_NAME = uuidv4(); const testTags = ['policy:1234', 'non-policy-tag', 'policy:4321']; let exceptions: FoundExceptionListItemSchema; @@ -190,12 +190,12 @@ describe('Policy details artifacts flyout', () => { data: [ getExceptionListItemSchemaMock({ name: FIRST_ONE_NAME, - id: uuid.v4(), + id: uuidv4(), tags: testTags, }), getExceptionListItemSchemaMock({ name: SECOND_ONE_NAME, - id: uuid.v4(), + id: uuidv4(), tags: testTags, }), ], diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alert_donut_embeddable.tsx b/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alert_donut_embeddable.tsx deleted file mode 100644 index 029bffdd8bc2b..0000000000000 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alert_donut_embeddable.tsx +++ /dev/null @@ -1,108 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ -import React, { useCallback, useEffect, useMemo } from 'react'; -import { useDispatch } from 'react-redux'; -import { DonutChartWrapper } from '../../../../common/components/charts/donutchart'; -import { useRefetchByRestartingSession } from '../../../../common/components/page/use_refetch_by_session'; -import { getAlertsByStatusAttributes } from '../../../../common/components/visualization_actions/lens_attributes/common/alerts/alerts_by_status_donut'; -import { LensEmbeddable } from '../../../../common/components/visualization_actions/lens_embeddable'; -import type { EmbeddableData } from '../../../../common/components/visualization_actions/types'; -import { parseVisualizationData } from '../../../../common/components/visualization_actions/utils'; -import { useDeepEqualSelector } from '../../../../common/hooks/use_selector'; -import { inputsActions, inputsSelectors } from '../../../../common/store/inputs'; -import { InputsModelId } from '../../../../common/store/inputs/constants'; -import { SourcererScopeName } from '../../../../common/store/sourcerer/model'; -import { ChartLabel } from './chart_label'; -import type { AlertDonutEmbeddableProps, VisualizationAlertsByStatusResponse } from './types'; -import { DETECTION_RESPONSE_ALERTS_BY_STATUS_ID } from './types'; - -const ChartSize = '135px'; - -const AlertDonutEmbeddableComponent: React.FC = ({ - status, - timerange, - label, -}) => { - const dispatch = useDispatch(); - const queryId = `${DETECTION_RESPONSE_ALERTS_BY_STATUS_ID}-${status}`; - const { session, refetchByRestartingSession } = useRefetchByRestartingSession({ - inputId: InputsModelId.global, - queryId, - }); - const getGlobalQuery = inputsSelectors.globalQueryByIdSelector(); - const { inspect } = useDeepEqualSelector((state) => getGlobalQuery(state, queryId)); - const visualizationData = inspect?.response - ? parseVisualizationData(inspect?.response) - : null; - - const onEmbeddableLoad = useCallback( - ({ requests, responses, isLoading }: EmbeddableData) => { - dispatch( - inputsActions.setQuery({ - inputId: InputsModelId.global, - id: queryId, - searchSessionId: session.current.start(), - refetch: refetchByRestartingSession, - loading: isLoading, - inspect: { dsl: requests, response: responses }, - }) - ); - }, - [dispatch, queryId, refetchByRestartingSession, session] - ); - - const extraOptions = useMemo(() => ({ status }), [status]); - - useEffect(() => { - dispatch( - inputsActions.setQuery({ - inputId: InputsModelId.global, - id: queryId, - searchSessionId: session.current.start(), - refetch: refetchByRestartingSession, - loading: false, - inspect: null, - }) - ); - }, [dispatch, queryId, refetchByRestartingSession, session, status]); - - useEffect(() => { - return () => { - dispatch( - inputsActions.deleteOneQuery({ - inputId: InputsModelId.global, - id: queryId, - }) - ); - }; - }, [dispatch, queryId]); - - const dataExists = visualizationData != null && visualizationData[0].hits.total !== 0; - - return ( - : null} - > - - - ); -}; - -export const AlertDonutEmbeddable = React.memo(AlertDonutEmbeddableComponent); diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.test.tsx b/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.test.tsx index b955e096cc295..40a9fab612ad6 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.test.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.test.tsx @@ -20,8 +20,7 @@ jest.mock('../../../../common/hooks/use_experimental_features', () => { return { useIsExperimentalFeatureEnabled: jest.fn() }; }); -jest.mock('./alert_donut_embeddable'); - +jest.mock('../../../../common/components/visualization_actions/visualization_embeddable'); jest.mock('./chart_label', () => { return { ChartLabel: jest.fn((props) => ), @@ -173,7 +172,7 @@ describe('AlertsByStatus', () => { ); expect( - container.querySelector(`[data-test-subj="alert-donut-embeddable"]`) + container.querySelector(`[data-test-subj="visualization-embeddable"]`) ).toBeInTheDocument(); expect((useAlertsByStatus as jest.Mock).mock.calls[0][0].skip).toBeTruthy(); }); diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.tsx b/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.tsx index 1032dd2d4e95c..a23bfa31c9d10 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/detection_response/alerts_by_status/alerts_by_status.tsx @@ -55,9 +55,12 @@ import { LinkButton, useGetSecuritySolutionLinkProps } from '../../../../common/ import { useNavigateToTimeline } from '../hooks/use_navigate_to_timeline'; import { useIsExperimentalFeatureEnabled } from '../../../../common/hooks/use_experimental_features'; import { useGlobalTime } from '../../../../common/containers/use_global_time'; -import { AlertDonutEmbeddable } from './alert_donut_embeddable'; import { useAlertsByStatusVisualizationData } from './use_alerts_by_status_visualization_data'; import { DETECTION_RESPONSE_ALERTS_BY_STATUS_ID } from './types'; +import { SourcererScopeName } from '../../../../common/store/sourcerer/model'; +import { VisualizationEmbeddable } from '../../../../common/components/visualization_actions/visualization_embeddable'; +import type { Status } from '../../../../../common/detection_engine/schemas/common'; +import { getAlertsByStatusAttributes } from '../../../../common/components/visualization_actions/lens_attributes/common/alerts/alerts_by_status_donut'; const StyledFlexItem = styled(EuiFlexItem)` padding: 0 4px; @@ -68,6 +71,8 @@ const StyledLegendFlexItem = styled(EuiFlexItem)` padding-top: 45px; `; +const ChartSize = '135px'; + interface AlertsByStatusProps { additionalFilters?: ESBoolQuery[]; entityFilter?: EntityFilter; @@ -87,6 +92,10 @@ const eventKindSignalFilter: EntityFilter = { value: 'signal', }; +const openDonutOptions = { status: 'open' as Status }; +const acknowledgedDonutOptions = { status: 'acknowledged' as Status }; +const closedDonutOptions = { status: 'closed' as Status }; + export const AlertsByStatus = ({ additionalFilters, signalIndexName, @@ -193,9 +202,9 @@ export const AlertsByStatus = ({ <> - {totalAlerts !== 0 || - (visualizationTotalAlerts !== 0 && ( - + + {totalAlerts !== 0 || + (visualizationTotalAlerts !== 0 && ( <> @@ -203,16 +212,25 @@ export const AlertsByStatus = ({ <> {ALERTS(totalAlertsCount)} - - ))} + ))} + + {isChartEmbeddablesEnabled ? ( - ) : ( {isChartEmbeddablesEnabled ? ( - ) : ( {isChartEmbeddablesEnabled ? ( - ) : ( { } = useKibana(); const { to, from, setQuery, deleteQuery } = useGlobalTime(); // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `useCaseItems-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `useCaseItems-${uuidv4()}`, []); const [updatedAt, setUpdatedAt] = useState(Date.now()); const [isLoading, setIsLoading] = useState(true); const [casesCounts, setCasesCounts] = useState(null); diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/cases_table/use_case_items.ts b/x-pack/plugins/security_solution/public/overview/components/detection_response/cases_table/use_case_items.ts index c0e7a2a96d3f2..5bb453e566ae9 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/cases_table/use_case_items.ts +++ b/x-pack/plugins/security_solution/public/overview/components/detection_response/cases_table/use_case_items.ts @@ -10,7 +10,7 @@ import { useState, useEffect, useMemo } from 'react'; import type { CaseStatuses } from '@kbn/cases-plugin/common'; import type { Cases } from '@kbn/cases-plugin/common/ui'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { APP_ID } from '../../../../../common/constants'; import { useGlobalTime } from '../../../../common/containers/use_global_time'; import { useKibana } from '../../../../common/lib/kibana'; @@ -46,7 +46,7 @@ export const useCaseItems: UseCaseItems = ({ skip }) => { const [updatedAt, setUpdatedAt] = useState(Date.now()); const [items, setItems] = useState([]); // create a unique, but stable (across re-renders) query id - const uniqueQueryId = useMemo(() => `useCaseItems-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `useCaseItems-${uuidv4()}`, []); useEffect(() => { let isSubscribed = true; diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/hooks/use_navigate_to_timeline.tsx b/x-pack/plugins/security_solution/public/overview/components/detection_response/hooks/use_navigate_to_timeline.tsx index 24c9968c7cffa..d40ccada2a398 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/hooks/use_navigate_to_timeline.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/detection_response/hooks/use_navigate_to_timeline.tsx @@ -7,7 +7,7 @@ import { useCallback, useMemo } from 'react'; import { useDispatch } from 'react-redux'; -import { v4 as uuid } from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { useDeepEqualSelector } from '../../../../common/hooks/use_selector'; import { SourcererScopeName } from '../../../../common/store/sourcerer/model'; @@ -83,14 +83,14 @@ export const useNavigateToTimeline = () => { if (mainFilter) { const dataProvider = getDataProvider( mainFilter.field, - uuid(), + uuidv4(), mainFilter.value, mainFilter.operator ); for (const filter of orFilterGroup.slice(1)) { dataProvider.and.push( - getDataProvider(filter.field, uuid(), filter.value, filter.operator) + getDataProvider(filter.field, uuidv4(), filter.value, filter.operator) ); } dataProviders.push(dataProvider); diff --git a/x-pack/plugins/security_solution/public/overview/components/detection_response/soc_trends/hooks/use_cases_mttr.tsx b/x-pack/plugins/security_solution/public/overview/components/detection_response/soc_trends/hooks/use_cases_mttr.tsx index bd2d5a8de5f79..7b52bc11e58c4 100644 --- a/x-pack/plugins/security_solution/public/overview/components/detection_response/soc_trends/hooks/use_cases_mttr.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/detection_response/soc_trends/hooks/use_cases_mttr.tsx @@ -6,7 +6,7 @@ */ import { useEffect, useMemo, useReducer } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { statReducer } from './stat_reducer'; import type { GlobalTimeArgs } from '../../../../../common/containers/use_global_time'; import { useKibana } from '../../../../../common/lib/kibana'; @@ -37,7 +37,7 @@ export const useCasesMttr = ({ const { services: { cases }, } = useKibana(); - const uniqueQueryId = useMemo(() => `useCasesMttr-${uuid.v4()}`, []); + const uniqueQueryId = useMemo(() => `useCasesMttr-${uuidv4()}`, []); const [state, dispatch] = useReducer(statReducer, { description: i18n.CASES_MTTR_DESCRIPTION, isLoading: true, diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/anomalies/columns.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/anomalies/columns.tsx index dca980b04f2b8..7aacb20909b25 100644 --- a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/anomalies/columns.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/anomalies/columns.tsx @@ -45,11 +45,11 @@ export const useAnomaliesColumns = ( truncateText: true, mobileOptions: { show: true }, 'data-test-subj': 'anomalies-table-column-name', - render: (name, { count, job }) => { + render: (jobName, { count, job }) => { if (count > 0 || (job && isJobStarted(job.jobState, job.datafeedState))) { - return name; + return jobName; } else { - return {name}; + return {jobName}; } }, }, diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/common/risk_score_donut_chart.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/common/risk_score_donut_chart.tsx index 8ba0cbd1a9745..ee92ff1dde3ff 100644 --- a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/common/risk_score_donut_chart.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/common/risk_score_donut_chart.tsx @@ -43,7 +43,7 @@ export const RiskScoreDonutChart = ({ severityCount }: RiskScoreDonutChartProps) const [donutChartData, legendItems, total] = useRiskDonutChartData(severityCount); return ( - + {legendItems.length > 0 && } diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/__mocks__/index.ts b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/__mocks__/index.ts new file mode 100644 index 0000000000000..bf863d0011ad3 --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/__mocks__/index.ts @@ -0,0 +1,16 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { RiskSeverity } from '../../../../../../common/search_strategy/security_solution'; + +export const mockSeverityCount = { + [RiskSeverity.unknown]: 1, + [RiskSeverity.low]: 2, + [RiskSeverity.moderate]: 3, + [RiskSeverity.high]: 4, + [RiskSeverity.critical]: 5, +}; diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.test.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.test.tsx new file mode 100644 index 0000000000000..cd2183cc9611f --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.test.tsx @@ -0,0 +1,97 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { render } from '@testing-library/react'; +import React from 'react'; +import { RiskScoreEntity } from '../../../../../common/search_strategy'; +import { useIsExperimentalFeatureEnabled } from '../../../../common/hooks/use_experimental_features'; +import { useSpaceId } from '../../../../common/hooks/use_space_id'; +import { TestProviders } from '../../../../common/mock'; +import { ChartContent } from './chart_content'; +import { mockSeverityCount } from './__mocks__'; + +jest.mock('../../../../common/components/visualization_actions/visualization_embeddable'); +jest.mock('../../../../common/hooks/use_experimental_features', () => ({ + useIsExperimentalFeatureEnabled: jest.fn(), +})); +jest.mock('../../../../common/hooks/use_space_id', () => ({ + useSpaceId: jest.fn(), +})); +describe('ChartContent', () => { + beforeEach(() => { + jest.clearAllMocks(); + (useIsExperimentalFeatureEnabled as jest.Mock).mockReturnValue(false); + (useSpaceId as jest.Mock).mockReturnValue('default'); + }); + it('renders VisualizationEmbeddable when isChartEmbeddablesEnabled = true and dataExists = true', () => { + (useIsExperimentalFeatureEnabled as jest.Mock).mockReturnValue(true); + + const { getByTestId } = render( + + ); + + expect(getByTestId('visualization-embeddable')).toBeInTheDocument(); + }); + + it('should not render VisualizationEmbeddable when dataExists = false', () => { + (useIsExperimentalFeatureEnabled as jest.Mock).mockReturnValue(true); + + const { queryByTestId } = render( + + + + ); + + expect(queryByTestId('visualization-embeddable')).not.toBeInTheDocument(); + }); + + it('should not render VisualizationEmbeddable when spaceId = undefined', () => { + (useIsExperimentalFeatureEnabled as jest.Mock).mockReturnValue(true); + (useSpaceId as jest.Mock).mockReturnValue(undefined); + const { queryByTestId } = render( + + + + ); + + expect(queryByTestId('visualization-embeddable')).not.toBeInTheDocument(); + }); + + it('renders RiskScoreDonutChart when isChartEmbeddablesEnabled = false', () => { + const { getByTestId } = render( + + + + ); + + expect(getByTestId('risk-score-donut-chart')).toBeInTheDocument(); + }); +}); diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.tsx new file mode 100644 index 0000000000000..40acfe37f59a7 --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/chart_content.tsx @@ -0,0 +1,61 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useMemo } from 'react'; +import type { RiskScoreEntity } from '../../../../../common/search_strategy'; +import { EMPTY_SEVERITY_COUNT } from '../../../../../common/search_strategy'; +import { getRiskScoreDonutAttributes } from '../../../../common/components/visualization_actions/lens_attributes/common/risk_scores/risk_score_donut'; +import { VisualizationEmbeddable } from '../../../../common/components/visualization_actions/visualization_embeddable'; +import { useIsExperimentalFeatureEnabled } from '../../../../common/hooks/use_experimental_features'; +import { useSpaceId } from '../../../../common/hooks/use_space_id'; +import type { SeverityCount } from '../../../../explore/components/risk_score/severity/types'; +import { RiskScoreDonutChart } from '../common/risk_score_donut_chart'; +import { TOTAL_LABEL } from '../common/translations'; + +const ChartContentComponent = ({ + dataExists, + kpiQueryId, + riskEntity, + severityCount, + timerange, +}: { + dataExists?: boolean; + kpiQueryId: string; + riskEntity: RiskScoreEntity; + severityCount: SeverityCount | undefined; + timerange: { + from: string; + to: string; + }; +}) => { + const isChartEmbeddablesEnabled = useIsExperimentalFeatureEnabled('chartEmbeddablesEnabled'); + const spaceId = useSpaceId(); + const extraOptions = useMemo(() => ({ spaceId }), [spaceId]); + + return ( + <> + {isChartEmbeddablesEnabled && spaceId && dataExists && ( + + )} + {!isChartEmbeddablesEnabled && ( + + )} + + ); +}; + +export const ChartContent = React.memo(ChartContentComponent); diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.test.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.test.tsx new file mode 100644 index 0000000000000..262bf4792288f --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.test.tsx @@ -0,0 +1,83 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import type { RenderResult } from '@testing-library/react'; +import { render } from '@testing-library/react'; +import React from 'react'; +import { SecurityPageName } from '../../../../../common/constants'; +import { RiskScoreEntity } from '../../../../../common/search_strategy'; +import { useGetSecuritySolutionLinkProps } from '../../../../common/components/links'; +import { RiskScoreHeaderContent } from './header_content'; +import { mockSeverityCount } from './__mocks__'; + +jest.mock('../../../../common/components/links', () => { + const actual = jest.requireActual('../../../../common/components/links'); + return { + ...actual, + useGetSecuritySolutionLinkProps: jest.fn(), + }; +}); +const mockGetSecuritySolutionLinkProps = jest + .fn() + .mockReturnValue({ onClick: jest.fn(), href: '' }); + +describe('RiskScoreHeaderContent', () => { + let res: RenderResult; + jest.clearAllMocks(); + + (useGetSecuritySolutionLinkProps as jest.Mock).mockReturnValue(mockGetSecuritySolutionLinkProps); + beforeEach(() => { + res = render( + + ); + }); + it('should render when toggleStatus = true', () => { + expect(res.getByTestId(`user-risk-score-header-content`)).toBeInTheDocument(); + }); + + it('should render learn more button', () => { + expect(res.getByText(`Learn more`)).toBeInTheDocument(); + }); + + it('should render severity filter group', () => { + expect(res.getByTestId(`risk-filter-button`)).toBeInTheDocument(); + }); + + it('should render view all button', () => { + expect(res.getByTestId(`view-all-button`)).toBeInTheDocument(); + }); + + it('should not render if toggleStatus = false', () => { + res = render( + + ); + expect(res.getByTestId(`view-all-button`)).toBeInTheDocument(); + }); +}); diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.tsx new file mode 100644 index 0000000000000..3ddd737486a2f --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/header_content.tsx @@ -0,0 +1,76 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import React, { useMemo } from 'react'; +import { EuiFlexGroup, EuiFlexItem, EuiButtonEmpty } from '@elastic/eui'; +import type { RiskSeverity, RiskScoreEntity } from '../../../../../common/search_strategy'; +import { SeverityFilterGroup } from '../../../../explore/components/risk_score/severity/severity_filter_group'; +import type { SeverityCount } from '../../../../explore/components/risk_score/severity/types'; +import { EMPTY_SEVERITY_COUNT } from '../../../../../common/search_strategy'; +import { LinkButton, useGetSecuritySolutionLinkProps } from '../../../../common/components/links'; +import type { SecurityPageName } from '../../../../../common/constants'; +import * as i18n from './translations'; + +const RiskScoreHeaderContentComponent = ({ + entityDocLink, + entityLinkProps, + onSelectSeverityFilterGroup, + riskEntity, + selectedSeverity, + severityCount, + toggleStatus, +}: { + entityDocLink: string; + entityLinkProps: { + deepLinkId: SecurityPageName; + path: string; + onClick: () => void; + }; + onSelectSeverityFilterGroup: (newSelection: RiskSeverity[]) => void; + riskEntity: RiskScoreEntity; + selectedSeverity: RiskSeverity[]; + severityCount: SeverityCount | undefined; + toggleStatus: boolean; +}) => { + const getSecuritySolutionLinkProps = useGetSecuritySolutionLinkProps(); + + const [goToEntityRiskTab, entityRiskTabUrl] = useMemo(() => { + const { onClick, href } = getSecuritySolutionLinkProps(entityLinkProps); + return [onClick, href]; + }, [entityLinkProps, getSecuritySolutionLinkProps]); + return toggleStatus ? ( + + + + {i18n.LEARN_MORE} + + + + + + + + {i18n.VIEW_ALL} + + + + ) : null; +}; + +export const RiskScoreHeaderContent = React.memo(RiskScoreHeaderContentComponent); diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/index.tsx b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/index.tsx index a8bf0cd70be8e..9f6e018083459 100644 --- a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/index.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/index.tsx @@ -5,93 +5,40 @@ * 2.0. */ import React, { useCallback, useEffect, useMemo, useState } from 'react'; -import { EuiButtonEmpty, EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; +import { EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; -import { useDispatch } from 'react-redux'; import { EnableRiskScore } from '../../../../explore/components/risk_score/enable_risk_score'; -import { getTabsOnUsersUrl } from '../../../../common/components/link_to/redirect_to_users'; -import { UsersTableType } from '../../../../explore/users/store/model'; -import { SeverityFilterGroup } from '../../../../explore/components/risk_score/severity/severity_filter_group'; -import { LinkButton, useGetSecuritySolutionLinkProps } from '../../../../common/components/links'; -import { getTabsOnHostsUrl } from '../../../../common/components/link_to/redirect_to_hosts'; -import { HostsTableType, HostsType } from '../../../../explore/hosts/store/model'; import { getRiskScoreColumns } from './columns'; import { LastUpdatedAt } from '../../../../common/components/last_updated_at'; import { HeaderSection } from '../../../../common/components/header_section'; import { useRiskScore, useRiskScoreKpi } from '../../../../explore/containers/risk_score'; import type { RiskSeverity } from '../../../../../common/search_strategy'; -import { EMPTY_SEVERITY_COUNT, RiskScoreEntity } from '../../../../../common/search_strategy'; -import { SecurityPageName } from '../../../../app/types'; -import * as i18n from './translations'; +import { RiskScoreEntity } from '../../../../../common/search_strategy'; import { generateSeverityFilter } from '../../../../explore/hosts/store/helpers'; import { useQueryInspector } from '../../../../common/components/page/manage_query'; import { useGlobalTime } from '../../../../common/containers/use_global_time'; import { InspectButtonContainer } from '../../../../common/components/inspect'; import { useQueryToggle } from '../../../../common/containers/query_toggle'; -import { hostsActions } from '../../../../explore/hosts/store'; -import { RiskScoreDonutChart } from '../common/risk_score_donut_chart'; import { StyledBasicTable } from '../common/styled_basic_table'; -import { RISKY_HOSTS_DOC_LINK, RISKY_USERS_DOC_LINK } from '../../../../../common/constants'; import { RiskScoreHeaderTitle } from '../../../../explore/components/risk_score/risk_score_onboarding/risk_score_header_title'; import { RiskScoresNoDataDetected } from '../../../../explore/components/risk_score/risk_score_onboarding/risk_score_no_data_detected'; import { useRefetchQueries } from '../../../../common/hooks/use_refetch_queries'; import { Loader } from '../../../../common/components/loader'; import { Panel } from '../../../../common/components/panel'; import * as commonI18n from '../common/translations'; -import { usersActions } from '../../../../explore/users/store'; import { useNavigateToTimeline } from '../../detection_response/hooks/use_navigate_to_timeline'; import type { TimeRange } from '../../../../common/store/inputs/model'; import { openAlertsFilter } from '../../detection_response/utils'; -const HOST_RISK_TABLE_QUERY_ID = 'hostRiskDashboardTable'; -const HOST_RISK_KPI_QUERY_ID = 'headerHostRiskScoreKpiQuery'; -const USER_RISK_TABLE_QUERY_ID = 'userRiskDashboardTable'; -const USER_RISK_KPI_QUERY_ID = 'headerUserRiskScoreKpiQuery'; +import { useEntityInfo } from './use_entity'; +import { RiskScoreHeaderContent } from './header_content'; +import { ChartContent } from './chart_content'; const EntityAnalyticsRiskScoresComponent = ({ riskEntity }: { riskEntity: RiskScoreEntity }) => { const { deleteQuery, setQuery, from, to } = useGlobalTime(); const [updatedAt, setUpdatedAt] = useState(Date.now()); - const dispatch = useDispatch(); - - const entity = useMemo( - () => - riskEntity === RiskScoreEntity.host - ? { - docLink: RISKY_HOSTS_DOC_LINK, - linkProps: { - deepLinkId: SecurityPageName.hosts, - path: getTabsOnHostsUrl(HostsTableType.risk), - onClick: () => { - dispatch( - hostsActions.updateHostRiskScoreSeverityFilter({ - severitySelection: [], - hostsType: HostsType.page, - }) - ); - }, - }, - tableQueryId: HOST_RISK_TABLE_QUERY_ID, - kpiQueryId: HOST_RISK_KPI_QUERY_ID, - } - : { - docLink: RISKY_USERS_DOC_LINK, - linkProps: { - deepLinkId: SecurityPageName.users, - path: getTabsOnUsersUrl(UsersTableType.risk), - onClick: () => { - dispatch( - usersActions.updateUserRiskScoreSeverityFilter({ - severitySelection: [], - }) - ); - }, - }, - tableQueryId: USER_RISK_TABLE_QUERY_ID, - kpiQueryId: USER_RISK_KPI_QUERY_ID, - }, - [dispatch, riskEntity] - ); + const entity = useEntityInfo(riskEntity); const { openTimelineWithFilters } = useNavigateToTimeline(); @@ -122,7 +69,10 @@ const EntityAnalyticsRiskScoresComponent = ({ riskEntity }: { riskEntity: RiskSc [riskEntity, openEntityInTimeline] ); const [selectedSeverity, setSelectedSeverity] = useState([]); - const getSecuritySolutionLinkProps = useGetSecuritySolutionLinkProps(); + + const onSelectSeverityFilterGroup = useCallback((newSelection: RiskSeverity[]) => { + setSelectedSeverity(newSelection); + }, []); const severityFilter = useMemo(() => { const [filter] = generateSeverityFilter(selectedSeverity, riskEntity); @@ -191,11 +141,6 @@ const EntityAnalyticsRiskScoresComponent = ({ riskEntity }: { riskEntity: RiskSc setUpdatedAt(Date.now()); }, [isTableLoading, isKpiLoading]); // Update the time when data loads - const [goToEntityRiskTab, entityRiskTabUrl] = useMemo(() => { - const { onClick, href } = getSecuritySolutionLinkProps(entity.linkProps); - return [onClick, href]; - }, [entity.linkProps, getSecuritySolutionLinkProps]); - const refreshPage = useRefetchQueries(); if (!isLicenseValid) { @@ -236,41 +181,26 @@ const EntityAnalyticsRiskScoresComponent = ({ riskEntity }: { riskEntity: RiskSc toggleQuery={setToggleStatus} tooltip={commonI18n.HOST_RISK_TABLE_TOOLTIP} > - {toggleStatus && ( - - - - {i18n.LEARN_MORE} - - - - - - - - {i18n.VIEW_ALL} - - - - )} + {toggleStatus && ( - + 0} + kpiQueryId={entity.kpiQueryId} + riskEntity={riskEntity} + severityCount={severityCount} + timerange={timerange} + /> { + const actual = jest.requireActual('react-redux'); + return { + ...actual, + useDispatch: jest.fn(), + }; +}); + +describe('useEntityInfo', () => { + it('should return host entity info', () => { + const { result } = renderHook(() => useEntityInfo(RiskScoreEntity.host)); + expect(result?.current).toMatchInlineSnapshot(` + Object { + "docLink": "https://www.elastic.co/guide/en/security/current/host-risk-score.html", + "kpiQueryId": "headerHostRiskScoreKpiQuery", + "linkProps": Object { + "deepLinkId": "hosts", + "onClick": [Function], + "path": "/hostRisk", + }, + "tableQueryId": "hostRiskDashboardTable", + } + `); + }); + it('should return user entity info', () => { + const { result } = renderHook(() => useEntityInfo(RiskScoreEntity.user)); + expect(result?.current).toMatchInlineSnapshot(` + Object { + "docLink": "https://www.elastic.co/guide/en/security/current/user-risk-score.html", + "kpiQueryId": "headerUserRiskScoreKpiQuery", + "linkProps": Object { + "deepLinkId": "users", + "onClick": [Function], + "path": "/userRisk", + }, + "tableQueryId": "userRiskDashboardTable", + } + `); + }); +}); diff --git a/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/use_entity.ts b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/use_entity.ts new file mode 100644 index 0000000000000..10494a1d679f1 --- /dev/null +++ b/x-pack/plugins/security_solution/public/overview/components/entity_analytics/risk_score/use_entity.ts @@ -0,0 +1,62 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { useDispatch } from 'react-redux'; +import { getTabsOnUsersUrl } from '../../../../common/components/link_to/redirect_to_users'; +import { UsersTableType } from '../../../../explore/users/store/model'; + +import { getTabsOnHostsUrl } from '../../../../common/components/link_to/redirect_to_hosts'; +import { HostsTableType, HostsType } from '../../../../explore/hosts/store/model'; + +import { RiskScoreEntity } from '../../../../../common/search_strategy/security_solution/risk_score'; +import { usersActions } from '../../../../explore/users/store'; +import { RISKY_HOSTS_DOC_LINK, RISKY_USERS_DOC_LINK } from '../../../../../common/constants'; +import { hostsActions } from '../../../../explore/hosts/store'; +import { SecurityPageName } from '../../../../app/types'; + +const HOST_RISK_TABLE_QUERY_ID = 'hostRiskDashboardTable'; +const HOST_RISK_KPI_QUERY_ID = 'headerHostRiskScoreKpiQuery'; +const USER_RISK_TABLE_QUERY_ID = 'userRiskDashboardTable'; +const USER_RISK_KPI_QUERY_ID = 'headerUserRiskScoreKpiQuery'; + +export const useEntityInfo = (riskEntity: RiskScoreEntity) => { + const dispatch = useDispatch(); + + return riskEntity === RiskScoreEntity.host + ? { + docLink: RISKY_HOSTS_DOC_LINK, + linkProps: { + deepLinkId: SecurityPageName.hosts, + path: getTabsOnHostsUrl(HostsTableType.risk), + onClick: () => { + dispatch( + hostsActions.updateHostRiskScoreSeverityFilter({ + severitySelection: [], + hostsType: HostsType.page, + }) + ); + }, + }, + tableQueryId: HOST_RISK_TABLE_QUERY_ID, + kpiQueryId: HOST_RISK_KPI_QUERY_ID, + } + : { + docLink: RISKY_USERS_DOC_LINK, + linkProps: { + deepLinkId: SecurityPageName.users, + path: getTabsOnUsersUrl(UsersTableType.risk), + onClick: () => { + dispatch( + usersActions.updateUserRiskScoreSeverityFilter({ + severitySelection: [], + }) + ); + }, + }, + tableQueryId: USER_RISK_TABLE_QUERY_ID, + kpiQueryId: USER_RISK_KPI_QUERY_ID, + }; +}; diff --git a/x-pack/plugins/security_solution/public/overview/components/host_overview/__snapshots__/index.test.tsx.snap b/x-pack/plugins/security_solution/public/overview/components/host_overview/__snapshots__/index.test.tsx.snap index a79c7abde9cc8..3cc220906af3b 100644 --- a/x-pack/plugins/security_solution/public/overview/components/host_overview/__snapshots__/index.test.tsx.snap +++ b/x-pack/plugins/security_solution/public/overview/components/host_overview/__snapshots__/index.test.tsx.snap @@ -198,6 +198,7 @@ exports[`Host Summary Component it renders the default Host Summary 1`] = ` indexNames={Array []} isInDetailsSidePanel={false} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" @@ -402,6 +403,7 @@ exports[`Host Summary Component it renders the panel view Host Summary 1`] = ` indexNames={Array []} isInDetailsSidePanel={true} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" diff --git a/x-pack/plugins/security_solution/public/overview/components/host_overview/index.test.tsx b/x-pack/plugins/security_solution/public/overview/components/host_overview/index.test.tsx index 29799ebcbb813..4f7c2882c022e 100644 --- a/x-pack/plugins/security_solution/public/overview/components/host_overview/index.test.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/host_overview/index.test.tsx @@ -42,6 +42,7 @@ describe('Host Summary Component', () => { narrowDateRange: jest.fn(), startDate: '2019-06-15T06:00:00.000Z', hostName: 'testHostName', + jobNameById: {}, }; beforeEach(() => { diff --git a/x-pack/plugins/security_solution/public/overview/components/host_overview/index.tsx b/x-pack/plugins/security_solution/public/overview/components/host_overview/index.tsx index 404561263fe53..954dc51572ea2 100644 --- a/x-pack/plugins/security_solution/public/overview/components/host_overview/index.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/host_overview/index.tsx @@ -54,6 +54,7 @@ interface HostSummaryProps { endDate: string; narrowDateRange: NarrowDateRange; hostName: string; + jobNameById: Record; } const HostRiskOverviewWrapper = styled(EuiFlexGroup)` @@ -76,6 +77,7 @@ export const HostOverview = React.memo( narrowDateRange, startDate, hostName, + jobNameById, }) => { const capabilities = useMlCapabilities(); const userPermissions = hasMlUserPermissions(capabilities); @@ -198,6 +200,7 @@ export const HostOverview = React.memo( endDate={endDate} isLoading={isLoadingAnomaliesData} narrowDateRange={narrowDateRange} + jobNameById={jobNameById} /> ), }, @@ -211,6 +214,7 @@ export const HostOverview = React.memo( narrowDateRange, startDate, userPermissions, + jobNameById, ] ); diff --git a/x-pack/plugins/security_solution/public/overview/components/user_overview/__snapshots__/index.test.tsx.snap b/x-pack/plugins/security_solution/public/overview/components/user_overview/__snapshots__/index.test.tsx.snap index 27e9ed8ef9a83..ee1cf28f2274b 100644 --- a/x-pack/plugins/security_solution/public/overview/components/user_overview/__snapshots__/index.test.tsx.snap +++ b/x-pack/plugins/security_solution/public/overview/components/user_overview/__snapshots__/index.test.tsx.snap @@ -171,6 +171,7 @@ exports[`User Summary Component it renders the default User Summary 1`] = ` indexPatterns={Array []} isInDetailsSidePanel={false} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" @@ -349,6 +350,7 @@ exports[`User Summary Component it renders the panel view User Summary 1`] = ` indexPatterns={Array []} isInDetailsSidePanel={true} isLoadingAnomaliesData={false} + jobNameById={Object {}} loading={false} narrowDateRange={[MockFunction]} startDate="2019-06-15T06:00:00.000Z" diff --git a/x-pack/plugins/security_solution/public/overview/components/user_overview/index.test.tsx b/x-pack/plugins/security_solution/public/overview/components/user_overview/index.test.tsx index 5eff09be5fd15..7e58a09d57adc 100644 --- a/x-pack/plugins/security_solution/public/overview/components/user_overview/index.test.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/user_overview/index.test.tsx @@ -55,6 +55,7 @@ describe('User Summary Component', () => { startDate: '2019-06-15T06:00:00.000Z', userName: 'testUserName', indexPatterns: [], + jobNameById: {}, }; beforeEach(() => { diff --git a/x-pack/plugins/security_solution/public/overview/components/user_overview/index.tsx b/x-pack/plugins/security_solution/public/overview/components/user_overview/index.tsx index d3f80bd9fa041..c1cf7726e1aff 100644 --- a/x-pack/plugins/security_solution/public/overview/components/user_overview/index.tsx +++ b/x-pack/plugins/security_solution/public/overview/components/user_overview/index.tsx @@ -52,6 +52,7 @@ export interface UserSummaryProps { narrowDateRange: NarrowDateRange; userName: string; indexPatterns: string[]; + jobNameById: Record; } const UserRiskOverviewWrapper = styled(EuiFlexGroup)` @@ -74,6 +75,7 @@ export const UserOverview = React.memo( endDate, userName, indexPatterns, + jobNameById, }) => { const capabilities = useMlCapabilities(); const userPermissions = hasMlUserPermissions(capabilities); @@ -179,6 +181,7 @@ export const UserOverview = React.memo( endDate={endDate} isLoading={isLoadingAnomaliesData} narrowDateRange={narrowDateRange} + jobNameById={jobNameById} /> ), }, @@ -192,6 +195,7 @@ export const UserOverview = React.memo( narrowDateRange, startDate, userPermissions, + jobNameById, ] ); diff --git a/x-pack/plugins/security_solution/public/plugin.tsx b/x-pack/plugins/security_solution/public/plugin.tsx index 3e08672939b5c..538845eaeefa9 100644 --- a/x-pack/plugins/security_solution/public/plugin.tsx +++ b/x-pack/plugins/security_solution/public/plugin.tsx @@ -58,10 +58,30 @@ import { getLazyEndpointGenericErrorsListExtension } from './management/pages/po import type { ExperimentalFeatures } from '../common/experimental_features'; import { parseExperimentalConfigValue } from '../common/experimental_features'; import { LazyEndpointCustomAssetsExtension } from './management/pages/policy/view/ingest_manager_integration/lazy_endpoint_custom_assets_extension'; + import type { SecurityAppStore } from './common/store/types'; export class Plugin implements IPlugin { + /** + * The current Kibana branch. e.g. 'main' + */ + readonly kibanaBranch: string; + /** + * The current Kibana version. e.g. '8.0.0' or '8.0.0-SNAPSHOT' + */ readonly kibanaVersion: string; + /** + * For internal use. Specify which version of the Detection Rules fleet package to install + * when upgrading rules. If not provided, the latest compatible package will be installed, + * or if running from a dev environment or -SNAPSHOT build, the latest pre-release package + * will be used (if fleet is available or not within an airgapped environment). + * + * Note: This is for `upgrade only`, which occurs by means of the `useUpgradeSecurityPackages` + * hook when navigating to a Security Solution page. The package version specified in + * `fleet_packages.json` in project root will always be installed first on Kibana start if + * the package is not already installed. + */ + readonly prebuiltRulesPackageVersion?: string; private config: SecuritySolutionUiConfigType; readonly experimentalFeatures: ExperimentalFeatures; @@ -69,6 +89,8 @@ export class Plugin implements IPlugin(); this.experimentalFeatures = parseExperimentalConfigValue(this.config.enableExperimental || []); this.kibanaVersion = initializerContext.env.packageInfo.version; + this.kibanaBranch = initializerContext.env.packageInfo.branch; + this.prebuiltRulesPackageVersion = this.config.prebuiltRulesPackageVersion; } private appUpdater$ = new Subject(); @@ -214,7 +236,13 @@ export class Plugin implements IPlugin { - const { threatIntelligence } = useKibana().services; + const { threatIntelligence, http } = useKibana().services; const ThreatIntelligencePlugin = threatIntelligence.getComponent(); const sourcererDataView = useSourcererDataView(); @@ -44,6 +48,15 @@ const ThreatIntelligence = memo(() => { sourcererDataView: sourcererDataView as unknown as SourcererDataView, getUseInvestigateInTimeline: useInvestigateInTimeline, + blockList: { + exceptionListApiClient: BlocklistsApiClient.getInstance(http), + useSetUrlParams, + // @ts-ignore + getFlyoutComponent: () => ArtifactFlyout, + // @ts-ignore + getFormComponent: () => BlockListForm, + }, + useQuery: () => useSelector(inputsSelectors.globalQuerySelector()), useFilters: () => useSelector(inputsSelectors.globalFiltersQuerySelector()), useGlobalTime, diff --git a/x-pack/plugins/security_solution/public/timelines/components/notes/helpers.tsx b/x-pack/plugins/security_solution/public/timelines/components/notes/helpers.tsx index ca5d2dfdee788..82eb7b4b7dc30 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/notes/helpers.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/notes/helpers.tsx @@ -9,7 +9,7 @@ import { EuiIcon, EuiFlexGroup, EuiFlexItem, EuiTitle } from '@elastic/eui'; import moment from 'moment'; import React from 'react'; import styled from 'styled-components'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Note } from '../../../common/lib/note'; @@ -73,7 +73,7 @@ NotesCount.displayName = 'NotesCount'; /** Creates a new instance of a `note` */ export const createNote = ({ newNote, user }: { newNote: string; user: string }): Note => ({ created: moment.utc().toDate(), - id: uuid.v4(), + id: uuidv4(), lastEdit: null, note: newNote, saveObjectId: null, diff --git a/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.test.ts b/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.test.ts index 0b8d6152ac8f4..c789b20f6bd7d 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.test.ts +++ b/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.test.ts @@ -53,8 +53,8 @@ jest.mock('../../store/timeline/actions'); jest.mock('../../../common/store/app/actions'); jest.mock('uuid', () => { return { - v1: jest.fn(() => 'uuid.v1()'), - v4: jest.fn(() => 'uuid.v4()'), + v1: jest.fn(() => 'uuidv1()'), + v4: jest.fn(() => 'uuidv4()'), }; }); @@ -876,7 +876,7 @@ describe('helpers', () => { })(); const expectedNote: Note = { created: new Date(anchor), - id: 'uuid.v4()', + id: 'uuidv4()', lastEdit: null, note: '# this would be some markdown', saveObjectId: null, @@ -888,7 +888,7 @@ describe('helpers', () => { expect(dispatchUpdateNote).toHaveBeenCalledWith({ note: expectedNote }); expect(dispatchAddGlobalTimelineNote).toHaveBeenLastCalledWith({ id: TimelineId.active, - noteId: 'uuid.v4()', + noteId: 'uuidv4()', }); }); }); diff --git a/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts b/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts index b82051c11a8a0..ef3dd58e06b66 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts +++ b/x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts @@ -8,7 +8,7 @@ import { set } from '@kbn/safer-lodash-set/fp'; import { getOr, isEmpty } from 'lodash/fp'; import type { Action } from 'typescript-fsa'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Dispatch } from 'redux'; import deepMerge from 'deepmerge'; @@ -201,7 +201,7 @@ const getTemplateTimelineId = ( return duplicate && timeline.timelineType === TimelineType.template ? // TODO: MOVE TO THE BACKEND - uuid.v4() + uuidv4() : timeline.templateTimelineId; }; diff --git a/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.test.tsx b/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.test.tsx index 915d4da71f609..da3c66e415fb0 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.test.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.test.tsx @@ -33,8 +33,9 @@ jest.mock('../../../../common/components/ml/anomaly/anomaly_table_provider', () children: (args: { anomaliesData: Anomalies; isLoadingAnomaliesData: boolean; + jobNameById: Record; }) => React.ReactNode; - }) => children({ anomaliesData: mockAnomalies, isLoadingAnomaliesData: false }), + }) => children({ anomaliesData: mockAnomalies, isLoadingAnomaliesData: false, jobNameById: {} }), })); describe('Expandable Host Component', () => { diff --git a/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.tsx b/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.tsx index a653358da61d3..bdbd6b28ffee2 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/side_panel/host_details/expandable_host.tsx @@ -95,7 +95,7 @@ export const ExpandableHostDetails = ({ endDate={to} skip={isInitializing} > - {({ isLoadingAnomaliesData, anomaliesData }) => ( + {({ isLoadingAnomaliesData, anomaliesData, jobNameById }) => ( )} diff --git a/x-pack/plugins/security_solution/public/timelines/components/side_panel/network_details/expandable_network.tsx b/x-pack/plugins/security_solution/public/timelines/components/side_panel/network_details/expandable_network.tsx index 33801fd70d36f..b3d4c93ce8b25 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/side_panel/network_details/expandable_network.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/side_panel/network_details/expandable_network.tsx @@ -29,7 +29,7 @@ import { useNetworkDetails } from '../../../../explore/network/containers/detail import { networkModel } from '../../../../explore/network/store'; import { useAnomaliesTableData } from '../../../../common/components/ml/anomaly/use_anomalies_table_data'; import { LandingCards } from '../../../../common/components/landing_cards'; -import { useInstalledSecurityJobsIds } from '../../../../common/components/ml/hooks/use_installed_security_jobs'; +import { useInstalledSecurityJobNameById } from '../../../../common/components/ml/hooks/use_installed_security_jobs'; interface ExpandableNetworkProps { expandedNetwork: { ip: string; flowTarget: FlowTargetSourceDest }; @@ -116,7 +116,8 @@ export const ExpandableNetworkDetails = ({ }); useInvalidFilterQuery({ id, filterQuery, kqlError, query, startDate: from, endDate: to }); - const { jobIds } = useInstalledSecurityJobsIds(); + const { jobNameById } = useInstalledSecurityJobNameById(); + const jobIds = useMemo(() => Object.keys(jobNameById), [jobNameById]); const [isLoadingAnomaliesData, anomaliesData] = useAnomaliesTableData({ criteriaFields: networkToCriteria(ip, flowTarget), startDate: from, @@ -143,6 +144,7 @@ export const ExpandableNetworkDetails = ({ endDate={to} narrowDateRange={narrowDateRange} indexPatterns={selectedPatterns} + jobNameById={jobNameById} /> ) : ( diff --git a/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.test.tsx b/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.test.tsx index 828f7dcf295fb..48d15017349e9 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.test.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.test.tsx @@ -33,8 +33,9 @@ jest.mock('../../../../common/components/ml/anomaly/anomaly_table_provider', () children: (args: { anomaliesData: Anomalies; isLoadingAnomaliesData: boolean; + jobNameById: Record; }) => React.ReactNode; - }) => children({ anomaliesData: mockAnomalies, isLoadingAnomaliesData: false }), + }) => children({ anomaliesData: mockAnomalies, isLoadingAnomaliesData: false, jobNameById: {} }), })); describe('Expandable Host Component', () => { diff --git a/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.tsx b/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.tsx index 1de3f840dad3d..e8554f04dbcaf 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/side_panel/user_details/expandable_user.tsx @@ -90,7 +90,7 @@ export const ExpandableUserDetails = ({ endDate={to} skip={isInitializing} > - {({ isLoadingAnomaliesData, anomaliesData }) => ( + {({ isLoadingAnomaliesData, anomaliesData, jobNameById }) => ( )} diff --git a/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/add_data_provider_popover.tsx b/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/add_data_provider_popover.tsx index 5e40c2c76e10e..c6e5463370e27 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/add_data_provider_popover.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/add_data_provider_popover.tsx @@ -17,7 +17,7 @@ import { EuiPopover, EuiIcon, } from '@elastic/eui'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { useDispatch } from 'react-redux'; import type { BrowserFields } from '../../../../common/containers/source'; @@ -126,7 +126,7 @@ const AddDataProviderPopoverComponent: React.FC = ( timelineId={timelineId} value="" type={DataProviderType.default} - providerId={`${timelineId}-${uuid.v4()}`} + providerId={`${timelineId}-${uuidv4()}`} /> ), }, @@ -144,7 +144,7 @@ const AddDataProviderPopoverComponent: React.FC = ( timelineId={timelineId} value="" type={DataProviderType.template} - providerId={`${timelineId}-${uuid.v4()}`} + providerId={`${timelineId}-${uuidv4()}`} /> ), }, @@ -195,7 +195,7 @@ const AddDataProviderPopoverComponent: React.FC = ( timelineId={timelineId} value="" type={DataProviderType.default} - providerId={`${timelineId}-${uuid.v4()}`} + providerId={`${timelineId}-${uuidv4()}`} /> ); }, [browserFields, handleDataProviderEdited, panels, timelineId, timelineType]); diff --git a/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/index.tsx b/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/index.tsx index 865c2cdd8559e..59c9aa8e24c06 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/index.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/timeline/data_providers/index.tsx @@ -8,7 +8,7 @@ import { rgba } from 'polished'; import React, { useMemo } from 'react'; import styled from 'styled-components'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { IS_DRAGGING_CLASS_NAME } from '@kbn/securitysolution-t-grid'; import { SourcererScopeName } from '../../../../common/store/sourcerer/model'; @@ -65,7 +65,7 @@ const DropTargetDataProviders = styled.div` DropTargetDataProviders.displayName = 'DropTargetDataProviders'; const getDroppableId = (id: string): string => - `${droppableTimelineProvidersPrefix}${id}${uuid.v4()}`; + `${droppableTimelineProvidersPrefix}${id}${uuidv4()}`; /** * Renders the data providers section of the timeline. diff --git a/x-pack/plugins/security_solution/public/timelines/components/timeline/eql_tab_content/index.test.tsx b/x-pack/plugins/security_solution/public/timelines/components/timeline/eql_tab_content/index.test.tsx index 9fce79a79ec6c..ff8fc140ebef5 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/timeline/eql_tab_content/index.test.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/timeline/eql_tab_content/index.test.tsx @@ -23,7 +23,6 @@ import { useTimelineEvents } from '../../../containers'; import { useTimelineEventsDetails } from '../../../containers/details'; import { useSourcererDataView } from '../../../../common/containers/sourcerer'; import { mockSourcererScope } from '../../../../common/containers/sourcerer/mocks'; -import { mockCasesContext } from '@kbn/cases-plugin/public/mocks/mock_cases_context'; jest.mock('../../../containers', () => ({ useTimelineEvents: jest.fn(), @@ -47,52 +46,7 @@ const mockUseResizeObserver: jest.Mock = useResizeObserver as jest.Mock; jest.mock('use-resize-observer/polyfilled'); mockUseResizeObserver.mockImplementation(() => ({})); -const useAddToTimeline = () => ({ - beginDrag: jest.fn(), - cancelDrag: jest.fn(), - dragToLocation: jest.fn(), - endDrag: jest.fn(), - hasDraggableLock: jest.fn(), - startDragToTimeline: jest.fn(), -}); - -jest.mock('../../../../common/lib/kibana', () => { - const originalModule = jest.requireActual('../../../../common/lib/kibana'); - return { - ...originalModule, - useKibana: jest.fn().mockReturnValue({ - services: { - theme: { - theme$: {}, - }, - application: { - navigateToApp: jest.fn(), - getUrlForApp: jest.fn(), - }, - cases: { - ui: { - getCasesContext: () => mockCasesContext, - }, - }, - docLinks: { links: { query: { eql: 'url-eql_doc' } } }, - uiSettings: { - get: jest.fn(), - }, - savedObjects: { - client: {}, - }, - timelines: { - getLastUpdated: jest.fn(), - getUseAddToTimeline: () => useAddToTimeline, - }, - triggersActionsUi: { - getFieldBrowser: jest.fn(), - }, - }, - }), - useGetUserSavedObjectPermissions: jest.fn(), - }; -}); +jest.mock('../../../../common/lib/kibana'); describe('Timeline', () => { let props = {} as EqlTabContentComponentProps; diff --git a/x-pack/plugins/security_solution/public/timelines/components/timeline/query_tab_content/index.test.tsx b/x-pack/plugins/security_solution/public/timelines/components/timeline/query_tab_content/index.test.tsx index 279643da32144..1e77a6c277da7 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/timeline/query_tab_content/index.test.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/timeline/query_tab_content/index.test.tsx @@ -26,7 +26,6 @@ import { useTimelineEventsDetails } from '../../../containers/details'; import { useSourcererDataView } from '../../../../common/containers/sourcerer'; import { mockSourcererScope } from '../../../../common/containers/sourcerer/mocks'; import { Direction } from '../../../../../common/search_strategy'; -import { mockCasesContext } from '@kbn/cases-plugin/public/mocks/mock_cases_context'; import * as helpers from '../../../../common/lib/kuery'; import { waitFor } from '@testing-library/react'; @@ -54,52 +53,7 @@ const mockUseResizeObserver: jest.Mock = useResizeObserver as jest.Mock; jest.mock('use-resize-observer/polyfilled'); mockUseResizeObserver.mockImplementation(() => ({})); -const useAddToTimeline = () => ({ - beginDrag: jest.fn(), - cancelDrag: jest.fn(), - dragToLocation: jest.fn(), - endDrag: jest.fn(), - hasDraggableLock: jest.fn(), - startDragToTimeline: jest.fn(), -}); - -jest.mock('../../../../common/lib/kibana', () => { - const originalModule = jest.requireActual('../../../../common/lib/kibana'); - return { - ...originalModule, - useKibana: jest.fn().mockReturnValue({ - services: { - theme: { - theme$: {}, - }, - application: { - navigateToApp: jest.fn(), - getUrlForApp: jest.fn(), - }, - cases: { - ui: { - getCasesContext: () => mockCasesContext, - }, - }, - uiSettings: { - get: jest.fn(), - }, - savedObjects: { - client: {}, - }, - triggersActionsUi: { - getFieldBrowser: jest.fn(), - }, - timelines: { - getLastUpdated: jest.fn(), - getLoadingPanel: jest.fn(), - getUseAddToTimeline: () => useAddToTimeline, - }, - }, - }), - useGetUserSavedObjectPermissions: jest.fn(), - }; -}); +jest.mock('../../../../common/lib/kibana'); describe('Timeline', () => { let props = {} as QueryTabContentComponentProps; diff --git a/x-pack/plugins/security_solution/public/timelines/store/timeline/helpers.ts b/x-pack/plugins/security_solution/public/timelines/store/timeline/helpers.ts index 7db59d5b7a0eb..49cea3f458102 100644 --- a/x-pack/plugins/security_solution/public/timelines/store/timeline/helpers.ts +++ b/x-pack/plugins/security_solution/public/timelines/store/timeline/helpers.ts @@ -7,7 +7,7 @@ import { getOr, omit, uniq, isEmpty, isEqualWith, cloneDeep, union } from 'lodash/fp'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Filter } from '@kbn/es-query'; @@ -173,7 +173,7 @@ export const addNewTimeline = ({ const templateTimelineInfo = timelineType === TimelineType.template ? { - templateTimelineId: uuid.v4(), + templateTimelineId: uuidv4(), templateTimelineVersion: 1, } : {}; diff --git a/x-pack/plugins/security_solution/server/config.mock.ts b/x-pack/plugins/security_solution/server/config.mock.ts index 45563178dd6dd..10ea0b588b379 100644 --- a/x-pack/plugins/security_solution/server/config.mock.ts +++ b/x-pack/plugins/security_solution/server/config.mock.ts @@ -24,6 +24,7 @@ export const createMockConfig = (): ConfigType => { maxTimelineImportPayloadBytes: 10485760, enableExperimental, packagerTaskInterval: '60s', + prebuiltRulesPackageVersion: '', alertMergeStrategy: 'missingFields', alertIgnoreFields: [], diff --git a/x-pack/plugins/security_solution/server/config.ts b/x-pack/plugins/security_solution/server/config.ts index 08683436505e3..5a4d18edda11c 100644 --- a/x-pack/plugins/security_solution/server/config.ts +++ b/x-pack/plugins/security_solution/server/config.ts @@ -109,6 +109,19 @@ export const configSchema = schema.object({ * Artifacts Configuration */ packagerTaskInterval: schema.string({ defaultValue: '60s' }), + + /** + * For internal use. Specify which version of the Detection Rules fleet package to install + * when upgrading rules. If not provided, the latest compatible package will be installed, + * or if running from a dev environment or -SNAPSHOT build, the latest pre-release package + * will be used (if fleet is available or not within an airgapped environment). + * + * Note: This is for `upgrade only`, which occurs by means of the `useUpgradeSecurityPackages` + * hook when navigating to a Security Solution page. The package version specified in + * `fleet_packages.json` in project root will always be installed first on Kibana start if + * the package is not already installed. + */ + prebuiltRulesPackageVersion: schema.maybe(schema.string()), }); export type ConfigSchema = TypeOf; diff --git a/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.test.ts b/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.test.ts index a16f2719ba90b..f6c4f2fb71058 100644 --- a/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.test.ts @@ -8,10 +8,6 @@ import { EndpointAppContextService } from './endpoint_app_context_services'; describe('test endpoint app context services', () => { - it('should return undefined on getAgentService if dependencies are not enabled', async () => { - const endpointAppContextService = new EndpointAppContextService(); - expect(endpointAppContextService.getAgentService()).toEqual(undefined); - }); it('should return undefined on getManifestManager if dependencies are not enabled', async () => { const endpointAppContextService = new EndpointAppContextService(); expect(endpointAppContextService.getManifestManager()).toEqual(undefined); diff --git a/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.ts b/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.ts index 8e7656150be23..d1e236f897ade 100644 --- a/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.ts +++ b/x-pack/plugins/security_solution/server/endpoint/endpoint_app_context_services.ts @@ -12,11 +12,7 @@ import type { PluginStartContract as CasesPluginStartContract, } from '@kbn/cases-plugin/server'; import type { SecurityPluginStart } from '@kbn/security-plugin/server'; -import type { - AgentService, - FleetStartContract, - AgentPolicyServiceInterface, -} from '@kbn/fleet-plugin/server'; +import type { FleetStartContract } from '@kbn/fleet-plugin/server'; import type { PluginStartContract as AlertsPluginStartContract } from '@kbn/alerting-plugin/server'; import { ENDPOINT_HOST_ISOLATION_EXCEPTIONS_LIST_ID } from '@kbn/securitysolution-list-constants'; import { @@ -37,7 +33,6 @@ import { import type { EndpointFleetServicesFactoryInterface, EndpointInternalFleetServicesInterface, - EndpointScopedFleetServicesInterface, } from './services/fleet/endpoint_fleet_services_factory'; import { registerListsPluginEndpointExtensionPoints } from '../lists_integration'; import type { EndpointAuthz } from '../../common/endpoint/types/authz'; @@ -50,12 +45,7 @@ export interface EndpointAppContextServiceSetupContract { securitySolutionRequestContextFactory: IRequestContextFactory; } -export type EndpointAppContextServiceStartContract = Partial< - Pick< - FleetStartContract, - 'agentService' | 'packageService' | 'packagePolicyService' | 'agentPolicyService' - > -> & { +export interface EndpointAppContextServiceStartContract { fleetAuthzService?: FleetStartContract['authz']; logger: Logger; endpointMetadataService: EndpointMetadataService; @@ -71,7 +61,7 @@ export type EndpointAppContextServiceStartContract = Partial< cases: CasesPluginStartContract | undefined; featureUsageService: FeatureUsageService; experimentalFeatures: ExperimentalFeatures; -}; +} /** * A singleton that holds shared services that are initialized during the start up phase @@ -96,11 +86,7 @@ export class EndpointAppContextService { this.security = dependencies.security; this.fleetServicesFactory = dependencies.endpointFleetServicesFactory; - if ( - dependencies.registerIngestCallback && - dependencies.manifestManager && - dependencies.packagePolicyService - ) { + if (dependencies.registerIngestCallback && dependencies.manifestManager) { const { registerIngestCallback, logger, @@ -189,14 +175,6 @@ export class EndpointAppContextService { return this.startDependencies.endpointMetadataService; } - public getScopedFleetServices(req: KibanaRequest): EndpointScopedFleetServicesInterface { - if (this.fleetServicesFactory === null) { - throw new EndpointAppContentServicesNotStartedError(); - } - - return this.fleetServicesFactory.asScoped(req); - } - public getInternalFleetServices(): EndpointInternalFleetServicesInterface { if (this.fleetServicesFactory === null) { throw new EndpointAppContentServicesNotStartedError(); @@ -205,16 +183,6 @@ export class EndpointAppContextService { return this.fleetServicesFactory.asInternalUser(); } - /** @deprecated use `getScopedFleetServices()` instead */ - public getAgentService(): AgentService | undefined { - return this.startDependencies?.agentService; - } - - /** @deprecated use `getScopedFleetServices()` instead */ - public getAgentPolicyService(): AgentPolicyServiceInterface | undefined { - return this.startDependencies?.agentPolicyService; - } - public getManifestManager(): ManifestManager | undefined { return this.startDependencies?.manifestManager; } diff --git a/x-pack/plugins/security_solution/server/endpoint/mocks.ts b/x-pack/plugins/security_solution/server/endpoint/mocks.ts index 3d9329ed85cff..be0738c5f0288 100644 --- a/x-pack/plugins/security_solution/server/endpoint/mocks.ts +++ b/x-pack/plugins/security_solution/server/endpoint/mocks.ts @@ -90,8 +90,6 @@ export const createMockEndpointAppContextService = ( start: jest.fn(), stop: jest.fn(), getExperimentalFeatures: jest.fn(), - getAgentService: jest.fn(), - getAgentPolicyService: jest.fn(), getManifestManager: jest.fn().mockReturnValue(mockManifestManager ?? jest.fn()), getEndpointMetadataService: jest.fn(() => mockEndpointMetadataContext.endpointMetadataService), getInternalFleetServices: jest.fn(() => mockEndpointMetadataContext.fleetServices), @@ -159,13 +157,9 @@ export const createMockEndpointAppContextServiceStartContract = ); return { - agentService, - agentPolicyService, endpointMetadataService, endpointFleetServicesFactory, - packagePolicyService, logger, - packageService, fleetAuthzService: createFleetAuthzServiceMock(), manifestManager: getManifestManagerMock(), security, diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/actions/audit_log.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/actions/audit_log.test.ts index 3780fd95e3d91..120f1753fc18e 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/actions/audit_log.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/actions/audit_log.test.ts @@ -31,7 +31,7 @@ import { createRouteHandlerContext, } from '../../mocks'; import { registerActionAuditLogRoutes } from './audit_log'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Results } from './mocks'; import { mockAuditLogSearchResult } from './mocks'; import type { SecuritySolutionRequestHandlerContext } from '../../../types'; @@ -53,7 +53,7 @@ describe('Action Log API', () => { it('should accept a single agent ID', () => { expect(() => { - EndpointActionLogRequestSchema.params.validate({ agent_id: uuid.v4() }); + EndpointActionLogRequestSchema.params.validate({ agent_id: uuidv4() }); }).not.toThrow(); }); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.test.ts index f9f9ae22be429..76c72ef2bba4a 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.test.ts @@ -26,9 +26,7 @@ import { loggingSystemMock, savedObjectsClientMock, } from '@kbn/core/server/mocks'; -import type { PackageClient } from '@kbn/fleet-plugin/server'; -import { createMockPackageService } from '@kbn/fleet-plugin/server/mocks'; -import { AGENT_ACTIONS_INDEX, ElasticsearchAssetType } from '@kbn/fleet-plugin/common'; +import { AGENT_ACTIONS_INDEX } from '@kbn/fleet-plugin/common'; import type { CasesClientMock } from '@kbn/cases-plugin/server/client/mocks'; import { parseExperimentalConfigValue } from '../../../../common/experimental_features'; @@ -36,7 +34,6 @@ import { LicenseService } from '../../../../common/license'; import { ISOLATE_HOST_ROUTE_V2, UNISOLATE_HOST_ROUTE_V2, - metadataTransformPrefix, ENDPOINT_ACTIONS_INDEX, KILL_PROCESS_ROUTE, SUSPEND_PROCESS_ROUTE, @@ -111,31 +108,6 @@ describe('Response actions', () => { const startContract = createMockEndpointAppContextServiceStartContract(); endpointAppContextService = new EndpointAppContextService(); const mockSavedObjectClient = savedObjectsClientMock.create(); - const mockPackageService = createMockPackageService(); - const mockedPackageClient = mockPackageService.asInternalUser as jest.Mocked; - mockedPackageClient.getInstallation.mockResolvedValue({ - installed_kibana: [], - package_assets: [], - es_index_patterns: {}, - name: '', - version: '', - install_status: 'installed', - install_version: '', - install_started_at: '', - install_source: 'registry', - installed_es: [ - { - id: 'logs-endpoint.events.security', - type: ElasticsearchAssetType.indexTemplate, - }, - { - id: `${metadataTransformPrefix}-0.16.0-dev.0`, - type: ElasticsearchAssetType.transform, - }, - ], - keep_policies_up_to_date: false, - verification_status: 'unknown', - }); licenseEmitter = new Subject(); licenseService = new LicenseService(); @@ -145,7 +117,6 @@ describe('Response actions', () => { endpointAppContextService.start({ ...startContract, licenseService, - packageService: mockPackageService, }); // add the host isolation route handlers to routerMock diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.ts b/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.ts index ec08ef4c7fd83..ac9c71cd931b5 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/actions/response_actions.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import moment from 'moment'; import type { RequestHandler, Logger } from '@kbn/core/server'; @@ -229,7 +229,7 @@ function responseActionRequestHandler { it('should accept a single agent ID', () => { expect(() => { - ActionStatusRequestSchema.query.validate({ agent_ids: uuid.v4() }); + ActionStatusRequestSchema.query.validate({ agent_ids: uuidv4() }); }).not.toThrow(); }); it('should accept multiple agent IDs', () => { expect(() => { - ActionStatusRequestSchema.query.validate({ agent_ids: [uuid.v4(), uuid.v4()] }); + ActionStatusRequestSchema.query.validate({ agent_ids: [uuidv4(), uuidv4()] }); }).not.toThrow(); }); it('should limit the maximum number of agent IDs', () => { - const tooManyCooks = new Array(200).fill(uuid.v4()); // all the same ID string + const tooManyCooks = new Array(200).fill(uuidv4()); // all the same ID string expect(() => { ActionStatusRequestSchema.query.validate({ agent_ids: tooManyCooks }); }).toThrow(); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/enrichment.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/enrichment.test.ts deleted file mode 100644 index e9b1f709dcedb..0000000000000 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/enrichment.test.ts +++ /dev/null @@ -1,195 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { coreMock } from '@kbn/core/server/mocks'; -import { HostStatus } from '../../../../common/endpoint/types'; -import { createMockMetadataRequestContext } from '../../mocks'; -import { EndpointDocGenerator } from '../../../../common/endpoint/generate_data'; -import type { MetadataRequestContext } from './handlers'; -import { enrichHostMetadata } from './handlers'; -import type { AgentClient } from '@kbn/fleet-plugin/server'; - -describe('test document enrichment', () => { - let metaReqCtx: ReturnType; - const docGen = new EndpointDocGenerator(); - - beforeEach(() => { - metaReqCtx = createMockMetadataRequestContext(); - }); - - const getMetadataRequestContext = () => - ({ - ...metaReqCtx, - requestHandlerContext: coreMock.createCustomRequestHandlerContext( - metaReqCtx.requestHandlerContext - ), - } as unknown as MetadataRequestContext); - - describe('host status enrichment', () => { - let statusFn: jest.Mock; - - beforeEach(() => { - statusFn = jest.fn(); - metaReqCtx.requestHandlerContext!.fleet!.agentClient.asCurrentUser = { - getAgentStatusById: statusFn, - } as unknown as AgentClient; - }); - - it('should return host healthy for online agent', async () => { - statusFn.mockImplementation(() => 'online'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.HEALTHY); - }); - - it('should return host offline for offline agent', async () => { - statusFn.mockImplementation(() => 'offline'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.OFFLINE); - }); - - it('should return host updating for unenrolling agent', async () => { - statusFn.mockImplementation(() => 'unenrolling'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.UPDATING); - }); - - it('should return host unhealthy for degraded agent', async () => { - statusFn.mockImplementation(() => 'degraded'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.UNHEALTHY); - }); - - it('should return host unhealthy for erroring agent', async () => { - statusFn.mockImplementation(() => 'error'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.UNHEALTHY); - }); - - it('should return host unhealthy for warning agent', async () => { - statusFn.mockImplementation(() => 'warning'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.UNHEALTHY); - }); - - it('should return host unhealthy for invalid agent', async () => { - statusFn.mockImplementation(() => 'asliduasofb'); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.host_status).toEqual(HostStatus.UNHEALTHY); - }); - }); - - describe('policy info enrichment', () => { - let agentMock: jest.Mock; - let agentPolicyMock: jest.Mock; - - beforeEach(() => { - agentMock = jest.fn(); - agentPolicyMock = jest.fn(); - metaReqCtx.requestHandlerContext!.fleet!.agentClient.asCurrentUser = { - getAgent: agentMock, - getAgentStatusById: jest.fn(), - } as unknown as AgentClient; - (metaReqCtx.endpointAppContextService.getAgentPolicyService as jest.Mock).mockImplementation( - () => { - return { - get: agentPolicyMock, - }; - } - ); - }); - - it('reflects current applied agent info', async () => { - const policyID = 'abc123'; - const policyRev = 9; - agentMock.mockImplementation(() => { - return { - policy_id: policyID, - policy_revision: policyRev, - }; - }); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.policy_info).toBeDefined(); - expect(enrichedHostList.policy_info?.agent.applied.id).toEqual(policyID); - expect(enrichedHostList.policy_info?.agent.applied.revision).toEqual(policyRev); - }); - - it('reflects current fleet agent info', async () => { - const policyID = 'xyz456'; - const policyRev = 15; - agentPolicyMock.mockImplementation(() => { - return { - id: policyID, - revision: policyRev, - }; - }); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.policy_info).toBeDefined(); - expect(enrichedHostList.policy_info?.agent.configured.id).toEqual(policyID); - expect(enrichedHostList.policy_info?.agent.configured.revision).toEqual(policyRev); - }); - - it('reflects current endpoint policy info', async () => { - const policyID = 'endpoint-b33f'; - const policyRev = 2; - agentPolicyMock.mockImplementation(() => { - return { - package_policies: [ - { - package: { name: 'endpoint' }, - id: policyID, - revision: policyRev, - }, - ], - }; - }); - - const enrichedHostList = await enrichHostMetadata( - docGen.generateHostMetadata(), - getMetadataRequestContext() - ); - expect(enrichedHostList.policy_info).toBeDefined(); - expect(enrichedHostList.policy_info?.endpoint.id).toEqual(policyID); - expect(enrichedHostList.policy_info?.endpoint.revision).toEqual(policyRev); - }); - }); -}); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/handlers.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/handlers.ts index 868025df46d4e..2faca1ea1f3f0 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/handlers.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/handlers.ts @@ -12,33 +12,18 @@ import type { RequestHandler, SavedObjectsClientContract, } from '@kbn/core/server'; -import type { PackagePolicy } from '@kbn/fleet-plugin/common/types/models'; -import { AgentNotFoundError } from '@kbn/fleet-plugin/server'; import { errorHandler } from '../error_handler'; -import type { - HostInfo, - HostMetadata, - HostResultList, - MetadataListResponse, -} from '../../../../common/endpoint/types'; -import { HostStatus } from '../../../../common/endpoint/types'; import type { SecuritySolutionRequestHandlerContext } from '../../../types'; -import { kibanaRequestToMetadataListESQuery } from './query_builders'; -import type { EndpointAppContext, HostListQueryResult } from '../../types'; +import type { EndpointAppContext } from '../../types'; import type { GetMetadataRequestSchema } from '.'; -import { findAllUnenrolledAgentIds } from './support/unenroll'; -import { findAgentIdsByStatus } from './support/agent_status'; import type { EndpointAppContextService } from '../../endpoint_app_context_services'; -import { fleetAgentStatusToEndpointHostStatus } from '../../utils'; -import { queryResponseToHostListResult } from './support/query_strategies'; import type { GetMetadataListRequestQuery } from '../../../../common/endpoint/schema/metadata'; import { ENDPOINT_DEFAULT_PAGE, ENDPOINT_DEFAULT_PAGE_SIZE, METADATA_TRANSFORMS_PATTERN, } from '../../../../common/endpoint/constants'; -import type { EndpointFleetServicesInterface } from '../../services/fleet/endpoint_fleet_services_factory'; export interface MetadataRequestContext { esClient?: IScopedClusterClient; @@ -67,44 +52,6 @@ export function getMetadataListRequestHandler( const esClient = (await context.core).elasticsearch.client.asInternalUser; const soClient = (await context.core).savedObjects.client; - let doesUnitedIndexExist = false; - let didUnitedIndexError = false; - let body: MetadataListResponse = { - data: [], - total: 0, - page: 0, - pageSize: 0, - }; - - try { - doesUnitedIndexExist = await endpointMetadataService.doesUnitedIndexExist(esClient); - } catch (error) { - // for better UX, try legacy query instead of immediately failing on united index error - didUnitedIndexError = true; - } - - // If no unified Index present, then perform a search using the legacy approach - if (!doesUnitedIndexExist || didUnitedIndexError) { - const endpointPolicies = await endpointMetadataService.getAllEndpointPackagePolicies(); - - const legacyResponse = await legacyListMetadataQuery( - context, - endpointAppContext, - fleetServices, - logger, - endpointPolicies, - request.query - ); - body = { - data: legacyResponse.hosts, - total: legacyResponse.total, - page: request.query.page || ENDPOINT_DEFAULT_PAGE, - pageSize: request.query.pageSize || ENDPOINT_DEFAULT_PAGE_SIZE, - }; - return response.ok({ body }); - } - - // Unified index is installed and being used - perform search using new approach try { const { data, total } = await endpointMetadataService.getHostMetadataList( esClient, @@ -113,17 +60,17 @@ export function getMetadataListRequestHandler( request.query ); - body = { - data, - total, - page: request.query.page || ENDPOINT_DEFAULT_PAGE, - pageSize: request.query.pageSize || ENDPOINT_DEFAULT_PAGE_SIZE, - }; + return response.ok({ + body: { + data, + total, + page: request.query.page || ENDPOINT_DEFAULT_PAGE, + pageSize: request.query.pageSize || ENDPOINT_DEFAULT_PAGE_SIZE, + }, + }); } catch (error) { return errorHandler(logger, response, error); } - - return response.ok({ body }); }; } @@ -172,163 +119,3 @@ export function getMetadataTransformStatsHandler( } }; } - -export async function mapToHostResultList( - // eslint-disable-next-line @typescript-eslint/no-explicit-any - queryParams: Record, - hostListQueryResult: HostListQueryResult, - metadataRequestContext: MetadataRequestContext -): Promise { - const totalNumberOfHosts = hostListQueryResult.resultLength; - if ((hostListQueryResult.resultList?.length ?? 0) > 0) { - return { - request_page_size: queryParams.size, - request_page_index: queryParams.from, - hosts: await Promise.all( - hostListQueryResult.resultList.map(async (entry) => - enrichHostMetadata(entry, metadataRequestContext) - ) - ), - total: totalNumberOfHosts, - }; - } else { - return { - request_page_size: queryParams.size, - request_page_index: queryParams.from, - total: totalNumberOfHosts, - hosts: [], - }; - } -} - -export async function enrichHostMetadata( - hostMetadata: HostMetadata, - metadataRequestContext: MetadataRequestContext -): Promise { - let hostStatus = HostStatus.UNHEALTHY; - let elasticAgentId = hostMetadata?.elastic?.agent?.id; - const log = metadataRequestContext.logger; - const coreContext = await metadataRequestContext.requestHandlerContext?.core; - - try { - if (!metadataRequestContext.esClient && !coreContext?.elasticsearch.client) { - throw new Error('esClient not found'); - } - - if (!metadataRequestContext.savedObjectsClient && !coreContext?.savedObjects) { - throw new Error('esSavedObjectClient not found'); - } - } catch (e) { - log.error(e); - throw e; - } - - const esSavedObjectClient = - metadataRequestContext?.savedObjectsClient ?? - (coreContext?.savedObjects.client as SavedObjectsClientContract); - const fleetContext = await metadataRequestContext.requestHandlerContext?.fleet; - - try { - /** - * Get agent status by elastic agent id if available or use the endpoint-agent id. - */ - - if (!elasticAgentId) { - elasticAgentId = hostMetadata.agent.id; - log.warn(`Missing elastic agent id, using host id instead ${elasticAgentId}`); - } - - const status = await fleetContext?.agentClient.asCurrentUser.getAgentStatusById(elasticAgentId); - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion - hostStatus = fleetAgentStatusToEndpointHostStatus(status!); - } catch (e) { - if (e instanceof AgentNotFoundError) { - log.warn(`agent with id ${elasticAgentId} not found`); - } else { - log.error(e); - throw e; - } - } - - let policyInfo: HostInfo['policy_info']; - try { - const agent = await fleetContext?.agentClient.asCurrentUser.getAgent(elasticAgentId); - const agentPolicy = await metadataRequestContext.endpointAppContextService - .getAgentPolicyService() - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion - ?.get(esSavedObjectClient, agent?.policy_id!, true); - const endpointPolicy = ((agentPolicy?.package_policies || []) as PackagePolicy[]).find( - (policy: PackagePolicy) => policy.package?.name === 'endpoint' - ); - - policyInfo = { - agent: { - applied: { - revision: agent?.policy_revision || 0, - id: agent?.policy_id || '', - }, - configured: { - revision: agentPolicy?.revision || 0, - id: agentPolicy?.id || '', - }, - }, - endpoint: { - revision: endpointPolicy?.revision || 0, - id: endpointPolicy?.id || '', - }, - }; - } catch (e) { - // this is a non-vital enrichment of expected policy revisions. - // if we fail just fetching these, the rest of the endpoint - // data should still be returned. log the error and move on - log.error(e); - } - - return { - metadata: hostMetadata, - host_status: hostStatus, - policy_info: policyInfo, - }; -} - -async function legacyListMetadataQuery( - context: SecuritySolutionRequestHandlerContext, - endpointAppContext: EndpointAppContext, - fleetServices: EndpointFleetServicesInterface, - logger: Logger, - endpointPolicies: PackagePolicy[], - queryOptions: GetMetadataListRequestQuery -): Promise { - const fleetAgentClient = fleetServices.agent; - const coreContext = await context.core; - - const metadataRequestContext: MetadataRequestContext = { - esClient: coreContext.elasticsearch.client, - endpointAppContextService: endpointAppContext.service, - logger, - requestHandlerContext: context, - savedObjectsClient: coreContext.savedObjects.client, - }; - - const endpointPolicyIds = endpointPolicies.map((policy) => policy.policy_id); - const esClient = coreContext.elasticsearch.client.asInternalUser; - - const unenrolledAgentIds = await findAllUnenrolledAgentIds(fleetAgentClient, endpointPolicyIds); - - const statusAgentIds = await findAgentIdsByStatus( - fleetAgentClient, - queryOptions?.hostStatuses || [] - ); - - const queryParams = await kibanaRequestToMetadataListESQuery({ - page: queryOptions?.page || ENDPOINT_DEFAULT_PAGE, - pageSize: queryOptions?.pageSize || ENDPOINT_DEFAULT_PAGE_SIZE, - kuery: queryOptions?.kuery || '', - unenrolledAgentIds, - statusAgentIds, - }); - - const result = await esClient.search(queryParams); - const hostListQueryResult = queryResponseToHostListResult(result); - return mapToHostResultList(queryParams, hostListQueryResult, metadataRequestContext); -} diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/metadata.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/metadata.test.ts index 38cffe7a99f5a..6a454dbcb759e 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/metadata.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/metadata.test.ts @@ -32,22 +32,18 @@ import { EndpointAppContextService } from '../../endpoint_app_context_services'; import { createMockConfig } from '../../../lib/detection_engine/routes/__mocks__'; import { EndpointDocGenerator } from '../../../../common/endpoint/generate_data'; import type { Agent } from '@kbn/fleet-plugin/common/types/models'; -import { ElasticsearchAssetType } from '@kbn/fleet-plugin/common/types/models'; import { legacyMetadataSearchResponseMock, unitedMetadataSearchResponseMock, } from './support/test_support'; import type { AgentClient, - PackageService, - PackageClient, + AgentPolicyServiceInterface, PackagePolicyClient, } from '@kbn/fleet-plugin/server'; import { HOST_METADATA_GET_ROUTE, HOST_METADATA_LIST_ROUTE, - metadataCurrentIndexPattern, - metadataTransformPrefix, METADATA_TRANSFORMS_STATUS_ROUTE, METADATA_UNITED_INDEX, } from '../../../../common/endpoint/constants'; @@ -60,37 +56,20 @@ import type { } from '@kbn/core-elasticsearch-client-server-mocks'; import { EndpointHostNotFoundError } from '../../services/metadata'; import { FleetAgentGenerator } from '../../../../common/endpoint/data_generators/fleet_agent_generator'; -import { createMockAgentClient, createMockPackageService } from '@kbn/fleet-plugin/server/mocks'; import type { TransformGetTransformStatsResponse } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; import { getEndpointAuthzInitialStateMock } from '../../../../common/endpoint/service/authz/mocks'; -class IndexNotFoundException extends Error { - meta: { body: { error: { type: string } } }; - - constructor() { - super(); - this.meta = { body: { error: { type: 'index_not_found_exception' } } }; - } -} - describe('test endpoint routes', () => { let routerMock: jest.Mocked; let mockResponse: jest.Mocked; let mockClusterClient: ClusterClientMock; let mockScopedClient: ScopedClusterClientMock; let mockSavedObjectClient: jest.Mocked; - let mockPackageService: PackageService; // eslint-disable-next-line @typescript-eslint/no-explicit-any let routeHandler: RequestHandler; // eslint-disable-next-line @typescript-eslint/no-explicit-any let routeConfig: RouteConfig; - // tests assume that fleet is enabled, and thus agentService is available - let mockAgentService: Required< - ReturnType - >['agentService']; - let mockAgentPolicyService: Required< - ReturnType - >['agentPolicyService']; + let mockAgentPolicyService: jest.Mocked; let mockAgentClient: jest.Mocked; let endpointAppContextService: EndpointAppContextService; let startContract: EndpointAppContextServiceStartContract; @@ -112,7 +91,8 @@ describe('test endpoint routes', () => { startContract = createMockEndpointAppContextServiceStartContract(); ( - startContract.packagePolicyService as jest.Mocked + startContract.endpointFleetServicesFactory.asInternalUser() + .packagePolicy as jest.Mocked ).list.mockImplementation(() => { return Promise.resolve({ items: [], @@ -123,37 +103,12 @@ describe('test endpoint routes', () => { }); endpointAppContextService = new EndpointAppContextService(); - mockPackageService = createMockPackageService(); - const mockPackageClient = mockPackageService.asInternalUser as jest.Mocked; - mockPackageClient.getInstallation.mockResolvedValue({ - installed_kibana: [], - package_assets: [], - es_index_patterns: {}, - name: '', - version: '', - install_status: 'installed', - install_version: '', - install_started_at: '', - install_source: 'registry', - installed_es: [ - { - id: 'logs-endpoint.events.security', - type: ElasticsearchAssetType.indexTemplate, - }, - { - id: `${metadataTransformPrefix}-0.16.0-dev.0`, - type: ElasticsearchAssetType.transform, - }, - ], - keep_policies_up_to_date: false, - verification_status: 'unknown', - }); endpointAppContextService.setup(createMockEndpointAppContextServiceSetupContract()); - endpointAppContextService.start({ ...startContract, packageService: mockPackageService }); - mockAgentService = startContract.agentService!; - mockAgentClient = createMockAgentClient(); - mockAgentService.asInternalUser = mockAgentClient; - mockAgentPolicyService = startContract.agentPolicyService!; + endpointAppContextService.start({ ...startContract }); + mockAgentClient = startContract.endpointFleetServicesFactory.asInternalUser() + .agent as jest.Mocked; + mockAgentPolicyService = startContract.endpointFleetServicesFactory.asInternalUser() + .agentPolicy as jest.Mocked; registerEndpointRoutes(routerMock, { logFactory: loggingSystemMock.create(), @@ -166,338 +121,110 @@ describe('test endpoint routes', () => { afterEach(() => endpointAppContextService.stop()); describe('GET list endpoints route', () => { - describe('with .metrics-endpoint.metadata_united_default index', () => { - it('should fallback to legacy index if index not found', async () => { - const mockRequest = httpServerMock.createKibanaRequest({ - query: { - page: 0, - pageSize: 10, - }, - }); - const response = legacyMetadataSearchResponseMock( - new EndpointDocGenerator().generateHostMetadata() - ); - const esSearchMock = mockScopedClient.asInternalUser.search; - esSearchMock - .mockImplementationOnce(() => { - throw new IndexNotFoundException(); - }) - .mockResponseImplementationOnce(() => ({ body: response })); - [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => - path.startsWith(HOST_METADATA_LIST_ROUTE) - )!; - mockAgentClient.getAgentStatusById.mockResolvedValue('error'); - mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); - await routeHandler( - createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), - mockRequest, - mockResponse - ); - - // should be called twice, united index first, then legacy index - expect(esSearchMock).toHaveBeenCalledTimes(2); - expect(esSearchMock.mock.calls[0][0]?.index).toEqual(METADATA_UNITED_INDEX); - expect(esSearchMock.mock.calls[1][0]?.index).toEqual(metadataCurrentIndexPattern); - expect(routeConfig.options).toEqual({ - authRequired: true, - tags: ['access:securitySolution'], - }); - expect(mockResponse.ok).toBeCalled(); - const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; - expect(endpointResultList.data.length).toEqual(1); - expect(endpointResultList.total).toEqual(1); - expect(endpointResultList.page).toEqual(0); - expect(endpointResultList.pageSize).toEqual(10); + it('should return expected metadata', async () => { + const mockRequest = httpServerMock.createKibanaRequest({ + query: { + page: 0, + pageSize: 10, + hostStatuses: ['updating'], + kuery: 'not host.ip:10.140.73.246', + }, + }); + mockSavedObjectClient.find.mockResolvedValueOnce({ + total: 0, + saved_objects: [], + page: 1, + per_page: 10, }); + mockAgentClient.getAgentStatusById.mockResolvedValue('error'); + mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); + mockAgentPolicyService.getByIds = jest.fn().mockResolvedValueOnce([]); + const metadata = new EndpointDocGenerator().generateHostMetadata(); + const esSearchMock = mockScopedClient.asInternalUser.search; + esSearchMock.mockResponseOnce(unitedMetadataSearchResponseMock(metadata)); + [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => + path.startsWith(HOST_METADATA_LIST_ROUTE) + )!; - it('should return expected metadata', async () => { - const mockRequest = httpServerMock.createKibanaRequest({ - query: { - page: 0, - pageSize: 10, - hostStatuses: ['updating'], - kuery: 'not host.ip:10.140.73.246', - }, - }); - mockSavedObjectClient.find.mockResolvedValueOnce({ - total: 0, - saved_objects: [], - page: 1, - per_page: 10, - }); - mockAgentClient.getAgentStatusById.mockResolvedValue('error'); - mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); - mockAgentPolicyService.getByIds = jest.fn().mockResolvedValueOnce([]); - const metadata = new EndpointDocGenerator().generateHostMetadata(); - const esSearchMock = mockScopedClient.asInternalUser.search; - // @ts-expect-error incorrect type - esSearchMock.mockResponseOnce(undefined); - esSearchMock.mockResponseOnce(unitedMetadataSearchResponseMock(metadata)); - [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => - path.startsWith(HOST_METADATA_LIST_ROUTE) - )!; - - await routeHandler( - createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), - mockRequest, - mockResponse - ); - - expect(esSearchMock).toHaveBeenCalledTimes(2); - expect(esSearchMock.mock.calls[0][0]?.index).toEqual(METADATA_UNITED_INDEX); - // @ts-expect-error size not defined as top level property when using typesWithBodyKey - expect(esSearchMock.mock.calls[0][0]?.size).toEqual(1); - expect(esSearchMock.mock.calls[1][0]?.index).toEqual(METADATA_UNITED_INDEX); - // @ts-expect-error partial definition - expect(esSearchMock.mock.calls[1][0]?.body?.query).toEqual({ - bool: { - must: [ - { - bool: { - must_not: { - terms: { - 'agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - ], - }, + await routeHandler( + createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), + mockRequest, + mockResponse + ); + + expect(esSearchMock).toHaveBeenCalledTimes(1); + expect(esSearchMock.mock.calls[0][0]?.index).toEqual(METADATA_UNITED_INDEX); + // @ts-expect-error partial definition + expect(esSearchMock.mock.calls[0][0]?.body?.query).toEqual({ + bool: { + must: [ + { + bool: { + must_not: { + terms: { + 'agent.id': [ + '00000000-0000-0000-0000-000000000000', + '11111111-1111-1111-1111-111111111111', + ], }, - filter: [ - { terms: { 'united.agent.policy_id': [] } }, - { exists: { field: 'united.endpoint.agent.id' } }, - { exists: { field: 'united.agent.agent.id' } }, - { term: { 'united.agent.active': { value: true } } }, - ], }, + filter: [ + { terms: { 'united.agent.policy_id': [] } }, + { exists: { field: 'united.endpoint.agent.id' } }, + { exists: { field: 'united.agent.agent.id' } }, + { term: { 'united.agent.active': { value: true } } }, + ], }, - { - bool: { - should: [ - { - bool: { - should: [{ match: { status: 'updating' } }], - minimum_should_match: 1, - }, - }, - { - bool: { - should: [{ match: { status: 'unenrolling' } }], - minimum_should_match: 1, - }, - }, - { - bool: { - should: [{ match: { status: 'enrolling' } }], - minimum_should_match: 1, - }, + }, + { + bool: { + should: [ + { + bool: { + should: [{ match: { status: 'updating' } }], + minimum_should_match: 1, }, - ], - minimum_should_match: 1, - }, - }, - { - bool: { - must_not: { + }, + { bool: { - should: [{ match: { 'host.ip': '10.140.73.246' } }], + should: [{ match: { status: 'unenrolling' } }], minimum_should_match: 1, }, }, - }, - }, - ], - }, - }); - expect(routeConfig.options).toEqual({ - authRequired: true, - tags: ['access:securitySolution'], - }); - expect(mockResponse.ok).toBeCalled(); - const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; - expect(endpointResultList.data.length).toEqual(1); - expect(endpointResultList.data[0].metadata).toEqual(metadata); - expect(endpointResultList.total).toEqual(1); - expect(endpointResultList.page).toEqual(0); - expect(endpointResultList.pageSize).toEqual(10); - }); - }); - - describe('with metrics-endpoint.metadata_current_default index', () => { - it('test find the latest of all endpoints', async () => { - const mockRequest = httpServerMock.createKibanaRequest({ - query: { - page: 0, - pageSize: 10, - }, - }); - const response = legacyMetadataSearchResponseMock( - new EndpointDocGenerator().generateHostMetadata() - ); - const esSearchMock = mockScopedClient.asInternalUser.search; - esSearchMock - .mockImplementationOnce(() => { - throw new IndexNotFoundException(); - }) - .mockResponseOnce(response); - [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => - path.startsWith(HOST_METADATA_LIST_ROUTE) - )!; - mockAgentClient.getAgentStatusById.mockResolvedValue('error'); - mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); - await routeHandler( - createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), - mockRequest, - mockResponse - ); - - expect(esSearchMock).toHaveBeenCalledTimes(2); - expect(routeConfig.options).toEqual({ - authRequired: true, - tags: ['access:securitySolution'], - }); - expect(mockResponse.ok).toBeCalled(); - const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; - expect(endpointResultList.data.length).toEqual(1); - expect(endpointResultList.total).toEqual(1); - expect(endpointResultList.page).toEqual(0); - expect(endpointResultList.pageSize).toEqual(10); - }); - - it('test find the latest of all endpoints with paging properties', async () => { - const mockRequest = httpServerMock.createKibanaRequest({ - query: { - page: 1, - pageSize: 10, - }, - }); - const esSearchMock = mockScopedClient.asInternalUser.search; - - mockAgentClient.getAgentStatusById.mockResolvedValue('error'); - mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); - esSearchMock - .mockImplementationOnce(() => { - throw new IndexNotFoundException(); - }) - .mockResponseOnce( - legacyMetadataSearchResponseMock(new EndpointDocGenerator().generateHostMetadata()) - ); - [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => - path.startsWith(HOST_METADATA_LIST_ROUTE) - )!; - - await routeHandler( - createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), - mockRequest, - mockResponse - ); - expect(esSearchMock).toHaveBeenCalledTimes(2); - // @ts-expect-error partial definition - expect(esSearchMock.mock.calls[1][0]?.body?.query.bool.must_not).toContainEqual({ - terms: { - 'elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - ], - }, - }); - expect(routeConfig.options).toEqual({ - authRequired: true, - tags: ['access:securitySolution'], - }); - expect(mockResponse.ok).toBeCalled(); - const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; - expect(endpointResultList.data.length).toEqual(1); - expect(endpointResultList.total).toEqual(1); - expect(endpointResultList.page).toEqual(1); - expect(endpointResultList.pageSize).toEqual(10); - }); - - it('test find the latest of all endpoints with paging and filters properties', async () => { - const mockRequest = httpServerMock.createKibanaRequest({ - query: { - page: 1, - pageSize: 10, - kuery: 'not host.ip:10.140.73.246', - }, - }); - const esSearchMock = mockScopedClient.asInternalUser.search; - - mockAgentClient.getAgentStatusById.mockResolvedValue('error'); - mockAgentClient.listAgents.mockResolvedValue(noUnenrolledAgent); - esSearchMock - .mockImplementationOnce(() => { - throw new IndexNotFoundException(); - }) - .mockResponseOnce( - legacyMetadataSearchResponseMock(new EndpointDocGenerator().generateHostMetadata()) - ); - [routeConfig, routeHandler] = routerMock.get.mock.calls.find(([{ path }]) => - path.startsWith(HOST_METADATA_LIST_ROUTE) - )!; - - await routeHandler( - createRouteHandlerContext(mockScopedClient, mockSavedObjectClient), - mockRequest, - mockResponse - ); - - expect(esSearchMock).toBeCalled(); - expect( - // KQL filter to be passed through - // @ts-expect-error partial definition - esSearchMock.mock.calls[1][0]?.body?.query.bool.must - ).toContainEqual({ - bool: { - must_not: { - bool: { - should: [ { - match: { - 'host.ip': '10.140.73.246', + bool: { + should: [{ match: { status: 'enrolling' } }], + minimum_should_match: 1, }, }, ], minimum_should_match: 1, }, }, - }, - }); - // @ts-expect-error partial definition - expect(esSearchMock.mock.calls[1][0]?.body?.query.bool.must).toContainEqual({ - bool: { - must_not: [ - { - terms: { - 'elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - ], - }, - }, - { - terms: { - // here we DO want to see both schemas are present - // to make this schema-compatible forward and back - 'HostDetails.elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - ], + { + bool: { + must_not: { + bool: { + should: [{ match: { 'host.ip': '10.140.73.246' } }], + minimum_should_match: 1, + }, }, }, - ], - }, - }); - expect(routeConfig.options).toEqual({ - authRequired: true, - tags: ['access:securitySolution'], - }); - expect(mockResponse.ok).toBeCalled(); - const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; - expect(endpointResultList.data.length).toEqual(1); - expect(endpointResultList.total).toEqual(1); - expect(endpointResultList.page).toEqual(1); - expect(endpointResultList.pageSize).toEqual(10); + }, + ], + }, + }); + expect(routeConfig.options).toEqual({ + authRequired: true, + tags: ['access:securitySolution'], }); + expect(mockResponse.ok).toBeCalled(); + const endpointResultList = mockResponse.ok.mock.calls[0][0]?.body as MetadataListResponse; + expect(endpointResultList.data.length).toEqual(1); + expect(endpointResultList.data[0].metadata).toEqual(metadata); + expect(endpointResultList.total).toEqual(1); + expect(endpointResultList.page).toEqual(0); + expect(endpointResultList.pageSize).toEqual(10); }); it('should get forbidden if no security solution access', async () => { diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.test.ts index 89651d221285f..bfdc8022e5ca2 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.test.ts @@ -5,169 +5,13 @@ * 2.0. */ -import { - kibanaRequestToMetadataListESQuery, - getESQueryHostMetadataByID, - buildUnitedIndexQuery, -} from './query_builders'; +import { getESQueryHostMetadataByID, buildUnitedIndexQuery } from './query_builders'; import { metadataCurrentIndexPattern } from '../../../../common/endpoint/constants'; import { get } from 'lodash'; import { expectedCompleteUnitedIndexQuery } from './query_builders.fixtures'; import { savedObjectsClientMock } from '@kbn/core/server/mocks'; describe('query builder', () => { - describe('MetadataListESQuery', () => { - it('queries the correct index', async () => { - const query = await kibanaRequestToMetadataListESQuery({ - page: 0, - pageSize: 10, - kuery: '', - unenrolledAgentIds: [], - statusAgentIds: [], - }); - expect(query.index).toEqual(metadataCurrentIndexPattern); - }); - - it('sorts using *event.created', async () => { - const query = await kibanaRequestToMetadataListESQuery({ - page: 0, - pageSize: 10, - kuery: '', - unenrolledAgentIds: [], - statusAgentIds: [], - }); - expect(query.body.sort).toContainEqual({ - 'event.created': { - order: 'desc', - unmapped_type: 'date', - }, - }); - expect(query.body.sort).toContainEqual({ - 'HostDetails.event.created': { - order: 'desc', - unmapped_type: 'date', - }, - }); - }); - - it('excludes unenrolled elastic agents when they exist, by default', async () => { - const unenrolledElasticAgentId = '1fdca33f-799f-49f4-939c-ea4383c77672'; - const query = await kibanaRequestToMetadataListESQuery({ - page: 0, - pageSize: 10, - kuery: '', - unenrolledAgentIds: [unenrolledElasticAgentId], - statusAgentIds: [], - }); - - expect(query.body.query).toEqual({ - bool: { - must_not: [ - { - terms: { - 'elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - unenrolledElasticAgentId, - ], - }, - }, - { - terms: { - 'HostDetails.elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - unenrolledElasticAgentId, - ], - }, - }, - ], - }, - }); - }); - }); - - describe('test query builder with kql filter', () => { - it('test default query params for all endpoints metadata when body filter is provided', async () => { - const query = await kibanaRequestToMetadataListESQuery({ - page: 0, - pageSize: 10, - kuery: 'not host.ip:10.140.73.246', - unenrolledAgentIds: [], - statusAgentIds: [], - }); - - expect(query.body.query.bool.must).toContainEqual({ - bool: { - must_not: { - bool: { - should: [ - { - match: { - 'host.ip': '10.140.73.246', - }, - }, - ], - minimum_should_match: 1, - }, - }, - }, - }); - }); - - it( - 'test default query params for all endpoints endpoint metadata excluding unerolled endpoint ' + - 'and when body filter is provided', - async () => { - const unenrolledElasticAgentId = '1fdca33f-799f-49f4-939c-ea4383c77672'; - const query = await kibanaRequestToMetadataListESQuery({ - page: 0, - pageSize: 10, - kuery: 'not host.ip:10.140.73.246', - unenrolledAgentIds: [unenrolledElasticAgentId], - statusAgentIds: [], - }); - - expect(query.body.query.bool.must).toEqual([ - { - bool: { - must_not: [ - { - terms: { - 'elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - '1fdca33f-799f-49f4-939c-ea4383c77672', - ], - }, - }, - { - terms: { - 'HostDetails.elastic.agent.id': [ - '00000000-0000-0000-0000-000000000000', - '11111111-1111-1111-1111-111111111111', - '1fdca33f-799f-49f4-939c-ea4383c77672', - ], - }, - }, - ], - }, - }, - { - bool: { - must_not: { - bool: { - minimum_should_match: 1, - should: [{ match: { 'host.ip': '10.140.73.246' } }], - }, - }, - }, - }, - ]); - } - ); - }); - describe('MetadataGetQuery', () => { it('searches the correct index', () => { const query = getESQueryHostMetadataByID('nonsense-id'); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.ts index ede30e7491fb7..171212690617a 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/query_builders.ts @@ -55,84 +55,6 @@ export const MetadataSortMethod: estypes.SortCombinations[] = [ }, ]; -export async function kibanaRequestToMetadataListESQuery( - queryBuilderOptions: QueryBuilderOptions - // eslint-disable-next-line @typescript-eslint/no-explicit-any -): Promise> { - return { - body: { - query: buildQueryBody( - queryBuilderOptions?.kuery, - IGNORED_ELASTIC_AGENT_IDS.concat(queryBuilderOptions?.unenrolledAgentIds ?? []), - queryBuilderOptions?.statusAgentIds - ), - track_total_hits: true, - sort: MetadataSortMethod, - }, - from: queryBuilderOptions.page * queryBuilderOptions.pageSize, - size: queryBuilderOptions.pageSize, - index: metadataCurrentIndexPattern, - }; -} - -function buildQueryBody( - kuery: string = '', - unerolledAgentIds: string[] | undefined, - statusAgentIds: string[] | undefined - // eslint-disable-next-line @typescript-eslint/no-explicit-any -): Record { - // the filtered properties may be preceded by 'HostDetails' under an older index mapping - const filterUnenrolledAgents = - unerolledAgentIds && unerolledAgentIds.length > 0 - ? { - must_not: [ - { terms: { 'elastic.agent.id': unerolledAgentIds } }, // OR - { terms: { 'HostDetails.elastic.agent.id': unerolledAgentIds } }, - ], - } - : null; - const filterStatusAgents = - statusAgentIds && statusAgentIds.length - ? { - filter: [ - { - bool: { - // OR's the two together - should: [ - { terms: { 'elastic.agent.id': statusAgentIds } }, - { terms: { 'HostDetails.elastic.agent.id': statusAgentIds } }, - ], - }, - }, - ], - } - : null; - - const idFilter = { - bool: { - ...filterUnenrolledAgents, - ...filterStatusAgents, - }, - }; - - if (kuery) { - const kqlQuery = toElasticsearchQuery(fromKueryExpression(kuery)); - const q = []; - if (filterUnenrolledAgents || filterStatusAgents) { - q.push(idFilter); - } - q.push({ ...kqlQuery }); - return { - bool: { must: q }, - }; - } - return filterUnenrolledAgents || filterStatusAgents - ? idFilter - : { - match_all: {}, - }; -} - export function getESQueryHostMetadataByID(agentID: string): estypes.SearchRequest { return { body: { diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.test.ts index 2a78a2a1e322e..10431421d4c9f 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.test.ts @@ -5,134 +5,50 @@ * 2.0. */ -import { buildStatusesKuery, findAgentIdsByStatus } from './agent_status'; -import type { AgentClient } from '@kbn/fleet-plugin/server/services'; -import { createMockAgentClient } from '@kbn/fleet-plugin/server/mocks'; -import type { Agent } from '@kbn/fleet-plugin/common/types/models'; -import { AgentStatusKueryHelper } from '@kbn/fleet-plugin/common/services'; +import { buildStatusesKuery } from './agent_status'; -describe('test filtering endpoint hosts by agent status', () => { - let mockAgentClient: jest.Mocked; - beforeEach(() => { - mockAgentClient = createMockAgentClient(); +describe('buildStatusesKuery', () => { + it('correctly builds kuery for healthy status', () => { + const status = ['healthy']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot(`"(status:online)"`); }); - it('will accept a valid status condition', async () => { - mockAgentClient.listAgents.mockImplementationOnce(() => - Promise.resolve({ - agents: [], - total: 0, - page: 1, - perPage: 10, - }) - ); - - const result = await findAgentIdsByStatus(mockAgentClient, ['healthy']); - expect(result).toBeDefined(); + it('correctly builds kuery for offline status', () => { + const status = ['offline']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot(`"(status:offline)"`); }); - it('will filter for offline hosts', async () => { - mockAgentClient.listAgents - .mockImplementationOnce(() => - Promise.resolve({ - agents: [{ id: 'id1' } as unknown as Agent, { id: 'id2' } as unknown as Agent], - total: 2, - page: 1, - perPage: 2, - }) - ) - .mockImplementationOnce(() => - Promise.resolve({ - agents: [], - total: 2, - page: 2, - perPage: 2, - }) - ); - - const result = await findAgentIdsByStatus(mockAgentClient, ['offline']); - const offlineKuery = AgentStatusKueryHelper.buildKueryForOfflineAgents(); - expect(mockAgentClient.listAgents.mock.calls[0][0].kuery).toEqual( - expect.stringContaining(offlineKuery) - ); - expect(result).toBeDefined(); - expect(result).toEqual(['id1', 'id2']); + it('correctly builds kuery for unhealthy status', () => { + const status = ['unhealthy']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot(`"((status:error or status:degraded))"`); }); - it('will filter for multiple statuses', async () => { - mockAgentClient.listAgents - .mockImplementationOnce(() => - Promise.resolve({ - agents: [{ id: 'A' } as unknown as Agent, { id: 'B' } as unknown as Agent], - total: 2, - page: 1, - perPage: 2, - }) - ) - .mockImplementationOnce(() => - Promise.resolve({ - agents: [], - total: 2, - page: 2, - perPage: 2, - }) - ); - - const result = await findAgentIdsByStatus(mockAgentClient, ['updating', 'unhealthy']); - const unenrollKuery = AgentStatusKueryHelper.buildKueryForUpdatingAgents(); - const errorKuery = AgentStatusKueryHelper.buildKueryForErrorAgents(); - expect(mockAgentClient.listAgents.mock.calls[0][0].kuery).toEqual( - expect.stringContaining(`${unenrollKuery} OR ${errorKuery}`) + it('correctly builds kuery for updating status', () => { + const status = ['updating']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot( + `"((status:updating or status:unenrolling or status:enrolling))"` ); - expect(result).toBeDefined(); - expect(result).toEqual(['A', 'B']); }); - describe('buildStatusesKuery', () => { - it('correctly builds kuery for healthy status', () => { - const status = ['healthy']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot(`"(status:online)"`); - }); - - it('correctly builds kuery for offline status', () => { - const status = ['offline']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot(`"(status:offline)"`); - }); - - it('correctly builds kuery for unhealthy status', () => { - const status = ['unhealthy']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot(`"((status:error or status:degraded))"`); - }); - - it('correctly builds kuery for updating status', () => { - const status = ['updating']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot( - `"((status:updating or status:unenrolling or status:enrolling))"` - ); - }); - - it('correctly builds kuery for inactive status', () => { - const status = ['inactive']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot(`"(status:inactive)"`); - }); + it('correctly builds kuery for inactive status', () => { + const status = ['inactive']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot(`"(status:inactive)"`); + }); - it('correctly builds kuery for unenrolled status', () => { - const status = ['unenrolled']; - const kuery = buildStatusesKuery(status); - expect(kuery).toMatchInlineSnapshot(`"(status:unenrolled)"`); - }); + it('correctly builds kuery for unenrolled status', () => { + const status = ['unenrolled']; + const kuery = buildStatusesKuery(status); + expect(kuery).toMatchInlineSnapshot(`"(status:unenrolled)"`); + }); - it('correctly builds kuery for multiple statuses', () => { - const statuses = ['offline', 'unhealthy']; - const kuery = buildStatusesKuery(statuses); - expect(kuery).toMatchInlineSnapshot( - `"(status:offline OR (status:error or status:degraded))"` - ); - }); + it('correctly builds kuery for multiple statuses', () => { + const statuses = ['offline', 'unhealthy']; + const kuery = buildStatusesKuery(statuses); + expect(kuery).toMatchInlineSnapshot(`"(status:offline OR (status:error or status:degraded))"`); }); }); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.ts index 803975dad7f66..2676de0bc6215 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/agent_status.ts @@ -5,9 +5,7 @@ * 2.0. */ -import type { AgentClient } from '@kbn/fleet-plugin/server'; import { AgentStatusKueryHelper } from '@kbn/fleet-plugin/common/services'; -import type { Agent } from '@kbn/fleet-plugin/common/types/models'; import { HostStatus } from '../../../../../common/endpoint/types'; const STATUS_QUERY_MAP = new Map([ @@ -30,34 +28,3 @@ export function buildStatusesKuery(statusesToFilter: string[]): string | undefin return `(${statusQueries.join(' OR ')})`; } - -export async function findAgentIdsByStatus( - agentClient: AgentClient, - statuses: string[], - pageSize: number = 1000 -): Promise { - if (!statuses.length) { - return []; - } - const helpers = statuses.map((s) => STATUS_QUERY_MAP.get(s)); - const searchOptions = (pageNum: number) => { - return { - page: pageNum, - perPage: pageSize, - showInactive: true, - kuery: `(packages : "endpoint" AND (${helpers.join(' OR ')}))`, - }; - }; - - let page = 1; - - const result: string[] = []; - let hasMore = true; - - while (hasMore) { - const agents = await agentClient.listAgents(searchOptions(page++)); - result.push(...agents.agents.map((agent: Agent) => agent.id)); - hasMore = agents.agents.length > 0; - } - return result; -} diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.test.ts deleted file mode 100644 index 768ae52b35a42..0000000000000 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.test.ts +++ /dev/null @@ -1,91 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { findAllUnenrolledAgentIds } from './unenroll'; -import type { AgentClient } from '@kbn/fleet-plugin/server/services'; -import { - createMockAgentClient, - createPackagePolicyServiceMock, -} from '@kbn/fleet-plugin/server/mocks'; -import type { Agent, PackagePolicy } from '@kbn/fleet-plugin/common/types/models'; -import type { PackagePolicyClient } from '@kbn/fleet-plugin/server'; - -describe('test find all unenrolled Agent id', () => { - let mockAgentClient: jest.Mocked; - let mockPackagePolicyService: jest.Mocked; - - beforeEach(() => { - mockAgentClient = createMockAgentClient(); - mockPackagePolicyService = createPackagePolicyServiceMock(); - }); - - it('can find all unerolled endpoint agent ids', async () => { - mockPackagePolicyService.list - .mockResolvedValueOnce({ - items: [ - { - id: '1', - policy_id: 'abc123', - } as unknown as PackagePolicy, - ], - total: 1, - perPage: 10, - page: 1, - }) - .mockResolvedValueOnce({ - items: [], - total: 1, - perPage: 10, - page: 1, - }); - mockAgentClient.listAgents - .mockImplementationOnce(() => - Promise.resolve({ - agents: [ - { - id: 'id1', - } as unknown as Agent, - ], - total: 2, - page: 1, - perPage: 1, - }) - ) - .mockImplementationOnce(() => - Promise.resolve({ - agents: [ - { - id: 'id2', - } as unknown as Agent, - ], - total: 2, - page: 1, - perPage: 1, - }) - ) - .mockImplementationOnce(() => - Promise.resolve({ - agents: [], - total: 2, - page: 1, - perPage: 1, - }) - ); - const endpointPolicyIds = ['test-endpoint-policy-id']; - const agentIds = await findAllUnenrolledAgentIds(mockAgentClient, endpointPolicyIds); - - expect(agentIds).toBeTruthy(); - expect(agentIds).toEqual(['id1', 'id2']); - - expect(mockAgentClient.listAgents).toHaveBeenNthCalledWith(1, { - page: 1, - perPage: 1000, - showInactive: true, - kuery: `(active : false) OR (active: true AND NOT policy_id:("${endpointPolicyIds[0]}"))`, - }); - }); -}); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.ts b/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.ts deleted file mode 100644 index 6f5ac098cf154..0000000000000 --- a/x-pack/plugins/security_solution/server/endpoint/routes/metadata/support/unenroll.ts +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import type { AgentClient } from '@kbn/fleet-plugin/server'; -import type { Agent } from '@kbn/fleet-plugin/common/types/models'; - -export async function findAllUnenrolledAgentIds( - agentClient: AgentClient, - endpointPolicyIds: string[], - pageSize: number = 1000 -): Promise { - // We want: - // 1. if no endpoint policies exist, then get all Agents - // 2. if we have a list of agent policies, then Agents that are Active and that are - // NOT enrolled with an Agent Policy that has endpoint - const kuery = - endpointPolicyIds.length > 0 - ? `(active : false) OR (active: true AND NOT policy_id:("${endpointPolicyIds.join( - '" OR "' - )}"))` - : undefined; - - const searchOptions = (pageNum: number) => { - return { - page: pageNum, - perPage: pageSize, - showInactive: true, - kuery, - }; - }; - - let page = 1; - - const result: string[] = []; - let hasMore = true; - - while (hasMore) { - const unenrolledAgents = await agentClient.listAgents(searchOptions(page++)); - result.push(...unenrolledAgents.agents.map((agent: Agent) => agent.id)); - hasMore = unenrolledAgents.agents.length > 0; - } - return result; -} diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/policy/handlers.test.ts b/x-pack/plugins/security_solution/server/endpoint/routes/policy/handlers.test.ts index e92f316f7c125..c8ea7bbbedb48 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/policy/handlers.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/policy/handlers.test.ts @@ -11,7 +11,6 @@ import { createMockEndpointAppContextServiceStartContract, createRouteHandlerContext, } from '../../mocks'; -import { createMockAgentClient, createMockAgentService } from '@kbn/fleet-plugin/server/mocks'; import { getHostPolicyResponseHandler, getAgentPolicySummaryHandler } from './handlers'; import type { KibanaResponseFactory, SavedObjectsClientContract } from '@kbn/core/server'; import { @@ -29,7 +28,7 @@ import { requestContextMock, } from '../../../lib/detection_engine/routes/__mocks__'; import type { Agent } from '@kbn/fleet-plugin/common/types/models'; -import type { AgentClient, AgentService } from '@kbn/fleet-plugin/server/services'; +import type { AgentClient } from '@kbn/fleet-plugin/server/services'; import { get } from 'lodash'; import type { ScopedClusterClientMock } from '@kbn/core-elasticsearch-client-server-mocks'; @@ -99,7 +98,6 @@ describe('test policy response handler', () => { }); describe('test agent policy summary handler', () => { - let mockAgentService: jest.Mocked; let mockAgentClient: jest.Mocked; let agentListResult: { @@ -121,9 +119,6 @@ describe('test policy response handler', () => { mockSavedObjectClient = savedObjectsClientMock.create(); mockResponse = httpServerMock.createResponseFactory(); endpointAppContextService = new EndpointAppContextService(); - mockAgentService = createMockAgentService(); - mockAgentClient = createMockAgentClient(); - mockAgentService.asScoped.mockReturnValue(mockAgentClient); emptyAgentListResult = { agents: [], total: 2, @@ -168,8 +163,9 @@ describe('test policy response handler', () => { endpointAppContextService.setup(createMockEndpointAppContextServiceSetupContract()); endpointAppContextService.start({ ...createMockEndpointAppContextServiceStartContract(), - ...{ agentService: mockAgentService }, }); + mockAgentClient = endpointAppContextService.getInternalFleetServices() + .agent as jest.Mocked; }); afterEach(() => endpointAppContextService.stop()); diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/policy/index.ts b/x-pack/plugins/security_solution/server/endpoint/routes/policy/index.ts index 568a61d2691d8..5bd30cbb77d78 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/policy/index.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/policy/index.ts @@ -36,6 +36,11 @@ export function registerPolicyRoutes(router: IRouter, endpointAppContext: Endpoi ) ); + /** + * @deprecated + * @removeBy 9.0.0 + * + */ router.get( { path: AGENT_POLICY_SUMMARY_ROUTE, diff --git a/x-pack/plugins/security_solution/server/endpoint/routes/policy/service.ts b/x-pack/plugins/security_solution/server/endpoint/routes/policy/service.ts index 1afafa2b61245..8ec7664ba2c0d 100644 --- a/x-pack/plugins/security_solution/server/endpoint/routes/policy/service.ts +++ b/x-pack/plugins/security_solution/server/endpoint/routes/policy/service.ts @@ -113,11 +113,9 @@ export async function agentVersionsMap( const result: Map = new Map(); let hasMore = true; while (hasMore) { - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion const queryResult = await endpointAppContext.service - .getAgentService()! - .asScoped(request) - .listAgents(searchOptions(page++)); + .getInternalFleetServices() + .agent.listAgents(searchOptions(page++)); queryResult.agents.forEach((agent: Agent) => { const agentVersion = agent.local_metadata?.elastic?.agent?.version; if (result.has(agentVersion)) { diff --git a/x-pack/plugins/security_solution/server/endpoint/services/actions/utils.test.ts b/x-pack/plugins/security_solution/server/endpoint/services/actions/utils.test.ts index cd97bf96673bf..98797c3a7cc67 100644 --- a/x-pack/plugins/security_solution/server/endpoint/services/actions/utils.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/services/actions/utils.test.ts @@ -29,7 +29,7 @@ import type { LogsEndpointAction, LogsEndpointActionResponse, } from '../../../../common/endpoint/types'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Results } from '../../routes/actions/mocks'; import { mockAuditLogSearchResult } from '../../routes/actions/mocks'; @@ -230,7 +230,7 @@ describe('When using Actions service utilities', () => { let endpointResponseAtError: EndpointActivityLogActionResponse; beforeEach(() => { - const actionId = uuid.v4(); + const actionId = uuidv4(); fleetResponseAtError = fleetActionGenerator.generateActivityLogActionResponse({ item: { data: { agent_id: '123', action_id: actionId, error: 'agent failed to deliver' }, @@ -326,7 +326,7 @@ describe('When using Actions service utilities', () => { beforeEach(() => { agentIds = ['123', '456', '789']; - actionId = uuid.v4(); + actionId = uuidv4(); action123Responses = [ fleetActionGenerator.generateActivityLogActionResponse({ item: { data: { agent_id: '123', error: '', action_id: actionId } }, @@ -599,8 +599,8 @@ describe('When using Actions service utilities', () => { let errorResponses: Array; beforeEach(() => { - const actionId0 = uuid.v4(); - const actionId1 = uuid.v4(); + const actionId0 = uuidv4(); + const actionId1 = uuidv4(); actionRequests123 = [ fleetActionGenerator.generateActivityLogAction({ item: { @@ -723,7 +723,7 @@ describe('When using Actions service utilities', () => { beforeEach(() => { const agents = ['agent-id']; - const actionIds = [uuid.v4(), uuid.v4()]; + const actionIds = [uuidv4(), uuidv4()]; fleetActions = actionIds.map((id) => { return { diff --git a/x-pack/plugins/security_solution/server/endpoint/services/fleet/endpoint_fleet_services_factory.ts b/x-pack/plugins/security_solution/server/endpoint/services/fleet/endpoint_fleet_services_factory.ts index 807a04e716fc8..658ff9f2a327e 100644 --- a/x-pack/plugins/security_solution/server/endpoint/services/fleet/endpoint_fleet_services_factory.ts +++ b/x-pack/plugins/security_solution/server/endpoint/services/fleet/endpoint_fleet_services_factory.ts @@ -5,11 +5,7 @@ * 2.0. */ -import type { - KibanaRequest, - SavedObjectsClientContract, - SavedObjectsServiceStart, -} from '@kbn/core/server'; +import type { SavedObjectsClientContract, SavedObjectsServiceStart } from '@kbn/core/server'; import type { AgentClient, AgentPolicyServiceInterface, @@ -20,8 +16,6 @@ import type { import { createInternalReadonlySoClient } from '../../utils/create_internal_readonly_so_client'; export interface EndpointFleetServicesFactoryInterface { - asScoped(req: KibanaRequest): EndpointScopedFleetServicesInterface; - asInternalUser(): EndpointInternalFleetServicesInterface; } @@ -34,24 +28,6 @@ export class EndpointFleetServicesFactory implements EndpointFleetServicesFactor private savedObjectsStart: SavedObjectsServiceStart ) {} - asScoped(req: KibanaRequest): EndpointScopedFleetServicesInterface { - const { - agentPolicyService: agentPolicy, - packagePolicyService: packagePolicy, - agentService, - packageService, - } = this.fleetDependencies; - - return { - agent: agentService.asScoped(req), - agentPolicy, - packages: packageService.asScoped(req), - packagePolicy, - - asInternal: this.asInternalUser.bind(this), - }; - } - asInternalUser(): EndpointInternalFleetServicesInterface { const { agentPolicyService: agentPolicy, @@ -66,7 +42,6 @@ export class EndpointFleetServicesFactory implements EndpointFleetServicesFactor packages: packageService.asInternalUser, packagePolicy, - asScoped: this.asScoped.bind(this), internalReadonlySoClient: createInternalReadonlySoClient(this.savedObjectsStart), }; } @@ -82,19 +57,7 @@ export interface EndpointFleetServicesInterface { packagePolicy: PackagePolicyClient; } -export interface EndpointScopedFleetServicesInterface extends EndpointFleetServicesInterface { - /** - * get internal fleet services instance - */ - asInternal: EndpointFleetServicesFactoryInterface['asInternalUser']; -} - export interface EndpointInternalFleetServicesInterface extends EndpointFleetServicesInterface { - /** - * get scoped endpoint fleet services instance - */ - asScoped: EndpointFleetServicesFactoryInterface['asScoped']; - /** * An internal SO client (readonly) that can be used with the Fleet services that require it */ diff --git a/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.test.ts b/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.test.ts index 892fbb5d984a3..27c758ca43a8b 100644 --- a/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.test.ts @@ -74,30 +74,6 @@ describe('EndpointMetadataService', () => { }); }); - describe('#doesUnitedIndexExist', () => { - it('should return true if united index found', async () => { - esClient.search.mockResponse(unitedMetadataSearchResponseMock()); - const doesIndexExist = await metadataService.doesUnitedIndexExist(esClient); - - expect(doesIndexExist).toEqual(true); - }); - - it('should return false if united index not found', async () => { - esClient.search.mockRejectedValue({ - meta: { body: { error: { type: 'index_not_found_exception' } } }, - }); - const doesIndexExist = await metadataService.doesUnitedIndexExist(esClient); - - expect(doesIndexExist).toEqual(false); - }); - - it('should throw wrapped error if es error other than index not found', async () => { - esClient.search.mockRejectedValue({}); - const response = metadataService.doesUnitedIndexExist(esClient); - await expect(response).rejects.toThrow(EndpointError); - }); - }); - describe('#getHostMetadataList', () => { let agentPolicyServiceMock: jest.Mocked; @@ -122,6 +98,28 @@ describe('EndpointMetadataService', () => { await expect(metadataListResponse).rejects.toThrow(EndpointError); }); + it('should not throw if index not found', async () => { + esClient.search.mockRejectedValue({ + meta: { body: { error: { type: 'index_not_found_exception' } } }, + }); + const metadataListResponse = await metadataService.getHostMetadataList( + esClient, + soClient, + testMockedContext.fleetServices, + { + page: 0, + pageSize: 10, + kuery: '', + hostStatuses: [], + } + ); + + expect(metadataListResponse).toEqual({ + data: [], + total: 0, + }); + }); + it('should correctly list HostMetadata', async () => { const policyId = 'test-agent-policy-id'; const packagePolicies = [ diff --git a/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.ts b/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.ts index 17183579e1f74..79017d03ba386 100644 --- a/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.ts +++ b/x-pack/plugins/security_solution/server/endpoint/services/metadata/endpoint_metadata_service.ts @@ -47,7 +47,6 @@ import { wrapErrorIfNeeded, } from '../../utils'; import { createInternalReadonlySoClient } from '../../utils/create_internal_readonly_so_client'; -import { METADATA_UNITED_INDEX } from '../../../../common/endpoint/constants'; import { getAllEndpointPackagePolicies } from '../../routes/metadata/support/endpoint_package_policies'; import type { GetMetadataListRequestQuery } from '../../../../common/endpoint/schema/metadata'; import { EndpointError } from '../../../../common/endpoint/errors'; @@ -357,33 +356,6 @@ export class EndpointMetadataService { return endpointPackagePolicy as PolicyData; } - /** - * Returns whether the united metadata index exists - * - * @param esClient - * - * @throws - */ - async doesUnitedIndexExist(esClient: ElasticsearchClient): Promise { - try { - await esClient.search({ - index: METADATA_UNITED_INDEX, - size: 1, - }); - return true; - } catch (error) { - const errorType = error?.meta?.body?.error?.type ?? ''; - // only index not found is expected - if (errorType !== 'index_not_found_exception') { - const err = wrapErrorIfNeeded(error); - this.logger?.error(err); - throw err; - } - } - - return false; - } - /** * Retrieve list of host metadata. Only supports new united index. * @@ -407,6 +379,14 @@ export class EndpointMetadataService { try { unitedMetadataQueryResponse = await esClient.search(unitedIndexQuery); } catch (error) { + const errorType = error?.meta?.body?.error?.type ?? ''; + if (errorType === 'index_not_found_exception') { + return { + data: [], + total: 0, + }; + } + const err = wrapErrorIfNeeded(error); this.logger?.error(err); throw err; diff --git a/x-pack/plugins/security_solution/server/endpoint/utils/action_list_helpers.test.ts b/x-pack/plugins/security_solution/server/endpoint/utils/action_list_helpers.test.ts index b2145bc8740f5..cfee4407500bd 100644 --- a/x-pack/plugins/security_solution/server/endpoint/utils/action_list_helpers.test.ts +++ b/x-pack/plugins/security_solution/server/endpoint/utils/action_list_helpers.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { ScopedClusterClientMock } from '@kbn/core/server/mocks'; import { elasticsearchServiceMock } from '@kbn/core/server/mocks'; import { @@ -337,7 +337,7 @@ describe('action helpers', () => { ); }); it('should query with actionIds and elasticAgentIds when provided', async () => { - const actionIds = [uuid.v4(), uuid.v4()]; + const actionIds = [uuidv4(), uuidv4()]; const elasticAgentIds = ['123', '456']; const esClient = mockScopedEsClient.asInternalUser; applyActionListEsSearchMock(esClient); diff --git a/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_event_filters.ts b/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_event_filters.ts index 70854e31f6956..70be4f5e19870 100644 --- a/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_event_filters.ts +++ b/x-pack/plugins/security_solution/server/fleet_integration/handlers/create_event_filters.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { ENDPOINT_EVENT_FILTERS_LIST_ID, @@ -94,7 +94,7 @@ export const createNonInteractiveSessionEventFilter = ( value: 'false', }, ], - itemId: uuid.v4(), + itemId: uuidv4(), meta: [], comments: [], }); diff --git a/x-pack/plugins/security_solution/server/index.ts b/x-pack/plugins/security_solution/server/index.ts index e167f62afd1e7..cc59610f21124 100644 --- a/x-pack/plugins/security_solution/server/index.ts +++ b/x-pack/plugins/security_solution/server/index.ts @@ -20,6 +20,7 @@ export const plugin = (context: PluginInitializerContext) => { export const config: PluginConfigDescriptor = { exposeToBrowser: { enableExperimental: true, + prebuiltRulesPackageVersion: true, }, schema: configSchema, deprecations: ({ renameFromRoot, unused }) => [ diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.test.ts index fd7351c677a2a..3d3accea3fa24 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.test.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.test.ts @@ -12,7 +12,7 @@ import { getFindResultWithSingleHit, getPrepackagedRulesStatusRequest, } from '../../../routes/__mocks__/request_responses'; -import { requestContextMock, serverMock, createMockConfig } from '../../../routes/__mocks__'; +import { requestContextMock, serverMock } from '../../../routes/__mocks__'; import type { SecurityPluginSetup } from '@kbn/security-plugin/server'; import { checkTimelinesStatus } from '../../../../timeline/utils/check_timelines_status'; import { @@ -82,7 +82,7 @@ describe('get_prepackaged_rule_status_route', () => { prepackagedTimelines: [], }); - getPrebuiltRulesAndTimelinesStatusRoute(server.router, createMockConfig(), securitySetup); + getPrebuiltRulesAndTimelinesStatusRoute(server.router, securitySetup); }); describe('status codes', () => { diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.ts index c765ed4ab6cc3..ced2a0e8ea663 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/get_prebuilt_rules_and_timelines_status/route.ts @@ -8,7 +8,6 @@ import { transformError } from '@kbn/securitysolution-es-utils'; import { validate } from '@kbn/securitysolution-io-ts-utils'; import { buildSiemResponse } from '../../../routes/utils'; -import type { ConfigType } from '../../../../../config'; import type { SetupPlugins } from '../../../../../plugin'; import type { SecuritySolutionPluginRouter } from '../../../../../types'; @@ -22,7 +21,7 @@ import { findRules } from '../../../rule_management/logic/search/find_rules'; import { getLatestPrebuiltRules } from '../../logic/get_latest_prebuilt_rules'; import { getRulesToInstall } from '../../logic/get_rules_to_install'; import { getRulesToUpdate } from '../../logic/get_rules_to_update'; -import { ruleAssetSavedObjectsClientFactory } from '../../logic/rule_asset/rule_asset_saved_objects_client'; +import { ruleAssetsClientFactory } from '../../logic/rule_asset/rule_asset_saved_objects_client'; import { rulesToMap } from '../../logic/utils'; import { buildFrameworkRequest } from '../../../../timeline/utils/common'; @@ -33,7 +32,6 @@ import { export const getPrebuiltRulesAndTimelinesStatusRoute = ( router: SecuritySolutionPluginRouter, - config: ConfigType, security: SetupPlugins['security'] ) => { router.get( @@ -49,7 +47,7 @@ export const getPrebuiltRulesAndTimelinesStatusRoute = ( const ctx = await context.resolve(['core', 'alerting']); const savedObjectsClient = ctx.core.savedObjects.client; const rulesClient = ctx.alerting.getRulesClient(); - const ruleAssetsClient = ruleAssetSavedObjectsClientFactory(savedObjectsClient); + const ruleAssetsClient = ruleAssetsClientFactory(savedObjectsClient); try { const latestPrebuiltRules = await getLatestPrebuiltRules(ruleAssetsClient); diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/install_prebuilt_rules_and_timelines/route.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/install_prebuilt_rules_and_timelines/route.ts index 2eca0146dc8a7..d2aa7216404d2 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/install_prebuilt_rules_and_timelines/route.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/install_prebuilt_rules_and_timelines/route.ts @@ -27,7 +27,7 @@ import { createPrebuiltRules } from '../../logic/create_prebuilt_rules'; import { updatePrebuiltRules } from '../../logic/update_prebuilt_rules'; import { getRulesToInstall } from '../../logic/get_rules_to_install'; import { getRulesToUpdate } from '../../logic/get_rules_to_update'; -import { ruleAssetSavedObjectsClientFactory } from '../../logic/rule_asset/rule_asset_saved_objects_client'; +import { ruleAssetsClientFactory } from '../../logic/rule_asset/rule_asset_saved_objects_client'; import { rulesToMap } from '../../logic/utils'; import { installPrepackagedTimelines } from '../../../../timeline/routes/prepackaged_timelines/install_prepackaged_timelines'; @@ -90,7 +90,7 @@ export const createPrepackagedRules = async ( const savedObjectsClient = context.core.savedObjects.client; const siemClient = context.getAppClient(); const exceptionsListClient = context.getExceptionListClient() ?? exceptionsClient; - const ruleAssetsClient = ruleAssetSavedObjectsClientFactory(savedObjectsClient); + const ruleAssetsClient = ruleAssetsClientFactory(savedObjectsClient); const { maxTimelineImportExportSize } = config; diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/register_routes.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/register_routes.ts index 39e822af3e147..c396eea87da9d 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/register_routes.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/api/register_routes.ts @@ -5,7 +5,6 @@ * 2.0. */ -import type { ConfigType } from '../../../../config'; import type { SetupPlugins } from '../../../../plugin_contract'; import type { SecuritySolutionPluginRouter } from '../../../../types'; @@ -14,9 +13,8 @@ import { installPrebuiltRulesAndTimelinesRoute } from './install_prebuilt_rules_ export const registerPrebuiltRulesRoutes = ( router: SecuritySolutionPluginRouter, - config: ConfigType, security: SetupPlugins['security'] ) => { - getPrebuiltRulesAndTimelinesStatusRoute(router, config, security); + getPrebuiltRulesAndTimelinesStatusRoute(router, security); installPrebuiltRulesAndTimelinesRoute(router); }; diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/get_latest_prebuilt_rules.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/get_latest_prebuilt_rules.ts index 914ab6b7ccf7f..36fb03c9bac7a 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/get_latest_prebuilt_rules.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/get_latest_prebuilt_rules.ts @@ -13,32 +13,23 @@ import { PrebuiltRuleToInstall } from '../../../../../common/detection_engine/pr import { withSecuritySpan } from '../../../../utils/with_security_span'; import type { IRuleAssetSOAttributes, - RuleAssetSavedObjectsClient, + IRuleAssetsClient, } from './rule_asset/rule_asset_saved_objects_client'; +import { prebuiltRulesToMap } from './utils'; + export const getLatestPrebuiltRules = async ( - client: RuleAssetSavedObjectsClient + ruleAssetsClient: IRuleAssetsClient ): Promise> => withSecuritySpan('getLatestPrebuiltRules', async () => { - const fleetRules = await getFleetRules(client); - return new Map(fleetRules.map((rule) => [rule.rule_id, rule])); + const ruleAssets = await ruleAssetsClient.fetchLatestVersions(); + return prebuiltRulesToMap(validateRuleAssets(ruleAssets)); }); -/** - * Retrieve and validate prebuilt rules that were installed from Fleet as saved objects. - */ -const getFleetRules = async ( - client: RuleAssetSavedObjectsClient -): Promise => { - const fleetResponse = await client.all(); - const fleetRules = fleetResponse.map((so) => so.attributes); - return validateFleetRules(fleetRules); -}; - /** * Validate the rules from Saved Objects created by Fleet. */ -const validateFleetRules = (rules: IRuleAssetSOAttributes[]): PrebuiltRuleToInstall[] => { +const validateRuleAssets = (rules: IRuleAssetSOAttributes[]): PrebuiltRuleToInstall[] => { return rules.map((rule) => { const decoded = PrebuiltRuleToInstall.decode(rule); const checked = exactCheck(rule, decoded); diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_asset/rule_asset_saved_objects_client.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_asset/rule_asset_saved_objects_client.ts index be963fb3dae9e..556ebbe2df108 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_asset/rule_asset_saved_objects_client.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_asset/rule_asset_saved_objects_client.ts @@ -5,17 +5,16 @@ * 2.0. */ -import type { - SavedObjectsClientContract, - SavedObjectsFindOptions, - SavedObjectsFindResponse, -} from '@kbn/core/server'; +import type { AggregationsMultiBucketAggregateBase } from '@elastic/elasticsearch/lib/api/types'; +import type { AggregationsTopHitsAggregate } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; +import type { SavedObjectsClientContract } from '@kbn/core/server'; +import { invariant } from '../../../../../../common/utils/invariant'; +import { withSecuritySpan } from '../../../../../utils/with_security_span'; import { ruleAssetSavedObjectType } from './rule_asset_saved_object_mappings'; -const DEFAULT_PAGE_SIZE = 100; +const MAX_PREBUILT_RULES_COUNT = 10_000; -// eslint-disable-next-line @typescript-eslint/no-explicit-any -export interface IRuleAssetSOAttributes extends Record { +export interface IRuleAssetSOAttributes extends Record { rule_id: string | null | undefined; version: string | null | undefined; name: string | null | undefined; @@ -27,33 +26,53 @@ export interface IRuleAssetSavedObject { attributes: IRuleAssetSOAttributes; } -export interface RuleAssetSavedObjectsClient { - find: ( - options?: Omit - ) => Promise>; - all: () => Promise; +export interface IRuleAssetsClient { + fetchLatestVersions: () => Promise; } -export const ruleAssetSavedObjectsClientFactory = ( +export const ruleAssetsClientFactory = ( savedObjectsClient: SavedObjectsClientContract -): RuleAssetSavedObjectsClient => { +): IRuleAssetsClient => { return { - find: (options) => - savedObjectsClient.find({ - ...options, - type: ruleAssetSavedObjectType, - }), - all: async () => { - const finder = savedObjectsClient.createPointInTimeFinder({ - perPage: DEFAULT_PAGE_SIZE, - type: ruleAssetSavedObjectType, + fetchLatestVersions: () => { + return withSecuritySpan('RuleAssetsClient.fetchLatestVersions', async () => { + const findResult = await savedObjectsClient.find< + IRuleAssetSavedObject, + { + rules: AggregationsMultiBucketAggregateBase<{ + latest_version: AggregationsTopHitsAggregate; + }>; + } + >({ + type: ruleAssetSavedObjectType, + aggs: { + rules: { + terms: { + field: `${ruleAssetSavedObjectType}.attributes.rule_id`, + size: MAX_PREBUILT_RULES_COUNT, + }, + aggs: { + latest_version: { + top_hits: { + size: 1, + sort: { + [`${ruleAssetSavedObjectType}.version`]: 'desc', + }, + }, + }, + }, + }, + }, + }); + const buckets = findResult.aggregations?.rules?.buckets ?? []; + + invariant(Array.isArray(buckets), 'Expected buckets to be an array'); + + return buckets.map((bucket) => { + const hit = bucket.latest_version.hits.hits[0]; + return hit._source[ruleAssetSavedObjectType]; + }); }); - const responses: IRuleAssetSavedObject[] = []; - for await (const response of finder.find()) { - responses.push(...response.saved_objects.map((so) => so as IRuleAssetSavedObject)); - } - await finder.close(); - return responses; }, }; }; diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/routes/__mocks__/request_context.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/routes/__mocks__/request_context.ts index 5a0e9f13d1fb9..ae76c0d128a98 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/routes/__mocks__/request_context.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/routes/__mocks__/request_context.ts @@ -136,10 +136,6 @@ const createSecuritySolutionRequestContextMock = ( // TODO: Mock EndpointInternalFleetServicesInterface and return the mocked object. throw new Error('Not implemented'); }), - getScopedFleetServices: jest.fn((req: KibanaRequest) => { - // TODO: Mock EndpointScopedFleetServicesInterface and return the mocked object. - throw new Error('Not implemented'); - }), getQueryRuleAdditionalOptions: { licensing, osqueryCreateAction: jest.fn(), diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.test.ts index a36746623dbcd..ecc646d11c8da 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.test.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SanitizedRule } from '@kbn/alerting-plugin/common'; import type { RuleParams } from '../../../rule_schema'; import { duplicateRule } from './duplicate_rule'; @@ -84,7 +84,7 @@ describe('duplicateRule', () => { }); beforeAll(() => { - (uuid.v4 as jest.Mock).mockReturnValue('new ruleId'); + (uuidv4 as jest.Mock).mockReturnValue('new ruleId'); }); afterAll(() => { diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.ts index f5ee4fc8ae35d..4a99085123b41 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/logic/actions/duplicate_rule.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { ruleTypeMappings } from '@kbn/securitysolution-rules'; import type { SanitizedRule } from '@kbn/alerting-plugin/common'; @@ -25,7 +25,7 @@ interface DuplicateRuleParams { export const duplicateRule = async ({ rule }: DuplicateRuleParams): Promise => { // Generate a new static ruleId - const ruleId = uuid.v4(); + const ruleId = uuidv4(); // If it's a prebuilt rule, reset Related Integrations, Required Fields and Setup Guide. // We do this because for now we don't allow the users to edit these fields for custom rules. diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/normalization/rule_converters.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/normalization/rule_converters.ts index e15c88ccf3aa1..4e2d17ec91803 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/normalization/rule_converters.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/normalization/rule_converters.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { BadRequestError } from '@kbn/securitysolution-es-utils'; import { validateNonExact } from '@kbn/securitysolution-io-ts-utils'; @@ -485,7 +485,7 @@ export const convertCreateAPIToInternalSchema = ( defaultEnabled = true ): InternalRuleCreate => { const typeSpecificParams = typeSpecificSnakeToCamel(input); - const newRuleId = input.rule_id ?? uuid.v4(); + const newRuleId = input.rule_id ?? uuidv4(); return { name: input.name, tags: input.tags ?? [], diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/utils/utils.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/utils/utils.ts index 173e1a5f5b906..3e3275321d7ab 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/utils/utils.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_management/utils/utils.ts @@ -7,7 +7,7 @@ import { partition } from 'lodash/fp'; import pMap from 'p-map'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SavedObjectsClientContract } from '@kbn/core/server'; import type { RuleAction } from '@kbn/securitysolution-io-ts-alerting-types'; @@ -139,12 +139,12 @@ export const getTupleDuplicateErrorsAndUniqueRules = ( const { errors, rulesAcc } = rules.reduce( (acc, parsedRule) => { if (parsedRule instanceof Error) { - acc.rulesAcc.set(uuid.v4(), parsedRule); + acc.rulesAcc.set(uuidv4(), parsedRule); } else { const { rule_id: ruleId } = parsedRule; if (acc.rulesAcc.has(ruleId) && !isOverwrite) { acc.errors.set( - uuid.v4(), + uuidv4(), createBulkErrorObject({ ruleId, statusCode: 400, @@ -302,7 +302,7 @@ export const getInvalidConnectors = async ( } catch (exc) { if (exc?.output?.statusCode === 403) { reducerAccumulator.errors.set( - uuid.v4(), + uuidv4(), createBulkErrorObject({ statusCode: exc.output.statusCode, message: `You may not have actions privileges required to import rules with actions: ${exc.output.payload.message}`, @@ -310,7 +310,7 @@ export const getInvalidConnectors = async ( ); } else { reducerAccumulator.errors.set( - uuid.v4(), + uuidv4(), createBulkErrorObject({ statusCode: 404, message: JSON.stringify(exc), @@ -322,7 +322,7 @@ export const getInvalidConnectors = async ( const { errors, rulesAcc } = rules.reduce( (acc, parsedRule) => { if (parsedRule instanceof Error) { - acc.rulesAcc.set(uuid.v4(), parsedRule); + acc.rulesAcc.set(uuidv4(), parsedRule); } else { const { rule_id: ruleId, actions } = parsedRule; const missingActionIds = actions @@ -342,7 +342,7 @@ export const getInvalidConnectors = async ( ? 'connectors are missing. Connector ids missing are:' : 'connector is missing. Connector id missing is:'; acc.errors.set( - uuid.v4(), + uuidv4(), createBulkErrorObject({ ruleId, statusCode: 404, diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_utils.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_utils.ts index 6899fbac46d95..9d84a1731b088 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_utils.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_monitoring/logic/rule_execution_log/execution_saved_object/saved_objects_utils.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuidv5 from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import type { SavedObjectReference } from '@kbn/core/server'; import { RULE_EXECUTION_SO_TYPE } from './saved_objects_type'; diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/route.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/route.ts index 57d5e67234b88..24aaf9ac4cd0c 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/route.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_preview/api/preview_rules/route.ts @@ -5,7 +5,7 @@ * 2.0. */ import moment from 'moment'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { transformError } from '@kbn/securitysolution-es-utils'; import { QUERY_RULE_TYPE_ID, SAVED_QUERY_RULE_TYPE_ID } from '@kbn/securitysolution-rules'; import type { Logger, StartServicesAccessor } from '@kbn/core/server'; @@ -121,7 +121,7 @@ export const previewRulesRoute = async ( await listsContext?.getExceptionListClient().createEndpointList(); const spaceId = siemClient.getSpaceId(); - const previewId = uuid.v4(); + const previewId = uuidv4(); const username = security?.authc.getCurrentUser(request)?.username; const loggedStatusChanges: Array = []; const previewRuleExecutionLogger = createPreviewRuleExecutionLogger(loggedStatusChanges); @@ -238,7 +238,7 @@ export const previewRulesRoute = async ( invocationStartTime = moment(); ({ state: statePreview } = (await executor({ - executionId: uuid.v4(), + executionId: uuidv4(), params, previousStartedAt, rule, diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.test.ts new file mode 100644 index 0000000000000..73717a7c0a5ec --- /dev/null +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.test.ts @@ -0,0 +1,33 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { filterSource } from './filter_source'; + +describe('filterSource', () => { + test('should remove keys starting with kibana without modifying the original doc', () => { + const testDoc = { + _index: '', + _id: '', + _source: { + 'kibana.alert.suppression.docs_count': 5, + 'host.name': 'test-host', + }, + }; + const filtered = filterSource(testDoc); + expect(filtered).toEqual({ + 'host.name': 'test-host', + }); + expect(testDoc).toEqual({ + _index: '', + _id: '', + _source: { + 'kibana.alert.suppression.docs_count': 5, + 'host.name': 'test-host', + }, + }); + }); +}); diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.ts index 707fc6a76f7eb..58e99969e74a8 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/factories/utils/filter_source.ts @@ -25,5 +25,11 @@ export const filterSource = (doc: SignalSourceHit) => { [ALERT_THRESHOLD_RESULT]: null, }; + Object.keys(filteredSource).forEach((key) => { + if (key.startsWith('kibana')) { + delete filteredSource[key]; + } + }); + return filteredSource; }; diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/filters/filter_events_against_list.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/filters/filter_events_against_list.test.ts index b702b3ac63acc..c7c1824d76c69 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/filters/filter_events_against_list.test.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/filters/filter_events_against_list.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/exception_list_item_schema.mock'; import { getSearchListItemResponseMock } from '@kbn/lists-plugin/common/schemas/response/search_list_item_schema.mock'; @@ -15,7 +15,7 @@ import { filterEventsAgainstList } from './filter_events_against_list'; import { repeatedHitsWithSortId } from '../__mocks__/es_results'; import { ruleExecutionLogMock } from '../../rule_monitoring/mocks'; -const someGuids = Array.from({ length: 13 }).map((x) => uuid.v4()); +const someGuids = Array.from({ length: 13 }).map((x) => uuidv4()); describe('filterEventsAgainstList', () => { let listClient = listMock.getListClient(); diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/search_after_bulk_create.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/search_after_bulk_create.test.ts index 8a6bfd7cb2641..caaf0b8c4cf73 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/search_after_bulk_create.test.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/search_after_bulk_create.test.ts @@ -15,7 +15,7 @@ import { import { searchAfterAndBulkCreate } from './search_after_bulk_create'; import type { RuleExecutorServicesMock } from '@kbn/alerting-plugin/server/mocks'; import { alertsMock } from '@kbn/alerting-plugin/server/mocks'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { listMock } from '@kbn/lists-plugin/server/mocks'; import { getExceptionListItemSchemaMock } from '@kbn/lists-plugin/common/schemas/response/exception_list_item_schema.mock'; import type { BulkCreate, BulkResponse, RuleRangeTuple, WrapHits } from './types'; @@ -36,6 +36,7 @@ import { ALERT_RULE_CONSUMER, ALERT_RULE_EXECUTION_UUID, ALERT_RULE_NAME, + ALERT_RULE_PARAMETERS, ALERT_RULE_PRODUCER, ALERT_RULE_TAGS, ALERT_RULE_TYPE_ID, @@ -55,13 +56,14 @@ describe('searchAfterAndBulkCreate', () => { let inputIndexPattern: string[] = []; let listClient = listMock.getListClient(); const ruleExecutionLogger = ruleExecutionLogMock.forExecutors.create(); - const someGuids = Array.from({ length: 13 }).map(() => uuid.v4()); + const someGuids = Array.from({ length: 13 }).map(() => uuidv4()); const sampleParams = getQueryRuleParams(); const queryCompleteRule = getCompleteRuleMock(sampleParams); const defaultFilter = { match_all: {}, }; const mockCommonFields: CommonAlertFieldsLatest = { + [ALERT_RULE_PARAMETERS]: {}, [ALERT_RULE_CATEGORY]: 'Custom Query Rule', [ALERT_RULE_CONSUMER]: SERVER_APP_ID, [ALERT_RULE_EXECUTION_UUID]: '97e8f53a-4971-4935-bb54-9b8f86930cc7', diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/utils.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/utils.ts index fbf538af284d9..3c6fec4afdcdf 100644 --- a/x-pack/plugins/security_solution/server/lib/detection_engine/signals/utils.ts +++ b/x-pack/plugins/security_solution/server/lib/detection_engine/signals/utils.ts @@ -7,7 +7,7 @@ import { createHash } from 'crypto'; import { chunk, get, invert, isEmpty, partition } from 'lodash'; import moment from 'moment'; -import uuidv5 from 'uuid/v5'; +import { v5 as uuidv5 } from 'uuid'; import dateMath from '@kbn/datemath'; import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; diff --git a/x-pack/plugins/security_solution/server/lib/exceptions/api/manage_exceptions/route.ts b/x-pack/plugins/security_solution/server/lib/exceptions/api/manage_exceptions/route.ts index 4168943e6e033..a30745da834ea 100644 --- a/x-pack/plugins/security_solution/server/lib/exceptions/api/manage_exceptions/route.ts +++ b/x-pack/plugins/security_solution/server/lib/exceptions/api/manage_exceptions/route.ts @@ -5,7 +5,7 @@ * 2.0. */ import * as t from 'io-ts'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SHARED_EXCEPTION_LIST_URL } from '../../../../../common/constants'; import type { SecuritySolutionPluginRouter } from '../../../../types'; @@ -57,7 +57,7 @@ export const createSharedExceptionListRoute = (router: SecuritySolutionPluginRou const createdSharedList = await listsClient?.createExceptionList({ description, immutable: false, - listId: uuid.v4(), + listId: uuidv4(), meta: undefined, name, namespaceType: 'single', diff --git a/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/helpers/bulk_create_saved_objects.ts b/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/helpers/bulk_create_saved_objects.ts index e85e7df7a9f3c..7cd493cff2b74 100644 --- a/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/helpers/bulk_create_saved_objects.ts +++ b/x-pack/plugins/security_solution/server/lib/risk_score/prebuilt_saved_objects/helpers/bulk_create_saved_objects.ts @@ -8,7 +8,7 @@ import type { SavedObjectsClientContract } from '@kbn/core-saved-objects-api-ser import { transformError } from '@kbn/securitysolution-es-utils'; import type { Logger } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { i18n } from '@kbn/i18n'; import { RiskScoreEntity } from '../../../../../common/search_strategy'; import * as savedObjectsToCreate from '../saved_object'; @@ -66,7 +66,7 @@ export const bulkCreateSavedObjects = async ({ const idReplaceMappings: Record = {}; mySavedObjects.forEach((so) => { if (so.id.startsWith(' { diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/readme.md b/x-pack/plugins/security_solution/server/lib/sourcerer/readme.md deleted file mode 100644 index 3435959348c6a..0000000000000 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/readme.md +++ /dev/null @@ -1,78 +0,0 @@ -# Sourcerer API - -### Model reference - -```typescript -interface KibanaDataView { - /** Uniquely identifies a Kibana Data View */ - id: string; - /** list of active patterns that return data */ - patternList: string[]; - /** - * title of Kibana Data View - * title also serves as "all pattern list", including inactive - * comma separated string - */ - title: string; -} -``` - -### API usage - -The sourcerer API has one route with 2 methods - -1. POST - `createSourcererDataViewRoute` - 1. REQUEST: - ```typescript - POST /internal/security_solution/sourcerer - { - patternList: [...configPatternList, ...(signal.name != null ? [signal.name] : [])] - } - ``` - 2. RESPONSE: - ```typescript - { - /** default security-solution data view */ - defaultDataView: KibanaDataView; - - /** all Kibana data views, including default security-solution */ - kibanaDataViews: KibanaDataView[]; - } - ``` - 3. This route is called from `security_solution/public/plugin.tsx` on app load. It passes an argument of `patternList` which is an array of the config index patterns defined in Stack Management > Advanced Settings > Security Solution > Elasticsearch indices along with the default signal index - 4. `dataViewService.getIdsWithTitle` is called to get all existing data views ids and titles - 5. Next `dataViewService.get` method is called to attempt to retrieve the default security data view by id (`siemClient.getSourcererDataViewId()`). If the data view id does not exist, it uses `dataViewService.createAndSave` to create the default security data view. - 6. `patternListAsTitle` (a string of the patternList passed) is compared to the current `siemDataViewTitle`. If they do not match, we use `dataViewService.updateSavedObject` to update the data view title. This may happen when a pattern is added or removed from the Stack Management > Advanced Settings > Security Solution > Elasticsearch indices. - 7. Next we call `buildSourcererDataView` for the default data view only. This takes the `dataView.title` and finds which patterns on the list returns data. Valid patterns are returned in an array called `patternList`. The non-default data views will have an empty array for patternList, and we will call this function if/when the data view is selected to save time. - 8. At the end we return a body of - ``` - { - /** default security-solution data view */ - defaultDataView: KibanaDataView; - - /** all Kibana data views, including default security-solution */ - kibanaDataViews: KibanaDataView[]; - } - ``` - 9. The other place this POST is called is when the default signal index does not yet exist. In the front-end there is a method called `pollForSignalIndex` that is defined when the signal index has been initiated but does not have data. It is called whenever the detection sourcerer or timeline sourcerer mounts, or whenever the search bar is refreshed. If the signal index is defined, `pollForSignalIndex` ceases to exist and is not called. - 10. One more place we call the POST method is when the signal index first has data, we send a POST in a method called `onSignalIndexUpdated` to include the newly created index in the data view -2. GET - `getSourcererDataViewRoute` - 1. REQUEST: - ```typescript - GET /internal/security_solution/sourcerer?dataViewId=security-solution-default - ``` - 2. RESPONSE: - ```typescript - KibanaDataView - ``` -3. When the user changes the data view from the default in the UI, we call the GET method to find which index patterns in the `dataView.title` are valid, returning a valid `patternList`. -4. We return a body of a single `KibanaDataView` - -### Helpers -To build the valid pattern list, we call `findExistingIndices` which takes the pattern list as an argument, and returns a boolean array of which patterns are valid. To check if indices exist, we use the field caps API for each pattern checking for the field `_id`. This will return a list of valid indices. If the array is empty, no indices exist for the pattern. For example: -```typescript - // Given - findExistingIndices(['auditbeat-*', 'fakebeat-*', 'packetbeat-*']) - // Returns - [true, false, true] -``` \ No newline at end of file diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.test.ts b/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.test.ts deleted file mode 100644 index 006b054f7ad03..0000000000000 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.test.ts +++ /dev/null @@ -1,46 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ -import { findExistingIndices } from './helpers'; -import type { ElasticsearchClient } from '@kbn/core/server'; - -const fieldCaps = jest - .fn() - .mockImplementation(() => new Promise((resolve) => resolve([true, true]))); -const esClient = { - fieldCaps, -}; - -describe('sourcerer helpers', () => { - beforeEach(() => { - jest.clearAllMocks(); - }); - it('findExistingIndices calls with regular indices', async () => { - await findExistingIndices(['a', 'b'], esClient as unknown as ElasticsearchClient); - expect(esClient.fieldCaps.mock.calls[0][0].index).toEqual('a'); - expect(esClient.fieldCaps.mock.calls[1][0].index).toEqual('b'); - }); - it('findExistingIndices calls with regular indices in place of exclude indices', async () => { - await findExistingIndices(['a', '-b'], esClient as unknown as ElasticsearchClient); - expect(esClient.fieldCaps.mock.calls[0][0].index).toEqual('a'); - expect(esClient.fieldCaps.mock.calls[1][0].index).toEqual('b'); - }); - it('findExistingIndices removes leading / trailing whitespace, and dashes from exclude patterns', async () => { - await findExistingIndices( - [ - ' include-with-leading-and-trailing-whitespace ', - ' -exclude-with-leading-and-trailing-whitespace ', - ], - esClient as unknown as ElasticsearchClient - ); - expect(esClient.fieldCaps.mock.calls[0][0].index).toEqual( - 'include-with-leading-and-trailing-whitespace' - ); - expect(esClient.fieldCaps.mock.calls[1][0].index).toEqual( - 'exclude-with-leading-and-trailing-whitespace' - ); - }); -}); diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.ts b/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.ts deleted file mode 100644 index 19e65d2d10fbf..0000000000000 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/helpers.ts +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import type { ElasticsearchClient } from '@kbn/core/server'; - -export const findExistingIndices = async ( - indices: string[], - esClient: ElasticsearchClient -): Promise => - Promise.all( - indices - .map(async (index) => { - const indexToQuery = index.trim().startsWith('-') - ? index.trim().substring(1) - : index.trim(); - const searchResponse = await esClient.fieldCaps({ - index: indexToQuery, - fields: '_id', - ignore_unavailable: true, - allow_no_indices: false, - }); - return searchResponse.indices.length > 0; - }) - .map((p) => p.catch((e) => false)) - ); diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.test.ts b/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.test.ts deleted file mode 100644 index 1125a0ce65428..0000000000000 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.test.ts +++ /dev/null @@ -1,330 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { createSourcererDataViewRoute } from '.'; -import { - requestMock, - serverMock, - requestContextMock, -} from '../../detection_engine/routes/__mocks__'; - -import { SOURCERER_API_URL } from '../../../../common/constants'; -import type { StartServicesAccessor } from '@kbn/core/server'; -import type { StartPlugins } from '../../../plugin'; - -jest.mock('./helpers', () => { - const original = jest.requireActual('./helpers'); - - return { - ...original, - findExistingIndices: () => new Promise((resolve) => resolve([true, true])), - }; -}); -const mockPattern = { - id: 'security-solution', - fields: [ - { name: '@timestamp', searchable: true, type: 'date', aggregatable: true }, - { name: '@version', searchable: true, type: 'string', aggregatable: true }, - { name: 'agent.ephemeral_id', searchable: true, type: 'string', aggregatable: true }, - { name: 'agent.hostname', searchable: true, type: 'string', aggregatable: true }, - { name: 'agent.id', searchable: true, type: 'string', aggregatable: true }, - ], - title: - 'apm-*-transaction*,traces-apm*,auditbeat-*,endgame-*,filebeat-*,logs-*,packetbeat-*,winlogbeat-*,ml_host_risk_score_*,.siem-signals-default', -}; -const mockPatternList = [ - 'apm-*-transaction*', - 'traces-apm*', - 'auditbeat-*', - 'endgame-*', - 'filebeat-*', - 'logs-*', - 'packetbeat-*', - 'winlogbeat-*', - 'ml_host_risk_score_*', - '.siem-signals-default', -]; -const mockDataViews = [ - { - id: 'metrics-*', - title: 'metrics-*', - }, - { - id: 'logs-*', - title: 'logs-*', - }, - mockPattern, -]; -const getStartServices = jest.fn().mockReturnValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => new Promise((rs) => rs(mockDataViews)), - get: () => new Promise((rs) => rs(mockPattern)), - createAndSave: () => new Promise((rs) => rs(mockPattern)), - updateSavedObject: () => new Promise((rs) => rs(mockPattern)), - }), - }, - }, - }, -] as unknown) as StartServicesAccessor; - -const getStartServicesNotSiem = jest.fn().mockReturnValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => - new Promise((rs) => rs(mockDataViews.filter((v) => v.id !== mockPattern.id))), - get: (id: string) => - new Promise((rs) => - id === mockPattern.id - ? rs(null) - : rs({ - id: 'dataview-lambda', - title: 'fun-*,dog-*,cat-*', - }) - ), - createAndSave: () => new Promise((rs) => rs(mockPattern)), - updateSavedObject: () => new Promise((rs) => rs(mockPattern)), - }), - }, - }, - }, -] as unknown) as StartServicesAccessor; - -const mockDataViewsTransformed = { - defaultDataView: { - id: 'security-solution', - patternList: ['apm-*-transaction*', 'traces-apm*'], - title: - 'apm-*-transaction*,traces-apm*,auditbeat-*,endgame-*,filebeat-*,logs-*,packetbeat-*,winlogbeat-*,ml_host_risk_score_*,.siem-signals-default', - }, - kibanaDataViews: [ - { - id: 'metrics-*', - title: 'metrics-*', - }, - { - id: 'logs-*', - title: 'logs-*', - }, - { - id: 'security-solution', - patternList: ['apm-*-transaction*', 'traces-apm*'], - title: - 'apm-*-transaction*,traces-apm*,auditbeat-*,endgame-*,filebeat-*,logs-*,packetbeat-*,winlogbeat-*,ml_host_risk_score_*,.siem-signals-default', - }, - ], -}; - -describe('sourcerer route', () => { - let server: ReturnType; - let { context } = requestContextMock.createTools(); - - describe('post', () => { - const getSourcererRequest = (patternList: string[]) => - requestMock.create({ - method: 'post', - path: SOURCERER_API_URL, - body: { patternList }, - }); - - describe('functional tests', () => { - beforeEach(() => { - server = serverMock.create(); - ({ context } = requestContextMock.createTools()); - }); - test('returns sourcerer formatted Data Views when SIEM Data View does NOT exist', async () => { - createSourcererDataViewRoute(server.router, getStartServicesNotSiem); - const response = await server.inject( - getSourcererRequest(mockPatternList), - requestContextMock.convertContext(context) - ); - expect(response.status).toEqual(200); - expect(response.body).toEqual(mockDataViewsTransformed); - }); - - test('returns sourcerer formatted Data Views when SIEM Data View does NOT exist but has been created in the mean time', async () => { - const getMock = jest.fn(); - getMock.mockResolvedValueOnce(mockPattern); - const getStartServicesSpecial = jest.fn().mockResolvedValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => - new Promise((rs) => rs(mockDataViews.filter((v) => v.id !== mockPattern.id))), - get: getMock, - createAndSave: jest.fn().mockRejectedValue({ statusCode: 409 }), - updateSavedObject: () => new Promise((rs, rj) => rj(new Error('error'))), - }), - }, - }, - }, - ] as unknown) as StartServicesAccessor; - createSourcererDataViewRoute(server.router, getStartServicesSpecial); - const response = await server.inject( - getSourcererRequest(mockPatternList), - requestContextMock.convertContext(context) - ); - expect(response.status).toEqual(200); - expect(response.body).toEqual(mockDataViewsTransformed); - }); - - test('passes sorted title on create and save', async () => { - const getMock = jest.fn(); - getMock.mockResolvedValueOnce(null); - getMock.mockResolvedValueOnce(mockPattern); - const mockCreateAndSave = jest.fn(); - const getStartServicesSpecial = jest.fn().mockResolvedValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => - new Promise((rs) => rs(mockDataViews.filter((v) => v.id !== mockPattern.id))), - get: getMock, - createAndSave: mockCreateAndSave.mockImplementation( - () => new Promise((rs) => rs(mockPattern)) - ), - updateSavedObject: () => new Promise((rs, rj) => rj(new Error('error'))), - }), - }, - }, - }, - ] as unknown) as StartServicesAccessor; - createSourcererDataViewRoute(server.router, getStartServicesSpecial); - await server.inject( - getSourcererRequest(['-elastic-logs-*', ...mockPatternList]), - requestContextMock.convertContext(context) - ); - expect(mockCreateAndSave.mock.calls[0][0].title).toEqual( - '.siem-signals-default,apm-*-transaction*,auditbeat-*,endgame-*,filebeat-*,logs-*,ml_host_risk_score_*,packetbeat-*,traces-apm*,winlogbeat-*,-elastic-logs-*' - ); - }); - - test('passes override=true on create and save', async () => { - const getMock = jest.fn(); - getMock.mockResolvedValueOnce(null); - getMock.mockResolvedValueOnce(mockPattern); - const mockCreateAndSave = jest.fn(); - const getStartServicesSpecial = jest.fn().mockResolvedValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => - new Promise((rs) => rs(mockDataViews.filter((v) => v.id !== mockPattern.id))), - get: getMock, - createAndSave: mockCreateAndSave.mockImplementation( - () => new Promise((rs) => rs(mockPattern)) - ), - updateSavedObject: () => new Promise((rs, rj) => rj(new Error('error'))), - }), - }, - }, - }, - ] as unknown) as StartServicesAccessor; - createSourcererDataViewRoute(server.router, getStartServicesSpecial); - await server.inject( - getSourcererRequest(mockPatternList), - requestContextMock.convertContext(context) - ); - expect(mockCreateAndSave).toHaveBeenCalled(); - expect(mockCreateAndSave.mock.calls[0][1]).toEqual(true); - }); - - test('passes sorted title on updateSavedObject', async () => { - const getMock = jest.fn(); - getMock.mockResolvedValueOnce(null); - getMock.mockResolvedValueOnce(mockPattern); - const mockCreateAndSave = jest.fn(); - const mockUpdateSavedObject = jest.fn(); - const getStartServicesSpecial = jest.fn().mockResolvedValue([ - null, - { - data: { - indexPatterns: { - dataViewsServiceFactory: () => ({ - getIdsWithTitle: () => - new Promise((rs) => - rs([{ id: 'security-solution', title: 'winlogbeat-*,-elastic-logs-*' }]) - ), - get: jest.fn().mockResolvedValue({ - id: 'security-solution', - title: 'winlogbeat-*,-elastic-logs-*', - }), - createAndSave: mockCreateAndSave.mockImplementation( - () => new Promise((rs) => rs(mockPattern)) - ), - updateSavedObject: mockUpdateSavedObject.mockImplementation( - () => new Promise((rs) => rs(mockPattern)) - ), - }), - }, - }, - }, - ] as unknown) as StartServicesAccessor; - createSourcererDataViewRoute(server.router, getStartServicesSpecial); - await server.inject( - getSourcererRequest(['-elastic-logs-*', ...mockPatternList]), - requestContextMock.convertContext(context) - ); - expect(mockUpdateSavedObject).toHaveBeenCalledWith({ - id: 'security-solution', - title: - '.siem-signals-default,apm-*-transaction*,auditbeat-*,endgame-*,filebeat-*,logs-*,ml_host_risk_score_*,packetbeat-*,traces-apm*,winlogbeat-*,-elastic-logs-*', - }); - }); - - test('returns sourcerer formatted Data Views when SIEM Data View exists', async () => { - createSourcererDataViewRoute(server.router, getStartServices); - const response = await server.inject( - getSourcererRequest(mockPatternList), - requestContextMock.convertContext(context) - ); - expect(response.status).toEqual(200); - expect(response.body).toEqual(mockDataViewsTransformed); - }); - - test('returns sourcerer formatted Data Views when SIEM Data View exists and patternList input is changed', async () => { - createSourcererDataViewRoute(server.router, getStartServices); - mockPatternList.shift(); - const response = await server.inject( - getSourcererRequest(mockPatternList), - requestContextMock.convertContext(context) - ); - expect(response.status).toEqual(200); - expect(response.body).toEqual({ - defaultDataView: { - id: 'security-solution', - patternList: ['.siem-signals-default', 'auditbeat-*'], - title: - '.siem-signals-default,auditbeat-*,endgame-*,filebeat-*,logs-*,ml_host_risk_score_*,packetbeat-*,traces-apm*,winlogbeat-*', - }, - kibanaDataViews: [ - mockDataViewsTransformed.kibanaDataViews[0], - mockDataViewsTransformed.kibanaDataViews[1], - { - id: 'security-solution', - patternList: ['.siem-signals-default', 'auditbeat-*'], - title: - '.siem-signals-default,auditbeat-*,endgame-*,filebeat-*,logs-*,ml_host_risk_score_*,packetbeat-*,traces-apm*,winlogbeat-*', - }, - ], - }); - }); - }); - }); -}); diff --git a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts b/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts deleted file mode 100644 index d959322a9720f..0000000000000 --- a/x-pack/plugins/security_solution/server/lib/sourcerer/routes/index.ts +++ /dev/null @@ -1,210 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { transformError } from '@kbn/securitysolution-es-utils'; -import type { ElasticsearchClient, StartServicesAccessor } from '@kbn/core/server'; - -import type { DataView, DataViewListItem } from '@kbn/data-views-plugin/common'; -import { DEFAULT_TIME_FIELD, SOURCERER_API_URL } from '../../../../common/constants'; -import type { SecuritySolutionPluginRouter } from '../../../types'; -import { buildRouteValidation } from '../../../utils/build_validation/route_validation'; -import type { StartPlugins } from '../../../plugin'; -import { buildSiemResponse } from '../../detection_engine/routes/utils'; -import { findExistingIndices } from './helpers'; -import { sourcererDataViewSchema, sourcererSchema } from './schema'; -import { ensurePatternFormat } from '../../../../common/utils/sourcerer'; - -export const createSourcererDataViewRoute = ( - router: SecuritySolutionPluginRouter, - getStartServices: StartServicesAccessor -) => { - router.post( - { - path: SOURCERER_API_URL, - validate: { - body: buildRouteValidation(sourcererSchema), - }, - options: { - authRequired: true, - tags: ['access:securitySolution'], - }, - }, - async (context, request, response) => { - const siemResponse = buildSiemResponse(response); - const coreContext = await context.core; - const siemClient = (await context.securitySolution)?.getAppClient(); - const dataViewId = siemClient.getSourcererDataViewId(); - - try { - const [ - , - { - data: { indexPatterns }, - }, - ] = await getStartServices(); - - const dataViewService = await indexPatterns.dataViewsServiceFactory( - coreContext.savedObjects.client, - coreContext.elasticsearch.client.asCurrentUser, - request, - true - ); - - let allDataViews: DataViewListItem[] = await dataViewService.getIdsWithTitle(); - let siemDataView: DataView | DataViewListItem | null = - allDataViews.find((dv) => dv.id === dataViewId) ?? null; - - const { patternList } = request.body; - const patternListAsTitle = ensurePatternFormat(patternList).join(); - const siemDataViewTitle = siemDataView - ? ensurePatternFormat(siemDataView.title.split(',')).join() - : ''; - - if (siemDataView == null) { - try { - siemDataView = await dataViewService.createAndSave( - { - allowNoIndex: true, - id: dataViewId, - title: patternListAsTitle, - timeFieldName: DEFAULT_TIME_FIELD, - }, - // Override property - if a data view exists with the security solution pattern - // delete it and replace it with our data view - true - ); - } catch (err) { - const error = transformError(err); - if (err.name === 'DuplicateDataViewError' || error.statusCode === 409) { - siemDataView = await dataViewService.get(dataViewId); - } else { - throw error; - } - } - } else if (patternListAsTitle !== siemDataViewTitle) { - siemDataView = await dataViewService.get(dataViewId); - siemDataView.title = patternListAsTitle; - await dataViewService.updateSavedObject(siemDataView); - } - - if (allDataViews.some((dv) => dv.id === dataViewId)) { - allDataViews = allDataViews.map((v) => - v.id === dataViewId ? { ...v, title: patternListAsTitle } : v - ); - } else { - allDataViews.push({ ...siemDataView, id: siemDataView.id ?? dataViewId }); - } - - const defaultDataView = await buildSourcererDataView( - siemDataView, - coreContext.elasticsearch.client.asCurrentUser - ); - return response.ok({ - body: { - defaultDataView, - kibanaDataViews: allDataViews.map((dv) => - dv.id === dataViewId ? defaultDataView : dv - ), - }, - }); - } catch (err) { - const error = transformError(err); - return siemResponse.error({ - body: - error.statusCode === 403 - ? 'Users with write permissions need to access the Elastic Security app to initialize the app source data.' - : error.message, - statusCode: error.statusCode, - }); - } - } - ); -}; - -export const getSourcererDataViewRoute = ( - router: SecuritySolutionPluginRouter, - getStartServices: StartServicesAccessor -) => { - router.get( - { - path: SOURCERER_API_URL, - validate: { - query: buildRouteValidation(sourcererDataViewSchema), - }, - options: { - tags: ['access:securitySolution'], - }, - }, - async (context, request, response) => { - const siemResponse = buildSiemResponse(response); - const coreContext = await context.core; - const { dataViewId } = request.query; - try { - const [ - , - { - data: { indexPatterns }, - }, - ] = await getStartServices(); - - const dataViewService = await indexPatterns.dataViewsServiceFactory( - coreContext.savedObjects.client, - coreContext.elasticsearch.client.asCurrentUser, - request, - true - ); - const allDataViews: DataViewListItem[] = await dataViewService.getIdsWithTitle(); - const siemDataView: DataViewListItem | null = - allDataViews.find((dv) => dv.id === dataViewId) ?? null; - const kibanaDataView = siemDataView - ? await buildSourcererDataView( - siemDataView, - coreContext.elasticsearch.client.asCurrentUser - ) - : {}; - - return response.ok({ - body: kibanaDataView, - }); - } catch (err) { - const error = transformError(err); - return siemResponse.error({ - body: - error.statusCode === 403 - ? 'Users with write permissions need to access the Elastic Security app to initialize the app source data.' - : error.message, - statusCode: error.statusCode, - }); - } - } - ); -}; - -interface KibanaDataView { - /** Uniquely identifies a Kibana Data View */ - id: string; - /** list of active patterns that return data */ - patternList: string[]; - /** - * title of Kibana Data View - * title also serves as "all pattern list", including inactive - * comma separated string - */ - title: string; -} - -const buildSourcererDataView = async ( - dataView: DataView | DataViewListItem, - clientAsCurrentUser: ElasticsearchClient -): Promise => { - const patternList = dataView.title.split(','); - const activePatternBools: boolean[] = await findExistingIndices(patternList, clientAsCurrentUser); - const activePatternLists: string[] = patternList.filter( - (pattern, j, self) => self.indexOf(pattern) === j && activePatternBools[j] - ); - return { id: dataView.id ?? '', title: dataView.title, patternList: activePatternLists }; -}; diff --git a/x-pack/plugins/security_solution/server/lib/telemetry/receiver.ts b/x-pack/plugins/security_solution/server/lib/telemetry/receiver.ts index 6c88019152dfd..60b472ec45b4d 100644 --- a/x-pack/plugins/security_solution/server/lib/telemetry/receiver.ts +++ b/x-pack/plugins/security_solution/server/lib/telemetry/receiver.ts @@ -193,8 +193,8 @@ export class TelemetryReceiver implements ITelemetryReceiver { ) { this.kibanaIndex = kibanaIndex; this.alertsIndex = alertsIndex; - this.agentClient = endpointContextService?.getAgentService()?.asInternalUser; - this.agentPolicyService = endpointContextService?.getAgentPolicyService(); + this.agentClient = endpointContextService?.getInternalFleetServices().agent; + this.agentPolicyService = endpointContextService?.getInternalFleetServices().agentPolicy; this.esClient = core?.elasticsearch.client.asInternalUser; this.exceptionListClient = exceptionListClient; this.soClient = diff --git a/x-pack/plugins/security_solution/server/lib/timeline/routes/draft_timelines/clean_draft_timelines/index.ts b/x-pack/plugins/security_solution/server/lib/timeline/routes/draft_timelines/clean_draft_timelines/index.ts index 2def786ec7af6..a174a80e3a88c 100644 --- a/x-pack/plugins/security_solution/server/lib/timeline/routes/draft_timelines/clean_draft_timelines/index.ts +++ b/x-pack/plugins/security_solution/server/lib/timeline/routes/draft_timelines/clean_draft_timelines/index.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { transformError } from '@kbn/securitysolution-es-utils'; import type { SecuritySolutionPluginRouter } from '../../../../../types'; import type { ConfigType } from '../../../../..'; @@ -74,7 +74,7 @@ export const cleanDraftTimelinesRoute = ( request.body.timelineType === TimelineType.template ? { timelineType: request.body.timelineType, - templateTimelineId: uuid.v4(), + templateTimelineId: uuidv4(), templateTimelineVersion: 1, } : {}; diff --git a/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/get_timelines_from_stream.ts b/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/get_timelines_from_stream.ts index 743f667bb4d1f..6980d7815ae47 100644 --- a/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/get_timelines_from_stream.ts +++ b/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/get_timelines_from_stream.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { BulkError } from '../../../../detection_engine/routes/utils'; import { createBulkErrorObject } from '../../../../detection_engine/routes/utils'; import type { PromiseFromStreams } from './types'; @@ -17,13 +17,13 @@ export const getTupleDuplicateErrorsAndUniqueTimeline = ( const { errors, timelinesAcc } = timelines.reduce( (acc, parsedTimeline) => { if (parsedTimeline instanceof Error) { - acc.timelinesAcc.set(uuid.v4(), parsedTimeline); + acc.timelinesAcc.set(uuidv4(), parsedTimeline); } else { const { savedObjectId } = parsedTimeline; if (savedObjectId != null) { if (acc.timelinesAcc.has(savedObjectId) && !isOverwrite) { acc.errors.set( - uuid.v4(), + uuidv4(), createBulkErrorObject({ id: savedObjectId, statusCode: 400, @@ -33,7 +33,7 @@ export const getTupleDuplicateErrorsAndUniqueTimeline = ( } acc.timelinesAcc.set(savedObjectId, parsedTimeline); } else { - acc.timelinesAcc.set(uuid.v4(), parsedTimeline); + acc.timelinesAcc.set(uuidv4(), parsedTimeline); } } diff --git a/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/helpers.ts b/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/helpers.ts index af57a9a08dccb..603f2ae116839 100644 --- a/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/helpers.ts +++ b/x-pack/plugins/security_solution/server/lib/timeline/routes/timelines/import_timelines/helpers.ts @@ -7,7 +7,7 @@ import { has, chunk, omit } from 'lodash/fp'; import type { Readable } from 'stream'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { createPromiseFromStreams } from '@kbn/utils'; import { validate } from '@kbn/securitysolution-io-ts-utils'; @@ -79,7 +79,7 @@ export const setTimeline = ( templateTimelineVersion: isTemplateTimeline ? parsedTimeline.templateTimelineVersion ?? 1 : null, - templateTimelineId: isTemplateTimeline ? parsedTimeline.templateTimelineId ?? uuid.v4() : null, + templateTimelineId: isTemplateTimeline ? parsedTimeline.templateTimelineId ?? uuidv4() : null, }; }; diff --git a/x-pack/plugins/security_solution/server/lib/timeline/saved_object/notes/saved_object.ts b/x-pack/plugins/security_solution/server/lib/timeline/saved_object/notes/saved_object.ts index 5778064ac525a..09e1db4a5f0ff 100644 --- a/x-pack/plugins/security_solution/server/lib/timeline/saved_object/notes/saved_object.ts +++ b/x-pack/plugins/security_solution/server/lib/timeline/saved_object/notes/saved_object.ts @@ -7,7 +7,7 @@ import { failure } from 'io-ts/lib/PathReporter'; import { getOr } from 'lodash/fp'; -import uuid from 'uuid'; +import { v1 as uuidv1 } from 'uuid'; import { pipe } from 'fp-ts/lib/pipeable'; import { map, fold } from 'fp-ts/lib/Either'; @@ -92,7 +92,7 @@ export const persistNote = async ({ if (getOr(null, 'output.statusCode', err) === 403) { const noteToReturn: NoteResult = { ...note, - noteId: uuid.v1(), + noteId: uuidv1(), version: '', timelineId: '', timelineVersion: '', diff --git a/x-pack/plugins/security_solution/server/lists_integration/endpoint/validators/base_validator.test.ts b/x-pack/plugins/security_solution/server/lists_integration/endpoint/validators/base_validator.test.ts index 9abe0b6b04147..8c3dfcd4bc27e 100644 --- a/x-pack/plugins/security_solution/server/lists_integration/endpoint/validators/base_validator.test.ts +++ b/x-pack/plugins/security_solution/server/lists_integration/endpoint/validators/base_validator.test.ts @@ -37,7 +37,8 @@ describe('When using Artifacts Exceptions BaseValidator', () => { const servicesStart = createMockEndpointAppContextServiceStartContract(); - packagePolicyService = servicesStart.packagePolicyService as jest.Mocked; + packagePolicyService = servicesStart.endpointFleetServicesFactory.asInternalUser() + .packagePolicy as jest.Mocked; endpointAppContextServices = new EndpointAppContextService(); endpointAppContextServices.setup(createMockEndpointAppContextServiceSetupContract()); diff --git a/x-pack/plugins/security_solution/server/plugin.ts b/x-pack/plugins/security_solution/server/plugin.ts index bfd76caecfb1f..e3521a2160e47 100644 --- a/x-pack/plugins/security_solution/server/plugin.ts +++ b/x-pack/plugins/security_solution/server/plugin.ts @@ -478,10 +478,6 @@ export class Plugin implements ISecuritySolutionPlugin { this.endpointAppContextService.start({ fleetAuthzService: authz, - agentService, - packageService, - packagePolicyService, - agentPolicyService, endpointMetadataService: new EndpointMetadataService( core.savedObjects, agentPolicyService, diff --git a/x-pack/plugins/security_solution/server/request_context_factory.ts b/x-pack/plugins/security_solution/server/request_context_factory.ts index 4cf161e29407f..0804fefe041e7 100644 --- a/x-pack/plugins/security_solution/server/request_context_factory.ts +++ b/x-pack/plugins/security_solution/server/request_context_factory.ts @@ -112,10 +112,6 @@ export class RequestContextFactory implements IRequestContextFactory { getInternalFleetServices: memoize(() => endpointAppContextService.getInternalFleetServices()), - getScopedFleetServices: memoize((req: KibanaRequest) => - endpointAppContextService.getScopedFleetServices(req) - ), - getQueryRuleAdditionalOptions: { licensing, osqueryCreateAction: osquery.osqueryCreateAction, diff --git a/x-pack/plugins/security_solution/server/routes/index.ts b/x-pack/plugins/security_solution/server/routes/index.ts index 38809aff316a0..7758e74be4801 100644 --- a/x-pack/plugins/security_solution/server/routes/index.ts +++ b/x-pack/plugins/security_solution/server/routes/index.ts @@ -55,7 +55,6 @@ import type { CreateRuleOptions, CreateSecurityRuleTypeWrapperProps, } from '../lib/detection_engine/rule_types/types'; -import { createSourcererDataViewRoute, getSourcererDataViewRoute } from '../lib/sourcerer/routes'; import type { ITelemetryReceiver } from '../lib/telemetry/receiver'; import { telemetryDetectionRulesPreviewRoute } from '../lib/detection_engine/routes/telemetry/telemetry_detection_rules_preview_route'; import { readAlertsIndexExistsRoute } from '../lib/detection_engine/routes/index/read_alerts_index_exists_route'; @@ -91,7 +90,7 @@ export const initRoutes = ( ) => { registerFleetIntegrationsRoutes(router, logger); registerLegacyRuleActionsRoutes(router, logger); - registerPrebuiltRulesRoutes(router, config, security); + registerPrebuiltRulesRoutes(router, security); registerRuleExceptionsRoutes(router); registerManageExceptionsRoutes(router); registerRuleManagementRoutes(router, config, ml, logger); @@ -148,10 +147,6 @@ export const initRoutes = ( // Privileges API to get the generic user privileges readPrivilegesRoute(router, hasEncryptionKey); - // Sourcerer API to generate default pattern - createSourcererDataViewRoute(router, getStartServices); - getSourcererDataViewRoute(router, getStartServices); - // risky score module createEsIndexRoute(router, logger); deleteEsIndicesRoute(router); diff --git a/x-pack/plugins/security_solution/server/types.ts b/x-pack/plugins/security_solution/server/types.ts index 84a11b6ad0ba9..20688329eb1b2 100644 --- a/x-pack/plugins/security_solution/server/types.ts +++ b/x-pack/plugins/security_solution/server/types.ts @@ -25,10 +25,7 @@ import type { ConfigType } from './config'; import type { IRuleExecutionLogForRoutes } from './lib/detection_engine/rule_monitoring'; import type { FrameworkRequest } from './lib/framework'; import type { EndpointAuthz } from '../common/endpoint/types/authz'; -import type { - EndpointInternalFleetServicesInterface, - EndpointScopedFleetServicesInterface, -} from './endpoint/services/fleet'; +import type { EndpointInternalFleetServicesInterface } from './endpoint/services/fleet'; export { AppClient }; @@ -44,7 +41,6 @@ export interface SecuritySolutionApiRequestHandlerContext { getRacClient: (req: KibanaRequest) => Promise; getExceptionListClient: () => ExceptionListClient | null; getInternalFleetServices: () => EndpointInternalFleetServicesInterface; - getScopedFleetServices: (req: KibanaRequest) => EndpointScopedFleetServicesInterface; getQueryRuleAdditionalOptions: CreateQueryRuleAdditionalOptions; } diff --git a/x-pack/plugins/security_solution/tsconfig.json b/x-pack/plugins/security_solution/tsconfig.json index 3c756aff43f60..a342df6814735 100644 --- a/x-pack/plugins/security_solution/tsconfig.json +++ b/x-pack/plugins/security_solution/tsconfig.json @@ -134,5 +134,6 @@ "@kbn/controls-plugin", "@kbn/shared-ux-utility", "@kbn/user-profile-components", + "@kbn/guided-onboarding", ] } diff --git a/x-pack/plugins/session_view/public/components/process_tree/helpers.ts b/x-pack/plugins/session_view/public/components/process_tree/helpers.ts index 5ec8568a013b9..349a162d6b612 100644 --- a/x-pack/plugins/session_view/public/components/process_tree/helpers.ts +++ b/x-pack/plugins/session_view/public/components/process_tree/helpers.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { escapeRegExp } from 'lodash'; import { sortProcesses } from '../../../common/utils/sort_processes'; import { @@ -21,7 +21,7 @@ import { ProcessImpl } from './hooks'; // This is used to ensure we always have a record for a session leader, as well as // a parent record for potentially orphaned processes export function inferProcessFromLeaderInfo(sourceEvent?: ProcessEvent, leader?: ProcessFields) { - const entityId = leader?.entity_id || uuid.v4(); + const entityId = leader?.entity_id || uuidv4(); const process = new ProcessImpl(entityId); if (sourceEvent && leader) { diff --git a/x-pack/plugins/snapshot_restore/public/application/sections/home/policy_list/policy_details/tabs/tab_summary.tsx b/x-pack/plugins/snapshot_restore/public/application/sections/home/policy_list/policy_details/tabs/tab_summary.tsx index 814589275cad1..e1060f8743750 100644 --- a/x-pack/plugins/snapshot_restore/public/application/sections/home/policy_list/policy_details/tabs/tab_summary.tsx +++ b/x-pack/plugins/snapshot_restore/public/application/sections/home/policy_list/policy_details/tabs/tab_summary.tsx @@ -146,9 +146,9 @@ export const TabSummary: React.FunctionComponent = ({ policy }) => { - - - + + + = ({ policy }) => { {version} - + + - + + = ({ policy }) => { - - + + + + - - + + + = ({ policy }) => { {snapshotName} - + + - + + = ({ policy }) => { {repository} - - + + + + - - + + + = ({ policy }) => { {schedule} - + + - + + = ({ policy }) => { - - + + + + - - + + + = ({ policy }) => { - + + - + + = ({ policy }) => { /> )} - - + + + + - - + + + = ({ policy }) => { /> )} - + + - - + + + - - + + + = ({ policy }) => { /> )} - - - + + + {retention && ( diff --git a/x-pack/plugins/snapshot_restore/server/routes/api/repositories.test.ts b/x-pack/plugins/snapshot_restore/server/routes/api/repositories.test.ts index f29a84beaecf8..c4b99028701ad 100644 --- a/x-pack/plugins/snapshot_restore/server/routes/api/repositories.test.ts +++ b/x-pack/plugins/snapshot_restore/server/routes/api/repositories.test.ts @@ -380,6 +380,29 @@ describe('[Snapshot and Restore API Routes] Repositories', () => { await expect(router.runRequest(mockRequest)).resolves.toEqual({ body: expectedResponse }); }); + it('should return successful ES response when using unknown setting', async () => { + const mockEsResponse = { + [name]: { type: 's3', settings: { awsAccount: 'test-account' } }, + }; + getRepoFn.mockResolvedValue({ [name]: {} }); + createRepoFn.mockResolvedValue(mockEsResponse); + + const expectedResponse = mockEsResponse; + + await expect( + router.runRequest({ + ...mockRequest, + body: { + name, + type: 's3', + settings: { + path_style_access: 'test-account', + }, + }, + }) + ).resolves.toEqual({ body: expectedResponse }); + }); + it('should throw if ES error', async () => { getRepoFn.mockRejectedValue(new Error()); await expect(router.runRequest(mockRequest)).rejects.toThrowError(); diff --git a/x-pack/plugins/snapshot_restore/server/routes/api/validate_schemas.ts b/x-pack/plugins/snapshot_restore/server/routes/api/validate_schemas.ts index 35437c2e39acd..d312d02a30981 100644 --- a/x-pack/plugins/snapshot_restore/server/routes/api/validate_schemas.ts +++ b/x-pack/plugins/snapshot_restore/server/routes/api/validate_schemas.ts @@ -62,14 +62,8 @@ export const policySchema = schema.object({ isManagedPolicy: schema.boolean(), }); -const fsRepositorySettings = schema.object({ - location: schema.string(), - compress: schema.maybe(schema.boolean()), - chunkSize: schema.maybe(schema.oneOf([schema.string(), schema.literal(null)])), - maxRestoreBytesPerSec: schema.maybe(schema.string()), - maxSnapshotBytesPerSec: schema.maybe(schema.string()), - readonly: schema.maybe(schema.boolean()), -}); +// Only validate required settings, everything else is optional +const fsRepositorySettings = schema.object({ location: schema.string() }, { unknowns: 'allow' }); const fsRepositorySchema = schema.object({ name: schema.string(), @@ -87,20 +81,8 @@ const readOnlyRepository = schema.object({ settings: readOnlyRepositorySettings, }); -const s3RepositorySettings = schema.object({ - bucket: schema.string(), - client: schema.maybe(schema.string()), - basePath: schema.maybe(schema.string()), - compress: schema.maybe(schema.boolean()), - chunkSize: schema.maybe(schema.oneOf([schema.string(), schema.literal(null)])), - serverSideEncryption: schema.maybe(schema.boolean()), - bufferSize: schema.maybe(schema.string()), - cannedAcl: schema.maybe(schema.string()), - storageClass: schema.maybe(schema.string()), - maxRestoreBytesPerSec: schema.maybe(schema.string()), - maxSnapshotBytesPerSec: schema.maybe(schema.string()), - readonly: schema.maybe(schema.boolean()), -}); +// Only validate required settings, everything else is optional +const s3RepositorySettings = schema.object({ bucket: schema.string() }, { unknowns: 'allow' }); const s3Repository = schema.object({ name: schema.string(), @@ -108,17 +90,11 @@ const s3Repository = schema.object({ settings: s3RepositorySettings, }); +// Only validate required settings, everything else is optional const hdsRepositorySettings = schema.object( { uri: schema.string(), path: schema.string(), - loadDefaults: schema.maybe(schema.boolean()), - compress: schema.maybe(schema.boolean()), - chunkSize: schema.maybe(schema.oneOf([schema.string(), schema.literal(null)])), - maxRestoreBytesPerSec: schema.maybe(schema.string()), - maxSnapshotBytesPerSec: schema.maybe(schema.string()), - readonly: schema.maybe(schema.boolean()), - ['security.principal']: schema.maybe(schema.string()), }, { unknowns: 'allow' } ); @@ -129,17 +105,7 @@ const hdsfRepository = schema.object({ settings: hdsRepositorySettings, }); -const azureRepositorySettings = schema.object({ - client: schema.maybe(schema.string()), - container: schema.maybe(schema.string()), - basePath: schema.maybe(schema.string()), - locationMode: schema.maybe(schema.string()), - compress: schema.maybe(schema.boolean()), - chunkSize: schema.maybe(schema.oneOf([schema.string(), schema.literal(null)])), - maxRestoreBytesPerSec: schema.maybe(schema.string()), - maxSnapshotBytesPerSec: schema.maybe(schema.string()), - readonly: schema.maybe(schema.boolean()), -}); +const azureRepositorySettings = schema.object({}, { unknowns: 'allow' }); const azureRepository = schema.object({ name: schema.string(), @@ -147,16 +113,8 @@ const azureRepository = schema.object({ settings: azureRepositorySettings, }); -const gcsRepositorySettings = schema.object({ - bucket: schema.string(), - client: schema.maybe(schema.string()), - basePath: schema.maybe(schema.string()), - compress: schema.maybe(schema.boolean()), - chunkSize: schema.maybe(schema.oneOf([schema.string(), schema.literal(null)])), - maxRestoreBytesPerSec: schema.maybe(schema.string()), - maxSnapshotBytesPerSec: schema.maybe(schema.string()), - readonly: schema.maybe(schema.boolean()), -}); +// Only validate required settings, everything else is optional +const gcsRepositorySettings = schema.object({ bucket: schema.string() }, { unknowns: 'allow' }); const gcsRepository = schema.object({ name: schema.string(), diff --git a/x-pack/plugins/stack_alerts/server/rule_types/es_query/rule_type.test.ts b/x-pack/plugins/stack_alerts/server/rule_types/es_query/rule_type.test.ts index 1465f2c7e263e..8669e66d1026a 100644 --- a/x-pack/plugins/stack_alerts/server/rule_types/es_query/rule_type.test.ts +++ b/x-pack/plugins/stack_alerts/server/rule_types/es_query/rule_type.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { Writable } from '@kbn/utility-types'; import { RuleExecutorServices } from '@kbn/alerting-plugin/server'; import { @@ -691,7 +691,7 @@ async function invokeExecutor({ state?: EsQueryRuleState; }) { return await ruleType.executor({ - executionId: uuid.v4(), + executionId: uuidv4(), startedAt: new Date(), previousStartedAt: new Date(), services: ruleServices as unknown as RuleExecutorServices< @@ -704,10 +704,10 @@ async function invokeExecutor({ latestTimestamp: undefined, ...state, }, - spaceId: uuid.v4(), + spaceId: uuidv4(), rule: { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), tags: [], consumer: '', producer: '', diff --git a/x-pack/plugins/stack_alerts/server/rule_types/index_threshold/rule_type.test.ts b/x-pack/plugins/stack_alerts/server/rule_types/index_threshold/rule_type.test.ts index 12991ec5c94aa..5b3ed6ebec8ba 100644 --- a/x-pack/plugins/stack_alerts/server/rule_types/index_threshold/rule_type.test.ts +++ b/x-pack/plugins/stack_alerts/server/rule_types/index_threshold/rule_type.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import sinon from 'sinon'; import type { Writable } from '@kbn/utility-types'; import { loggingSystemMock } from '@kbn/core/server/mocks'; @@ -183,7 +183,7 @@ describe('ruleType', () => { }; await ruleType.executor({ - executionId: uuid.v4(), + executionId: uuidv4(), startedAt: new Date(), previousStartedAt: new Date(), services: alertServices as unknown as RuleExecutorServices< @@ -195,10 +195,10 @@ describe('ruleType', () => { state: { latestTimestamp: undefined, }, - spaceId: uuid.v4(), + spaceId: uuidv4(), rule: { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), tags: [], consumer: '', producer: '', @@ -246,7 +246,7 @@ describe('ruleType', () => { }; await ruleType.executor({ - executionId: uuid.v4(), + executionId: uuidv4(), startedAt: new Date(), previousStartedAt: new Date(), services: customAlertServices as unknown as RuleExecutorServices< @@ -258,10 +258,10 @@ describe('ruleType', () => { state: { latestTimestamp: undefined, }, - spaceId: uuid.v4(), + spaceId: uuidv4(), rule: { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), tags: [], consumer: '', producer: '', @@ -309,7 +309,7 @@ describe('ruleType', () => { }; await ruleType.executor({ - executionId: uuid.v4(), + executionId: uuidv4(), startedAt: new Date(), previousStartedAt: new Date(), services: customAlertServices as unknown as RuleExecutorServices< @@ -321,10 +321,10 @@ describe('ruleType', () => { state: { latestTimestamp: undefined, }, - spaceId: uuid.v4(), + spaceId: uuidv4(), rule: { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), tags: [], consumer: '', producer: '', @@ -371,7 +371,7 @@ describe('ruleType', () => { }; await ruleType.executor({ - executionId: uuid.v4(), + executionId: uuidv4(), startedAt: new Date(), previousStartedAt: new Date(), services: alertServices as unknown as RuleExecutorServices< @@ -383,10 +383,10 @@ describe('ruleType', () => { state: { latestTimestamp: undefined, }, - spaceId: uuid.v4(), + spaceId: uuidv4(), rule: { - id: uuid.v4(), - name: uuid.v4(), + id: uuidv4(), + name: uuidv4(), tags: [], consumer: '', producer: '', diff --git a/x-pack/plugins/stack_connectors/public/connector_types/opsgenie/translations.ts b/x-pack/plugins/stack_connectors/public/connector_types/opsgenie/translations.ts index 9b2615acd52aa..cd03725cb12fd 100644 --- a/x-pack/plugins/stack_connectors/public/connector_types/opsgenie/translations.ts +++ b/x-pack/plugins/stack_connectors/public/connector_types/opsgenie/translations.ts @@ -127,7 +127,7 @@ export const OPSGENIE_DOCUMENTATION = i18n.translate( export const OPSGENIE_ALIAS_HELP = i18n.translate( 'xpack.stackConnectors.components.opsgenie.fieldAliasHelpText', { - defaultMessage: 'The unique alert identifier used for de-deduplication in Opsgenie.', + defaultMessage: 'The unique alert identifier used for deduplication in Opsgenie.', } ); diff --git a/x-pack/plugins/stack_connectors/server/connector_types/email/send_email_graph_api.test.ts b/x-pack/plugins/stack_connectors/server/connector_types/email/send_email_graph_api.test.ts index 4ab03837f416b..199681a13e968 100644 --- a/x-pack/plugins/stack_connectors/server/connector_types/email/send_email_graph_api.test.ts +++ b/x-pack/plugins/stack_connectors/server/connector_types/email/send_email_graph_api.test.ts @@ -90,6 +90,7 @@ describe('sendEmailGraphApi', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, @@ -180,6 +181,7 @@ describe('sendEmailGraphApi', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, @@ -269,6 +271,7 @@ describe('sendEmailGraphApi', () => { "maxSockets": Infinity, "maxTotalSockets": Infinity, "options": Object { + "noDelay": true, "path": null, "rejectUnauthorized": true, }, diff --git a/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.test.ts b/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.test.ts index 3731aa6f09dc7..584a06f4b407a 100644 --- a/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.test.ts +++ b/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.test.ts @@ -15,7 +15,7 @@ describe('api_itom', () => { let externalService: jest.Mocked; const eventParamsWithFormattedDate = { ...itomEventParams, - time_of_event: '2021-10-13, 10:51:44', + time_of_event: '2021-10-13 10:51:44', }; beforeEach(() => { diff --git a/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.ts b/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.ts index d9479792967b2..c68f1d4419eb1 100644 --- a/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.ts +++ b/x-pack/plugins/stack_connectors/server/connector_types/servicenow_itom/api.ts @@ -20,7 +20,7 @@ const formatTimeOfEvent = (timeOfEvent: string | null): string | undefined => { return isValidDate(date) ? // The format is: yyyy-MM-dd HH:mm:ss GMT - date.toLocaleDateString('en-CA', { + date.toLocaleDateString('eo', { year: 'numeric', month: '2-digit', day: '2-digit', diff --git a/x-pack/plugins/synthetics/common/constants/synthetics/rest_api.ts b/x-pack/plugins/synthetics/common/constants/synthetics/rest_api.ts index 4e41dd2190da3..d4a770f574fdd 100644 --- a/x-pack/plugins/synthetics/common/constants/synthetics/rest_api.ts +++ b/x-pack/plugins/synthetics/common/constants/synthetics/rest_api.ts @@ -14,4 +14,5 @@ export enum SYNTHETICS_API_URLS { PARAMS = `/synthetics/params`, SYNC_GLOBAL_PARAMS = `/synthetics/sync_global_params`, ENABLE_DEFAULT_ALERTING = `/synthetics/enable_default_alerting`, + JOURNEY = `/internal/synthetics/journey/{checkGroup}`, } diff --git a/x-pack/plugins/synthetics/common/rules/alert_actions.ts b/x-pack/plugins/synthetics/common/rules/alert_actions.ts index 37de9f6c350d6..9c32fbdf8d3cf 100644 --- a/x-pack/plugins/synthetics/common/rules/alert_actions.ts +++ b/x-pack/plugins/synthetics/common/rules/alert_actions.ts @@ -15,7 +15,7 @@ import type { EmailActionParams, } from '@kbn/stack-connectors-plugin/server/connector_types'; import { RuleAction as RuleActionOrig } from '@kbn/alerting-plugin/common'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ActionConnector, ActionTypeId } from './types'; import { DefaultEmail } from '../runtime_types'; @@ -67,7 +67,7 @@ export function populateAlertActions({ switch (aId.actionTypeId) { case PAGER_DUTY_ACTION_ID: - const dedupKey = uuid.v4(); + const dedupKey = uuidv4(); action.params = getPagerDutyActionParams(translations, dedupKey); recoveredAction.params = getPagerDutyActionParams(translations, dedupKey, true); actions.push(recoveredAction); diff --git a/x-pack/plugins/synthetics/common/runtime_types/monitor_management/synthetics_overview_status.ts b/x-pack/plugins/synthetics/common/runtime_types/monitor_management/synthetics_overview_status.ts index 3df7a1c326721..a942316202ebb 100644 --- a/x-pack/plugins/synthetics/common/runtime_types/monitor_management/synthetics_overview_status.ts +++ b/x-pack/plugins/synthetics/common/runtime_types/monitor_management/synthetics_overview_status.ts @@ -18,8 +18,12 @@ export const OverviewStatusMetaDataCodec = t.interface({ }); export const OverviewStatusCodec = t.interface({ + allMonitorsCount: t.number, + disabledMonitorsCount: t.number, + projectMonitorsCount: t.number, up: t.number, down: t.number, + pending: t.number, disabledCount: t.number, upConfigs: t.record(t.string, OverviewStatusMetaDataCodec), downConfigs: t.record(t.string, OverviewStatusMetaDataCodec), diff --git a/x-pack/plugins/synthetics/common/runtime_types/ping/synthetics.ts b/x-pack/plugins/synthetics/common/runtime_types/ping/synthetics.ts index ae5dd0046200d..10fd7ecc6d2fe 100644 --- a/x-pack/plugins/synthetics/common/runtime_types/ping/synthetics.ts +++ b/x-pack/plugins/synthetics/common/runtime_types/ping/synthetics.ts @@ -7,6 +7,7 @@ import { isRight } from 'fp-ts/lib/Either'; import * as t from 'io-ts'; +import { ErrorStateCodec } from './error_state'; /** * This type has some overlap with the Ping type, but it helps avoid runtime type @@ -254,6 +255,9 @@ export const SyntheticsJourneyApiResponseType = t.intersection([ timestamp: t.string, checkGroup: t.string, }), + summary: t.type({ + state: ErrorStateCodec, + }), }), ]), t.null, diff --git a/x-pack/plugins/synthetics/e2e/helpers/make_checks.ts b/x-pack/plugins/synthetics/e2e/helpers/make_checks.ts index b9e913524cb1f..534a486e085ce 100644 --- a/x-pack/plugins/synthetics/e2e/helpers/make_checks.ts +++ b/x-pack/plugins/synthetics/e2e/helpers/make_checks.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { merge, flattenDeep } from 'lodash'; import type { Client } from '@elastic/elasticsearch'; import { makePing } from './make_ping'; @@ -37,7 +37,7 @@ export const makeCheck = async ({ }: CheckProps): Promise<{ monitorId: string; docs: any }> => { const cgFields = { monitor: { - check_group: uuid.v4(), + check_group: uuidv4(), }, }; diff --git a/x-pack/plugins/synthetics/e2e/helpers/make_ping.ts b/x-pack/plugins/synthetics/e2e/helpers/make_ping.ts index c93d6f437268d..e39244e51bfff 100644 --- a/x-pack/plugins/synthetics/e2e/helpers/make_ping.ts +++ b/x-pack/plugins/synthetics/e2e/helpers/make_ping.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { merge } from 'lodash'; import type { Client } from '@elastic/elasticsearch'; import { makeTls, TlsProps } from './make_tls'; @@ -90,7 +90,7 @@ export const makePing = async ( }, ip: '127.0.0.1', id: monitorId, - check_group: uuid.v4(), + check_group: uuidv4(), type: 'http', status: 'up', timespan: { diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/add_monitor.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/add_monitor.journey.ts index 60283e94dff4f..7c27d3addd1e2 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/add_monitor.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/add_monitor.journey.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { journey, step, expect, Page } from '@elastic/synthetics'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; import { FormMonitorType } from '../../../common/runtime_types'; @@ -16,11 +16,11 @@ const basicMonitorDetails = { location: customLocation || 'US Central', schedule: '3', }; -const httpName = `http monitor ${uuid.v4()}`; -const icmpName = `icmp monitor ${uuid.v4()}`; -const tcpName = `tcp monitor ${uuid.v4()}`; -const browserName = `browser monitor ${uuid.v4()}`; -const browserRecorderName = `browser monitor recorder ${uuid.v4()}`; +const httpName = `http monitor ${uuidv4()}`; +const icmpName = `icmp monitor ${uuidv4()}`; +const tcpName = `tcp monitor ${uuidv4()}`; +const browserName = `browser monitor ${uuidv4()}`; +const browserRecorderName = `browser monitor recorder ${uuidv4()}`; const apmServiceName = 'apmServiceName'; const configuration = { diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/default_status_alert.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/default_status_alert.journey.ts index 192fa0f8b6cb2..3da959eefa145 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/default_status_alert.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/default_status_alert.journey.ts @@ -8,7 +8,7 @@ import { journey, step, before, after, expect } from '@elastic/synthetics'; import { byTestId } from '@kbn/ux-plugin/e2e/journeys/utils'; import { RetryService } from '@kbn/ftr-common-functional-services'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; import { getReasonMessage } from '../../../../server/legacy_uptime/lib/alerts/status_check'; import { syntheticsAppPageProvider } from '../../../page_objects/synthetics/synthetics_app'; @@ -143,7 +143,7 @@ journey(`DefaultStatusAlert`, async ({ page, params }) => { }); step('Adds another down monitor and it auto adds the alert', async () => { - const monitorId = uuid.v4(); + const monitorId = uuidv4(); const name = `Test Monitor 2`; configId2 = await services.addTestMonitor(name, { type: 'http', diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/sample_docs/sample_docs.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/sample_docs/sample_docs.ts index 9508e3384d9cf..21b7bd301214c 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/sample_docs/sample_docs.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/alert_rules/sample_docs/sample_docs.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export const firstUpHit = { summary: { @@ -171,7 +171,7 @@ export const firstDownHit = ({ ip: '142.250.181.196', name: name ?? 'Test Monitor', fleet_managed: true, - check_group: uuid.v4(), + check_group: uuidv4(), timespan: { lt: '2022-12-18T09:52:50.128Z', gte: '2022-12-18T09:49:50.128Z', diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/index.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/index.ts index 4b4869e02877f..c7232fefb6efd 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/index.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/index.ts @@ -21,3 +21,4 @@ export * from './alert_rules/default_status_alert.journey'; export * from './test_now_mode.journey'; export * from './data_retention.journey'; export * from './monitor_details_page/monitor_summary.journey'; +export * from './test_run_details.journey'; diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/management_list.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/management_list.journey.ts index eaf1bc78241f0..ad220cbc20ded 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/management_list.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/management_list.journey.ts @@ -7,6 +7,7 @@ import { journey, step, expect, before, after } from '@elastic/synthetics'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; +import { byTestId } from '@kbn/ux-plugin/e2e/journeys/utils'; import { addTestMonitor, cleanTestMonitors, @@ -22,6 +23,11 @@ journey(`MonitorManagementList`, async ({ page, params }) => { const testMonitor2 = 'Test monitor 2'; const testMonitor3 = 'Test monitor 3'; + const pageBaseUrl = 'http://localhost:5620/app/synthetics/monitors'; + const searchBarInput = page.locator( + '[placeholder="Search by name, url, host, tag, project or location"]' + ); + page.setDefaultTimeout(60 * 1000); before(async () => { @@ -48,19 +54,14 @@ journey(`MonitorManagementList`, async ({ page, params }) => { }); step('shows the count', async () => { - await page.locator('text=Monitors'); - await page.click('text=1-3'); + await page.waitForSelector('text=Monitors'); + await page.waitForSelector('text=1-3'); }); - step( - 'Click text=Showing 1-3 of 3 ConfigurationsSortingThis table contains 3 rows out of 3 rows; Page 1', - async () => { - await page.click( - 'text=Showing 1-3 of 3 ConfigurationsSortingThis table contains 3 rows out of 3 rows; Page 1' - ); - await page.click('[aria-label="expands filter group for Type filter"]'); - } - ); + step('Click text=Showing 1-3 of 3 Configurations; Page 1', async () => { + await page.waitForSelector('text=Showing 1-3 of 3 Configurations'); + await page.click('[aria-label="expands filter group for Type filter"]'); + }); step( 'Click [aria-label="Use up and down arrows to move focus over options. Enter to select. Escape to collapse options."] >> text=browser', @@ -69,27 +70,33 @@ journey(`MonitorManagementList`, async ({ page, params }) => { '[aria-label="Use up and down arrows to move focus over options. Enter to select. Escape to collapse options."] >> text=browser' ); await page.click('[aria-label="Apply the selected filters for Type"]'); - expect(page.url()).toBe( - 'http://localhost:5620/app/synthetics/monitors?monitorType=%5B%22browser%22%5D' - ); + expect(page.url()).toBe(`${pageBaseUrl}?monitorType=%5B%22browser%22%5D`); await page.click('[placeholder="Search by name, url, host, tag, project or location"]'); await Promise.all([ page.waitForNavigation({ - url: 'http://localhost:5620/app/synthetics/monitors?monitorType=%5B%22browser%22%5D&query=3', + url: `${pageBaseUrl}?monitorType=%5B%22browser%22%5D&query=3`, }), page.fill('[placeholder="Search by name, url, host, tag, project or location"]', '3'), ]); await page.click('text=1-1'); - await page.click( - 'text=Showing 1-1 of 1 ConfigurationSortingThis table contains 1 rows out of 1 rows; Page 1 ' - ); + await page.waitForSelector('text=Showing 1-1 of 1 Configuration'); } ); step('when no results appears', async () => { - await page.click('[placeholder="Search by name, url, host, tag, project or location"]'); - await page.fill('[placeholder="Search by name, url, host, tag, project or location"]', '5553'); + await searchBarInput.click(); + await searchBarInput.fill('5553'); + + await page.waitForSelector('text=0-0'); + + // Clear search + await searchBarInput.press('Escape'); + await page.waitForSelector('text=1-3'); + }); - await page.click('text=0-0'); + step('Shows monitor summary', async () => { + const statSummaryPanel = page.locator(byTestId('syntheticsManagementSummaryStats')); // Summary stat elements + await expect(statSummaryPanel.locator('text=3').count()).resolves.toEqual(1); // Configurations + await expect(statSummaryPanel.locator('text=0').count()).resolves.toEqual(1); // Disabled }); }); diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/data/sample_docs.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/data/sample_docs.ts index 9f0d38fc0136e..f9a28c7eaa1bf 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/data/sample_docs.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/data/sample_docs.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getGeoData } from './browser_docs'; export interface DocOverrides { @@ -227,7 +227,7 @@ export const firstDownHit = ({ ip: '142.250.181.196', name: name ?? 'Test Monitor', fleet_managed: true, - check_group: uuid.v4(), + check_group: uuidv4(), timespan: { lt: '2022-12-18T09:52:50.128Z', gte: '2022-12-18T09:49:50.128Z', diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/synthetics_services.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/synthetics_services.ts index 67fb0d83c7f58..44b05520f5de2 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/synthetics_services.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/services/synthetics_services.ts @@ -35,7 +35,11 @@ export class SyntheticsServices { } } - async addTestMonitor(name: string, data: Record = { type: 'browser' }) { + async addTestMonitor( + name: string, + data: Record = { type: 'browser' }, + configId?: string + ) { const testData = { alert: { status: { enabled: true } }, locations: [{ id: 'us_central', isServiceManaged: true }], @@ -45,7 +49,10 @@ export class SyntheticsServices { }; try { const response = await axios.post( - this.kibanaUrl + '/internal/uptime/service/monitors', + this.kibanaUrl + + (configId + ? `/internal/uptime/service/monitors?id=${configId}` + : `/internal/uptime/service/monitors`), testData, { auth: { username: 'elastic', password: 'changeme' }, diff --git a/x-pack/plugins/synthetics/e2e/journeys/synthetics/test_run_details.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/synthetics/test_run_details.journey.ts new file mode 100644 index 0000000000000..3f8df4a46cbbd --- /dev/null +++ b/x-pack/plugins/synthetics/e2e/journeys/synthetics/test_run_details.journey.ts @@ -0,0 +1,64 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { journey, step, before, after } from '@elastic/synthetics'; +import { byTestId } from '@kbn/ux-plugin/e2e/journeys/utils'; +import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; +import { syntheticsAppPageProvider } from '../../page_objects/synthetics/synthetics_app'; +import { SyntheticsServices } from './services/synthetics_services'; + +journey(`TestRunDetailsPage`, async ({ page, params }) => { + recordVideo(page); + + page.setDefaultTimeout(60 * 1000); + const syntheticsApp = syntheticsAppPageProvider({ page, kibanaUrl: params.kibanaUrl }); + + const services = new SyntheticsServices(params); + + before(async () => { + await services.cleaUp(); + await services.enableMonitorManagedViaApi(); + await services.addTestMonitor( + 'https://www.google.com', + { + type: 'browser', + urls: 'https://www.google.com', + custom_heartbeat_id: 'a47bfc4e-361a-4eb0-83f3-b5bb68781b5b', + locations: [ + { id: 'us_central', label: 'North America - US Central', isServiceManaged: true }, + ], + }, + 'a47bfc4e-361a-4eb0-83f3-b5bb68781b5b' + ); + }); + + after(async () => { + await services.cleaUp(); + }); + + step('Go to monitor summary page', async () => { + await syntheticsApp.navigateToOverview(true); + }); + + step('Monitor is as up in summary page', async () => { + await page.hover('text=https://www.google.com'); + await page.click('[aria-label="Open actions menu"]'); + await page.click('text=Go to monitor'); + await page.waitForSelector(byTestId('monitorLatestStatusUp')); + await page.click(byTestId('syntheticsMonitorHistoryTab')); + }); + + step('Go to test run page', async () => { + await page.click(byTestId('superDatePickerToggleQuickMenuButton')); + await page.click('text=Last 1 year'); + await page.click(byTestId('row-ab240846-8d22-11ed-8fac-52bb19a2321e')); + + await page.waitForSelector('text=Test run details'); + await page.waitForSelector('text=Go to https://www.google.com'); + await page.waitForSelector('text=After 2.1 s'); + }); +}); diff --git a/x-pack/plugins/synthetics/e2e/journeys/uptime/alerts/status_alert_flyouts_in_alerting_app.ts b/x-pack/plugins/synthetics/e2e/journeys/uptime/alerts/status_alert_flyouts_in_alerting_app.ts index 7fd8355a69a75..325633bba7413 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/uptime/alerts/status_alert_flyouts_in_alerting_app.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/uptime/alerts/status_alert_flyouts_in_alerting_app.ts @@ -61,8 +61,9 @@ journey('StatusFlyoutInAlertingApp', async ({ page, params }) => { await page.click(byTestId('"xpack.synthetics.alerts.monitorStatus.filterBar"')); - await assertText({ page, text: 'browser' }); - await assertText({ page, text: 'http' }); + await page.waitForSelector(`text=browser`); + await page.waitForSelector(`text=http`); + await retry.tryForTime(30 * 1000, async () => { await page.click('text=browser'); diff --git a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_details.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_details.journey.ts index 85b113af7fd9f..e386c8717d39a 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_details.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_details.journey.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { journey, step, expect, after, Page } from '@elastic/synthetics'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; import { monitorManagementPageProvider } from '../../page_objects/uptime/monitor_management'; @@ -14,7 +14,7 @@ journey('MonitorDetails', async ({ page, params }: { page: Page; params: any }) recordVideo(page); const uptime = monitorManagementPageProvider({ page, kibanaUrl: params.kibanaUrl }); - const name = `Test monitor ${uuid.v4()}`; + const name = `Test monitor ${uuidv4()}`; after(async () => { await uptime.enableMonitorManagement(false); diff --git a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_management.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_management.journey.ts index 188b322b36834..f5a5ed151c056 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_management.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_management.journey.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { journey, step, expect, after, Page } from '@elastic/synthetics'; import { byTestId } from '@kbn/observability-plugin/e2e/utils'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; @@ -18,10 +18,10 @@ const basicMonitorDetails = { location: customLocation || 'US Central', schedule: '3', }; -const httpName = `http monitor ${uuid.v4()}`; -const icmpName = `icmp monitor ${uuid.v4()}`; -const tcpName = `tcp monitor ${uuid.v4()}`; -const browserName = `browser monitor ${uuid.v4()}`; +const httpName = `http monitor ${uuidv4()}`; +const icmpName = `icmp monitor ${uuidv4()}`; +const tcpName = `tcp monitor ${uuidv4()}`; +const browserName = `browser monitor ${uuidv4()}`; const configuration = { [DataStream.HTTP]: { @@ -154,7 +154,7 @@ journey('Monitor Management breadcrumbs', async ({ page, params }: { page: Page; recordVideo(page); const uptime = monitorManagementPageProvider({ page, kibanaUrl: params.kibanaUrl }); const defaultMonitorDetails = { - name: `Sample monitor ${uuid.v4()}`, + name: `Sample monitor ${uuidv4()}`, location: 'US Central', schedule: '3', apmServiceName: 'service', @@ -218,13 +218,13 @@ journey( const sortedMonitors = [ Object.assign({}, configuration[DataStream.ICMP].monitorConfig, { - name: `A ${uuid.v4()}`, + name: `A ${uuidv4()}`, }), Object.assign({}, configuration[DataStream.ICMP].monitorConfig, { - name: `B ${uuid.v4()}`, + name: `B ${uuidv4()}`, }), Object.assign({}, configuration[DataStream.ICMP].monitorConfig, { - name: `aa ${uuid.v4()}`, + name: `aa ${uuidv4()}`, }), ]; diff --git a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_name.journey.ts b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_name.journey.ts index 3ad8ed80ff259..972b64d39217b 100644 --- a/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_name.journey.ts +++ b/x-pack/plugins/synthetics/e2e/journeys/uptime/monitor_name.journey.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { journey, step, expect, Page } from '@elastic/synthetics'; import { byTestId } from '@kbn/observability-plugin/e2e/utils'; import { recordVideo } from '@kbn/observability-plugin/e2e/record_video'; @@ -13,7 +13,7 @@ import { monitorManagementPageProvider } from '../../page_objects/uptime/monitor journey(`MonitorName`, async ({ page, params }: { page: Page; params: any }) => { recordVideo(page); - const name = `Test monitor ${uuid.v4()}`; + const name = `Test monitor ${uuidv4()}`; const uptime = monitorManagementPageProvider({ page, kibanaUrl: params.kibanaUrl }); const createBasicMonitor = async () => { diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/location_status_badges.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/location_status_badges.tsx new file mode 100644 index 0000000000000..f0957fb5cdfa6 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/location_status_badges.tsx @@ -0,0 +1,141 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useState } from 'react'; +import { + EuiBadge, + EuiFlexGroup, + EuiFlexItem, + EuiHealth, + EuiIcon, + EuiLoadingSpinner, + EuiToolTip, +} from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import { LocationsStatus } from '../../../hooks'; +import { useMonitorDetailLocator } from '../../../hooks/use_monitor_detail_locator'; +const DEFAULT_DISPLAY_COUNT = 3; + +export const LocationStatusBadges = ({ + loading, + locations, + configId, +}: { + locations: LocationsStatus; + loading: boolean; + configId: string; +}) => { + const [toDisplay, setToDisplay] = useState(DEFAULT_DISPLAY_COUNT); + + if (loading && !locations) { + return ; + } + + const locationsToDisplay = locations.slice(0, toDisplay); + + return ( + + {locationsToDisplay.map((loc) => ( + + + + ))} + {locations.length > toDisplay && ( + + + {locations.slice(toDisplay, locations.length).map((loc) => ( + {loc.label} + ))} + + } + > + { + setToDisplay(locations.length); + }} + onClickAriaLabel={EXPAND_LOCATIONS_LABEL} + > + +{locations.length - toDisplay} + + + + )} + {toDisplay > DEFAULT_DISPLAY_COUNT && ( + + + { + setToDisplay(DEFAULT_DISPLAY_COUNT); + }} + onClickAriaLabel={COLLAPSE_LOCATIONS_LABEL} + > + -{locations.length - DEFAULT_DISPLAY_COUNT} + + + + )} + + ); +}; + +const MonitorDetailLinkForLocation = ({ + configId, + locationId, + locationLabel, + color, +}: { + configId: string; + locationId: string; + locationLabel: string; + color: string; +}) => { + const monitorDetailLinkUrl = useMonitorDetailLocator({ + configId, + locationId, + }); + + return ( + } + color="hollow" + iconOnClickAriaLabel={CLICK_LOCATION_LABEL} + iconOnClick={() => { + // Empty + }} + href={monitorDetailLinkUrl ?? '/'} + > + {locationLabel} + + ); +}; + +const EXPAND_LOCATIONS_LABEL = i18n.translate( + 'xpack.synthetics.management.monitorList.locations.expand', + { + defaultMessage: 'Click to view remaining locations', + } +); + +const COLLAPSE_LOCATIONS_LABEL = i18n.translate( + 'xpack.synthetics.management.monitorList.locations.collapse', + { + defaultMessage: 'Click to collapse locations', + } +); + +const CLICK_LOCATION_LABEL = i18n.translate('xpack.synthetics.management.location.clickMessage', { + defaultMessage: 'Click to view details for this location.', +}); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_details_panel.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_details_panel.tsx index de663a47cf878..2bfd04fa26d57 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_details_panel.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_details_panel.tsx @@ -7,32 +7,38 @@ import React from 'react'; import { - EuiDescriptionList, - EuiDescriptionListTitle as TitleLabel, - EuiDescriptionListDescription as DescriptionLabel, - EuiBadge, - EuiSpacer, EuiLink, EuiText, + EuiSpacer, + EuiDescriptionList, EuiLoadingContent, + EuiDescriptionListTitle, + EuiDescriptionListDescription, } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { useDispatch } from 'react-redux'; import { euiStyled } from '@kbn/kibana-react-plugin/common'; -import moment from 'moment'; -import { capitalize } from 'lodash'; +import { TagsBadges } from './tag_badges'; +import { useFormatTestRunAt } from '../../../utils/monitor_test_result/test_time_formats'; import { PanelWithTitle } from './panel_with_title'; -import { useKibanaDateFormat } from '../../../../../hooks/use_kibana_date_format'; import { MonitorEnabled } from '../../monitors_page/management/monitor_list_table/monitor_enabled'; import { getMonitorAction } from '../../../state'; import { LocationsStatus } from '../../monitor_details/monitor_summary/locations_status'; -import { MonitorTags } from '../../monitor_details/monitor_summary/monitor_tags'; import { ConfigKey, EncryptedSyntheticsSavedMonitor, MonitorFields, Ping, } from '../../../../../../common/runtime_types'; +import { MonitorTypeBadge } from './monitor_type_badge'; + +const TitleLabel = euiStyled(EuiDescriptionListTitle)` + width: 40%; +`; + +const DescriptionLabel = euiStyled(EuiDescriptionListDescription)` + width: 60%; +`; export const MonitorDetailsPanel = ({ monitor, @@ -106,22 +112,18 @@ export const MonitorDetailsPanel = ({ {configId} {MONITOR_TYPE_LABEL} - - {monitor?.type === 'browser' - ? capitalize(monitor?.type) - : monitor?.type?.toUpperCase()} - + {FREQUENCY_LABEL} {frequencyStr(monitor[ConfigKey.SCHEDULE])} {LOCATIONS_LABEL} - + {TAGS_LABEL} - + @@ -183,9 +185,9 @@ function translateUnitMessage(unitMsg: string) { } const Time = ({ timestamp }: { timestamp?: string }) => { - const formatStr = useKibanaDateFormat(); + const dateTimeFormatted = useFormatTestRunAt(timestamp); - return timestamp ? : null; + return timestamp ? : null; }; export const WrapperStyle = euiStyled.div` diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_location_select.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_location_select.tsx index dc87881eb7ab2..9e2d864e720b0 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_location_select.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_location_select.tsx @@ -15,14 +15,12 @@ import { EuiPopover, } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { useTheme } from '@kbn/observability-plugin/public'; import React, { useMemo, useState, useCallback } from 'react'; import { EncryptedSyntheticsSavedMonitor, ServiceLocation, } from '../../../../../../common/runtime_types'; -import { useLocations } from '../../../hooks'; import { useStatusByLocation } from '../../../hooks'; export const MonitorLocationSelect = ({ @@ -40,11 +38,10 @@ export const MonitorLocationSelect = ({ selectedLocation?: ServiceLocation | null; monitorLocations?: EncryptedSyntheticsSavedMonitor['locations']; }) => { - const { locations } = useLocations(); - const theme = useTheme(); - - const { locations: locationsStatus, loading: loadingLocationsStatus } = - useStatusByLocation(configId); + const { locations: locationsStatus, loading: loadingLocationsStatus } = useStatusByLocation({ + configId, + monitorLocations, + }); const [isLocationListOpen, setIsLocationListOpen] = useState(false); const openLocationList = useCallback(() => setIsLocationListOpen(true), []); @@ -65,34 +62,18 @@ export const MonitorLocationSelect = ({ const menuItems = loadingLocationsStatus && !locationsStatus ? [Loading...] - : monitorLocations + : locationsStatus .map((location) => { - const fullLocation = locations.find((l) => l.id === location.id); - if (!fullLocation) { - return; - } - - const locationStatus = locationsStatus.find( - (ls) => ls.observer?.geo?.name === fullLocation.label - ); - - const locationHealthColor = - typeof locationStatus === 'undefined' - ? 'subdued' - : (locationStatus?.summary?.down ?? 0) > 0 - ? theme.eui.euiColorVis9 // down - : theme.eui.euiColorVis0; // up - return ( } + icon={} onClick={() => { closeLocationList(); - onChange(fullLocation.id, fullLocation.label); + onChange(location.id, location.label); }} > - {fullLocation.label} + {location.label} ); }) @@ -123,14 +104,11 @@ export const MonitorLocationSelect = ({ isDisabled, isLocationListOpen, loadingLocationsStatus, - locations, locationsStatus, monitorLocations, onChange, openLocationList, selectedLocation, - theme.eui.euiColorVis0, - theme.eui.euiColorVis9, ]); if (!selectedLocation || !monitorLocations) { diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_status.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_status.tsx index 271f748c471ab..0f0c548160a0a 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_status.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_status.tsx @@ -5,26 +5,24 @@ * 2.0. */ import React from 'react'; -import { EuiBadge, EuiDescriptionList, EuiLoadingSpinner } from '@elastic/eui'; +import { EuiBadge, EuiDescriptionList, EuiLoadingContent } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; import { EncryptedSyntheticsMonitor } from '../../../../../../common/runtime_types'; -export const MonitorStatus = ({ - loading, - monitor, +const BadgeStatus = ({ status, - compressed = true, + monitor, + loading, + isBrowserType, }: { + status?: string; loading?: boolean; - compressed?: boolean; monitor: EncryptedSyntheticsMonitor; - status?: string; + isBrowserType: boolean; }) => { - const isBrowserType = monitor.type === 'browser'; - - const badge = loading ? ( - - ) : !status ? ( + return loading && !monitor ? ( + + ) : !status || status === 'unknown' ? ( {PENDING_LABEL} @@ -37,12 +35,38 @@ export const MonitorStatus = ({ {isBrowserType ? FAILED_LABEL : DOWN_LABEL} ); +}; + +export const MonitorStatus = ({ + loading, + monitor, + status, + compressed = true, +}: { + loading?: boolean; + compressed?: boolean; + monitor: EncryptedSyntheticsMonitor; + status?: string; +}) => { + const isBrowserType = monitor.type === 'browser'; return ( + ), + }, + ]} /> ); }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_type_badge.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_type_badge.tsx new file mode 100644 index 0000000000000..5664d30761a96 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/monitor_type_badge.tsx @@ -0,0 +1,78 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { MouseEvent, KeyboardEvent } from 'react'; +import { EuiBadge, EuiIcon } from '@elastic/eui'; +import { euiStyled } from '@kbn/kibana-react-plugin/common'; +import { + EncryptedSyntheticsMonitor, + ConfigKey, + FormMonitorType, + DataStream, +} from '../../../../../../common/runtime_types'; + +export function MonitorTypeBadge({ + monitor, + ariaLabel, + onClick, + onKeyPress, +}: { + monitor: EncryptedSyntheticsMonitor; + ariaLabel?: string; + onClick?: (evt: MouseEvent) => void; + onKeyPress?: (evt: KeyboardEvent) => void; +}) { + const badge = ( + + {' '} + {getMonitorTypeBadgeTitle(monitor)} + + ); + + return onClick ? ( +
    + {badge} +
    + ) : ( + badge + ); +} + +function getMonitorTypeBadgeTitle(monitor: EncryptedSyntheticsMonitor) { + switch (monitor[ConfigKey.FORM_MONITOR_TYPE]) { + case FormMonitorType.TCP: + case FormMonitorType.HTTP: + case FormMonitorType.ICMP: + return monitor?.type?.toUpperCase(); + case FormMonitorType.SINGLE: + return 'Page'; + case FormMonitorType.MULTISTEP: + return 'Journey'; + } + + switch (monitor?.type) { + case DataStream.BROWSER: + return 'Journey'; + default: + return monitor?.type?.toUpperCase(); + } +} + +function getMonitorTypeBadgeIcon(monitor: EncryptedSyntheticsMonitor) { + return monitor?.type === 'browser' ? 'videoPlayer' : 'online'; +} + +const EuiBadgeStyled = euiStyled(EuiBadge)<{ 'data-is-clickable': boolean }>` + ${({ 'data-is-clickable': dataIsClickable }) => (dataIsClickable ? `cursor: pointer;` : '')} + &&& { + .euiBadge__text { + display: flex; + align-items: center; + gap: 4px; + } + } +`; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/tag_badges.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/tag_badges.tsx index 3dc6bbd1836bf..f92a2a524ff1d 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/tag_badges.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/components/tag_badges.tsx @@ -6,7 +6,7 @@ */ import React, { useState } from 'react'; -import { EuiBadge, EuiBadgeGroup, EuiText } from '@elastic/eui'; +import { EuiBadge, EuiFlexGroup, EuiFlexItem, EuiText, EuiToolTip } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; interface Props { @@ -33,47 +33,77 @@ export const TagsBadges = ({ tags, onClick }: Props) => { const tagsToDisplay = tags.slice(0, toDisplay); return ( - + {tagsToDisplay.map((tag) => ( // filtering only makes sense in monitor list, where we have summary - - { - onClick?.(tag); - }} - onClickAriaLabel={getFilterLabel(tag)} - color="hollow" - className="eui-textTruncate" - style={{ maxWidth: 120 }} - > - {tag} - + + {onClick ? ( + { + onClick(tag); + }} + onClickAriaLabel={getFilterLabel(tag)} + color="hollow" + className="eui-textTruncate" + style={{ maxWidth: 120 }} + > + {tag} + + ) : ( + + {tag} + + )} + ))} {tags.length > toDisplay && ( - { - setToDisplay(tags.length); - }} - onClickAriaLabel={EXPAND_TAGS_LABEL} - > - +{tags.length - toDisplay} - + + + {tags.slice(toDisplay, tags.length).map((tag) => ( + + {tag} + + ))} + + } + > + { + setToDisplay(tags.length); + }} + onClickAriaLabel={EXPAND_TAGS_LABEL} + > + +{tags.length - toDisplay} + + + )} - {tags.length === toDisplay && ( - { - setToDisplay(3); - }} - onClickAriaLabel={COLLAPSE_TAGS_LABEL} - > - -{tags.length - 3} - + {toDisplay > 3 && ( + + + { + setToDisplay(3); + }} + onClickAriaLabel={COLLAPSE_TAGS_LABEL} + > + -{tags.length - 3} + + + )} - + ); }; @@ -82,7 +112,7 @@ const EXPAND_TAGS_LABEL = i18n.translate('xpack.synthetics.management.monitorLis }); const COLLAPSE_TAGS_LABEL = i18n.translate( - 'xpack.synthetics.management.monitorList.tags.collpase', + 'xpack.synthetics.management.monitorList.tags.collapse', { defaultMessage: 'Click to collapse tags', } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/edit_monitor.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/edit_monitor.tsx new file mode 100644 index 0000000000000..3573d2cffa133 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/edit_monitor.tsx @@ -0,0 +1,33 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { EuiButton } from '@elastic/eui'; +import React from 'react'; +import { i18n } from '@kbn/i18n'; +import { useParams } from 'react-router-dom'; +import { useSyntheticsSettingsContext } from '../../../contexts'; + +export const EditMonitorLink = () => { + const { basePath } = useSyntheticsSettingsContext(); + + const { monitorId } = useParams<{ monitorId: string }>(); + + return ( + + {EDIT_MONITOR} + + ); +}; + +const EDIT_MONITOR = i18n.translate('xpack.synthetics.monitorSummary.editMonitor', { + defaultMessage: 'Edit monitor', +}); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/error_details_link.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/error_details_link.tsx new file mode 100644 index 0000000000000..342608865a50a --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/error_details_link.tsx @@ -0,0 +1,74 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { EuiLink, EuiButtonEmpty } from '@elastic/eui'; +import React from 'react'; +import { i18n } from '@kbn/i18n'; +import { useSelectedLocation } from '../../monitor_details/hooks/use_selected_location'; +import { useSyntheticsSettingsContext } from '../../../contexts'; +import { getErrorDetailsUrl } from '../../monitor_details/monitor_errors/errors_list'; + +export const ErrorDetailsLink = ({ + stateId, + configId, + label, +}: { + configId: string; + stateId: string; + label: string; +}) => { + const { basePath } = useSyntheticsSettingsContext(); + const selectedLocation = useSelectedLocation(); + + return ( + + {label ?? VIEW_DETAILS} + + ); +}; + +export const ErrorDetailsButton = ({ + stateId, + configId, + label, +}: { + configId: string; + stateId: string; + label?: string; +}) => { + const { basePath } = useSyntheticsSettingsContext(); + const selectedLocation = useSelectedLocation(); + + if (!selectedLocation) return null; + + return ( + + {label ?? VIEW_DETAILS} + + ); +}; + +const VIEW_DETAILS = i18n.translate('xpack.synthetics.monitor.step.viewErrorDetails', { + defaultMessage: 'View error details', +}); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/step_details_link.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/step_details_link.tsx index f95984eafa08d..d9c2da03756b9 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/step_details_link.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/links/step_details_link.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { EuiButtonIcon } from '@elastic/eui'; +import { EuiButtonEmpty, EuiButtonIcon } from '@elastic/eui'; import React from 'react'; import { i18n } from '@kbn/i18n'; import { useSelectedLocation } from '../../monitor_details/hooks/use_selected_location'; @@ -15,14 +15,30 @@ export const StepDetailsLinkIcon = ({ stepIndex, checkGroup, configId, + asButton, + label, }: { checkGroup: string; + label?: string; configId: string; stepIndex?: number; + asButton?: boolean; }) => { const { basePath } = useSyntheticsSettingsContext(); const selectedLocation = useSelectedLocation(); + if (asButton) { + return ( + + {label ?? VIEW_DETAILS} + + ); + } + return ( { const testRunUrl = `/monitor/${monitorId}/test-run/${checkGroup}?locationId=${locationId}`; - if (basePath) { - return `${basePath}/app/synthetics${testRunUrl}`; - } else { - return testRunUrl; - } + return `${basePath}/app/synthetics${testRunUrl}`; +}; + +export const getTestRunDetailRelativeLink = ({ + monitorId, + checkGroup, + locationId, +}: { + monitorId: string; + checkGroup: string; + locationId?: string; +}) => { + return `/monitor/${monitorId}/test-run/${checkGroup}?locationId=${locationId}`; }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/monitor_test_result/status_badge.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/monitor_test_result/status_badge.tsx index a18c0d7a2ca7e..acfca86c2dea0 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/monitor_test_result/status_badge.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/monitor_test_result/status_badge.tsx @@ -7,10 +7,14 @@ import React from 'react'; import { i18n } from '@kbn/i18n'; -import { EuiBadge, IconColor, EuiThemeComputed } from '@elastic/eui'; +import { EuiBadge, IconColor, EuiThemeComputed, EuiLoadingContent } from '@elastic/eui'; -type MonitorStatus = 'succeeded' | 'failed' | 'skipped'; +type MonitorStatus = 'succeeded' | 'failed' | 'skipped' | 'unknown'; export const StatusBadge = ({ status }: { status: MonitorStatus }) => { + if (status === 'unknown') { + return ; + } + return ( {status === 'succeeded' ? COMPLETE_LABEL : status === 'failed' ? FAILED_LABEL : SKIPPED_LABEL} @@ -18,7 +22,7 @@ export const StatusBadge = ({ status }: { status: MonitorStatus }) => { ); }; -export const parseBadgeStatus = (status: string) => { +export const parseBadgeStatus = (status?: string) => { switch (status) { case 'succeeded': case 'success': @@ -32,7 +36,7 @@ export const parseBadgeStatus = (status: string) => { case 'skipped': return 'skipped'; default: - return 'skipped'; + return 'unknown'; } }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/screenshot/journey_step_screenshot_container.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/screenshot/journey_step_screenshot_container.tsx index 28efeeaf4946f..0527b6ad8c67a 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/screenshot/journey_step_screenshot_container.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/screenshot/journey_step_screenshot_container.tsx @@ -39,7 +39,9 @@ export const JourneyStepScreenshotContainer = ({ const { basePath } = useContext(SyntheticsSettingsContext); - const imgPath = `${basePath}/internal/uptime/journey/screenshot/${checkGroup}/${initialStepNumber}`; + const imgPath = checkGroup + ? `${basePath}/internal/uptime/journey/screenshot/${checkGroup}/${initialStepNumber}` + : ''; const intersection = useIntersection(intersectionRef, { root: null, diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/error_details/error_details_page.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/error_details/error_details_page.tsx index 24dc7c53d3fe6..1545c5a1df10b 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/error_details/error_details_page.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/error_details/error_details_page.tsx @@ -43,7 +43,7 @@ export function ErrorDetailsPage() { - + diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.test.tsx index dcb009c809a5e..47c1ce7989ef0 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.test.tsx @@ -149,20 +149,23 @@ describe('defaults', () => { }); it.each([ - [DataStream.HTTP, 'testCA'], - [DataStream.HTTP, ''], - [DataStream.TCP, 'testCA'], - [DataStream.TCP, ''], - ])('correctly formats isTLSEnabled', (formType, testCA) => { + [DataStream.HTTP, true], + [DataStream.HTTP, false], + [DataStream.TCP, true], + [DataStream.TCP, false], + ])('correctly formats isTLSEnabled', (formType, isTLSEnabled) => { const monitor = { ...DEFAULT_FIELDS[formType as DataStream], [ConfigKey.FORM_MONITOR_TYPE]: formType as unknown as FormMonitorType, - [ConfigKey.TLS_CERTIFICATE_AUTHORITIES]: testCA, + [ConfigKey.TLS_CERTIFICATE_AUTHORITIES]: 'mockCA', + [ConfigKey.METADATA]: { + is_tls_enabled: isTLSEnabled, + }, }; expect(formatDefaultFormValues(monitor)).toEqual({ ...monitor, - isTLSEnabled: Boolean(testCA), - [ConfigKey.TLS_CERTIFICATE_AUTHORITIES]: testCA, + [ConfigKey.TLS_CERTIFICATE_AUTHORITIES]: 'mockCA', + isTLSEnabled, }); }); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.tsx index edef022a2e997..b8e7d02b7c683 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/defaults.tsx @@ -4,16 +4,15 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import { isEqual } from 'lodash'; import { formatKibanaNamespace } from '../../../../../../common/formatters'; -import { DEFAULT_FIELDS, DEFAULT_TLS_FIELDS } from '../constants'; +import { DEFAULT_FIELDS } from '../constants'; import { ConfigKey, DataStream, FormMonitorType, SyntheticsMonitor, BrowserFields, - TLSFields, + HTTPFields, } from '../types'; export const getDefaultFormFields = ( @@ -96,16 +95,7 @@ export const formatDefaultFormValues = (monitor?: SyntheticsMonitor) => { case FormMonitorType.TCP: return { ...monitorWithFormMonitorType, - isTLSEnabled: isCustomTLSEnabled(monitor), + isTLSEnabled: (monitor as HTTPFields)[ConfigKey.METADATA].is_tls_enabled, }; } }; - -const isCustomTLSEnabled = (monitor: SyntheticsMonitor) => { - const sslKeys = Object.keys(monitor).filter((key) => key.includes('ssl')) as unknown as Array< - keyof TLSFields - >; - const sslValues: Record = {}; - sslKeys.map((key) => (sslValues[key] = (monitor as TLSFields)[key])); - return !isEqual(sslValues, DEFAULT_TLS_FIELDS); -}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.test.tsx index d13213766c3db..c284df9de90e7 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.test.tsx @@ -294,17 +294,15 @@ describe('format', () => { } ); - it.each([ - ['testCA', true], - ['', false], - ])('correctly formats form fields to monitor type', (certificateAuthorities, isTLSEnabled) => { + it.each([true, false])('correctly formats isTLSEnabled', (isTLSEnabled) => { expect( format({ ...formValues, + isTLSEnabled, ssl: { // @ts-ignore next ...formValues.ssl, - certificate_authorities: certificateAuthorities, + certificate_authorities: 'mockCA', }, }) ).toEqual({ @@ -346,7 +344,7 @@ describe('format', () => { }, 'service.name': '', 'ssl.certificate': '', - 'ssl.certificate_authorities': certificateAuthorities, + 'ssl.certificate_authorities': 'mockCA', 'ssl.key': '', 'ssl.key_passphrase': '', 'ssl.supported_protocols': ['TLSv1.1', 'TLSv1.2', 'TLSv1.3'], diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.ts b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.ts index 3495e0104e852..80afdbb57b73b 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/formatter.ts @@ -4,9 +4,9 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import { get, isEqual } from 'lodash'; +import { get } from 'lodash'; import { ConfigKey, DataStream, FormMonitorType, MonitorFields } from '../types'; -import { DEFAULT_FIELDS, DEFAULT_TLS_FIELDS } from '../constants'; +import { DEFAULT_FIELDS } from '../constants'; export const formatter = (fields: Record) => { const monitorType = fields[ConfigKey.MONITOR_TYPE] as DataStream; @@ -46,14 +46,14 @@ export const format = (fields: Record) => { [FormMonitorType.HTTP]: { ...formattedFields, [ConfigKey.METADATA]: { - is_tls_enabled: isCustomTLSEnabled(formattedFields), + is_tls_enabled: fields.isTLSEnabled, }, [ConfigKey.FORM_MONITOR_TYPE]: FormMonitorType.HTTP, }, [FormMonitorType.TCP]: { ...formattedFields, [ConfigKey.METADATA]: { - is_tls_enabled: isCustomTLSEnabled(formattedFields), + is_tls_enabled: fields.isTLSEnabled, }, [ConfigKey.FORM_MONITOR_TYPE]: FormMonitorType.TCP, }, @@ -64,11 +64,3 @@ export const format = (fields: Record) => { }; return formattedMap[fields[ConfigKey.FORM_MONITOR_TYPE] as FormMonitorType]; }; - -const isCustomTLSEnabled = (fields: MonitorFields) => { - const tlsFields: Record = {}; - Object.keys(DEFAULT_TLS_FIELDS).map((key) => { - tlsFields[key] = fields[key as keyof MonitorFields]; - }); - return !isEqual(tlsFields, DEFAULT_TLS_FIELDS); -}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/run_test_btn.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/run_test_btn.tsx index 36a46b63b58a5..17c8fd1f3fef0 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/run_test_btn.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_add_edit/form/run_test_btn.tsx @@ -118,9 +118,12 @@ const TEST_NOW_DESCRIPTION = i18n.translate('xpack.synthetics.testRun.descriptio defaultMessage: 'Test your monitor and verify the results before saving', }); -const TEST_SCHEDULED_LABEL = i18n.translate('xpack.synthetics.monitorList.testNow.scheduled', { - defaultMessage: 'Test is already scheduled', -}); +export const TEST_SCHEDULED_LABEL = i18n.translate( + 'xpack.synthetics.monitorList.testNow.scheduled', + { + defaultMessage: 'Test is already scheduled', + } +); const PRIVATE_AVAILABLE_LABEL = i18n.translate( 'xpack.synthetics.monitorList.testNow.available.private', @@ -129,9 +132,12 @@ const PRIVATE_AVAILABLE_LABEL = i18n.translate( } ); -const TEST_NOW_ARIA_LABEL = i18n.translate('xpack.synthetics.monitorList.testNow.AriaLabel', { - defaultMessage: 'Click to run test now', -}); +export const TEST_NOW_ARIA_LABEL = i18n.translate( + 'xpack.synthetics.monitorList.testNow.AriaLabel', + { + defaultMessage: 'Click to run test now', + } +); const RUN_TEST = i18n.translate('xpack.synthetics.monitorList.runTest.label', { defaultMessage: 'Run test', diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/hooks/use_journey_steps.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/hooks/use_journey_steps.tsx index a5f6d38b2a4a4..75d6b623e34e0 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/hooks/use_journey_steps.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/hooks/use_journey_steps.tsx @@ -29,7 +29,9 @@ export const useJourneySteps = (checkGroup?: string, lastRefresh?: number) => { const dispatch = useDispatch(); useEffect(() => { - dispatch(fetchJourneyAction.get({ checkGroup: checkGroupId })); + if (checkGroupId) { + dispatch(fetchJourneyAction.get({ checkGroup: checkGroupId })); + } }, [checkGroupId, dispatch, lastRefresh]); const isFailed = @@ -43,7 +45,7 @@ export const useJourneySteps = (checkGroup?: string, lastRefresh?: number) => { const stepLabels = stepEnds.map((stepEnd) => stepEnd?.synthetics?.step?.name ?? ''); const currentStep = stepIndex - ? journeyData?.steps.find((step) => step.synthetics?.step?.index === Number(stepIndex)) + ? stepEnds.find((step) => step.synthetics?.step?.index === Number(stepIndex)) : undefined; return { diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_details_last_run.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_details_last_run.tsx index 891421e1158d3..311f1b49b8e79 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_details_last_run.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_details_last_run.tsx @@ -4,30 +4,23 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import React from 'react'; +import React, { ReactElement } from 'react'; import moment from 'moment'; -import { EuiDescriptionList, EuiLoadingSpinner } from '@elastic/eui'; +import { EuiDescriptionList, EuiLoadingContent } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; -import { useSelectedMonitor } from './hooks/use_selected_monitor'; import { useMonitorLatestPing } from './hooks/use_monitor_latest_ping'; export const MonitorDetailsLastRun: React.FC = () => { - const { monitor } = useSelectedMonitor(); const { latestPing, loading: pingsLoading } = useMonitorLatestPing(); + let description: string | ReactElement = latestPing + ? moment(latestPing.timestamp).fromNow() + : '--'; - if (!monitor) { - return null; + if (!latestPing && pingsLoading) { + description = ; } - const description = pingsLoading ? ( - - ) : latestPing ? ( - moment(latestPing.timestamp).fromNow() - ) : ( - '--' - ); - return ; }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_list.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_list.tsx index 48f6ea76b12ed..b7b801b5a1b9a 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_list.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_list.tsx @@ -7,8 +7,9 @@ import { i18n } from '@kbn/i18n'; import React, { MouseEvent, useMemo, useState } from 'react'; -import { EuiBasicTable, EuiLink, EuiSpacer, EuiText } from '@elastic/eui'; +import { EuiBasicTable, EuiSpacer, EuiText } from '@elastic/eui'; import { useHistory, useParams } from 'react-router-dom'; +import { ErrorDetailsLink } from '../../common/links/error_details_link'; import { useSelectedLocation } from '../hooks/use_selected_location'; import { useKibanaDateFormat } from '../../../../../hooks/use_kibana_date_format'; import { Ping } from '../../../../../../common/runtime_types'; @@ -17,17 +18,13 @@ import { formatTestDuration, formatTestRunAt, } from '../../../utils/monitor_test_result/test_time_formats'; -import { useMonitorErrors } from '../hooks/use_monitor_errors'; -import { useSyntheticsSettingsContext } from '../../../contexts'; -export const ErrorsList = () => { +export const ErrorsList = ({ errorStates, loading }: { errorStates: Ping[]; loading: boolean }) => { const [pageIndex, setPageIndex] = useState(0); const [pageSize, setPageSize] = useState(10); const [sortField, setSortField] = useState('@timestamp'); const [sortDirection, setSortDirection] = useState<'asc' | 'desc'>('desc'); - const { errorStates, loading } = useMonitorErrors(); - const { monitorId } = useParams<{ monitorId: string }>(); const items = errorStates.slice(pageIndex * pageSize, pageIndex * pageSize + pageSize); @@ -42,8 +39,6 @@ export const ErrorsList = () => { const isBrowserType = errorStates[0]?.monitor.type === 'browser'; - const { basePath } = useSyntheticsSettingsContext(); - const history = useHistory(); const format = useKibanaDateFormat(); @@ -57,16 +52,11 @@ export const ErrorsList = () => { sortable: true, render: (value: string, item: Ping) => { return ( - - {formatTestRunAt(item.state!.started_at, format)} - + ); }, }, @@ -152,16 +142,16 @@ export const ErrorsList = () => { export const getErrorDetailsUrl = ({ basePath, - monitorId, + configId, stateId, locationId, }: { stateId: string; basePath: string; - monitorId: string; + configId: string; locationId: string; }) => { - return `${basePath}/app/synthetics/monitor/${monitorId}/errors/${stateId}?locationId=${locationId}`; + return `${basePath}/app/synthetics/monitor/${configId}/errors/${stateId}?locationId=${locationId}`; }; const ERRORS_LIST_LABEL = i18n.translate('xpack.synthetics.errorsList.label', { diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_tab_content.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_tab_content.tsx new file mode 100644 index 0000000000000..8317614ef889b --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/errors_tab_content.tsx @@ -0,0 +1,85 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { EuiFlexGroup, EuiFlexItem, EuiSpacer } from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import { Ping } from '../../../../../../common/runtime_types'; +import { PanelWithTitle } from '../../common/components/panel_with_title'; +import { MonitorErrorsCount } from '../monitor_summary/monitor_errors_count'; +import { FailedTestsCount } from './failed_tests_count'; +import { MonitorFailedTests } from './failed_tests'; +import { ErrorsList } from './errors_list'; +import { useAbsoluteDate, useGetUrlParams } from '../../../hooks'; +import { useMonitorQueryId } from '../hooks/use_monitor_query_id'; + +export const ErrorsTabContent = ({ + errorStates, + loading, +}: { + errorStates: Ping[]; + loading: boolean; +}) => { + const { dateRangeStart, dateRangeEnd } = useGetUrlParams(); + + const time = useAbsoluteDate({ from: dateRangeStart, to: dateRangeEnd }); + + const monitorId = useMonitorQueryId(); + + return ( + <> + + + + + + {monitorId && ( + + )} + + + + + + + + + + + + + + + + + + + + + + + + + + ); +}; + +const ERRORS_LABEL = i18n.translate('xpack.synthetics.errors.label', { + defaultMessage: 'Errors', +}); + +const OVERVIEW_LABEL = i18n.translate('xpack.synthetics.errors.overview', { + defaultMessage: 'Overview', +}); + +const FAILED_TESTS_LABEL = i18n.translate('xpack.synthetics.errors.failedTests', { + defaultMessage: 'Failed tests', +}); + +const FAILED_TESTS_BY_STEPS_LABEL = i18n.translate('xpack.synthetics.errors.failedTests.byStep', { + defaultMessage: 'Failed tests by step', +}); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/monitor_errors.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/monitor_errors.tsx index 946140007838d..b92c8c8fdd7d6 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/monitor_errors.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_errors/monitor_errors.tsx @@ -7,97 +7,90 @@ import { EuiFlexGroup, EuiFlexItem, - EuiPanel, + EuiIcon, + EuiLoadingSpinner, EuiSpacer, + EuiText, EuiTitle, - useEuiTheme, } from '@elastic/eui'; import React from 'react'; import { i18n } from '@kbn/i18n'; -import { useMonitorQueryId } from '../hooks/use_monitor_query_id'; -import { FailedTestsCount } from './failed_tests_count'; -import { useAbsoluteDate, useGetUrlParams } from '../../../hooks'; +import { useMonitorErrors } from '../hooks/use_monitor_errors'; import { SyntheticsDatePicker } from '../../common/date_picker/synthetics_date_picker'; -import { MonitorErrorsCount } from '../monitor_summary/monitor_errors_count'; -import { ErrorsList } from './errors_list'; -import { MonitorFailedTests } from './failed_tests'; +import { ErrorsTabContent } from './errors_tab_content'; export const MonitorErrors = () => { - const { euiTheme } = useEuiTheme(); + const { errorStates, loading } = useMonitorErrors(); - const { dateRangeStart, dateRangeEnd } = useGetUrlParams(); + const initialLoading = loading && errorStates.length === 0; - const time = useAbsoluteDate({ from: dateRangeStart, to: dateRangeEnd }); - - const monitorId = useMonitorQueryId(); + const emptyState = !loading && errorStates.length === 0; return ( <> - - - - -

    {OVERVIEW_LABEL}

    -
    - - - {monitorId && ( - - )} - - - - - -
    -
    - - - -

    {FAILED_TESTS_LABEL}

    -
    - -
    -
    -
    - - - - - -

    {ERRORS_LABEL}

    -
    - -
    -
    - - - -

    - {FAILED_TESTS_BY_STEPS_LABEL} -

    -
    -
    -
    -
    + {initialLoading && } + {emptyState && } +
    + +
    ); }; -const ERRORS_LABEL = i18n.translate('xpack.synthetics.errors.label', { - defaultMessage: 'Errors', +const LoadingErrors = () => { + return ( + + + + + + + +

    {CHEKCING_FOR_ERRORS}

    +
    + + + + {LOADING_DESCRIPTION} +
    +
    + ); +}; + +const EmptyErrors = () => { + return ( + + + + + + + +

    {NO_ERRORS_FOUND}

    +
    + + + + {KEEP_CALM} +
    +
    + ); +}; + +const KEEP_CALM = i18n.translate('xpack.synthetics.errors.keepCalm', { + defaultMessage: 'Keep calm and carry on.', }); -const OVERVIEW_LABEL = i18n.translate('xpack.synthetics.errors.overview', { - defaultMessage: 'Overview', +const NO_ERRORS_FOUND = i18n.translate('xpack.synthetics.errors.noErrorsFound', { + defaultMessage: 'No errors found', }); -const FAILED_TESTS_LABEL = i18n.translate('xpack.synthetics.errors.failedTests', { - defaultMessage: 'Failed tests', +const LOADING_DESCRIPTION = i18n.translate('xpack.synthetics.errors.loadingDescription', { + defaultMessage: 'This will take just a second.', }); -const FAILED_TESTS_BY_STEPS_LABEL = i18n.translate('xpack.synthetics.errors.failedTests.byStep', { - defaultMessage: 'Failed tests by step', +const CHEKCING_FOR_ERRORS = i18n.translate('xpack.synthetics.errors.checkingForErrors', { + defaultMessage: 'Checking for errors', }); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/last_test_run.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/last_test_run.tsx index b3aa2e129dc81..b22039f65ef9a 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/last_test_run.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/last_test_run.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import React, { useMemo } from 'react'; +import React from 'react'; import { EuiButton, EuiButtonEmpty, @@ -22,6 +22,7 @@ import { import { i18n } from '@kbn/i18n'; import { useParams } from 'react-router-dom'; +import { getTestRunDetailLink } from '../../common/links/test_details_link'; import { useSelectedLocation } from '../hooks/use_selected_location'; import { getErrorDetailsUrl } from '../monitor_errors/errors_list'; import { @@ -31,14 +32,13 @@ import { Ping, SyntheticsJourneyApiResponse, } from '../../../../../../common/runtime_types'; -import { formatTestRunAt } from '../../../utils/monitor_test_result/test_time_formats'; +import { useFormatTestRunAt } from '../../../utils/monitor_test_result/test_time_formats'; import { useSyntheticsRefreshContext, useSyntheticsSettingsContext } from '../../../contexts'; import { BrowserStepsList } from '../../common/monitor_test_result/browser_steps_list'; import { SinglePingResult } from '../../common/monitor_test_result/single_ping_result'; import { parseBadgeStatus, StatusBadge } from '../../common/monitor_test_result/status_badge'; -import { useKibanaDateFormat } from '../../../../../hooks/use_kibana_date_format'; import { useJourneySteps } from '../hooks/use_journey_steps'; import { useSelectedMonitor } from '../hooks/use_selected_monitor'; import { useMonitorLatestPing } from '../hooks/use_monitor_latest_ping'; @@ -107,7 +107,7 @@ export const LastTestRunComponent = ({ color="danger" href={getErrorDetailsUrl({ basePath, - monitorId: monitor?.id!, + configId: monitor?.id!, locationId: selectedLocation!.id, stateId: latestPing.state?.id!, })} @@ -148,14 +148,11 @@ const PanelHeader = ({ const { basePath } = useSyntheticsSettingsContext(); - const { monitorId } = useParams<{ monitorId: string }>(); + const selectedLocation = useSelectedLocation(); - const format = useKibanaDateFormat(); + const { monitorId } = useParams<{ monitorId: string }>(); - const lastRunTimestamp = useMemo( - () => (latestPing?.timestamp ? formatTestRunAt(latestPing?.timestamp, format) : ''), - [latestPing?.timestamp, format] - ); + const lastRunTimestamp = useFormatTestRunAt(latestPing?.timestamp); const isBrowserMonitor = monitor?.[ConfigKey.MONITOR_TYPE] === DataStream.BROWSER; @@ -208,7 +205,12 @@ const PanelHeader = ({ size="xs" iconType="inspect" iconSide="left" - href={`${basePath}/app/synthetics/monitor/${monitorId}/test-run/${latestPing?.monitor.check_group}`} + href={getTestRunDetailLink({ + basePath, + monitorId, + checkGroup: latestPing?.monitor.check_group, + locationId: selectedLocation?.id, + })} > {i18n.translate('xpack.synthetics.monitorDetails.summary.viewTestRun', { defaultMessage: 'View test run', diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/locations_status.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/locations_status.tsx index 51d50d1621e28..0e5101cece27b 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/locations_status.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/locations_status.tsx @@ -5,36 +5,18 @@ * 2.0. */ import React from 'react'; -import { EuiBadge, EuiBadgeGroup, EuiIcon, EuiLoadingSpinner } from '@elastic/eui'; -import { useTheme } from '@kbn/observability-plugin/public'; +import { LocationStatusBadges } from '../../common/components/location_status_badges'; +import { EncryptedSyntheticsSavedMonitor } from '../../../../../../common/runtime_types'; import { useStatusByLocation } from '../../../hooks/use_status_by_location'; -export const LocationsStatus = ({ configId }: { configId?: string }) => { - const { locations, loading } = useStatusByLocation(configId); +export const LocationsStatus = ({ + configId, + monitorLocations, +}: { + configId: string; + monitorLocations?: EncryptedSyntheticsSavedMonitor['locations']; +}) => { + const { locations, loading } = useStatusByLocation({ configId, monitorLocations }); - const theme = useTheme(); - - if (loading && !locations) { - return ; - } - - return ( - - {locations.map((loc) => ( - ( - 0 ? theme.eui.euiColorVis9 : theme.eui.euiColorVis0} - /> - )} - color="hollow" - > - {loc.observer?.geo?.name} - - ))} - - ); + return ; }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_summary.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_summary.tsx index 82fb8a2fb3cf6..94de32f1ac4cc 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_summary.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_summary.tsx @@ -58,19 +58,19 @@ export const MonitorSummary = () => {
    - + - + - + {monitorId && } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_tags.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_tags.tsx deleted file mode 100644 index 7960d5efbc1e7..0000000000000 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/monitor_tags.tsx +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import React from 'react'; -import { EuiBadge, EuiBadgeGroup } from '@elastic/eui'; - -export const MonitorTags = ({ tags }: { tags: string[] }) => { - return ( - - {tags.map((tag) => ( - {tag} - ))} - - ); -}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/test_runs_table.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/test_runs_table.tsx index e703abd8a77e2..22d124ffc4974 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/test_runs_table.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/monitor_summary/test_runs_table.tsx @@ -24,7 +24,10 @@ import { Criteria } from '@elastic/eui/src/components/basic_table/basic_table'; import { EuiTableSortingType } from '@elastic/eui/src/components/basic_table/table_types'; import { MONITOR_HISTORY_ROUTE, MONITOR_TYPES } from '../../../../../../common/constants'; -import { getTestRunDetailLink, TestDetailsLink } from '../../common/links/test_details_link'; +import { + getTestRunDetailRelativeLink, + TestDetailsLink, +} from '../../common/links/test_details_link'; import { ConfigKey, DataStream, Ping } from '../../../../../../common/runtime_types'; import { formatTestDuration } from '../../../utils/monitor_test_result/test_time_formats'; import { useGetUrlParams } from '../../../hooks'; @@ -166,7 +169,7 @@ export const TestRunsTable = ({ !targetElem.parentElement?.classList.contains('euiLink') ) { history.push( - getTestRunDetailLink({ + getTestRunDetailRelativeLink({ monitorId, checkGroup: item.monitor.check_group, locationId: selectedLocation?.id, diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/run_test_manually.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/run_test_manually.tsx index 475436d6577db..3c61057ba1f18 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/run_test_manually.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitor_details/run_test_manually.tsx @@ -5,15 +5,46 @@ * 2.0. */ -import { EuiButton } from '@elastic/eui'; +import { EuiButton, EuiToolTip } from '@elastic/eui'; import React from 'react'; import { i18n } from '@kbn/i18n'; +import { useDispatch, useSelector } from 'react-redux'; +import { TEST_NOW_ARIA_LABEL, TEST_SCHEDULED_LABEL } from '../monitor_add_edit/form/run_test_btn'; +import { useSelectedMonitor } from './hooks/use_selected_monitor'; +import { + manualTestMonitorAction, + manualTestRunInProgressSelector, +} from '../../state/manual_test_runs'; export const RunTestManually = () => { + const dispatch = useDispatch(); + + const { monitor } = useSelectedMonitor(); + + const hasPublicLocation = () => { + return monitor?.locations.some((loc) => loc.isServiceManaged); + }; + + const testInProgress = useSelector(manualTestRunInProgressSelector(monitor?.config_id)); + + const content = testInProgress ? TEST_SCHEDULED_LABEL : TEST_NOW_ARIA_LABEL; + return ( - - {RUN_TEST_LABEL} - + + { + if (monitor) { + dispatch(manualTestMonitorAction.get(monitor.config_id)); + } + }} + > + {RUN_TEST_LABEL} + + ); }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_overview_status.ts b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_overview_status.ts index d6390a080b19b..73da339d8aeb6 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_overview_status.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_overview_status.ts @@ -5,7 +5,7 @@ * 2.0. */ -import { useEffect, useRef } from 'react'; +import { useEffect, useRef, useCallback } from 'react'; import { useDispatch, useSelector } from 'react-redux'; import { useSyntheticsRefreshContext } from '../../../contexts/synthetics_refresh_context'; import { @@ -22,18 +22,22 @@ export function useOverviewStatus({ pageState }: { pageState: MonitorOverviewPag const lastRefreshRef = useRef(lastRefresh); const dispatch = useDispatch(); + const reload = useCallback(() => { + dispatch(fetchOverviewStatusAction.get(pageState)); + }, [dispatch, pageState]); useEffect(() => { if (lastRefresh !== lastRefreshRef.current) { dispatch(quietFetchOverviewStatusAction.get(pageState)); lastRefreshRef.current = lastRefresh; } else { - dispatch(fetchOverviewStatusAction.get(pageState)); + reload(); } - }, [dispatch, lastRefresh, pageState]); + }, [dispatch, reload, lastRefresh, pageState]); return { status, statusError, + reload, }; } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/labels.ts b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/labels.ts index dbece4ae95983..d7f3f892c0c76 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/labels.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/labels.ts @@ -71,3 +71,31 @@ export const BETA_TOOLTIP_MESSAGE = i18n.translate( 'This functionality is in beta and is subject to change. The design and code is less mature than official generally available features and is being provided as-is with no warranties. Beta features are not subject to the support service level agreement of official generally available features.', } ); + +export const SUMMARY_LABEL = i18n.translate('xpack.synthetics.monitorManagement.summary.heading', { + defaultMessage: 'Summary', +}); + +export const CONFIGURATIONS_LABEL = i18n.translate( + 'xpack.synthetics.monitorManagement.configurations.label', + { + defaultMessage: 'Configurations', + } +); + +export const DISABLED_LABEL = i18n.translate('xpack.synthetics.monitorManagement.disabled.label', { + defaultMessage: 'Disabled', +}); + +export const TEST_RUNS_LABEL = i18n.translate('xpack.synthetics.monitorManagement.testRuns.label', { + defaultMessage: 'Test runs', +}); + +export function getLastXDaysLabel(count: number) { + return i18n.translate('xpack.synthetics.monitorManagement.lastXDays', { + defaultMessage: 'Last {count, number} {count, plural, one {day} other {days}}', + values: { + count, + }, + }); +} diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_container.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_container.tsx index 3fe1d5c66de38..8b5f57fe7efdc 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_container.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_container.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import React, { useMemo } from 'react'; +import React, { useMemo, useEffect } from 'react'; import { EuiSpacer } from '@elastic/eui'; import type { useMonitorList } from '../hooks/use_monitor_list'; @@ -13,6 +13,7 @@ import { MonitorAsyncError } from './monitor_errors/monitor_async_error'; import { useOverviewStatus } from '../hooks/use_overview_status'; import { ListFilters } from './list_filters/list_filters'; import { MonitorList } from './monitor_list_table/monitor_list'; +import { MonitorStats } from './monitor_stats/monitor_stats'; export const MonitorListContainer = ({ isEnabled, @@ -46,7 +47,11 @@ export const MonitorListContainer = ({ }; }, [pageState]); - const { status } = useOverviewStatus(overviewStatusArgs); + const { status, reload: reloadStatus } = useOverviewStatus(overviewStatusArgs); + + useEffect(() => { + reloadStatus(); + }, [reloadStatus, syntheticsMonitors]); if (!isEnabled && absoluteTotal === 0) { return null; @@ -57,6 +62,8 @@ export const MonitorListContainer = ({ + + ), }, + // Only show Project ID column if project monitors are present + ...(status?.projectMonitorsCount ?? 0 > 0 + ? [ + { + align: 'left' as const, + field: ConfigKey.PROJECT_ID as string, + name: i18n.translate('xpack.synthetics.management.monitorList.projectId', { + defaultMessage: 'Project ID', + }), + sortable: true, + }, + ] + : []), { align: 'left' as const, field: ConfigKey.MONITOR_TYPE, @@ -72,8 +85,18 @@ export function useMonitorListColumns({ defaultMessage: 'Type', }), sortable: true, - render: (monitorType: DataStream) => ( - {monitorType === DataStream.BROWSER ? 'Browser' : 'Ping'} + render: (_: string, monitor: EncryptedSyntheticsSavedMonitor) => ( + { + history.push({ + search: `monitorType=${encodeURIComponent( + JSON.stringify([monitor[ConfigKey.MONITOR_TYPE]]) + )}`, + }); + }} + /> ), }, { @@ -110,7 +133,7 @@ export function useMonitorListColumns({ { - history.push({ search: `tags=${JSON.stringify([tag])}` }); + history.push({ search: `tags=${encodeURIComponent(JSON.stringify([tag]))}` }); }} /> ), diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/labels.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/labels.tsx index dc921a0fd9fbd..75660bcf91071 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/labels.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/labels.tsx @@ -34,13 +34,6 @@ export const NO_DATA_MESSAGE = i18n.translate( } ); -export const EXPAND_LOCATIONS_LABEL = i18n.translate( - 'xpack.synthetics.management.monitorList.locations.expand', - { - defaultMessage: 'Click to view remaining locations', - } -); - export const EXPAND_TAGS_LABEL = i18n.translate( 'xpack.synthetics.management.monitorList.tags.expand', { @@ -201,10 +194,6 @@ export const DISABLE_MONITOR_LABEL = i18n.translate( } ); -export const PROJECT = i18n.translate('xpack.synthetics.management.project', { - defaultMessage: 'Project', -}); - export const getMonitorEnabledSuccessLabel = (name: string) => i18n.translate('xpack.synthetics.management.monitorEnabledSuccessMessage', { defaultMessage: 'Monitor {name} enabled successfully.', @@ -222,3 +211,9 @@ export const getMonitorEnabledUpdateFailureMessage = (name: string) => defaultMessage: 'Unable to update monitor {name}.', values: { name }, }); + +export const getFilterForTypeMessage = (typeName: string) => + i18n.translate('xpack.synthetics.management.filter.clickTypeMessage', { + defaultMessage: 'Click to filter records for type {typeName}.', + values: { typeName }, + }); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_details_link.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_details_link.tsx index 9c679004f998f..f255feef4c860 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_details_link.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_details_link.tsx @@ -6,16 +6,14 @@ */ import React from 'react'; -import { EuiLink, EuiIcon } from '@elastic/eui'; +import { EuiLink } from '@elastic/eui'; import { useSelector } from 'react-redux'; import { selectSelectedLocationId } from '../../../../state'; import { ConfigKey, EncryptedSyntheticsSavedMonitor, - SourceType, } from '../../../../../../../common/runtime_types'; -import { useMonitorDetailLocator } from '../../hooks/use_monitor_detail_locator'; -import * as labels from './labels'; +import { useMonitorDetailLocator } from '../../../../hooks/use_monitor_detail_locator'; export const MonitorDetailsLink = ({ monitor }: { monitor: EncryptedSyntheticsSavedMonitor }) => { const lastSelectedLocationId = useSelector(selectSelectedLocationId); @@ -32,23 +30,5 @@ export const MonitorDetailsLink = ({ monitor }: { monitor: EncryptedSyntheticsSa locationId, }); - const isProjectMonitor = monitor[ConfigKey.MONITOR_SOURCE_TYPE] === SourceType.PROJECT; - const projectLabel = isProjectMonitor - ? `${labels.PROJECT}: ${monitor[ConfigKey.PROJECT_ID]}` - : ''; - - return ( - <> - {monitor.name} - {isProjectMonitor ? ( - - ) : null} - - ); + return {monitor.name}; }; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_enabled.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_enabled.tsx index 863353eba26b6..e4354a2592168 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_enabled.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_enabled.tsx @@ -68,7 +68,7 @@ export const MonitorEnabled = ({ label={enabled ? labels.DISABLE_MONITOR_LABEL : labels.ENABLE_MONITOR_LABEL} title={enabled ? labels.DISABLE_MONITOR_LABEL : labels.ENABLE_MONITOR_LABEL} data-test-subj="syntheticsIsMonitorEnabled" - isSwitchable={isSwitchable} + data-is-switchable={isSwitchable} onChange={handleEnabledChange} /> )} @@ -76,8 +76,10 @@ export const MonitorEnabled = ({ ); }; -const SwitchWithCursor = euiStyled(EuiSwitch)<{ isSwitchable: boolean }>` +// data-* is the DOM compatible prop format +const SwitchWithCursor = euiStyled(EuiSwitch)<{ 'data-is-switchable': boolean }>` & > button { - cursor: ${({ isSwitchable }) => (isSwitchable ? undefined : 'not-allowed')}; + cursor: ${({ 'data-is-switchable': isSwitchable }) => + isSwitchable ? undefined : 'not-allowed'}; } `; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_locations.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_locations.tsx index dc9792bab30c0..858e57b13d114 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_locations.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_list_table/monitor_locations.tsx @@ -5,16 +5,11 @@ * 2.0. */ -import React, { useState, useMemo } from 'react'; -import { EuiBadge, EuiBadgeGroup, EuiIcon, useEuiTheme } from '@elastic/eui'; +import React from 'react'; import { useTheme } from '@kbn/observability-plugin/public'; -import { - ServiceLocations, - ServiceLocation, - OverviewStatusState, -} from '../../../../../../../common/runtime_types'; -import { useLocations } from '../../../../hooks'; -import { EXPAND_LOCATIONS_LABEL } from './labels'; +import { LocationStatusBadges } from '../../../common/components/location_status_badges'; +import { ServiceLocations, OverviewStatusState } from '../../../../../../../common/runtime_types'; +import { LocationsStatus, useLocations } from '../../../../hooks'; interface Props { locations: ServiceLocations; @@ -22,56 +17,25 @@ interface Props { status: OverviewStatusState | null; } -const INITIAL_LIMIT = 3; - export const MonitorLocations = ({ locations, monitorId, status }: Props) => { - const { euiTheme } = useEuiTheme(); const theme = useTheme(); const { locations: allLocations } = useLocations(); - const locationLabelsById = useMemo(() => { - return allLocations.reduce((acc, cur) => { - return { ...acc, [cur.id]: cur.label }; - }, {} as Record); - }, [allLocations]); - const [toDisplay, setToDisplay] = useState(INITIAL_LIMIT); - const locationsToDisplay = locations.slice(0, toDisplay); + const locationsToDisplay = locations + .map((loc) => { + const fullLoc = allLocations.find((l) => l.id === loc.id); + if (fullLoc) { + return { + id: fullLoc.id, + label: fullLoc.label, + ...getLocationStatusColor(theme, fullLoc.label, monitorId, status), + }; + } + }) + .filter(Boolean) as LocationsStatus; return ( - - {locationsToDisplay.map((location: ServiceLocation) => ( - - - {locationLabelsById[location.id]} - - ))} - {locations.length > toDisplay && ( - { - setToDisplay(locations.length); - }} - onClickAriaLabel={EXPAND_LOCATIONS_LABEL} - > - +{locations.length - INITIAL_LIMIT} - - )} - + ); }; @@ -88,10 +52,10 @@ function getLocationStatusColor( const locById = `${monitorId}-${locationLabel}`; if (overviewStatus?.downConfigs[locById]) { - return euiColorVis9; + return { status: 'down', color: euiColorVis9 }; } else if (overviewStatus?.upConfigs[locById]) { - return euiColorVis0; + return { status: 'up', color: euiColorVis0 }; } - return euiColorDisabled; + return { status: 'unknown', color: euiColorDisabled }; } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_stats.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_stats.tsx new file mode 100644 index 0000000000000..853a627803fa1 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_stats.tsx @@ -0,0 +1,114 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { + EuiFlexGroup, + EuiPanel, + EuiStat, + EuiI18nNumber, + useEuiTheme, + EuiText, + EuiFlexItem, + EuiLoadingContent, +} from '@elastic/eui'; +import { euiStyled } from '@kbn/kibana-react-plugin/common'; + +import { OverviewStatusState } from '../../../../../../../common/runtime_types'; +import { useSyntheticsRefreshContext } from '../../../../contexts/synthetics_refresh_context'; + +import * as labels from '../labels'; +import { MonitorTestRunsCount } from './monitor_test_runs'; +import { MonitorTestRunsSparkline } from './monitor_test_runs_sparkline'; + +export const MonitorStats = ({ status }: { status: OverviewStatusState | null }) => { + const { euiTheme } = useEuiTheme(); + const { lastRefresh } = useSyntheticsRefreshContext(); + const to = new Date(lastRefresh).toISOString(); + + return ( + <> + + + +
    {labels.SUMMARY_LABEL}
    +
    + + + + + +
    + + + +
    {labels.getLastXDaysLabel(30)}
    +
    + + + + + + + +
    +
    + + ); +}; + +const EuiStatStyled = euiStyled(EuiStat)` + &&& { + color: ${({ theme }) => theme.eui.euiTitleColor}; + .euiStat__title { + color: ${({ theme }) => theme.eui.euiTitleColor}; + font-size: ${({ theme }) => theme.eui.euiFontSizeXL}; + } + } +`; + +const MonitorStat = ({ + description, + value, +}: { + description: string | undefined; + value: number | undefined; +}) => { + const { euiTheme } = useEuiTheme(); + const statValue = (value as number) ?? undefined; + + return ( + + ) : ( + + ) + } + reverse={true} + /> + ); +}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs.tsx new file mode 100644 index 0000000000000..5a6c3553e82be --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs.tsx @@ -0,0 +1,50 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; + +import { useKibana } from '@kbn/kibana-react-plugin/public'; +import { useTheme } from '@kbn/observability-plugin/public'; +import { ReportTypes } from '@kbn/observability-plugin/public'; + +import { ClientPluginsStart } from '../../../../../../plugin'; +import * as labels from '../labels'; + +interface MonitorCompleteCountProps { + from?: string; + to?: string; +} + +export const MonitorTestRunsCount = ({ + from = 'now-30d', + to = 'now', +}: MonitorCompleteCountProps) => { + const { observability } = useKibana().services; + const theme = useTheme(); + + const { ExploratoryViewEmbeddable } = observability; + + return ( + + ); +}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs_sparkline.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs_sparkline.tsx new file mode 100644 index 0000000000000..9f94ab1196506 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/management/monitor_stats/monitor_test_runs_sparkline.tsx @@ -0,0 +1,51 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; + +import { useKibana } from '@kbn/kibana-react-plugin/public'; +import { useTheme } from '@kbn/observability-plugin/public'; + +import { ClientPluginsStart } from '../../../../../../plugin'; +import * as labels from '../labels'; + +interface Props { + from?: string; + to?: string; +} +export const MonitorTestRunsSparkline = ({ from = 'now-30d', to = 'now' }: Props) => { + const { observability } = useKibana().services; + + const { ExploratoryViewEmbeddable } = observability; + + const theme = useTheme(); + + return ( + + ); +}; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.test.tsx index 955c64d92d4d7..c402b9d4ace7d 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.test.tsx @@ -10,7 +10,7 @@ import { fireEvent } from '@testing-library/react'; import { render } from '../../../../utils/testing/rtl_helpers'; import { ActionsPopover } from './actions_popover'; import * as editMonitorLocatorModule from '../../hooks/use_edit_monitor_locator'; -import * as monitorDetailLocatorModule from '../../hooks/use_monitor_detail_locator'; +import * as monitorDetailLocatorModule from '../../../../hooks/use_monitor_detail_locator'; import * as monitorEnableHandlerModule from '../../../../hooks/use_monitor_enable_handler'; import { FETCH_STATUS } from '@kbn/observability-plugin/public'; import { MonitorOverviewItem } from '../types'; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.tsx index c8cc859e7e0f4..95295c534c559 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/actions_popover.tsx @@ -28,7 +28,7 @@ import { ConfigKey, MonitorOverviewItem } from '../../../../../../../common/runt import { useMonitorEnableHandler } from '../../../../hooks/use_monitor_enable_handler'; import { setFlyoutConfig } from '../../../../state/overview/actions'; import { useEditMonitorLocator } from '../../hooks/use_edit_monitor_locator'; -import { useMonitorDetailLocator } from '../../hooks/use_monitor_detail_locator'; +import { useMonitorDetailLocator } from '../../../../hooks/use_monitor_detail_locator'; import { useLocationName } from '../../../../hooks'; type PopoverPosition = 'relative' | 'default'; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.test.tsx index 9aeec7e0a674c..7498ef268a8fd 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.test.tsx @@ -12,7 +12,7 @@ import { MonitorDetailFlyout } from './monitor_detail_flyout'; import * as observabilityPublic from '@kbn/observability-plugin/public'; import * as monitorDetail from '../../../../hooks/use_monitor_detail'; import * as statusByLocation from '../../../../hooks/use_status_by_location'; -import * as monitorDetailLocator from '../../hooks/use_monitor_detail_locator'; +import * as monitorDetailLocator from '../../../../hooks/use_monitor_detail_locator'; jest.mock('@kbn/observability-plugin/public'); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx index d1ed4ea2b2a80..f00e918f0b091 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/monitor_detail_flyout.tsx @@ -35,7 +35,7 @@ import { useDispatch, useSelector } from 'react-redux'; import { useTheme } from '@kbn/observability-plugin/public'; import { MonitorDetailsPanel } from '../../../common/components/monitor_details_panel'; import { ClientPluginsStart } from '../../../../../../plugin'; -import { useStatusByLocation } from '../../../../hooks/use_status_by_location'; +import { LocationsStatus, useStatusByLocation } from '../../../../hooks/use_status_by_location'; import { MonitorEnabled } from '../../management/monitor_list_table/monitor_enabled'; import { ActionsPopover } from './actions_popover'; import { @@ -51,7 +51,7 @@ import { MonitorOverviewItem, SyntheticsMonitor, } from '../types'; -import { useMonitorDetailLocator } from '../../hooks/use_monitor_detail_locator'; +import { useMonitorDetailLocator } from '../../../../hooks/use_monitor_detail_locator'; import { fetchSyntheticsMonitor } from '../../../../state/overview/api'; import { MonitorStatus } from '../../../common/components/monitor_status'; import { MonitorLocationSelect } from '../../../common/components/monitor_location_select'; @@ -170,14 +170,14 @@ function DetailedFlyoutHeader({ monitor, onEnabledChange, }: { - locations: ReturnType['locations']; + locations: LocationsStatus; currentLocation: string; configId: string; monitor: EncryptedSyntheticsMonitor; onEnabledChange: () => void; setCurrentLocation: (location: string, locationId: string) => void; }) { - const status = locations.find((l) => l.observer?.geo?.name === currentLocation)?.monitor?.status; + const status = locations.find((l) => l.label === currentLocation)?.status; const { locations: allLocations } = useSelector(selectServiceLocationsState); const selectedLocation = allLocations.find((ll) => ll.label === currentLocation); @@ -270,8 +270,10 @@ export function MonitorDetailFlyout(props: Props) { const [isActionsPopoverOpen, setIsActionsPopoverOpen] = useState(false); const monitorDetail = useMonitorDetail(configId, props.location); - const locationStatuses = useStatusByLocation(configId); - const locations = locationStatuses.locations?.filter((l: any) => !!l?.observer?.geo?.name) ?? []; + const { locations } = useStatusByLocation({ + configId, + monitorLocations: monitorSavedObject?.attributes.locations, + }); const isOverlay = useIsWithinMaxBreakpoint('xl'); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/overview_status.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/overview_status.tsx index e82ba5c48d2a8..fef09592af1ac 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/overview_status.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/overview/overview/overview_status.tsx @@ -27,6 +27,7 @@ export function OverviewStatus() { const [statusConfig, setStatusConfig] = useState({ up: status?.up, down: status?.down, + pending: status?.pending, disabledCount: status?.disabledCount, }); @@ -48,6 +49,7 @@ export function OverviewStatus() { up: status?.up || 0, down: 0, disabledCount: 0, + pending: status?.pending, }); break; case 'down': { @@ -55,6 +57,7 @@ export function OverviewStatus() { up: 0, down: status?.down || 0, disabledCount: 0, + pending: status?.pending, }); break; } @@ -63,6 +66,7 @@ export function OverviewStatus() { up: 0, down: 0, disabledCount: status?.disabledCount || 0, + pending: status?.pending, }); break; } @@ -72,6 +76,7 @@ export function OverviewStatus() { up: status.up, down: status.down, disabledCount: status.disabledCount, + pending: status?.pending, }); } }, [status, statusFilter]); @@ -113,6 +118,18 @@ export function OverviewStatus() { titleSize="m" />
    + {(statusConfig?.pending || 0) > 0 && ( + + + + )}
    ); @@ -130,6 +147,10 @@ const downDescription = i18n.translate('xpack.synthetics.overview.status.down.de defaultMessage: 'Down', }); +const pendingDescription = i18n.translate('xpack.synthetics.overview.status.pending.description', { + defaultMessage: 'Pending', +}); + const disabledDescription = i18n.translate( 'xpack.synthetics.overview.status.disabled.description', { diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_now_mode/hooks/use_test_flyout_open.ts b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_now_mode/hooks/use_test_flyout_open.ts index 2a8d8b4035fab..ed3bf648cfe57 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_now_mode/hooks/use_test_flyout_open.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_now_mode/hooks/use_test_flyout_open.ts @@ -8,7 +8,7 @@ import { useDispatch, useSelector } from 'react-redux'; import { useRouteMatch } from 'react-router-dom'; import { useEffect } from 'react'; -import { OVERVIEW_ROUTE } from '../../../../../../common/constants'; +import { MONITOR_ROUTE, OVERVIEW_ROUTE } from '../../../../../../common/constants'; import { hideTestNowFlyoutAction, testNowRunsSelector } from '../../../state/manual_test_runs'; export const useTestFlyoutOpen = () => { @@ -18,14 +18,20 @@ export const useTestFlyoutOpen = () => { path: [OVERVIEW_ROUTE], }); + const isMonitorDetails = useRouteMatch<{ monitorId: string }>({ + path: [MONITOR_ROUTE], + }); + const dispatch = useDispatch(); const flyoutTestOpen = Object.values(testNowRuns).find((value) => { return value.isTestNowFlyoutOpen; }); + const isSameMonitor = flyoutTestOpen?.configId === isMonitorDetails?.params.monitorId; + useEffect(() => { - if (!isOverview?.isExact && flyoutTestOpen) { + if (!isOverview?.isExact && flyoutTestOpen && !isSameMonitor) { dispatch(hideTestNowFlyoutAction()); } }); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/components/step_info.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/components/step_info.tsx new file mode 100644 index 0000000000000..62d94a52138c2 --- /dev/null +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/components/step_info.tsx @@ -0,0 +1,93 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { + EuiFlexGroup, + EuiFlexItem, + EuiLoadingContent, + EuiSpacer, + EuiText, + EuiTitle, +} from '@elastic/eui'; +import { i18n } from '@kbn/i18n'; +import { useParams } from 'react-router-dom'; +import { parseBadgeStatus, StatusBadge } from '../../common/monitor_test_result/status_badge'; +import { formatTestDuration } from '../../../utils/monitor_test_result/test_time_formats'; +import { ErrorDetailsButton } from '../../common/links/error_details_link'; +import { StepDetailsLinkIcon } from '../../common/links/step_details_link'; +import { JourneyStep } from '../../../../../../common/runtime_types'; + +export const StepMetaInfo = ({ + step, + stepIndex, + stateId, +}: { + step?: JourneyStep; + stepIndex: number; + stateId?: string; +}) => { + const { checkGroupId, monitorId } = useParams<{ checkGroupId: string; monitorId: string }>(); + + if (!step) { + return ( + + + + ); + } + + const isFailed = step.synthetics.step?.status === 'failed'; + + return ( + + +

    {STEP_NAME}

    +
    + {step?.synthetics.step?.name} + + + + + + + {AFTER_LABEL} + {formatTestDuration(step?.synthetics.step?.duration.us)} + + + + + {isFailed && stateId && ( + + + + )} + + + + +
    + ); +}; + +const STEP_NAME = i18n.translate('xpack.synthetics.testDetails.stepName', { + defaultMessage: 'Step name', +}); + +const AFTER_LABEL = i18n.translate('xpack.synthetics.testDetails.after', { + defaultMessage: 'After ', +}); + +const VIEW_PERFORMANCE = i18n.translate('xpack.synthetics.monitor.step.viewPerformanceBreakdown', { + defaultMessage: 'View performance breakdown', +}); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/step_screenshot_details.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/step_screenshot_details.tsx index 1bbf20c7d5ccb..50d799d6b2863 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/step_screenshot_details.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/step_screenshot_details.tsx @@ -10,12 +10,15 @@ import React from 'react'; import { useParams } from 'react-router-dom'; import { JourneyStep } from '../../../../../common/runtime_types'; import { JourneyStepScreenshotContainer } from '../common/screenshot/journey_step_screenshot_container'; +import { StepMetaInfo } from './components/step_info'; export const StepScreenshotDetails = ({ stepIndex, step, + stateId, }: { stepIndex: number; + stateId?: string; step?: JourneyStep; }) => { const { checkGroupId } = useParams<{ checkGroupId: string }>(); @@ -23,7 +26,7 @@ export const StepScreenshotDetails = ({ return ( - + - {/* TODO: add image details*/} + ); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/test_run_details.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/test_run_details.tsx index 446857ca9b779..a0cff11450bdf 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/test_run_details.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/test_run_details/test_run_details.tsx @@ -38,10 +38,12 @@ export const TestRunDetails = () => { const { monitorId } = useParams<{ monitorId: string }>(); const selectedLocation = useSelectedLocation(); + const stateId = stepsData?.details?.summary?.state?.id; + return ( <> - + @@ -72,7 +74,7 @@ export const TestRunDetails = () => { - + diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_monitor_detail_locator.ts b/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_monitor_detail_locator.ts similarity index 93% rename from x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_monitor_detail_locator.ts rename to x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_monitor_detail_locator.ts index d1b75ef5e0ca3..d1c181da28f17 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/monitors_page/hooks/use_monitor_detail_locator.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_monitor_detail_locator.ts @@ -7,7 +7,7 @@ import { useEffect, useState } from 'react'; import { syntheticsMonitorDetailLocatorID } from '@kbn/observability-plugin/common'; -import { useSyntheticsStartPlugins } from '../../../contexts'; +import { useSyntheticsStartPlugins } from '../contexts'; export function useMonitorDetailLocator({ configId, diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_status_by_location.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_status_by_location.tsx index 5271f532a5c7d..296a870b66f42 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_status_by_location.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/hooks/use_status_by_location.tsx @@ -5,10 +5,10 @@ * 2.0. */ -import { useEsSearch } from '@kbn/observability-plugin/public'; -import { useParams } from 'react-router-dom'; +import { useEsSearch, useTheme } from '@kbn/observability-plugin/public'; import { useMemo } from 'react'; -import { Ping } from '../../../../common/runtime_types'; +import { useLocations } from './use_locations'; +import { EncryptedSyntheticsSavedMonitor, Ping } from '../../../../common/runtime_types'; import { EXCLUDE_RUN_ONCE_FILTER, SUMMARY_FILTER, @@ -16,10 +16,20 @@ import { import { SYNTHETICS_INDEX_PATTERN, UNNAMED_LOCATION } from '../../../../common/constants'; import { useSyntheticsRefreshContext } from '../contexts'; -export function useStatusByLocation(monitorIdArg?: string) { +export type LocationsStatus = Array<{ status: string; id: string; label: string; color: string }>; + +export function useStatusByLocation({ + configId, + monitorLocations, +}: { + configId: string; + monitorLocations?: EncryptedSyntheticsSavedMonitor['locations']; +}) { + const theme = useTheme(); + const { lastRefresh } = useSyntheticsRefreshContext(); - const { monitorId } = useParams<{ monitorId: string }>(); + const { locations: allLocations } = useLocations(); const { data, loading } = useEsSearch( { @@ -33,7 +43,7 @@ export function useStatusByLocation(monitorIdArg?: string) { EXCLUDE_RUN_ONCE_FILTER, { term: { - config_id: monitorIdArg ?? monitorId, + config_id: configId, }, }, ], @@ -58,18 +68,51 @@ export function useStatusByLocation(monitorIdArg?: string) { }, }, }, - [lastRefresh, monitorId, monitorIdArg], + [lastRefresh, configId], { name: 'getMonitorStatusByLocation' } ); return useMemo(() => { - const locations = (data?.aggregations?.locations.buckets ?? []).map((loc) => { + const getColor = (status: string) => { + switch (status) { + case 'up': + return theme.eui.euiColorVis0; + case 'down': + return theme.eui.euiColorVis9; + default: + return 'subdued'; + } + }; + + const locationPings = (data?.aggregations?.locations.buckets ?? []).map((loc) => { return loc.summary.hits.hits?.[0]._source as Ping; }); + const locations = (monitorLocations ?? []) + .map((loc) => { + const fullLoc = allLocations.find((l) => l.id === loc.id); + if (fullLoc) { + const ping = locationPings.find((p) => p.observer?.geo?.name === fullLoc?.label); + const status = ping ? (ping.summary?.down ?? 0 > 0 ? 'down' : 'up') : 'unknown'; + return { + status, + id: fullLoc?.id, + label: fullLoc?.label, + color: getColor(status), + }; + } + }) + .filter(Boolean) as LocationsStatus; return { locations, loading, }; - }, [data, loading]); + }, [ + allLocations, + data?.aggregations?.locations.buckets, + loading, + monitorLocations, + theme.eui.euiColorVis0, + theme.eui.euiColorVis9, + ]); } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/routes.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/routes.tsx index b219e872ca721..69cad74504ddd 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/routes.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/routes.tsx @@ -16,6 +16,7 @@ import { APP_WRAPPER_CLASS } from '@kbn/core/public'; import { useKibana } from '@kbn/kibana-react-plugin/public'; import { useInspectorContext } from '@kbn/observability-plugin/public'; import type { LazyObservabilityPageTemplateProps } from '@kbn/observability-plugin/public'; +import { EditMonitorLink } from './components/common/links/edit_monitor'; import { MonitorDetailsLocation } from './components/monitor_details/monitor_details_location'; import { getStepDetailsRoute } from './components/step_details_page/route_config'; import { getTestRunDetailsRoute } from './components/test_run_details/route_config'; @@ -322,6 +323,7 @@ const getMonitorSummaryHeader = ( }, ], rightSideItems: [ + , , , , diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/api.ts b/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/api.ts index e0a8068e1d460..6759bee3b1fe3 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/api.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/api.ts @@ -17,7 +17,7 @@ import { Ping, PingType, } from '../../../../../common/runtime_types'; -import { API_URLS } from '../../../../../common/constants'; +import { API_URLS, SYNTHETICS_API_URLS } from '../../../../../common/constants'; export interface FetchJourneyStepsParams { checkGroup: string; @@ -34,7 +34,7 @@ export async function fetchBrowserJourney( params: FetchJourneyStepsParams ): Promise { return apiService.get( - API_URLS.JOURNEY.replace('{checkGroup}', params.checkGroup), + SYNTHETICS_API_URLS.JOURNEY.replace('{checkGroup}', params.checkGroup), { syntheticEventTypes: params.syntheticEventTypes }, SyntheticsJourneyApiResponseType ); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/effects.ts b/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/effects.ts index f28e3bbfc947d..5a403cdf87869 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/effects.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/state/browser_journey/effects.ts @@ -6,8 +6,14 @@ */ import { Action } from 'redux-actions'; -import { all, call, fork, put, select, takeEvery, takeLeading, throttle } from 'redux-saga/effects'; -import { ScreenshotBlockDoc, ScreenshotBlockCache } from '../../../../../common/runtime_types'; +import { all, call, fork, put, select, takeEvery, throttle } from 'redux-saga/effects'; +import { serializeHttpFetchError } from '../utils/http_error'; +import { FetchNetworkEventsParams } from '../network_events/actions'; +import { + ScreenshotBlockDoc, + ScreenshotBlockCache, + SyntheticsJourneyApiResponse, +} from '../../../../../common/runtime_types'; import { fetchBrowserJourney, fetchScreenshotBlockSet } from './api'; import { @@ -23,7 +29,6 @@ import { import { isPendingBlock } from './models'; import { selectBrowserJourneyState } from './selectors'; -import { fetchEffectFactory } from '../utils/fetch_effect'; export function* browserJourneyEffects() { yield all([fork(fetchScreenshotBlocks), fork(generateBlockStatsOnPut), fork(pruneBlockCache)]); @@ -89,8 +94,28 @@ function* pruneBlockCache() { } export function* fetchJourneyStepsEffect() { - yield takeLeading( - fetchJourneyAction.get, - fetchEffectFactory(fetchBrowserJourney, fetchJourneyAction.success, fetchJourneyAction.fail) + const inProgressRequests = new Set(); + + yield takeEvery( + String(fetchJourneyAction.get), + function* (action: Action): Generator { + try { + if (!inProgressRequests.has(action.payload.checkGroup)) { + inProgressRequests.add(action.payload.checkGroup); + + const response = (yield call( + fetchBrowserJourney, + action.payload + )) as SyntheticsJourneyApiResponse; + + inProgressRequests.delete(action.payload.checkGroup); + + yield put(fetchJourneyAction.success(response)); + } + } catch (e) { + inProgressRequests.delete(action.payload.checkGroup); + yield put(fetchJourneyAction.fail(serializeHttpFetchError(e, action.payload))); + } + } ); } diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/state/manual_test_runs/selectors.ts b/x-pack/plugins/synthetics/public/apps/synthetics/state/manual_test_runs/selectors.ts index 2aaa9f14e9f32..3531fd21d95d4 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/state/manual_test_runs/selectors.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/state/manual_test_runs/selectors.ts @@ -15,8 +15,9 @@ export const manualTestRunSelector = configId ? manualTestRuns[configId] : undefined; export const manualTestRunInProgressSelector = - (configId: string) => + (configId?: string) => ({ manualTestRuns }: SyntheticsAppState) => { + if (!configId) return false; return ( manualTestRuns[configId]?.status === 'in-progress' || manualTestRuns[configId]?.status === 'loading' diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts b/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts index 32a393a6eedff..5ede7bad9bb9b 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts +++ b/x-pack/plugins/synthetics/public/apps/synthetics/state/overview/api.ts @@ -43,7 +43,7 @@ export const fetchMonitorOverview = async ( pageState: MonitorOverviewPageState ): Promise => { const params = toMonitorOverviewQueryArgs(pageState); - return await apiService.get( + return apiService.get( SYNTHETICS_API_URLS.SYNTHETICS_OVERVIEW, params, MonitorOverviewResultCodec @@ -54,5 +54,5 @@ export const fetchOverviewStatus = async ( pageState: MonitorOverviewPageState ): Promise => { const params = toMonitorOverviewQueryArgs(pageState); - return await apiService.get(SYNTHETICS_API_URLS.OVERVIEW_STATUS, params, OverviewStatusCodec); + return apiService.get(SYNTHETICS_API_URLS.OVERVIEW_STATUS, params, OverviewStatusCodec); }; diff --git a/x-pack/plugins/synthetics/server/alert_rules/status_rule/status_rule_executor.ts b/x-pack/plugins/synthetics/server/alert_rules/status_rule/status_rule_executor.ts index 6cf752d26ed8d..0225eeb08acfd 100644 --- a/x-pack/plugins/synthetics/server/alert_rules/status_rule/status_rule_executor.ts +++ b/x-pack/plugins/synthetics/server/alert_rules/status_rule/status_rule_executor.ts @@ -10,10 +10,12 @@ import { SavedObjectsFindResult, } from '@kbn/core-saved-objects-api-server'; import { ElasticsearchClient } from '@kbn/core-elasticsearch-server'; -import { resolveMissingLabels } from '../../routes/status/current_status'; import { AlertConfigKey } from '../../../common/constants/monitor_management'; import { getAllLocations } from '../../synthetics_service/get_all_locations'; -import { getAllMonitors } from '../../saved_objects/synthetics_monitor/get_all_monitors'; +import { + getAllMonitors, + processMonitors, +} from '../../saved_objects/synthetics_monitor/get_all_monitors'; import { GetMonitorDownStatusMessageParams } from '../../legacy_uptime/lib/requests/get_monitor_status'; import { queryMonitorStatus } from '../../queries/query_monitor_status'; import { UptimeEsClient } from '../../legacy_uptime/lib/lib'; @@ -90,56 +92,34 @@ export class StatusRuleExecutor { soClient: this.soClient, search: `attributes.${AlertConfigKey.STATUS_ENABLED}: true`, }); - const allIds: string[] = []; - const enabledIds: string[] = []; - let listOfLocationsSet = new Set(); - const missingLabelLocations = new Set(); - - this.monitors.forEach((monitor) => { - const attrs = monitor.attributes; - allIds.push(attrs[ConfigKey.MONITOR_QUERY_ID]); - if (attrs[ConfigKey.ENABLED] === true) { - enabledIds.push(attrs[ConfigKey.MONITOR_QUERY_ID]); - } - - listOfLocationsSet = new Set([ - ...listOfLocationsSet, - ...(attrs[ConfigKey.LOCATIONS] - .filter((loc) => { - if (!loc.label) { - missingLabelLocations.add(loc.id); - } - return loc.label; - }) - .map((location) => location.label) as string[]), - ]); - }); - const { listOfLocations } = await resolveMissingLabels( - this.server, - this.soClient, - this.syntheticsMonitorClient, - listOfLocationsSet, - missingLabelLocations - ); + const { allIds, enabledIds, listOfLocations, monitorLocationMap, projectMonitorsCount } = + await processMonitors( + this.monitors, + this.server, + this.soClient, + this.syntheticsMonitorClient + ); - return { enabledIds, listOfLocations, allIds }; + return { enabledIds, listOfLocations, allIds, monitorLocationMap, projectMonitorsCount }; } async getDownChecks( prevDownConfigs: OverviewStatus['downConfigs'] = {} ): Promise { - const { listOfLocations, enabledIds } = await this.getMonitors(); + const { listOfLocations, enabledIds, allIds, monitorLocationMap, projectMonitorsCount } = + await this.getMonitors(); if (enabledIds.length > 0) { const currentStatus = await queryMonitorStatus( this.esClient, - [...listOfLocations], + listOfLocations, { to: 'now', from: this.previousStartedAt?.toISOString() ?? 'now-1m', }, - enabledIds + enabledIds, + monitorLocationMap ); const downConfigs = currentStatus.downConfigs; @@ -153,7 +133,13 @@ export class StatusRuleExecutor { const staleDownConfigs = this.markDeletedConfigs(downConfigs); - return { ...currentStatus, staleDownConfigs }; + return { + ...currentStatus, + staleDownConfigs, + projectMonitorsCount, + allMonitorsCount: allIds.length, + disabledMonitorsCount: allIds.length - enabledIds.length, + }; } const staleDownConfigs = this.markDeletedConfigs(prevDownConfigs); return { @@ -162,7 +148,11 @@ export class StatusRuleExecutor { staleDownConfigs, down: 0, up: 0, + pending: 0, enabledIds, + allMonitorsCount: allIds.length, + disabledMonitorsCount: allIds.length, + projectMonitorsCount, }; } diff --git a/x-pack/plugins/synthetics/server/legacy_uptime/lib/lib.ts b/x-pack/plugins/synthetics/server/legacy_uptime/lib/lib.ts index de76507c330d5..c77f75dae0eaa 100644 --- a/x-pack/plugins/synthetics/server/legacy_uptime/lib/lib.ts +++ b/x-pack/plugins/synthetics/server/legacy_uptime/lib/lib.ts @@ -186,6 +186,10 @@ export class UptimeEsClient { } } +export function createEsParams(params: T): T { + return params; +} + function getInspectEnabled(uiSettings?: CoreRequestHandlerContext['uiSettings']) { if (!uiSettings) { return false; diff --git a/x-pack/plugins/synthetics/server/queries/get_journey_details.ts b/x-pack/plugins/synthetics/server/queries/get_journey_details.ts new file mode 100644 index 0000000000000..bacc3cf64ae48 --- /dev/null +++ b/x-pack/plugins/synthetics/server/queries/get_journey_details.ts @@ -0,0 +1,172 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { QueryDslQueryContainer } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; +import { JourneyStep, Ping, SyntheticsJourneyApiResponse } from '../../common/runtime_types'; +import { UMElasticsearchQueryFn } from '../legacy_uptime/lib/adapters'; +import { createEsParams } from '../legacy_uptime/lib/lib'; + +export interface GetJourneyDetails { + checkGroup: string; +} + +type DocumentSource = (Ping & { '@timestamp': string }) | JourneyStep; + +export const getJourneyDetails: UMElasticsearchQueryFn< + GetJourneyDetails, + SyntheticsJourneyApiResponse['details'] +> = async ({ uptimeEsClient, checkGroup }) => { + const params = createEsParams({ + body: { + query: { + bool: { + filter: [ + { + term: { + 'monitor.check_group': checkGroup, + }, + }, + { + terms: { + 'synthetics.type': ['journey/start', 'heartbeat/summary'], + }, + }, + ], + }, + }, + size: 2, + }, + }); + + const { body: thisJourney } = await uptimeEsClient.search( + params, + 'getJourneyDetailsCurrentJourney' + ); + + const journeyStart = thisJourney.hits.hits.find( + (hit) => hit._source.synthetics?.type === 'journey/start' + ); + + if (journeyStart) { + const { _id, _source } = journeyStart; + const thisJourneySource = Object.assign({ _id }, _source) as JourneyStep; + + const baseSiblingParams = createEsParams({ + body: { + query: { + bool: { + filter: [ + { + term: { + 'monitor.id': thisJourneySource.monitor.id, + }, + }, + { + term: { + 'synthetics.type': 'journey/start', + }, + }, + ] as QueryDslQueryContainer[], + }, + }, + _source: ['@timestamp', 'monitor.check_group'], + size: 1, + }, + }); + + const previousParams = createEsParams({ + body: { + ...baseSiblingParams.body, + query: { + bool: { + filter: [ + ...baseSiblingParams.body.query.bool.filter, + { + range: { + '@timestamp': { + lt: thisJourneySource['@timestamp'], + }, + }, + }, + ], + }, + }, + sort: [{ '@timestamp': { order: 'desc' as const } }], + }, + }); + + const nextParams = createEsParams({ + body: { + ...baseSiblingParams.body, + query: { + bool: { + filter: [ + ...baseSiblingParams.body.query.bool.filter, + { + range: { + '@timestamp': { + gt: thisJourneySource['@timestamp'], + }, + }, + }, + ], + }, + }, + sort: [{ '@timestamp': { order: 'asc' as const } }], + }, + }); + + const [previousJourneyPromise, nextJourneyPromise] = await Promise.all([ + uptimeEsClient.search( + previousParams, + 'getJourneyDetailsPreviousJourney' + ), + uptimeEsClient.search( + nextParams, + 'getJourneyDetailsNextJourney' + ), + ]); + + const { body: previousJourneyResult } = previousJourneyPromise; + const { body: nextJourneyResult } = nextJourneyPromise; + + const previousJourney = + previousJourneyResult?.hits?.hits.length > 0 ? previousJourneyResult?.hits?.hits[0] : null; + const nextJourney = + nextJourneyResult?.hits?.hits.length > 0 ? nextJourneyResult?.hits?.hits[0] : null; + + const summaryPing = thisJourney.hits.hits.find( + ({ _source: summarySource }) => summarySource.synthetics?.type === 'heartbeat/summary' + )?._source; + + return { + timestamp: thisJourneySource['@timestamp'], + journey: thisJourneySource, + ...(summaryPing && 'state' in summaryPing && summaryPing.state + ? { + summary: { + state: summaryPing.state, + }, + } + : {}), + previous: previousJourney + ? { + checkGroup: previousJourney._source.monitor.check_group, + timestamp: previousJourney._source['@timestamp'], + } + : undefined, + next: nextJourney + ? { + checkGroup: nextJourney._source.monitor.check_group, + timestamp: nextJourney._source['@timestamp'], + } + : undefined, + }; + } else { + return null; + } +}; diff --git a/x-pack/plugins/synthetics/server/queries/query_monitor_status.ts b/x-pack/plugins/synthetics/server/queries/query_monitor_status.ts index 38b42674eab8c..04badd43fcaf1 100644 --- a/x-pack/plugins/synthetics/server/queries/query_monitor_status.ts +++ b/x-pack/plugins/synthetics/server/queries/query_monitor_status.ts @@ -17,8 +17,13 @@ export async function queryMonitorStatus( listOfLocations: string[], range: { from: string | number; to: string }, ids: string[], - monitorLocationsMap?: Record -): Promise> { + monitorLocationsMap: Record +): Promise< + Omit< + OverviewStatus, + 'disabledCount' | 'allMonitorsCount' | 'disabledMonitorsCount' | 'projectMonitorsCount' + > +> { const idSize = Math.trunc(DEFAULT_MAX_ES_BUCKET_SIZE / listOfLocations.length || 1); const pageCount = Math.ceil(ids.length / idSize); const promises: Array> = []; @@ -104,50 +109,61 @@ export async function queryMonitorStatus( } let up = 0; let down = 0; + let pending = 0; const upConfigs: Record = {}; const downConfigs: Record = {}; + for await (const response of promises) { response.body.aggregations?.id.buckets.forEach( ({ location, key: queryId }: { location: any; key: string }) => { - location.buckets.forEach(({ status }: { key: string; status: any }) => { - const ping = status.hits.hits[0]._source as Ping & { '@timestamp': string }; + const monLocations = monitorLocationsMap?.[queryId]; + const locationSummaries = location.buckets.map( + ({ status, key: locationName }: { key: string; status: any }) => { + const ping = status.hits.hits[0]._source as Ping & { '@timestamp': string }; + return { location: locationName, ping }; + } + ) as Array<{ location: string; ping: Ping & { '@timestamp': string } }>; - const locationName = ping.observer?.geo?.name!; + // discard any locations that are not in the monitorLocationsMap for the given monitor + monLocations?.forEach((monLocation) => { + const locationSummary = locationSummaries.find( + (summary) => summary.location === monLocation + ); - const monLocations = monitorLocationsMap?.[queryId]; - if (monLocations && !monLocations.includes(locationName)) { - // discard any locations that are not in the monitorLocationsMap for the given monitor - return; - } + if (locationSummary) { + const { ping } = locationSummary; + const downCount = ping.summary?.down ?? 0; + const upCount = ping.summary?.up ?? 0; + const configId = ping.config_id!; + const monitorQueryId = ping.monitor.id; - const downCount = ping.summary?.down ?? 0; - const upCount = ping.summary?.up ?? 0; - const configId = ping.config_id!; - const monitorQueryId = ping.monitor.id; - if (upCount > 0) { - up += 1; - upConfigs[`${configId}-${locationName}`] = { + const meta = { ping, configId, monitorQueryId, - location: locationName, - status: 'up', - timestamp: ping['@timestamp'], - }; - } else if (downCount > 0) { - down += 1; - downConfigs[`${configId}-${locationName}`] = { - ping, - configId, - monitorQueryId, - location: locationName, - status: 'down', + location: monLocation, timestamp: ping['@timestamp'], }; + + if (downCount > 0) { + down += 1; + downConfigs[`${configId}-${monLocation}`] = { + ...meta, + status: 'down', + }; + } else if (upCount > 0) { + up += 1; + upConfigs[`${configId}-${monLocation}`] = { + ...meta, + status: 'up', + }; + } + } else { + pending += 1; } }); } ); } - return { up, down, upConfigs, downConfigs, enabledIds: ids }; + return { up, down, pending, upConfigs, downConfigs, enabledIds: ids }; } diff --git a/x-pack/plugins/synthetics/server/routes/common.ts b/x-pack/plugins/synthetics/server/routes/common.ts index 0e39d2475ab14..da8a6b476ceb0 100644 --- a/x-pack/plugins/synthetics/server/routes/common.ts +++ b/x-pack/plugins/synthetics/server/routes/common.ts @@ -70,7 +70,7 @@ export const getMonitors = ( type: syntheticsMonitorType, perPage, page, - sortField: sortField === 'schedule.keyword' ? 'schedule.number' : sortField, + sortField: parseMappingKey(sortField), sortOrder, searchFields: SEARCH_FIELDS, search: query ? `${query}*` : undefined, @@ -170,3 +170,14 @@ export const isMonitorsQueryFiltered = (monitorQuery: MonitorsQuery) => { !!status?.length ); }; + +function parseMappingKey(key: string | undefined) { + switch (key) { + case 'schedule.keyword': + return 'schedule.number'; + case 'project_id.keyword': + return 'project_id'; + default: + return key; + } +} diff --git a/x-pack/plugins/synthetics/server/routes/index.ts b/x-pack/plugins/synthetics/server/routes/index.ts index a0583bd565848..5312074520ac9 100644 --- a/x-pack/plugins/synthetics/server/routes/index.ts +++ b/x-pack/plugins/synthetics/server/routes/index.ts @@ -5,6 +5,7 @@ * 2.0. */ +import { createJourneyRoute } from './pings/journeys'; import { updateDefaultAlertingRoute } from './default_alerts/update_default_alert'; import { syncParamsSyntheticsParamsRoute } from './settings/sync_global_params'; import { editSyntheticsParamsRoute } from './settings/edit_param'; @@ -75,6 +76,7 @@ export const syntheticsAppRestApiRoutes: SyntheticsRestApiRouteFactory[] = [ enableDefaultAlertingRoute, getDefaultAlertingRoute, updateDefaultAlertingRoute, + createJourneyRoute, ]; export const syntheticsAppStreamingApiRoutes: SyntheticsStreamingRouteFactory[] = [ diff --git a/x-pack/plugins/synthetics/server/routes/pings/journeys.ts b/x-pack/plugins/synthetics/server/routes/pings/journeys.ts new file mode 100644 index 0000000000000..9ef10fe6bebb2 --- /dev/null +++ b/x-pack/plugins/synthetics/server/routes/pings/journeys.ts @@ -0,0 +1,80 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { schema } from '@kbn/config-schema'; +import { API_URLS, SYNTHETICS_API_URLS } from '../../../common/constants'; +import { UMServerLibs } from '../../legacy_uptime/uptime_server'; +import { UMRestApiRouteFactory } from '../../legacy_uptime/routes/types'; +import { getJourneyDetails } from '../../queries/get_journey_details'; + +export const createJourneyRoute: UMRestApiRouteFactory = (libs: UMServerLibs) => ({ + method: 'GET', + path: SYNTHETICS_API_URLS.JOURNEY, + validate: { + params: schema.object({ + checkGroup: schema.string(), + }), + query: schema.object({ + // provides a filter for the types of synthetic events to include + // when fetching a journey's data + syntheticEventTypes: schema.maybe( + schema.oneOf([schema.arrayOf(schema.string()), schema.string()]) + ), + }), + }, + handler: async ({ uptimeEsClient, request, response }): Promise => { + const { checkGroup } = request.params; + const { syntheticEventTypes } = request.query; + + try { + const [result, details] = await Promise.all([ + await libs.requests.getJourneySteps({ + uptimeEsClient, + checkGroup, + syntheticEventTypes, + }), + await getJourneyDetails({ + uptimeEsClient, + checkGroup, + }), + ]); + + return { + checkGroup, + steps: result, + details, + }; + } catch (e: unknown) { + return response.custom({ statusCode: 500, body: { message: e } }); + } + }, +}); + +export const createJourneyFailedStepsRoute: UMRestApiRouteFactory = (libs: UMServerLibs) => ({ + method: 'GET', + path: API_URLS.JOURNEY_FAILED_STEPS, + validate: { + query: schema.object({ + checkGroups: schema.arrayOf(schema.string()), + }), + }, + handler: async ({ uptimeEsClient, request, response }): Promise => { + const { checkGroups } = request.query; + try { + const result = await libs.requests.getJourneyFailedSteps({ + uptimeEsClient, + checkGroups, + }); + return { + checkGroups, + steps: result, + }; + } catch (e) { + return response.customError({ statusCode: 500, body: e }); + } + }, +}); diff --git a/x-pack/plugins/synthetics/server/routes/status/current_status.test.ts b/x-pack/plugins/synthetics/server/routes/status/current_status.test.ts index b4312670e0133..d2c08d495973c 100644 --- a/x-pack/plugins/synthetics/server/routes/status/current_status.test.ts +++ b/x-pack/plugins/synthetics/server/routes/status/current_status.test.ts @@ -171,9 +171,11 @@ describe('current status route', () => { uptimeEsClient, ['Europe - Germany', 'Asia/Pacific - Japan'], { from: 140000, to: 'now' }, - ['id1', 'id2'] + ['id1', 'id2'], + { id1: ['Asia/Pacific - Japan'], id2: ['Europe - Germany', 'Asia/Pacific - Japan'] } ) ).toEqual({ + pending: 0, down: 1, enabledIds: ['id1', 'id2'], up: 2, @@ -324,9 +326,11 @@ describe('current status route', () => { uptimeEsClient, times(10000).map((n) => 'Europe - Germany' + n), { from: 2500, to: 'now' }, - ['id1', 'id2'] + ['id1', 'id2'], + { id1: ['Asia/Pacific - Japan'], id2: ['Europe - Germany', 'Asia/Pacific - Japan'] } ) ).toEqual({ + pending: 0, down: 1, enabledIds: ['id1', 'id2'], up: 2, diff --git a/x-pack/plugins/synthetics/server/routes/status/current_status.ts b/x-pack/plugins/synthetics/server/routes/status/current_status.ts index 159b464312f69..a2554cffc652c 100644 --- a/x-pack/plugins/synthetics/server/routes/status/current_status.ts +++ b/x-pack/plugins/synthetics/server/routes/status/current_status.ts @@ -7,17 +7,18 @@ import datemath, { Unit } from '@kbn/datemath'; import { SavedObjectsClientContract } from '@kbn/core/server'; -import pMap from 'p-map'; -import { getAllMonitors } from '../../saved_objects/synthetics_monitor/get_all_monitors'; +import { + getAllMonitors, + processMonitors, +} from '../../saved_objects/synthetics_monitor/get_all_monitors'; import { UptimeServerSetup } from '../../legacy_uptime/lib/adapters'; -import { getAllLocations } from '../../synthetics_service/get_all_locations'; import { queryMonitorStatus } from '../../queries/query_monitor_status'; import { SYNTHETICS_API_URLS } from '../../../common/constants'; import { UMServerLibs } from '../../legacy_uptime/uptime_server'; import { SyntheticsRestApiRouteFactory } from '../../legacy_uptime/routes'; import { UptimeEsClient } from '../../legacy_uptime/lib/lib'; import { SyntheticsMonitorClient } from '../../synthetics_service/synthetics_monitor/synthetics_monitor_client'; -import { ConfigKey, ServiceLocation } from '../../../common/runtime_types'; +import { ConfigKey } from '../../../common/runtime_types'; import { QuerySchema, MonitorsQuery } from '../common'; /** @@ -46,11 +47,6 @@ export async function getStatus( params: MonitorsQuery ) { const { query } = params; - const enabledIds: string[] = []; - let disabledCount = 0; - let maxPeriod = 0; - let listOfLocationsSet = new Set(); - const monitorLocationMap: Record = {}; /** * Walk through all monitor saved objects, bucket IDs by disabled/enabled status. * @@ -60,77 +56,43 @@ export async function getStatus( const allMonitors = await getAllMonitors({ soClient, - search: `${query}*`, + search: query ? `${query}*` : undefined, fields: [ ConfigKey.ENABLED, ConfigKey.LOCATIONS, ConfigKey.MONITOR_QUERY_ID, ConfigKey.SCHEDULE, + ConfigKey.MONITOR_SOURCE_TYPE, ], }); - let allLocations: ServiceLocation[] | null = null; - - const getLocationLabel = async (locationId: string) => { - if (!allLocations) { - const { publicLocations, privateLocations } = await getAllLocations( - server, - syntheticsMonitorClient, - soClient - ); - - allLocations = [...publicLocations, ...privateLocations]; - } - - return allLocations.find((loc) => loc.id === locationId)?.label ?? locationId; - }; - - for (const monitor of allMonitors) { - const attrs = monitor.attributes; - if (attrs[ConfigKey.ENABLED] === false) { - disabledCount += attrs[ConfigKey.LOCATIONS].length; - } else { - const missingLabels = new Set(); - - enabledIds.push(attrs[ConfigKey.MONITOR_QUERY_ID]); - const monLocs = new Set([ - ...(attrs[ConfigKey.LOCATIONS] - .filter((loc) => { - if (!loc.label) { - missingLabels.add(loc.id); - } - return loc.label; - }) - .map((location) => location.label) as string[]), - ]); - - // since label wasn't always part of location, there can be a case where we have a location - // with an id but no label. We need to fetch the label from the API - // Adding a migration to add the label to the saved object is a future consideration - const locLabels = await pMap([...missingLabels], async (locationId) => - getLocationLabel(locationId) - ); - - monitorLocationMap[attrs[ConfigKey.MONITOR_QUERY_ID]] = [...monLocs, ...locLabels]; - listOfLocationsSet = new Set([...listOfLocationsSet, ...monLocs, ...locLabels]); - - maxPeriod = Math.max(maxPeriod, periodToMs(attrs[ConfigKey.SCHEDULE])); - } - } - - const { up, down, upConfigs, downConfigs } = await queryMonitorStatus( + const { + enabledIds, + disabledCount, + maxPeriod, + listOfLocations, + monitorLocationMap, + disabledMonitorsCount, + projectMonitorsCount, + } = await processMonitors(allMonitors, server, soClient, syntheticsMonitorClient); + + const { up, down, pending, upConfigs, downConfigs } = await queryMonitorStatus( uptimeEsClient, - [...listOfLocationsSet], + listOfLocations, { from: maxPeriod, to: 'now' }, enabledIds, monitorLocationMap ); return { + allMonitorsCount: allMonitors.length, + disabledMonitorsCount, + projectMonitorsCount, enabledIds, disabledCount, up, down, + pending, upConfigs, downConfigs, }; @@ -159,33 +121,3 @@ export const createGetCurrentStatusRoute: SyntheticsRestApiRouteFactory = (libs: ); }, }); - -export const resolveMissingLabels = async ( - server: UptimeServerSetup, - savedObjectsClient: SavedObjectsClientContract, - syntheticsMonitorClient: SyntheticsMonitorClient, - listOfLocationsSet: Set, - missingLabelLocations: Set -) => { - const listOfLocations = Array.from(listOfLocationsSet); - - if (missingLabelLocations.size > 0) { - const { publicLocations, privateLocations } = await getAllLocations( - server, - syntheticsMonitorClient, - savedObjectsClient - ); - - const locations = [...publicLocations, ...privateLocations]; - - missingLabelLocations.forEach((id) => { - const location = locations.find((loc) => loc.id === id); - if (location) { - listOfLocations.push(location.label); - } - }); - return { listOfLocations }; - } - - return { listOfLocations }; -}; diff --git a/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.test.ts b/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.test.ts new file mode 100644 index 0000000000000..cdb6e2f520fc8 --- /dev/null +++ b/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.test.ts @@ -0,0 +1,236 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { processMonitors } from './get_all_monitors'; +import { UptimeServerSetup } from '../../legacy_uptime/lib/adapters'; +import { mockEncryptedSO } from '../../synthetics_service/utils/mocks'; +import { loggerMock } from '@kbn/logging-mocks'; +import { savedObjectsClientMock } from '@kbn/core-saved-objects-api-server-mocks'; +import { SyntheticsMonitorClient } from '../../synthetics_service/synthetics_monitor/synthetics_monitor_client'; +import { SyntheticsService } from '../../synthetics_service/synthetics_service'; +import * as getLocations from '../../synthetics_service/get_all_locations'; + +describe('processMonitors', () => { + const mockEsClient = { + search: jest.fn(), + }; + const logger = loggerMock.create(); + const soClient = savedObjectsClientMock.create(); + + const serverMock: UptimeServerSetup = { + logger, + uptimeEsClient: mockEsClient, + authSavedObjectsClient: soClient, + config: { + service: { + username: 'dev', + password: '12345', + manifestUrl: 'http://localhost:8080/api/manifest', + }, + }, + spaces: { + spacesService: { + getSpaceId: jest.fn().mockReturnValue('test-space'), + }, + }, + encryptedSavedObjects: mockEncryptedSO, + } as unknown as UptimeServerSetup; + + const syntheticsService = new SyntheticsService(serverMock); + + const monitorClient = new SyntheticsMonitorClient(syntheticsService, serverMock); + + it('should return a processed data', async () => { + const result = await processMonitors(testMonitors, serverMock, soClient, monitorClient); + expect(result).toEqual({ + allIds: [ + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22', + '7f796001-a795-4c0b-afdb-3ce74edea775', + '5e203f47-1261-4978-a915-cc3315d90fb1', + ], + disabledCount: 2, + disabledMonitorsCount: 1, + projectMonitorsCount: 1, + enabledIds: ['aa925d91-40b0-4f8f-b695-bb9b53cd4e22', '7f796001-a795-4c0b-afdb-3ce74edea775'], + listOfLocations: ['US Central QA', 'US Central Staging', 'North America - US Central'], + maxPeriod: 600000, + monitorLocationMap: { + '7f796001-a795-4c0b-afdb-3ce74edea775': [ + 'US Central QA', + 'North America - US Central', + 'US Central Staging', + ], + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22': ['US Central QA', 'US Central Staging'], + }, + }); + }); + + it('should return a processed data where location label is missing', async () => { + testMonitors[0].attributes.locations[0].label = undefined; + + const result = await processMonitors(testMonitors, serverMock, soClient, monitorClient); + expect(result).toEqual({ + allIds: [ + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22', + '7f796001-a795-4c0b-afdb-3ce74edea775', + '5e203f47-1261-4978-a915-cc3315d90fb1', + ], + disabledCount: 2, + disabledMonitorsCount: 1, + projectMonitorsCount: 1, + enabledIds: ['aa925d91-40b0-4f8f-b695-bb9b53cd4e22', '7f796001-a795-4c0b-afdb-3ce74edea775'], + listOfLocations: [ + 'US Central Staging', + 'us_central_qa', + 'US Central QA', + 'North America - US Central', + ], + maxPeriod: 600000, + monitorLocationMap: { + '7f796001-a795-4c0b-afdb-3ce74edea775': [ + 'US Central QA', + 'North America - US Central', + 'US Central Staging', + ], + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22': ['US Central Staging', 'us_central_qa'], + }, + }); + }); + + it('should return a processed data where location label is missing but it get resolved', async () => { + testMonitors[0].attributes.locations[0].label = undefined; + + jest.spyOn(getLocations, 'getAllLocations').mockResolvedValue( + new Promise((r) => + r({ + publicLocations: [ + { + id: 'us_central', + label: 'North America - US Central', + geo: { lat: 41.25, lon: -95.86 }, + url: 'https://central.dev', + isServiceManaged: true, + status: 'beta', + isInvalid: false, + }, + { + id: 'us_central_qa', + label: 'US Central QA', + geo: { lat: 41.25, lon: -95.86 }, + url: 'https://qa.elstc.co', + isServiceManaged: true, + status: 'beta', + isInvalid: false, + }, + { + id: 'us_central_staging', + label: 'US Central Staging', + geo: { lat: 41.25, lon: -95.86 }, + url: 'https://staging.no', + isServiceManaged: true, + status: 'beta', + isInvalid: false, + }, + ], + privateLocations: [], + throttling: { download: 20, upload: 10 }, + } as any) + ) + ); + + const result = await processMonitors(testMonitors, serverMock, soClient, monitorClient); + expect(result).toEqual({ + allIds: [ + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22', + '7f796001-a795-4c0b-afdb-3ce74edea775', + '5e203f47-1261-4978-a915-cc3315d90fb1', + ], + disabledCount: 2, + disabledMonitorsCount: 1, + projectMonitorsCount: 1, + enabledIds: ['aa925d91-40b0-4f8f-b695-bb9b53cd4e22', '7f796001-a795-4c0b-afdb-3ce74edea775'], + listOfLocations: ['US Central Staging', 'US Central QA', 'North America - US Central'], + maxPeriod: 600000, + monitorLocationMap: { + '7f796001-a795-4c0b-afdb-3ce74edea775': [ + 'US Central QA', + 'North America - US Central', + 'US Central Staging', + ], + 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22': ['US Central Staging', 'US Central QA'], + }, + }); + }); +}); + +const testMonitors: any = [ + { + type: 'synthetics-monitor', + id: 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22', + attributes: { + enabled: true, + schedule: { number: '3', unit: 'm' }, + locations: [ + { isServiceManaged: true, id: 'us_central_qa', label: 'US Central QA' }, + { isServiceManaged: true, id: 'us_central_staging', label: 'US Central Staging' }, + ], + id: 'aa925d91-40b0-4f8f-b695-bb9b53cd4e22', + }, + references: [], + migrationVersion: { 'synthetics-monitor': '8.6.0' }, + coreMigrationVersion: '8.7.0', + updated_at: '2023-01-17T08:21:53.528Z', + created_at: '2023-01-15T12:58:27.795Z', + version: 'Wzk1NzYyLDFd', + namespaces: ['default'], + score: 0, + }, + { + type: 'synthetics-monitor', + id: '7f796001-a795-4c0b-afdb-3ce74edea775', + attributes: { + enabled: true, + schedule: { unit: 'm', number: '10' }, + locations: [ + { isServiceManaged: true, id: 'us_central_qa', label: 'US Central QA' }, + { isServiceManaged: true, id: 'us_central', label: 'North America - US Central' }, + { isServiceManaged: true, id: 'us_central_staging', label: 'US Central Staging' }, + ], + id: '7f796001-a795-4c0b-afdb-3ce74edea775', + }, + references: [], + migrationVersion: { 'synthetics-monitor': '8.6.0' }, + coreMigrationVersion: '8.7.0', + updated_at: '2023-01-17T09:09:21.542Z', + created_at: '2023-01-13T22:49:59.273Z', + version: 'Wzk3MDM0LDFd', + namespaces: ['default'], + score: 0, + }, + { + type: 'synthetics-monitor', + id: '5e203f47-1261-4978-a915-cc3315d90fb1', + attributes: { + enabled: false, + schedule: { number: '3', unit: 'm' }, + locations: [ + { id: 'us_central_qa', label: 'US Central QA', isServiceManaged: true }, + { id: 'us_central_staging', label: 'US Central Staging', isServiceManaged: true }, + ], + id: '5e203f47-1261-4978-a915-cc3315d90fb1', + origin: 'project', + }, + references: [], + migrationVersion: { 'synthetics-monitor': '8.6.0' }, + coreMigrationVersion: '8.7.0', + updated_at: '2023-01-17T12:48:11.301Z', + created_at: '2023-01-17T12:48:11.301Z', + version: 'WzEwMDA5OSwxXQ==', + namespaces: ['default'], + score: 0, + }, +]; diff --git a/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.ts b/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.ts index c756bcad30630..d2c28d811eb54 100644 --- a/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.ts +++ b/x-pack/plugins/synthetics/server/saved_objects/synthetics_monitor/get_all_monitors.ts @@ -10,8 +10,18 @@ import { SavedObjectsFindOptions, SavedObjectsFindResult, } from '@kbn/core-saved-objects-api-server'; +import pMap from 'p-map'; +import { periodToMs } from '../../routes/status/current_status'; +import { UptimeServerSetup } from '../../legacy_uptime/lib/adapters'; +import { getAllLocations } from '../../synthetics_service/get_all_locations'; import { syntheticsMonitorType } from '../../legacy_uptime/lib/saved_objects/synthetics_monitor'; -import { EncryptedSyntheticsMonitor } from '../../../common/runtime_types'; +import { + ConfigKey, + EncryptedSyntheticsMonitor, + ServiceLocation, + SourceType, +} from '../../../common/runtime_types'; +import { SyntheticsMonitorClient } from '../../synthetics_service/synthetics_monitor/synthetics_monitor_client'; export const getAllMonitors = async ({ soClient, @@ -44,3 +54,92 @@ export const getAllMonitors = async ({ return hits; }; + +export const processMonitors = async ( + allMonitors: Array>, + server: UptimeServerSetup, + soClient: SavedObjectsClientContract, + syntheticsMonitorClient: SyntheticsMonitorClient +) => { + /** + * Walk through all monitor saved objects, bucket IDs by disabled/enabled status. + * + * Track max period to make sure the snapshot query should reach back far enough to catch + * latest ping for all enabled monitors. + */ + + const enabledIds: string[] = []; + let disabledCount = 0; + let disabledMonitorsCount = 0; + let maxPeriod = 0; + let projectMonitorsCount = 0; + const allIds: string[] = []; + let listOfLocationsSet = new Set(); + const monitorLocationMap: Record = {}; + + let allLocations: ServiceLocation[] | null = null; + + const getLocationLabel = async (locationId: string) => { + if (!allLocations) { + const { publicLocations, privateLocations } = await getAllLocations( + server, + syntheticsMonitorClient, + soClient + ); + + allLocations = [...publicLocations, ...privateLocations]; + } + + return allLocations.find((loc) => loc.id === locationId)?.label ?? locationId; + }; + + for (const monitor of allMonitors) { + const attrs = monitor.attributes; + + allIds.push(attrs[ConfigKey.MONITOR_QUERY_ID]); + + projectMonitorsCount += attrs?.[ConfigKey.MONITOR_SOURCE_TYPE] === SourceType.PROJECT ? 1 : 0; + + if (attrs[ConfigKey.ENABLED] === false) { + disabledCount += attrs[ConfigKey.LOCATIONS].length; + disabledMonitorsCount += 1; + } else { + const missingLabels = new Set(); + + enabledIds.push(attrs[ConfigKey.MONITOR_QUERY_ID]); + const monLocs = new Set([ + ...(attrs[ConfigKey.LOCATIONS] + .filter((loc) => { + if (!loc.label) { + missingLabels.add(loc.id); + } + return loc.label; + }) + .map((location) => location.label) as string[]), + ]); + + // since label wasn't always part of location, there can be a case where we have a location + // with an id but no label. We need to fetch the label from the API + // Adding a migration to add the label to the saved object is a future consideration + const locLabels = await pMap([...missingLabels], async (locationId) => + getLocationLabel(locationId) + ); + + monitorLocationMap[attrs[ConfigKey.MONITOR_QUERY_ID]] = [...monLocs, ...locLabels]; + listOfLocationsSet = new Set([...listOfLocationsSet, ...monLocs, ...locLabels]); + + maxPeriod = Math.max(maxPeriod, periodToMs(attrs[ConfigKey.SCHEDULE])); + } + } + + return { + maxPeriod, + allIds, + enabledIds, + disabledCount, + monitorLocationMap, + disabledMonitorsCount, + projectMonitorsCount, + listOfLocations: [...listOfLocationsSet], + }; +}; diff --git a/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.test.ts b/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.test.ts index f10962d07c043..838eec82f2727 100644 --- a/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.test.ts +++ b/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.test.ts @@ -15,6 +15,7 @@ import { ResponseBodyIndexPolicy, ScheduleUnit, SyntheticsMonitor, + VerificationMode, } from '../../../common/runtime_types'; const testHTTPConfig: Partial = { @@ -40,6 +41,7 @@ const testHTTPConfig: Partial = { 'check.request.body': { type: 'text' as Mode, value: '' }, 'check.request.headers': {}, 'check.request.method': 'GET', + 'ssl.verification_mode': VerificationMode.NONE, username: '', }; @@ -102,105 +104,131 @@ describe('formatMonitorConfig', () => { urls: 'https://www.google.com', }); }); + + it.each([true, false])( + 'omits ssl fields when tls is disabled and includes ssl fields when enabled', + (isTLSEnabled) => { + const yamlConfig = formatMonitorConfig(Object.keys(testHTTPConfig) as ConfigKey[], { + ...testHTTPConfig, + [ConfigKey.METADATA]: { is_tls_enabled: isTLSEnabled }, + }); + + expect(yamlConfig).toEqual({ + 'check.request.method': 'GET', + enabled: true, + locations: [], + max_redirects: '0', + name: 'Test', + password: '3z9SBOQWW5F0UrdqLVFqlF6z', + 'response.include_body': 'on_error', + 'response.include_headers': true, + schedule: '@every 3m', + timeout: '16s', + type: 'http', + urls: 'https://www.google.com', + ...(isTLSEnabled ? { 'ssl.verification_mode': 'none' } : {}), + }); + } + ); }); +}); - describe('browser fields', () => { - let formattedBrowserConfig: Record; +describe('browser fields', () => { + let formattedBrowserConfig: Record; + + beforeEach(() => { + formattedBrowserConfig = { + enabled: true, + 'filter_journeys.tags': ['dev'], + ignore_https_errors: false, + name: 'Test', + locations: [], + schedule: '@every 3m', + screenshots: 'on', + 'source.inline.script': + "step('Go to https://www.google.com/', async () => {\n await page.goto('https://www.google.com/');\n});", + throttling: { + download: 5, + latency: 20, + upload: 3, + }, + timeout: '16s', + type: 'browser', + synthetics_args: ['--hasTouch true'], + params: { + a: 'param', + }, + playwright_options: { + playwright: 'option', + }, + }; + }); - beforeEach(() => { - formattedBrowserConfig = { - enabled: true, - 'filter_journeys.tags': ['dev'], - ignore_https_errors: false, - name: 'Test', - locations: [], - schedule: '@every 3m', - screenshots: 'on', - 'source.inline.script': - "step('Go to https://www.google.com/', async () => {\n await page.goto('https://www.google.com/');\n});", - throttling: { - download: 5, - latency: 20, - upload: 3, - }, - timeout: '16s', - type: 'browser', - synthetics_args: ['--hasTouch true'], - params: { - a: 'param', - }, - playwright_options: { - playwright: 'option', - }, - }; - }); + it('sets browser keys properly', () => { + const yamlConfig = formatMonitorConfig( + Object.keys(testBrowserConfig) as ConfigKey[], + testBrowserConfig + ); - it('sets browser keys properly', () => { - const yamlConfig = formatMonitorConfig( - Object.keys(testBrowserConfig) as ConfigKey[], - testBrowserConfig - ); + expect(yamlConfig).toEqual(formattedBrowserConfig); + }); - expect(yamlConfig).toEqual(formattedBrowserConfig); + it('does not set empty strings or empty objects for params and playwright options', () => { + const yamlConfig = formatMonitorConfig(Object.keys(testBrowserConfig) as ConfigKey[], { + ...testBrowserConfig, + playwright_options: '{}', + params: '', }); - it('does not set empty strings or empty objects for params and playwright options', () => { - const yamlConfig = formatMonitorConfig(Object.keys(testBrowserConfig) as ConfigKey[], { - ...testBrowserConfig, - playwright_options: '{}', - params: '', - }); - - expect(yamlConfig).toEqual(omit(formattedBrowserConfig, ['params', 'playwright_options'])); - }); + expect(yamlConfig).toEqual(omit(formattedBrowserConfig, ['params', 'playwright_options'])); + }); - it('excludes UI fields', () => { - testBrowserConfig['throttling.is_enabled'] = false; - testBrowserConfig['throttling.upload_speed'] = '3'; + it('excludes UI fields', () => { + testBrowserConfig['throttling.is_enabled'] = false; + testBrowserConfig['throttling.upload_speed'] = '3'; - const formattedConfig = formatMonitorConfig( - Object.keys(testBrowserConfig) as ConfigKey[], - testBrowserConfig - ); + const formattedConfig = formatMonitorConfig( + Object.keys(testBrowserConfig) as ConfigKey[], + testBrowserConfig + ); - const expected = { - ...formattedConfig, - throttling: false, - 'throttling.is_enabled': undefined, - 'throttling.upload_speed': undefined, - }; + const expected = { + ...formattedConfig, + throttling: false, + 'throttling.is_enabled': undefined, + 'throttling.upload_speed': undefined, + }; - expect(formattedConfig).toEqual(expected); - }); + expect(formattedConfig).toEqual(expected); + }); - it('excludes empty array values', () => { - testBrowserConfig['filter_journeys.tags'] = []; + it('excludes empty array values', () => { + testBrowserConfig['filter_journeys.tags'] = []; - const formattedConfig = formatMonitorConfig( - Object.keys(testBrowserConfig) as ConfigKey[], - testBrowserConfig - ); + const formattedConfig = formatMonitorConfig( + Object.keys(testBrowserConfig) as ConfigKey[], + testBrowserConfig + ); - const expected = { - ...formattedConfig, - 'filter_journeys.tags': undefined, - }; + const expected = { + ...formattedConfig, + 'filter_journeys.tags': undefined, + }; - expect(formattedConfig).toEqual(expected); - }); + expect(formattedConfig).toEqual(expected); + }); - it('does not exclude "false" fields', () => { - testBrowserConfig.enabled = false; + it('does not exclude "false" fields', () => { + testBrowserConfig.enabled = false; - const formattedConfig = formatMonitorConfig( - Object.keys(testBrowserConfig) as ConfigKey[], - testBrowserConfig - ); + const formattedConfig = formatMonitorConfig( + Object.keys(testBrowserConfig) as ConfigKey[], + testBrowserConfig + ); - const expected = { ...formattedConfig, enabled: false }; + const expected = { ...formattedConfig, enabled: false }; - expect(formattedConfig).toEqual(expected); - }); + expect(formattedConfig).toEqual(expected); }); }); diff --git a/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.ts b/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.ts index 37f7e8ec03550..0c2d746690ed3 100644 --- a/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.ts +++ b/x-pack/plugins/synthetics/server/synthetics_service/formatters/format_configs.ts @@ -12,6 +12,7 @@ import { MonitorFields, SyntheticsMonitor, HeartbeatConfig, + TLSFields, } from '../../../common/runtime_types'; import { formatters } from '.'; @@ -53,6 +54,13 @@ export const formatMonitorConfig = (configKeys: ConfigKey[], config: Partial + key.includes('ssl') + ) as unknown as Array; + sslKeys.forEach((key) => (formattedMonitor[key] = null)); + } + Object.keys(uiToHeartbeatKeyMap).forEach((key) => { const hbKey = key as YamlKeys; const configKey = uiToHeartbeatKeyMap[hbKey]; diff --git a/x-pack/plugins/synthetics/server/synthetics_service/service_api_client.test.ts b/x-pack/plugins/synthetics/server/synthetics_service/service_api_client.test.ts index 62a54db4460a6..52056b77ae8b7 100644 --- a/x-pack/plugins/synthetics/server/synthetics_service/service_api_client.test.ts +++ b/x-pack/plugins/synthetics/server/synthetics_service/service_api_client.test.ts @@ -200,7 +200,7 @@ describe('callAPI', () => { 'x-kibana-version': '8.7.0', }, httpsAgent: expect.objectContaining({ - options: { rejectUnauthorized: true, path: null }, + options: { noDelay: true, rejectUnauthorized: true, path: null }, }), method: 'POST', url: 'https://service.dev/monitors', @@ -213,7 +213,7 @@ describe('callAPI', () => { 'x-kibana-version': '8.7.0', }, httpsAgent: expect.objectContaining({ - options: { rejectUnauthorized: true, path: null }, + options: { noDelay: true, rejectUnauthorized: true, path: null }, }), method: 'POST', url: 'https://qa.service.elstc.co/monitors', @@ -226,7 +226,7 @@ describe('callAPI', () => { 'x-kibana-version': '8.7.0', }, httpsAgent: expect.objectContaining({ - options: { rejectUnauthorized: true, path: null }, + options: { noDelay: true, rejectUnauthorized: true, path: null }, }), method: 'POST', url: 'https://qa.service.stg.co/monitors', @@ -293,6 +293,7 @@ describe('callAPI', () => { httpsAgent: expect.objectContaining({ options: { rejectUnauthorized: true, + noDelay: true, path: null, cert: 'test-certificate', key: 'test-key', diff --git a/x-pack/plugins/synthetics/tsconfig.json b/x-pack/plugins/synthetics/tsconfig.json index c59c1a4221821..685a74cc6e871 100644 --- a/x-pack/plugins/synthetics/tsconfig.json +++ b/x-pack/plugins/synthetics/tsconfig.json @@ -69,6 +69,7 @@ "@kbn/bfetch-plugin", "@kbn/actions-plugin", "@kbn/core-elasticsearch-server", + "@kbn/core-saved-objects-api-server-mocks", ], "exclude": [ "target/**/*", diff --git a/x-pack/plugins/task_manager/server/buffered_task_store.test.ts b/x-pack/plugins/task_manager/server/buffered_task_store.test.ts index 45607713a3128..1e585f370bc12 100644 --- a/x-pack/plugins/task_manager/server/buffered_task_store.test.ts +++ b/x-pack/plugins/task_manager/server/buffered_task_store.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { taskStoreMock } from './task_store.mock'; import { BufferedTaskStore } from './buffered_task_store'; import { asErr, asOk } from './lib/result_type'; @@ -95,7 +95,7 @@ describe('Buffered Task Store', () => { function mockTask() { return { - id: `task_${uuid.v4()}`, + id: `task_${uuidv4()}`, attempts: 0, schedule: undefined, params: { hello: 'world' }, diff --git a/x-pack/plugins/task_manager/server/ephemeral_task_lifecycle.test.ts b/x-pack/plugins/task_manager/server/ephemeral_task_lifecycle.test.ts index 3ff7341faab4c..353df1e11d110 100644 --- a/x-pack/plugins/task_manager/server/ephemeral_task_lifecycle.test.ts +++ b/x-pack/plugins/task_manager/server/ephemeral_task_lifecycle.test.ts @@ -15,7 +15,7 @@ import { asErr, asOk } from './lib/result_type'; import { FillPoolResult } from './lib/fill_pool'; import { EphemeralTaskLifecycle, EphemeralTaskLifecycleOpts } from './ephemeral_task_lifecycle'; import { ConcreteTaskInstance, TaskStatus } from './task'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { asTaskPollingCycleEvent, asTaskRunEvent, TaskPersistence } from './task_events'; import { TaskRunResult } from './task_running'; import { TaskPoolRunResult } from './task_pool'; @@ -173,7 +173,7 @@ describe('EphemeralTaskLifecycle', () => { lifecycleEvent$.next( asTaskRunEvent( - uuid.v4(), + uuidv4(), asOk({ task: mockTask(), result: TaskRunResult.Success, @@ -386,7 +386,7 @@ describe('EphemeralTaskLifecycle', () => { function mockTask(overrides: Partial = {}): ConcreteTaskInstance { return { - id: uuid.v4(), + id: uuidv4(), runAt: new Date(), taskType: 'foo', schedule: undefined, diff --git a/x-pack/plugins/task_manager/server/lib/bulk_remove_if_exist.test.ts b/x-pack/plugins/task_manager/server/lib/bulk_remove_if_exist.test.ts index ac71653c31c8f..0b1c08f448398 100644 --- a/x-pack/plugins/task_manager/server/lib/bulk_remove_if_exist.test.ts +++ b/x-pack/plugins/task_manager/server/lib/bulk_remove_if_exist.test.ts @@ -5,13 +5,13 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; import { bulkRemoveIfExist } from './bulk_remove_if_exist'; import { taskStoreMock } from '../task_store.mock'; describe('removeIfExists', () => { - const ids = [uuid.v4(), uuid.v4()]; + const ids = [uuidv4(), uuidv4()]; test('removes the tasks by its IDs', async () => { const ts = taskStoreMock.create({}); @@ -34,7 +34,7 @@ describe('removeIfExists', () => { test('throws if any other error is caused by task removal', async () => { const ts = taskStoreMock.create({}); - const error = SavedObjectsErrorHelpers.createInvalidVersionError(uuid.v4()); + const error = SavedObjectsErrorHelpers.createInvalidVersionError(uuidv4()); ts.bulkRemove.mockRejectedValue(error); expect(bulkRemoveIfExist(ts, ids)).rejects.toBe(error); diff --git a/x-pack/plugins/task_manager/server/lib/is_task_not_found_error.test.ts b/x-pack/plugins/task_manager/server/lib/is_task_not_found_error.test.ts index 6cc6beb26bf7b..6a5d0c48b6c77 100644 --- a/x-pack/plugins/task_manager/server/lib/is_task_not_found_error.test.ts +++ b/x-pack/plugins/task_manager/server/lib/is_task_not_found_error.test.ts @@ -7,11 +7,11 @@ import { isTaskSavedObjectNotFoundError } from './is_task_not_found_error'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; describe('isTaskSavedObjectNotFoundError', () => { test('identifies SavedObjects Not Found errors', () => { - const id = uuid.v4(); + const id = uuidv4(); // ensure the error created by SO parses as a string with the format we expect expect( `${SavedObjectsErrorHelpers.createGenericNotFoundError('task', id)}`.includes(`task/${id}`) @@ -26,7 +26,7 @@ describe('isTaskSavedObjectNotFoundError', () => { }); test('identifies generic errors', () => { - const id = uuid.v4(); + const id = uuidv4(); expect(isTaskSavedObjectNotFoundError(new Error(`not found`), id)).toBe(false); }); }); diff --git a/x-pack/plugins/task_manager/server/lib/remove_if_exists.test.ts b/x-pack/plugins/task_manager/server/lib/remove_if_exists.test.ts index 7b9ec4bbb8b28..748e529ef1446 100644 --- a/x-pack/plugins/task_manager/server/lib/remove_if_exists.test.ts +++ b/x-pack/plugins/task_manager/server/lib/remove_if_exists.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; import { removeIfExists } from './remove_if_exists'; import { taskStoreMock } from '../task_store.mock'; @@ -13,7 +13,7 @@ import { taskStoreMock } from '../task_store.mock'; describe('removeIfExists', () => { test('removes the task by its ID', async () => { const ts = taskStoreMock.create({}); - const id = uuid.v4(); + const id = uuidv4(); expect(await removeIfExists(ts, id)).toBe(undefined); @@ -22,7 +22,7 @@ describe('removeIfExists', () => { test('handles 404 errors caused by the task not existing', async () => { const ts = taskStoreMock.create({}); - const id = uuid.v4(); + const id = uuidv4(); ts.remove.mockRejectedValue(SavedObjectsErrorHelpers.createGenericNotFoundError('task', id)); @@ -33,9 +33,9 @@ describe('removeIfExists', () => { test('throws if any other errro is caused by task removal', async () => { const ts = taskStoreMock.create({}); - const id = uuid.v4(); + const id = uuidv4(); - const error = SavedObjectsErrorHelpers.createInvalidVersionError(uuid.v4()); + const error = SavedObjectsErrorHelpers.createInvalidVersionError(uuidv4()); ts.remove.mockRejectedValue(error); expect(removeIfExists(ts, id)).rejects.toBe(error); diff --git a/x-pack/plugins/task_manager/server/lib/result_type.test.ts b/x-pack/plugins/task_manager/server/lib/result_type.test.ts index 0d2a9012071ae..d35f00d30920c 100644 --- a/x-pack/plugins/task_manager/server/lib/result_type.test.ts +++ b/x-pack/plugins/task_manager/server/lib/result_type.test.ts @@ -5,23 +5,23 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { unwrapPromise, asOk, asErr } from './result_type'; describe(`Result`, () => { describe(`unwrapPromise`, () => { test(`unwraps OKs from the result`, async () => { - const uniqueId = uuid.v4(); + const uniqueId = uuidv4(); expect(await unwrapPromise(Promise.resolve(asOk(uniqueId)))).toEqual(uniqueId); }); test(`unwraps Errs from the result`, async () => { - const uniqueId = uuid.v4(); + const uniqueId = uuidv4(); expect(unwrapPromise(Promise.resolve(asErr(uniqueId)))).rejects.toEqual(uniqueId); }); test(`unwraps Errs from the result when promise rejects`, async () => { - const uniqueId = uuid.v4(); + const uniqueId = uuidv4(); expect(unwrapPromise(Promise.reject(asErr(uniqueId)))).rejects.toEqual(uniqueId); }); }); diff --git a/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.test.ts b/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.test.ts deleted file mode 100644 index 00c4a613fd425..0000000000000 --- a/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.test.ts +++ /dev/null @@ -1,309 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { loggingSystemMock, savedObjectsRepositoryMock } from '@kbn/core/server/mocks'; -import { SerializedConcreteTaskInstance, TaskStatus } from '../task'; -import { NUM_RETRIES, retryOnBulkUpdateConflict } from './retry_on_bulk_update_conflict'; - -const mockSavedObjectsRepository = savedObjectsRepositoryMock.create(); -const mockLogger = loggingSystemMock.create().get(); -const mockedDate = new Date('2019-02-12T21:01:22.479Z'); - -const task1 = { - type: 'task', - id: 'task:123456', - attributes: { - runAt: mockedDate.toISOString(), - scheduledAt: mockedDate.toISOString(), - startedAt: null, - retryAt: null, - params: `{ "hello": "world" }`, - state: `{ "id": "123456" }`, - taskType: 'alert', - attempts: 3, - status: 'idle' as TaskStatus, - ownerId: null, - traceparent: '', - }, -}; - -const task2 = { - type: 'task', - id: 'task:324242', - attributes: { - runAt: mockedDate.toISOString(), - scheduledAt: mockedDate.toISOString(), - startedAt: null, - retryAt: null, - params: `{ "hello": "world" }`, - state: `{ "foo": "bar" }`, - taskType: 'report', - attempts: 3, - status: 'idle' as TaskStatus, - ownerId: null, - traceparent: '', - }, -}; - -const task3 = { - type: 'task', - id: 'task:xyaaa', - attributes: { - runAt: mockedDate.toISOString(), - scheduledAt: mockedDate.toISOString(), - startedAt: null, - retryAt: null, - params: `{ "goodbye": "world" }`, - state: `{ "foo": "bar" }`, - taskType: 'action', - attempts: 3, - status: 'idle' as TaskStatus, - ownerId: null, - traceparent: '', - }, -}; - -describe('retryOnBulkUpdateConflict', () => { - beforeEach(() => { - jest.resetAllMocks(); - }); - - test('should not retry when all updates are successful', async () => { - const savedObjectResponse = [ - { - id: task1.id, - type: task1.type, - attributes: task1.attributes, - references: [], - }, - ]; - mockSavedObjectsRepository.bulkUpdate.mockResolvedValueOnce({ - saved_objects: savedObjectResponse, - }); - const { savedObjects } = await retryOnBulkUpdateConflict({ - logger: mockLogger, - savedObjectsRepository: mockSavedObjectsRepository, - objects: [task1], - }); - - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenCalledTimes(1); - expect(savedObjects).toEqual(savedObjectResponse); - }); - - test('should throw error when saved objects bulkUpdate throws an error', async () => { - mockSavedObjectsRepository.bulkUpdate.mockImplementationOnce(() => { - throw new Error('fail'); - }); - await expect(() => - retryOnBulkUpdateConflict({ - logger: mockLogger, - savedObjectsRepository: mockSavedObjectsRepository, - objects: [task1], - }) - ).rejects.toThrowErrorMatchingInlineSnapshot(`"fail"`); - }); - - test('should not retry and return non-conflict errors', async () => { - const savedObjectResponse = [ - { - id: task1.id, - type: task1.type, - attributes: task1.attributes, - references: [], - }, - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Not a conflict`, - message: `Some error that's not a conflict`, - statusCode: 404, - }, - references: [], - }, - ]; - mockSavedObjectsRepository.bulkUpdate.mockResolvedValueOnce({ - saved_objects: savedObjectResponse, - }); - const { savedObjects } = await retryOnBulkUpdateConflict({ - logger: mockLogger, - savedObjectsRepository: mockSavedObjectsRepository, - objects: [task1, task2], - }); - - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenCalledTimes(1); - expect(savedObjects).toEqual(savedObjectResponse); - }); - - test(`should return conflict errors when number of retries exceeds ${NUM_RETRIES}`, async () => { - const savedObjectResponse = [ - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Conflict`, - message: `There was a conflict`, - statusCode: 409, - }, - references: [], - }, - ]; - mockSavedObjectsRepository.bulkUpdate.mockResolvedValue({ - saved_objects: savedObjectResponse, - }); - const { savedObjects } = await retryOnBulkUpdateConflict({ - logger: mockLogger, - savedObjectsRepository: mockSavedObjectsRepository, - objects: [task2], - }); - - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenCalledTimes(NUM_RETRIES + 1); - expect(savedObjects).toEqual(savedObjectResponse); - - expect(mockLogger.warn).toBeCalledWith('Bulk update saved object conflicts, exceeded retries'); - }); - - test('should retry as expected when there are conflicts', async () => { - mockSavedObjectsRepository.bulkUpdate - .mockResolvedValueOnce({ - saved_objects: [ - { - id: task1.id, - type: task1.type, - attributes: task1.attributes, - references: [], - }, - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Conflict`, - message: `This is a conflict`, - statusCode: 409, - }, - references: [], - }, - { - id: task3.id, - type: task3.type, - attributes: task3.attributes, - error: { - error: `Conflict`, - message: `This is a conflict`, - statusCode: 409, - }, - references: [], - }, - ], - }) - .mockResolvedValueOnce({ - saved_objects: [ - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Conflict`, - message: `This is a conflict`, - statusCode: 409, - }, - references: [], - }, - { - id: task3.id, - type: task3.type, - attributes: task3.attributes, - references: [], - }, - ], - }) - .mockResolvedValueOnce({ - saved_objects: [ - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Conflict`, - message: `This is a conflict`, - statusCode: 409, - }, - references: [], - }, - ], - }) - .mockResolvedValueOnce({ - saved_objects: [ - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - error: { - error: `Conflict`, - message: `This is a conflict`, - statusCode: 409, - }, - references: [], - }, - ], - }) - .mockResolvedValueOnce({ - saved_objects: [ - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - references: [], - }, - ], - }); - const { savedObjects } = await retryOnBulkUpdateConflict({ - logger: mockLogger, - savedObjectsRepository: mockSavedObjectsRepository, - objects: [task1, task2, task3], - retries: 5, - }); - - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenCalledTimes(5); - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenNthCalledWith( - 1, - [task1, task2, task3], - undefined - ); - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenNthCalledWith( - 2, - [task2, task3], - undefined - ); - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenNthCalledWith(3, [task2], undefined); - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenNthCalledWith(4, [task2], undefined); - expect(mockSavedObjectsRepository.bulkUpdate).toHaveBeenNthCalledWith(5, [task2], undefined); - expect(savedObjects).toEqual([ - { - id: task1.id, - type: task1.type, - attributes: task1.attributes, - references: [], - }, - { - id: task3.id, - type: task3.type, - attributes: task3.attributes, - references: [], - }, - { - id: task2.id, - type: task2.type, - attributes: task2.attributes, - references: [], - }, - ]); - }); -}); diff --git a/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.ts b/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.ts deleted file mode 100644 index cdf4d9234e541..0000000000000 --- a/x-pack/plugins/task_manager/server/lib/retry_on_bulk_update_conflict.ts +++ /dev/null @@ -1,123 +0,0 @@ -/* - * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one - * or more contributor license agreements. Licensed under the Elastic License - * 2.0; you may not use this file except in compliance with the Elastic License - * 2.0. - */ - -import { - ISavedObjectsRepository, - Logger, - SavedObjectsBulkUpdateObject, - SavedObjectsBulkUpdateOptions, - SavedObjectsUpdateResponse, -} from '@kbn/core/server'; - -export const NUM_RETRIES = 2; - -interface RetryOnBulkUpdateConflictOpts { - logger: Logger; - savedObjectsRepository: ISavedObjectsRepository; - objects: Array>; - options?: SavedObjectsBulkUpdateOptions; - retries?: number; -} - -interface RetryOnBulkUpdateConflictResults { - savedObjects: Array>; -} - -export const retryOnBulkUpdateConflict = async ({ - logger, - savedObjectsRepository, - objects, - options, - retries = NUM_RETRIES, -}: RetryOnBulkUpdateConflictOpts): Promise> => { - return retryOnBulkUpdateConflictHelper({ - logger, - savedObjectsRepository, - objects, - options, - retries, - }); -}; - -const retryOnBulkUpdateConflictHelper = async ({ - logger, - savedObjectsRepository, - objects, - options, - retries = NUM_RETRIES, - accResults = [], -}: RetryOnBulkUpdateConflictOpts & { - accResults?: Array>; -}): Promise> => { - try { - const { saved_objects: savedObjectsResults } = await savedObjectsRepository.bulkUpdate( - objects, - options - ); - - const currResults: Array> = []; - const currConflicts: Array> = []; - const objectsToRetry: Array> = []; - savedObjectsResults.forEach( - (savedObjectResult: SavedObjectsUpdateResponse, index: number) => { - if (savedObjectResult.error && savedObjectResult.error.statusCode === 409) { - // The SavedObjectsRepository maintains the order of the docs - // so we can rely on the index in the `docs` to match an error - // on the same index in the `bulkUpdate` result - objectsToRetry.push(objects[index]); - currConflicts.push(savedObjectResult); - } else { - // Save results, whether they are successful or non-conflict errors - currResults.push(savedObjectResult); - } - } - ); - - const results = - retries <= 0 - ? [...accResults, ...currResults, ...currConflicts] - : [...accResults, ...currResults]; - - if (objectsToRetry.length === 0) { - return { - savedObjects: results, - }; - } - - if (retries <= 0) { - logger.warn(`Bulk update saved object conflicts, exceeded retries`); - - return { - savedObjects: results, - }; - } - - await waitBeforeNextRetry(retries); - - return retryOnBulkUpdateConflictHelper({ - logger, - savedObjectsRepository, - objects: objectsToRetry, - options, - retries: retries - 1, - accResults: results, - }); - } catch (err) { - throw err; - } -}; - -export const randomDelayMs = Math.floor(Math.random() * 100); -export const getExponentialDelayMultiplier = (retries: number) => 1 + (NUM_RETRIES - retries) ** 2; -export const RETRY_IF_CONFLICTS_DELAY = 250; -export const waitBeforeNextRetry = async (retries: number): Promise => { - const exponentialDelayMultiplier = getExponentialDelayMultiplier(retries); - - await new Promise((resolve) => - setTimeout(resolve, RETRY_IF_CONFLICTS_DELAY * exponentialDelayMultiplier + randomDelayMs) - ); -}; diff --git a/x-pack/plugins/task_manager/server/monitoring/background_task_utilization_statistics.test.ts b/x-pack/plugins/task_manager/server/monitoring/background_task_utilization_statistics.test.ts index 6fda5cdecbf76..45b29c44b1a4b 100644 --- a/x-pack/plugins/task_manager/server/monitoring/background_task_utilization_statistics.test.ts +++ b/x-pack/plugins/task_manager/server/monitoring/background_task_utilization_statistics.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Subject, Observable } from 'rxjs'; import { take, bufferCount, skip, map } from 'rxjs/operators'; import { ConcreteTaskInstance, TaskStatus } from '../task'; @@ -460,7 +460,7 @@ const mockTaskRunEvent = ( }; const mockTaskInstance = (overrides: Partial = {}): ConcreteTaskInstance => ({ - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', diff --git a/x-pack/plugins/task_manager/server/monitoring/ephemeral_task_statistics.test.ts b/x-pack/plugins/task_manager/server/monitoring/ephemeral_task_statistics.test.ts index 1ddfe4bb22088..8a2305c3076a5 100644 --- a/x-pack/plugins/task_manager/server/monitoring/ephemeral_task_statistics.test.ts +++ b/x-pack/plugins/task_manager/server/monitoring/ephemeral_task_statistics.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Subject, Observable } from 'rxjs'; import stats from 'stats-lite'; import { take, bufferCount, skip, map } from 'rxjs/operators'; @@ -366,7 +366,7 @@ const mockTaskRunEvent = ( }; const mockTaskInstance = (overrides: Partial = {}): ConcreteTaskInstance => ({ - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', diff --git a/x-pack/plugins/task_manager/server/monitoring/task_run_calcultors.test.ts b/x-pack/plugins/task_manager/server/monitoring/task_run_calcultors.test.ts index c396e3848eb3f..b5f6be8b7524d 100644 --- a/x-pack/plugins/task_manager/server/monitoring/task_run_calcultors.test.ts +++ b/x-pack/plugins/task_manager/server/monitoring/task_run_calcultors.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { calculateRunningAverage, @@ -29,7 +29,7 @@ describe('calculateRunningAverage', () => { describe('calculateFrequency', () => { test('calculates the frequency of each terms in the list as a percentage', async () => { - const [term1, term2, term3] = [uuid.v4(), uuid.v4(), uuid.v4()]; + const [term1, term2, term3] = [uuidv4(), uuidv4(), uuidv4()]; expect( calculateFrequency([term1, term2, term2, term3, term1, term1, term2, term1, term3]) ).toEqual({ @@ -53,7 +53,7 @@ describe('createRunningAveragedStat', () => { describe('createMapOfRunningAveragedStats', () => { test('create a function which tracks multiple window of values by key', async () => { - const [term1, term2, term3] = [uuid.v4(), uuid.v4(), uuid.v4()]; + const [term1, term2, term3] = [uuidv4(), uuidv4(), uuidv4()]; const mappedQueues = createMapOfRunningAveragedStats(3); expect(mappedQueues(term1, 1)).toEqual({ [term1]: [1] }); expect(mappedQueues(term1, 2)).toEqual({ [term1]: [1, 2] }); diff --git a/x-pack/plugins/task_manager/server/monitoring/task_run_statistics.test.ts b/x-pack/plugins/task_manager/server/monitoring/task_run_statistics.test.ts index 39b262d05f410..4d69b23b699b7 100644 --- a/x-pack/plugins/task_manager/server/monitoring/task_run_statistics.test.ts +++ b/x-pack/plugins/task_manager/server/monitoring/task_run_statistics.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Subject, Observable } from 'rxjs'; import stats from 'stats-lite'; import sinon from 'sinon'; @@ -916,7 +916,7 @@ const mockTaskPollingEvent = (overrides: Partial = {}) => }; const mockTaskInstance = (overrides: Partial = {}): ConcreteTaskInstance => ({ - id: uuid.v4(), + id: uuidv4(), attempts: 0, status: TaskStatus.Running, version: '123', diff --git a/x-pack/plugins/task_manager/server/plugin.ts b/x-pack/plugins/task_manager/server/plugin.ts index 7f2f537a25284..100254f6dae32 100644 --- a/x-pack/plugins/task_manager/server/plugin.ts +++ b/x-pack/plugins/task_manager/server/plugin.ts @@ -207,7 +207,6 @@ export class TaskManagerPlugin const serializer = savedObjects.createSerializer(); const taskStore = new TaskStore({ - logger: this.logger, serializer, savedObjectsRepository, esClient: elasticsearch.client.asInternalUser, diff --git a/x-pack/plugins/task_manager/server/queries/task_claiming.test.ts b/x-pack/plugins/task_manager/server/queries/task_claiming.test.ts index d9cd052856b34..d847165bdba9d 100644 --- a/x-pack/plugins/task_manager/server/queries/task_claiming.test.ts +++ b/x-pack/plugins/task_manager/server/queries/task_claiming.test.ts @@ -6,7 +6,7 @@ */ import _ from 'lodash'; -import uuid from 'uuid'; +import { v1 as uuidv1, v4 as uuidv4 } from 'uuid'; import { filter, take, toArray } from 'rxjs/operators'; import { TaskStatus, ConcreteTaskInstance } from '../task'; @@ -395,7 +395,7 @@ if (doc['task.runAt'].size()!=0) { test('it should claim in batches partitioned by maxConcurrency', async () => { const maxAttempts = _.random(2, 43); const definitions = new TaskTypeDictionary(mockLogger()); - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const fieldUpdates = { ownerId: taskManagerId, retryAt: new Date(Date.now()), @@ -547,7 +547,7 @@ if (doc['task.runAt'].size()!=0) { test('it should reduce the available capacity from batch to batch', async () => { const maxAttempts = _.random(2, 43); const definitions = new TaskTypeDictionary(mockLogger()); - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); definitions.registerTaskDefinitions({ unlimited: { title: 'unlimited', @@ -642,7 +642,7 @@ if (doc['task.runAt'].size()!=0) { test('it shuffles the types claimed in batches to ensure no type starves another', async () => { const maxAttempts = _.random(2, 43); const definitions = new TaskTypeDictionary(mockLogger()); - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); definitions.registerTaskDefinitions({ unlimited: { title: 'unlimited', @@ -730,7 +730,7 @@ if (doc['task.runAt'].size()!=0) { test('it passes any unusedTaskTypes to script', async () => { const maxAttempts = _.random(2, 43); const customMaxAttempts = _.random(44, 100); - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const fieldUpdates = { ownerId: taskManagerId, retryAt: new Date(Date.now()), @@ -853,7 +853,7 @@ if (doc['task.runAt'].size()!=0) { }); test('it claims tasks by setting their ownerId, status and retryAt', async () => { - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const claimOwnershipUntil = new Date(Date.now()); const fieldUpdates = { ownerId: taskManagerId, @@ -891,7 +891,7 @@ if (doc['task.runAt'].size()!=0) { }); test('it filters out running tasks', async () => { - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const claimOwnershipUntil = new Date(Date.now()); const runAt = new Date(); const tasks = [ @@ -979,7 +979,7 @@ if (doc['task.runAt'].size()!=0) { }); test('it returns task objects', async () => { - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const claimOwnershipUntil = new Date(Date.now()); const runAt = new Date(); const tasks = [ @@ -1093,7 +1093,7 @@ if (doc['task.runAt'].size()!=0) { }); test('it returns version_conflicts that do not include conflicts that were proceeded against', async () => { - const taskManagerId = uuid.v1(); + const taskManagerId = uuidv1(); const claimOwnershipUntil = new Date(Date.now()); const runAt = new Date(); const tasks = [ @@ -1211,7 +1211,7 @@ if (doc['task.runAt'].size()!=0) { } function instantiateStoreWithMockedApiResponses({ - taskManagerId = uuid.v4(), + taskManagerId = uuidv4(), definitions = taskDefinitions, getCapacity = () => 10, tasksClaimed, @@ -1305,7 +1305,7 @@ function generateFakeTasks(count: number = 1) { function mockInstance(instance: Partial = {}) { return Object.assign( { - id: uuid.v4(), + id: uuidv4(), taskType: 'bar', sequenceNumber: 32, primaryTerm: 32, diff --git a/x-pack/plugins/task_manager/server/routes/background_task_utilization.test.ts b/x-pack/plugins/task_manager/server/routes/background_task_utilization.test.ts index a10952ddd0463..66052b095a258 100644 --- a/x-pack/plugins/task_manager/server/routes/background_task_utilization.test.ts +++ b/x-pack/plugins/task_manager/server/routes/background_task_utilization.test.ts @@ -6,7 +6,7 @@ */ import { of, Subject } from 'rxjs'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { httpServiceMock } from '@kbn/core/server/mocks'; import { mockHandlerArguments } from './_mock_handler_arguments'; import { sleep } from '../test_utils'; @@ -43,7 +43,7 @@ describe('backgroundTaskUtilizationRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: '.kibana', @@ -67,7 +67,7 @@ describe('backgroundTaskUtilizationRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -107,7 +107,7 @@ describe('backgroundTaskUtilizationRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -153,7 +153,7 @@ describe('backgroundTaskUtilizationRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -170,7 +170,7 @@ describe('backgroundTaskUtilizationRoute', () => { it(`logs an error if the utilization stats are null`, async () => { const router = httpServiceMock.createRouter(); const stats$ = new Subject(); - const id = uuid.v4(); + const id = uuidv4(); backgroundTaskUtilizationRoute({ router, monitoringStats$: stats$, diff --git a/x-pack/plugins/task_manager/server/routes/health.test.ts b/x-pack/plugins/task_manager/server/routes/health.test.ts index c20e2df314e84..6105b7487163c 100644 --- a/x-pack/plugins/task_manager/server/routes/health.test.ts +++ b/x-pack/plugins/task_manager/server/routes/health.test.ts @@ -8,7 +8,7 @@ import { Observable, of, Subject } from 'rxjs'; import { take } from 'rxjs/operators'; import { merge } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { httpServiceMock, docLinksServiceMock } from '@kbn/core/server/mocks'; import { healthRoute } from './health'; import { mockHandlerArguments } from './_mock_handler_arguments'; @@ -59,7 +59,7 @@ describe('healthRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: '.kibana', @@ -83,7 +83,7 @@ describe('healthRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -125,7 +125,7 @@ describe('healthRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -173,7 +173,7 @@ describe('healthRoute', () => { router, monitoringStats$: of(), logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig(), kibanaVersion: '8.0', kibanaIndexName: 'foo', @@ -203,7 +203,7 @@ describe('healthRoute', () => { const stats$ = new Subject(); - const id = uuid.v4(); + const id = uuidv4(); healthRoute({ router, monitoringStats$: stats$, @@ -264,7 +264,7 @@ describe('healthRoute', () => { const stats$ = new Subject(); - const id = uuid.v4(); + const id = uuidv4(); healthRoute({ router, monitoringStats$: stats$, @@ -343,7 +343,7 @@ describe('healthRoute', () => { const stats$ = new Subject(); - const id = uuid.v4(); + const id = uuidv4(); healthRoute({ router, monitoringStats$: stats$, @@ -418,7 +418,7 @@ describe('healthRoute', () => { router, monitoringStats$: stats$, logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig({ monitored_stats_required_freshness: 1000, monitored_aggregated_stats_refresh_rate: 60000, @@ -501,7 +501,7 @@ describe('healthRoute', () => { router, monitoringStats$: stats$, logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig({ monitored_stats_required_freshness: 5000, monitored_aggregated_stats_refresh_rate: 60000, @@ -576,7 +576,7 @@ describe('healthRoute', () => { router, monitoringStats$: stats$, logger, - taskManagerId: uuid.v4(), + taskManagerId: uuidv4(), config: getTaskManagerConfig({ monitored_stats_required_freshness: 1000, monitored_aggregated_stats_refresh_rate: 60000, diff --git a/x-pack/plugins/task_manager/server/saved_objects/migrations.test.ts b/x-pack/plugins/task_manager/server/saved_objects/migrations.test.ts index fe8cc3f81eced..6c7f821d26517 100644 --- a/x-pack/plugins/task_manager/server/saved_objects/migrations.test.ts +++ b/x-pack/plugins/task_manager/server/saved_objects/migrations.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getMigrations } from './migrations'; import { SavedObjectUnsanitizedDoc } from '@kbn/core/server'; import { migrationMocks } from '@kbn/core/server/mocks'; @@ -322,7 +322,7 @@ function getMockData( ...overwrites, }, updated_at: getUpdatedAt(), - id: uuid.v4(), + id: uuidv4(), type: 'task', }; } diff --git a/x-pack/plugins/task_manager/server/task_pool.test.ts b/x-pack/plugins/task_manager/server/task_pool.test.ts index b30bd9facfa2b..baef1587cd242 100644 --- a/x-pack/plugins/task_manager/server/task_pool.test.ts +++ b/x-pack/plugins/task_manager/server/task_pool.test.ts @@ -13,7 +13,7 @@ import { Logger } from '@kbn/core/server'; import { asOk } from './lib/result_type'; import { SavedObjectsErrorHelpers } from '@kbn/core/server'; import moment from 'moment'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { TaskRunningStage } from './task_running'; describe('TaskPool', () => { @@ -375,7 +375,7 @@ describe('TaskPool', () => { const shouldRun = mockRun(); const shouldNotRun = mockRun(); - const taskId = uuid.v4(); + const taskId = uuidv4(); const task1 = mockTask({ id: taskId, run: shouldRun }); const task2 = mockTask({ id: taskId, @@ -402,8 +402,8 @@ describe('TaskPool', () => { function mockTask(overrides = {}) { return { isExpired: false, - taskExecutionId: uuid.v4(), - id: uuid.v4(), + taskExecutionId: uuidv4(), + id: uuidv4(), cancel: async () => undefined, markTaskAsRunning: jest.fn(async () => true), run: mockRun(), diff --git a/x-pack/plugins/task_manager/server/task_running/ephemeral_task_runner.ts b/x-pack/plugins/task_manager/server/task_running/ephemeral_task_runner.ts index e010a7a0126b8..baf4e253c67a9 100644 --- a/x-pack/plugins/task_manager/server/task_running/ephemeral_task_runner.ts +++ b/x-pack/plugins/task_manager/server/task_running/ephemeral_task_runner.ts @@ -12,7 +12,7 @@ */ import apm from 'elastic-apm-node'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { withSpan } from '@kbn/apm-utils'; import { identity } from 'lodash'; import { Logger, ExecutionContextStart } from '@kbn/core/server'; @@ -107,7 +107,7 @@ export class EphemeralTaskManagerRunner implements TaskRunner { this.beforeMarkRunning = beforeMarkRunning; this.onTaskEvent = onTaskEvent; this.executionContext = executionContext; - this.uuid = uuid.v4(); + this.uuid = uuidv4(); } /** diff --git a/x-pack/plugins/task_manager/server/task_running/task_runner.ts b/x-pack/plugins/task_manager/server/task_running/task_runner.ts index d2038621d6dbe..62bc9d4f19734 100644 --- a/x-pack/plugins/task_manager/server/task_running/task_runner.ts +++ b/x-pack/plugins/task_manager/server/task_running/task_runner.ts @@ -12,7 +12,7 @@ */ import apm from 'elastic-apm-node'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { withSpan } from '@kbn/apm-utils'; import { identity, defaults, flow, omit } from 'lodash'; import { Logger, SavedObjectsErrorHelpers, ExecutionContextStart } from '@kbn/core/server'; @@ -183,7 +183,7 @@ export class TaskManagerRunner implements TaskRunner { this.defaultMaxAttempts = defaultMaxAttempts; this.executionContext = executionContext; this.usageCounter = usageCounter; - this.uuid = uuid.v4(); + this.uuid = uuidv4(); this.eventLoopDelayConfig = eventLoopDelayConfig; } diff --git a/x-pack/plugins/task_manager/server/task_scheduling.ts b/x-pack/plugins/task_manager/server/task_scheduling.ts index ac4294c12baaf..3178b85eb390b 100644 --- a/x-pack/plugins/task_manager/server/task_scheduling.ts +++ b/x-pack/plugins/task_manager/server/task_scheduling.ts @@ -8,7 +8,7 @@ import { filter, take } from 'rxjs/operators'; import pMap from 'p-map'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { chunk, pick } from 'lodash'; import { Subject } from 'rxjs'; import agent from 'elastic-apm-node'; @@ -43,7 +43,6 @@ import { EphemeralTaskRejectedDueToCapacityError } from './task_running'; const VERSION_CONFLICT_STATUS = 409; const BULK_ACTION_SIZE = 100; -const BULK_UPDATE_NUM_RETRIES = 3; export interface TaskSchedulingOpts { logger: Logger; taskStore: TaskStore; @@ -265,10 +264,7 @@ export class TaskScheduling { } private async bulkUpdateTasksHelper(updatedTasks: ConcreteTaskInstance[]) { - // Performs bulk update with retries - return ( - await this.store.bulkUpdate(updatedTasks, BULK_UPDATE_NUM_RETRIES) - ).reduce( + return (await this.store.bulkUpdate(updatedTasks)).reduce( (acc, task) => { if (task.tag === 'ok') { acc.tasks.push(task.value); @@ -326,7 +322,7 @@ export class TaskScheduling { task ); } - const id = uuid.v4(); + const id = uuidv4(); const { taskInstance: modifiedTask } = await this.middleware.beforeSave({ ...options, taskInstance: task, diff --git a/x-pack/plugins/task_manager/server/task_store.test.ts b/x-pack/plugins/task_manager/server/task_store.test.ts index 5d1484101cd0c..dfc21a7142ece 100644 --- a/x-pack/plugins/task_manager/server/task_store.test.ts +++ b/x-pack/plugins/task_manager/server/task_store.test.ts @@ -15,11 +15,7 @@ import { TaskLifecycleResult, SerializedConcreteTaskInstance, } from './task'; -import { - elasticsearchServiceMock, - savedObjectsServiceMock, - loggingSystemMock, -} from '@kbn/core/server/mocks'; +import { elasticsearchServiceMock, savedObjectsServiceMock } from '@kbn/core/server/mocks'; import { TaskStore, SearchOpts, AggregationOpts } from './task_store'; import { savedObjectsRepositoryMock } from '@kbn/core/server/mocks'; import { SavedObjectAttributes, SavedObjectsErrorHelpers } from '@kbn/core/server'; @@ -29,7 +25,6 @@ import { AdHocTaskCounter } from './lib/adhoc_task_counter'; const savedObjectsClient = savedObjectsRepositoryMock.create(); const serializer = savedObjectsServiceMock.createSerializer(); -const logger = loggingSystemMock.create().get(); const adHocTaskCounter = new AdHocTaskCounter(); const randomId = () => `id-${_.random(1, 20)}`; @@ -72,7 +67,6 @@ describe('TaskStore', () => { store = new TaskStore({ index: 'tasky', taskManagerId: '', - logger, serializer, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, @@ -239,7 +233,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -309,7 +302,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -408,7 +400,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -512,7 +503,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -520,98 +510,6 @@ describe('TaskStore', () => { }); }); - test('correctly returns errors from saved object bulk update', async () => { - const task = { - runAt: mockedDate, - scheduledAt: mockedDate, - startedAt: null, - retryAt: null, - id: 'task:324242', - params: { hello: 'world' }, - state: { foo: 'bar' }, - taskType: 'report', - attempts: 3, - status: 'idle' as TaskStatus, - version: '123', - ownerId: null, - traceparent: '', - }; - - savedObjectsClient.bulkUpdate.mockResolvedValueOnce({ - saved_objects: [ - { - id: task.id, - type: task.taskType, - attributes: { - runAt: mockedDate.toISOString(), - scheduledAt: mockedDate.toISOString(), - startedAt: null, - retryAt: null, - params: `{ "hello": "world" }`, - state: `{ "foo": "bar" }`, - taskType: 'report', - attempts: 3, - status: 'idle' as TaskStatus, - ownerId: null, - traceparent: '', - }, - error: { - error: `Not a conflict`, - message: `Some error that's not a conflict`, - statusCode: 404, - }, - references: [], - }, - ], - }); - const result = await store.bulkUpdate([task]); - expect(result).toEqual([ - { - error: { - entity: { - attempts: 3, - id: 'task:324242', - ownerId: null, - params: { hello: 'world' }, - retryAt: null, - runAt: mockedDate, - scheduledAt: mockedDate, - startedAt: null, - state: { foo: 'bar' }, - status: 'idle', - taskType: 'report', - traceparent: '', - version: '123', - }, - error: { - attributes: { - attempts: 3, - ownerId: null, - params: '{ "hello": "world" }', - retryAt: null, - runAt: mockedDate.toISOString(), - scheduledAt: mockedDate.toISOString(), - startedAt: null, - state: '{ "foo": "bar" }', - status: 'idle', - taskType: 'report', - traceparent: '', - }, - error: { - error: 'Not a conflict', - message: "Some error that's not a conflict", - statusCode: 404, - }, - id: 'task:324242', - references: [], - type: 'report', - }, - }, - tag: 'err', - }, - ]); - }); - test('pushes error from saved objects client to errors$', async () => { const task = { runAt: mockedDate, @@ -646,7 +544,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -681,7 +578,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -716,7 +612,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -802,7 +697,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -823,7 +717,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -842,7 +735,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, @@ -861,7 +753,6 @@ describe('TaskStore', () => { index: 'tasky', taskManagerId: '', serializer, - logger, esClient: elasticsearchServiceMock.createClusterClient().asInternalUser, definitions: taskDefinitions, savedObjectsRepository: savedObjectsClient, diff --git a/x-pack/plugins/task_manager/server/task_store.ts b/x-pack/plugins/task_manager/server/task_store.ts index aca1d2af956dc..e810ea5c1ef3e 100644 --- a/x-pack/plugins/task_manager/server/task_store.ts +++ b/x-pack/plugins/task_manager/server/task_store.ts @@ -15,7 +15,6 @@ import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; import type { SavedObjectsBulkDeleteResponse } from '@kbn/core/server'; import { - Logger, SavedObject, ISavedObjectsSerializer, SavedObjectsRawDoc, @@ -36,10 +35,8 @@ import { import { TaskTypeDictionary } from './task_type_dictionary'; import { AdHocTaskCounter } from './lib/adhoc_task_counter'; -import { retryOnBulkUpdateConflict } from './lib/retry_on_bulk_update_conflict'; export interface StoreOpts { - logger: Logger; esClient: ElasticsearchClient; index: string; taskManagerId: string; @@ -97,7 +94,6 @@ export class TaskStore { public readonly errors$ = new Subject(); private esClient: ElasticsearchClient; - private logger: Logger; private definitions: TaskTypeDictionary; private savedObjectsRepository: ISavedObjectsRepository; private serializer: ISavedObjectsSerializer; @@ -115,7 +111,6 @@ export class TaskStore { constructor(opts: StoreOpts) { this.esClient = opts.esClient; this.index = opts.index; - this.logger = opts.logger; this.taskManagerId = opts.taskManagerId; this.definitions = opts.definitions; this.serializer = opts.serializer; @@ -251,45 +246,34 @@ export class TaskStore { * @param {Array} docs * @returns {Promise>} */ - public async bulkUpdate( - docs: ConcreteTaskInstance[], - retries: number = 0 - ): Promise { + public async bulkUpdate(docs: ConcreteTaskInstance[]): Promise { const attributesByDocId = docs.reduce((attrsById, doc) => { attrsById.set(doc.id, taskInstanceToAttributes(doc)); return attrsById; }, new Map()); - let updatedSavedObjects: Array>; + let updatedSavedObjects: Array; try { - ({ savedObjects: updatedSavedObjects } = - await retryOnBulkUpdateConflict({ - logger: this.logger, - savedObjectsRepository: this.savedObjectsRepository, - objects: docs.map((doc) => ({ + ({ saved_objects: updatedSavedObjects } = + await this.savedObjectsRepository.bulkUpdate( + docs.map((doc) => ({ type: 'task', id: doc.id, options: { version: doc.version }, attributes: attributesByDocId.get(doc.id)!, })), - options: { + { refresh: false, - }, - retries, - })); + } + )); } catch (e) { this.errors$.next(e); throw e; } - return updatedSavedObjects.map((updatedSavedObject) => { - const doc = docs.find((d) => d.id === updatedSavedObject.id); - return updatedSavedObject.error !== undefined - ? asErr({ - entity: doc, - error: updatedSavedObject, - }) - : asOk( + return updatedSavedObjects.map((updatedSavedObject, index) => + isSavedObjectsUpdateResponse(updatedSavedObject) + ? asOk( savedObjectToConcreteTaskInstance({ ...updatedSavedObject, attributes: defaults( @@ -297,8 +281,15 @@ export class TaskStore { attributesByDocId.get(updatedSavedObject.id)! ), }) - ); - }) as BulkUpdateResult[]; + ) + : asErr({ + // The SavedObjectsRepository maintains the order of the docs + // so we can rely on the index in the `docs` to match an error + // on the same index in the `bulkUpdate` result + entity: docs[index], + error: updatedSavedObject, + }) + ); } /** @@ -544,3 +535,9 @@ function ensureAggregationOnlyReturnsTaskObjects(opts: AggregationOpts): Aggrega query, }; } + +function isSavedObjectsUpdateResponse( + result: SavedObjectsUpdateResponse | Error +): result is SavedObjectsUpdateResponse { + return result && typeof (result as SavedObjectsUpdateResponse).id === 'string'; +} diff --git a/x-pack/plugins/telemetry_collection_xpack/schema/xpack_plugins.json b/x-pack/plugins/telemetry_collection_xpack/schema/xpack_plugins.json index cb3e798e4a6e7..d65ae5a95231d 100644 --- a/x-pack/plugins/telemetry_collection_xpack/schema/xpack_plugins.json +++ b/x-pack/plugins/telemetry_collection_xpack/schema/xpack_plugins.json @@ -9534,6 +9534,12 @@ "description": "The session cleanup interval that is configured, in minutes (0 if disabled)." } }, + "sessionConcurrentSessionsMaxSessions": { + "type": "long", + "_meta": { + "description": "The maximum number of the concurrent user sessions (0 if not configured)." + } + }, "anonymousCredentialType": { "type": "keyword", "_meta": { diff --git a/x-pack/plugins/threat_intelligence/cypress/e2e/block_list.cy.ts b/x-pack/plugins/threat_intelligence/cypress/e2e/block_list.cy.ts new file mode 100644 index 0000000000000..af3758906ea10 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/cypress/e2e/block_list.cy.ts @@ -0,0 +1,92 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + BLOCK_LIST_ADD_BUTTON, + BLOCK_LIST_DESCRIPTION, + BLOCK_LIST_NAME, + BLOCK_LIST_TOAST_LIST, + FLYOUT_ADD_TO_BLOCK_LIST_ITEM, + FLYOUT_TAKE_ACTION_BUTTON, + INDICATORS_TABLE_ADD_TO_BLOCK_LIST_BUTTON_ICON, + INDICATORS_TABLE_MORE_ACTION_BUTTON_ICON, + TOGGLE_FLYOUT_BUTTON, +} from '../screens/indicators'; +import { login } from '../tasks/login'; +import { esArchiverLoad, esArchiverUnload } from '../tasks/es_archiver'; +import { selectRange } from '../tasks/select_range'; + +const THREAT_INTELLIGENCE = '/app/security/threat_intelligence/indicators'; + +const BLOCK_LIST_NEW_NAME = 'new blocklist entry'; + +const fillBlocklistForm = () => { + cy.get(BLOCK_LIST_NAME).type(BLOCK_LIST_NEW_NAME); + cy.get(BLOCK_LIST_DESCRIPTION).type('the best description'); + cy.get(BLOCK_LIST_ADD_BUTTON).last().click(); + + const text: string = `"${BLOCK_LIST_NEW_NAME}" has been added`; + cy.get(BLOCK_LIST_TOAST_LIST).should('exist').and('contain.text', text); +}; + +describe('Block list with invalid indicators', () => { + before(() => { + esArchiverLoad('threat_intelligence/invalid_indicators_data'); + login(); + }); + + beforeEach(() => { + cy.visit(THREAT_INTELLIGENCE); + selectRange(); + }); + + after(() => { + esArchiverUnload('threat_intelligence/invalid_indicators_data'); + }); + + it('should disabled the indicators table context menu item if invalid indicator', () => { + cy.get(INDICATORS_TABLE_MORE_ACTION_BUTTON_ICON).eq(3).click(); + cy.get(INDICATORS_TABLE_ADD_TO_BLOCK_LIST_BUTTON_ICON).should('be.disabled'); + }); + + it('should disable the flyout context menu items if invalid indicator', () => { + cy.get(TOGGLE_FLYOUT_BUTTON).eq(3).click({ force: true }); + cy.get(FLYOUT_TAKE_ACTION_BUTTON).first().click(); + cy.get(FLYOUT_ADD_TO_BLOCK_LIST_ITEM).should('be.disabled'); + }); +}); + +describe('Block list interactions', () => { + before(() => { + esArchiverLoad('threat_intelligence/indicators_data'); + login(); + }); + + beforeEach(() => { + cy.visit(THREAT_INTELLIGENCE); + selectRange(); + }); + + after(() => { + esArchiverUnload('threat_intelligence/indicators_data'); + }); + + it('should add to block list from the indicators table', () => { + cy.get(INDICATORS_TABLE_MORE_ACTION_BUTTON_ICON).first().click(); + cy.get(INDICATORS_TABLE_ADD_TO_BLOCK_LIST_BUTTON_ICON).first().click(); + + fillBlocklistForm(); + }); + + it('should add to block list from the indicator flyout', () => { + cy.get(TOGGLE_FLYOUT_BUTTON).first().click({ force: true }); + cy.get(FLYOUT_TAKE_ACTION_BUTTON).first().click(); + cy.get(FLYOUT_ADD_TO_BLOCK_LIST_ITEM).first().click(); + + fillBlocklistForm(); + }); +}); diff --git a/x-pack/plugins/threat_intelligence/cypress/screens/indicators.ts b/x-pack/plugins/threat_intelligence/cypress/screens/indicators.ts index ac5637f5e722c..764d6348a07a8 100644 --- a/x-pack/plugins/threat_intelligence/cypress/screens/indicators.ts +++ b/x-pack/plugins/threat_intelligence/cypress/screens/indicators.ts @@ -17,6 +17,7 @@ import { } from '../../public/modules/indicators/components/barchart/legend_action/test_ids'; import { DROPDOWN_TEST_ID } from '../../public/modules/indicators/components/barchart/field_selector/test_ids'; import { + ADD_TO_BLOCK_LIST_TEST_ID as INDICATOR_FLYOUT_TAKE_ACTION_ADD_TO_BLOCK_LIST_TEST_ID, ADD_TO_EXISTING_CASE_TEST_ID as INDICATOR_FLYOUT_TAKE_ACTION_ADD_TO_EXISTING_CASE_TEST_ID, ADD_TO_NEW_CASE_TEST_ID as INDICATOR_FLYOUT_TAKE_ACTION_ADD_TO_NEW_CASE_TEST_ID, INVESTIGATE_IN_TIMELINE_TEST_ID as INDICATOR_FLYOUT_TAKE_ACTION_INVESTIGATE_IN_TIMELINE_TEST_ID, @@ -33,6 +34,7 @@ import { INDICATORS_FLYOUT_TITLE_TEST_ID, } from '../../public/modules/indicators/components/flyout/test_ids'; import { + ADD_TO_BLOCK_LIST_TEST_ID as INDICATORS_TABLE_ADD_TO_BLOCK_LIST_TEST_ID, ADD_TO_EXISTING_TEST_ID as INDICATORS_TABLE_ADD_TO_EXISTING_TEST_ID, ADD_TO_NEW_CASE_TEST_ID as INDICATORS_TABLE_ADD_TO_NEW_CASE_TEST_ID, MORE_ACTIONS_TEST_ID as INDICATORS_TABLE_MORE_ACTIONS_TEST_ID, @@ -101,6 +103,8 @@ export const INDICATORS_TABLE_ADD_TO_NEW_CASE_BUTTON_ICON = `[data-test-subj="${ export const INDICATORS_TABLE_ADD_TO_EXISTING_CASE_BUTTON_ICON = `[data-test-subj="${INDICATORS_TABLE_ADD_TO_EXISTING_TEST_ID}"]`; +export const INDICATORS_TABLE_ADD_TO_BLOCK_LIST_BUTTON_ICON = `[data-test-subj="${INDICATORS_TABLE_ADD_TO_BLOCK_LIST_TEST_ID}"]`; + /* Flyout */ export const TOGGLE_FLYOUT_BUTTON = `[data-test-subj="${BUTTON_TEST_ID}"]`; @@ -147,6 +151,8 @@ export const FLYOUT_ADD_TO_NEW_CASE_ITEM = `[data-test-subj="${INDICATOR_FLYOUT_ export const FLYOUT_INVESTIGATE_IN_TIMELINE_ITEM = `[data-test-subj="${INDICATOR_FLYOUT_TAKE_ACTION_INVESTIGATE_IN_TIMELINE_TEST_ID}"]`; +export const FLYOUT_ADD_TO_BLOCK_LIST_ITEM = `[data-test-subj="${INDICATOR_FLYOUT_TAKE_ACTION_ADD_TO_BLOCK_LIST_TEST_ID}"]`; + /* Field selector */ export const FIELD_SELECTOR = `[data-test-subj="${DROPDOWN_TEST_ID}"]`; @@ -197,6 +203,16 @@ export const NEW_CASE_DESCRIPTION_INPUT = `[data-test-subj="euiMarkdownEditorTex export const NEW_CASE_CREATE_BUTTON = `[data-test-subj="create-case-submit"]`; +/* Block list */ + +export const BLOCK_LIST_NAME = '[data-test-subj="blocklist-form-name-input"]'; + +export const BLOCK_LIST_DESCRIPTION = '[data-test-subj="blocklist-form-description-input"]'; + +export const BLOCK_LIST_ADD_BUTTON = '[class="eui-textTruncate"]'; + +export const BLOCK_LIST_TOAST_LIST = '[data-test-subj="globalToastList"]'; + /* Miscellaneous */ export const UNTITLED_TIMELINE_BUTTON = `[data-test-subj="flyoutOverlay"]`; diff --git a/x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx b/x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx index 77398772a3bb2..80cf2259ee93d 100644 --- a/x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx +++ b/x-pack/plugins/threat_intelligence/public/common/mocks/mock_security_context.tsx @@ -5,7 +5,8 @@ * 2.0. */ -import React from 'react'; +import React, { NamedExoticComponent } from 'react'; +import { BlockListFlyoutProps, BlockListFormProps } from '../../types'; import { SecuritySolutionPluginContext } from '../..'; export const getSecuritySolutionContextMock = (): SecuritySolutionPluginContext => ({ @@ -18,7 +19,10 @@ export const getSecuritySolutionContextMock = (): SecuritySolutionPluginContext ({ children }) =>
    {children}
    , licenseService: { - isEnterprise() { + isEnterprise(): boolean { + return true; + }, + isPlatinumPlus(): boolean { return true; }, }, @@ -48,4 +52,11 @@ export const getSecuritySolutionContextMock = (): SecuritySolutionPluginContext registerQuery: () => {}, deregisterQuery: () => {}, + + blockList: { + exceptionListApiClient: {}, + useSetUrlParams: () => (params, replace) => {}, + getFlyoutComponent: () => (
    ) as unknown as NamedExoticComponent, + getFormComponent: () => (
    ) as unknown as NamedExoticComponent, + }, }); diff --git a/x-pack/plugins/threat_intelligence/public/common/mocks/story_providers.tsx b/x-pack/plugins/threat_intelligence/public/common/mocks/story_providers.tsx index fbbc134a42c13..07f62805fe530 100644 --- a/x-pack/plugins/threat_intelligence/public/common/mocks/story_providers.tsx +++ b/x-pack/plugins/threat_intelligence/public/common/mocks/story_providers.tsx @@ -23,6 +23,7 @@ import { mockUiSettingsService } from './mock_kibana_ui_settings_service'; import { mockKibanaTimelinesService } from './mock_kibana_timelines_service'; import { mockTriggersActionsUiService } from './mock_kibana_triggers_actions_ui_service'; import { InspectorContext } from '../../containers/inspector'; +import { BlockListProvider } from '../../modules/indicators/containers/block_list_provider'; export interface KibanaContextMock { /** @@ -101,7 +102,9 @@ export const StoryProvidersComponent: VFC = ({ - {children} + + {children} + diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/__snapshots__/add_to_block_list.test.tsx.snap b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/__snapshots__/add_to_block_list.test.tsx.snap new file mode 100644 index 0000000000000..c8738e007c824 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/__snapshots__/add_to_block_list.test.tsx.snap @@ -0,0 +1,193 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[` should render a disabled EuiContextMenuItem 1`] = ` +Object { + "asFragment": [Function], + "baseElement": +
    + +
    + , + "container":
    + +
    , + "debug": [Function], + "findAllByAltText": [Function], + "findAllByDisplayValue": [Function], + "findAllByLabelText": [Function], + "findAllByPlaceholderText": [Function], + "findAllByRole": [Function], + "findAllByTestId": [Function], + "findAllByText": [Function], + "findAllByTitle": [Function], + "findByAltText": [Function], + "findByDisplayValue": [Function], + "findByLabelText": [Function], + "findByPlaceholderText": [Function], + "findByRole": [Function], + "findByTestId": [Function], + "findByText": [Function], + "findByTitle": [Function], + "getAllByAltText": [Function], + "getAllByDisplayValue": [Function], + "getAllByLabelText": [Function], + "getAllByPlaceholderText": [Function], + "getAllByRole": [Function], + "getAllByTestId": [Function], + "getAllByText": [Function], + "getAllByTitle": [Function], + "getByAltText": [Function], + "getByDisplayValue": [Function], + "getByLabelText": [Function], + "getByPlaceholderText": [Function], + "getByRole": [Function], + "getByTestId": [Function], + "getByText": [Function], + "getByTitle": [Function], + "queryAllByAltText": [Function], + "queryAllByDisplayValue": [Function], + "queryAllByLabelText": [Function], + "queryAllByPlaceholderText": [Function], + "queryAllByRole": [Function], + "queryAllByTestId": [Function], + "queryAllByText": [Function], + "queryAllByTitle": [Function], + "queryByAltText": [Function], + "queryByDisplayValue": [Function], + "queryByLabelText": [Function], + "queryByPlaceholderText": [Function], + "queryByRole": [Function], + "queryByTestId": [Function], + "queryByText": [Function], + "queryByTitle": [Function], + "rerender": [Function], + "unmount": [Function], +} +`; + +exports[` should render an EuiContextMenuItem 1`] = ` +Object { + "asFragment": [Function], + "baseElement": +
    + +
    + , + "container":
    + +
    , + "debug": [Function], + "findAllByAltText": [Function], + "findAllByDisplayValue": [Function], + "findAllByLabelText": [Function], + "findAllByPlaceholderText": [Function], + "findAllByRole": [Function], + "findAllByTestId": [Function], + "findAllByText": [Function], + "findAllByTitle": [Function], + "findByAltText": [Function], + "findByDisplayValue": [Function], + "findByLabelText": [Function], + "findByPlaceholderText": [Function], + "findByRole": [Function], + "findByTestId": [Function], + "findByText": [Function], + "findByTitle": [Function], + "getAllByAltText": [Function], + "getAllByDisplayValue": [Function], + "getAllByLabelText": [Function], + "getAllByPlaceholderText": [Function], + "getAllByRole": [Function], + "getAllByTestId": [Function], + "getAllByText": [Function], + "getAllByTitle": [Function], + "getByAltText": [Function], + "getByDisplayValue": [Function], + "getByLabelText": [Function], + "getByPlaceholderText": [Function], + "getByRole": [Function], + "getByTestId": [Function], + "getByText": [Function], + "getByTitle": [Function], + "queryAllByAltText": [Function], + "queryAllByDisplayValue": [Function], + "queryAllByLabelText": [Function], + "queryAllByPlaceholderText": [Function], + "queryAllByRole": [Function], + "queryAllByTestId": [Function], + "queryAllByText": [Function], + "queryAllByTitle": [Function], + "queryByAltText": [Function], + "queryByDisplayValue": [Function], + "queryByLabelText": [Function], + "queryByPlaceholderText": [Function], + "queryByRole": [Function], + "queryByTestId": [Function], + "queryByText": [Function], + "queryByTitle": [Function], + "rerender": [Function], + "unmount": [Function], +} +`; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.stories.tsx b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.stories.tsx new file mode 100644 index 0000000000000..437ad64d9fb99 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.stories.tsx @@ -0,0 +1,37 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { Story } from '@storybook/react'; +import { EuiContextMenuPanel } from '@elastic/eui'; +import { SecuritySolutionContext } from '../../../../containers/security_solution_context'; +import { SecuritySolutionPluginContext } from '../../../..'; +import { getSecuritySolutionContextMock } from '../../../../common/mocks/mock_security_context'; +import { AddToBlockListContextMenu } from '.'; +import { BlockListProvider } from '../../../indicators/containers/block_list_provider'; + +export default { + title: 'AddToBlocklist', +}; + +export const ContextMenu: Story = () => { + const mockSecurityContext: SecuritySolutionPluginContext = getSecuritySolutionContextMock(); + + const mockIndicatorFileHashValue: string = 'abc'; + const mockOnClick: () => void = () => window.alert('clicked!'); + const items = [ + , + ]; + + return ( + + + + + + ); +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.test.tsx b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.test.tsx new file mode 100644 index 0000000000000..1c0c3eb448000 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.test.tsx @@ -0,0 +1,50 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { render } from '@testing-library/react'; +import { AddToBlockListContextMenu } from '.'; +import { BlockListProvider } from '../../../indicators/containers/block_list_provider'; +import { SecuritySolutionContext } from '../../../../containers/security_solution_context'; +import { SecuritySolutionPluginContext } from '../../../..'; +import { getSecuritySolutionContextMock } from '../../../../common/mocks/mock_security_context'; + +describe('', () => { + it('should render an EuiContextMenuItem', () => { + const mockSecurityContext: SecuritySolutionPluginContext = getSecuritySolutionContextMock(); + + const mockIndicatorFileHashValue: string = 'abc'; + const mockOnClick: () => void = () => window.alert('clicked!'); + + const component = render( + + + + + + ); + + expect(component).toMatchSnapshot(); + }); + + it('should render a disabled EuiContextMenuItem', () => { + const mockSecurityContext: SecuritySolutionPluginContext = getSecuritySolutionContextMock(); + + const mockIndicatorFileHashValue = null; + const mockOnClick: () => void = () => window.alert('clicked!'); + + const component = render( + + + + + + ); + + expect(component).toMatchSnapshot(); + }); +}); diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.tsx b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.tsx new file mode 100644 index 0000000000000..ca74f9e5652ef --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/add_to_block_list.tsx @@ -0,0 +1,62 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { VFC } from 'react'; +import { EuiContextMenuItem } from '@elastic/eui'; +import { FormattedMessage } from '@kbn/i18n-react'; +import { useBlockListContext } from '../../../indicators/hooks/use_block_list_context'; +import { useSetUrlParams } from '../../hooks/use_set_url_params'; + +export interface AddToBlockListProps { + /** + * Indicator's filehash value (either sha256, sha1 or md5) + */ + data: string | null; + /** + * Used for unit and e2e tests + */ + ['data-test-subj']?: string; + /** + * Click event to notify the parent component (to for example close the popover) + */ + onClick: () => void; +} + +/** + * Add to blocklist functionality displayed as a ContextMenuItem (in the main indicators table row and in the indicator flyout). + * The entry is disabled is the filehash isn't sha256, sha1 or md5. + * When clicking on the ContextMenuItem, the indicator filehash value is saved in context. + * The flyout is shown by adding a parameter to the url. + */ +export const AddToBlockListContextMenu: VFC = ({ + data, + 'data-test-subj': dataTestSub, + onClick, +}) => { + const { setBlockListIndicatorValue } = useBlockListContext(); + const { setUrlParams } = useSetUrlParams(); + + const menuItemClicked = () => { + onClick(); + setBlockListIndicatorValue(data as string); + setUrlParams({ show: 'create' }); + }; + + return ( + menuItemClicked()} + data-test-subj={dataTestSub} + disabled={data == null} + > + + + ); +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/index.ts b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/index.ts new file mode 100644 index 0000000000000..b81a5690125d6 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/components/add_to_block_list/index.ts @@ -0,0 +1,8 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +export * from './add_to_block_list'; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/containers/flyout.tsx b/x-pack/plugins/threat_intelligence/public/modules/block_list/containers/flyout.tsx new file mode 100644 index 0000000000000..b75af1add4f41 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/containers/flyout.tsx @@ -0,0 +1,65 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { VFC } from 'react'; +import { + CreateExceptionListItemSchema, + EntriesArray, +} from '@kbn/securitysolution-io-ts-list-types'; +import { useSecurityContext } from '../../../hooks/use_security_context'; + +export interface BlockListFlyoutProps { + /** + * Indicator file-hash value (sha256, sh1 or md5) to pass to the block list flyout. + */ + indicatorFileHash: string; +} + +/** + * Component calling the block list flyout (retrieved from the SecuritySolution plugin via context). + * This reuses a lot of components passed down via context from the Security Solution plugin: + * - the flyout component: https://github.com/elastic/kibana/blob/main/x-pack/plugins/security_solution/public/management/components/artifact_list_page/components/artifact_flyout.tsx + * - the form component: https://github.com/elastic/kibana/blob/main/x-pack/plugins/security_solution/public/management/pages/blocklist/view/components/blocklist_form.tsx + */ +export const BlockListFlyout: VFC = ({ indicatorFileHash }) => { + const { blockList } = useSecurityContext(); + const Component = blockList.getFlyoutComponent(); + const exceptionListApiClient = blockList.exceptionListApiClient; + const FormComponent = blockList.getFormComponent(); + + // prepopulate the for with the indicator file hash + const entries: EntriesArray = [ + { + field: 'file.hash.*', + operator: 'included', + type: 'match_any', + value: [indicatorFileHash], + }, + ]; + + // prepare the payload to pass to the form (and then sent to the blocklist endpoint) + const item: CreateExceptionListItemSchema = { + description: '', + entries, + list_id: 'endpoint_blocklists', + name: '', + namespace_type: 'agnostic', + os_types: ['windows'], + tags: ['policy:all'], + type: 'simple', + }; + + const props = { + apiClient: exceptionListApiClient, + item, + policies: [], + FormComponent, + onClose: () => {}, + }; + + return ; +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/index.ts b/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/index.ts new file mode 100644 index 0000000000000..491a1968d7974 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/index.ts @@ -0,0 +1,8 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +export * from './use_set_url_params'; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/use_set_url_params.ts b/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/use_set_url_params.ts new file mode 100644 index 0000000000000..20f8312267c2b --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/hooks/use_set_url_params.ts @@ -0,0 +1,17 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useSecurityContext } from '../../../hooks'; + +/** + * Retrieve the useSetUrlParams hook from SecurityContext. + * The hook is passed down from the Security Solution plugin. + */ +export const useSetUrlParams = () => { + const { blockList } = useSecurityContext(); + return { setUrlParams: blockList.useSetUrlParams() }; +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.test.ts b/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.test.ts new file mode 100644 index 0000000000000..35b8d479b681d --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.test.ts @@ -0,0 +1,50 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { + generateMockFileIndicator, + Indicator, + RawIndicatorFieldId, +} from '../../../../common/types/indicator'; +import { canAddToBlockList } from './can_add_to_block_list'; +import { getIndicatorFieldAndValue } from '../../indicators'; + +describe('canAddToBlockList', () => { + it('should return null if indicator has none of required fields', () => { + const indicator = {} as unknown as Indicator; + const result = canAddToBlockList(indicator); + + expect(result).toEqual(null); + }); + + it('should return sha256 value if indicator has the field', () => { + const indicator = generateMockFileIndicator(); + const sha256 = getIndicatorFieldAndValue(indicator, RawIndicatorFieldId.FileSha256).value; + const result = canAddToBlockList(indicator); + + expect(result).toEqual(sha256); + }); + + it('should return sha1 value if sha256 is missing ', () => { + const indicator = generateMockFileIndicator(); + indicator.fields['threat.indicator.file.hash.sha256'] = undefined; + const sha1 = getIndicatorFieldAndValue(indicator, RawIndicatorFieldId.FileSha1).value; + const result = canAddToBlockList(indicator); + + expect(result).toEqual(sha1); + }); + + it('should return md5 value if sha256 and sha1 are missing', () => { + const indicator = generateMockFileIndicator(); + indicator.fields['threat.indicator.file.hash.sha256'] = undefined; + indicator.fields['threat.indicator.file.hash.sha1'] = undefined; + const md5 = getIndicatorFieldAndValue(indicator, RawIndicatorFieldId.FileMd5).value; + const result = canAddToBlockList(indicator); + + expect(result).toEqual(md5); + }); +}); diff --git a/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.ts b/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.ts new file mode 100644 index 0000000000000..037a4f4587e0f --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/block_list/utils/can_add_to_block_list.ts @@ -0,0 +1,43 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { Indicator, RawIndicatorFieldId } from '../../../../common/types/indicator'; +import { getIndicatorFieldAndValue } from '../../indicators'; + +/** + * Checks if an indicator has sha256, sha1 or md5 (in that order) and returns an empty string if it does not. + * The value is returned to be used in the add to block list logic. + * + * @param indicator the indicator we want to + */ +export const canAddToBlockList = (indicator: Indicator): string | null => { + const sha256: string | null = getIndicatorFieldAndValue( + indicator, + RawIndicatorFieldId.FileSha256 + ).value; + if (sha256 != null) { + return sha256; + } + + const sha1: string | null = getIndicatorFieldAndValue( + indicator, + RawIndicatorFieldId.FileSha1 + ).value; + if (sha1 != null) { + return sha1; + } + + const md5: string | null = getIndicatorFieldAndValue( + indicator, + RawIndicatorFieldId.FileMd5 + ).value; + if (md5 != null) { + return md5; + } + + return null; +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/take_action.tsx b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/take_action.tsx index 8a67d596c1333..93c5890b23396 100644 --- a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/take_action.tsx +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/take_action.tsx @@ -8,11 +8,14 @@ import React, { useState, VFC } from 'react'; import { EuiButton, EuiContextMenuPanel, EuiPopover, useGeneratedHtmlId } from '@elastic/eui'; import { FormattedMessage } from '@kbn/i18n-react'; +import { canAddToBlockList } from '../../../../block_list/utils/can_add_to_block_list'; +import { AddToBlockListContextMenu } from '../../../../block_list/components/add_to_block_list'; import { AddToNewCase } from '../../../../cases/components/add_to_new_case/add_to_new_case'; import { AddToExistingCase } from '../../../../cases/components/add_to_existing_case/add_to_existing_case'; import { Indicator } from '../../../../../../common/types/indicator'; import { InvestigateInTimelineContextMenu } from '../../../../timeline'; import { + ADD_TO_BLOCK_LIST_TEST_ID, ADD_TO_EXISTING_CASE_TEST_ID, ADD_TO_NEW_CASE_TEST_ID, INVESTIGATE_IN_TIMELINE_TEST_ID, @@ -39,6 +42,7 @@ export const TakeAction: VFC = ({ indicator }) => { setPopover(false); }; + const indicatorValue: string | null = canAddToBlockList(indicator); const items = [ = ({ indicator }) => { onClick={closePopover} data-test-subj={ADD_TO_NEW_CASE_TEST_ID} />, + , ]; const button = ( diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/test_ids.ts b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/test_ids.ts index 051a9637a9f6c..f661ae2357171 100644 --- a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/test_ids.ts +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/flyout/take_action/test_ids.ts @@ -9,3 +9,4 @@ export const TAKE_ACTION_BUTTON_TEST_ID = 'tiIndicatorFlyoutTakeActionButton'; export const INVESTIGATE_IN_TIMELINE_TEST_ID = 'tiIndicatorFlyoutInvestigateInTimelineContextMenu'; export const ADD_TO_EXISTING_CASE_TEST_ID = 'tiIndicatorFlyoutAddToExistingCaseContextMenu'; export const ADD_TO_NEW_CASE_TEST_ID = 'tiIndicatorFlyoutAddToNewCaseContextMenu'; +export const ADD_TO_BLOCK_LIST_TEST_ID = 'tiIndicatorFlyoutAddToBlockListContextMenu'; diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/more_actions.tsx b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/more_actions.tsx index 705b9c5090f6c..a5f6955f00004 100644 --- a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/more_actions.tsx +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/more_actions.tsx @@ -14,10 +14,17 @@ import { useGeneratedHtmlId, } from '@elastic/eui'; import { i18n } from '@kbn/i18n'; +import { AddToBlockListContextMenu } from '../../../../../block_list/components/add_to_block_list'; import { AddToNewCase } from '../../../../../cases/components/add_to_new_case/add_to_new_case'; import { AddToExistingCase } from '../../../../../cases/components/add_to_existing_case/add_to_existing_case'; import { Indicator } from '../../../../../../../common/types/indicator'; -import { ADD_TO_EXISTING_TEST_ID, ADD_TO_NEW_CASE_TEST_ID, MORE_ACTIONS_TEST_ID } from './test_ids'; +import { canAddToBlockList } from '../../../../../block_list/utils/can_add_to_block_list'; +import { + ADD_TO_BLOCK_LIST_TEST_ID, + ADD_TO_EXISTING_TEST_ID, + ADD_TO_NEW_CASE_TEST_ID, + MORE_ACTIONS_TEST_ID, +} from './test_ids'; const BUTTON_LABEL = i18n.translate('xpack.threatIntelligence.indicator.table.moreActions', { defaultMessage: 'More actions', @@ -55,6 +62,11 @@ export const MoreActions: VFC = ({ indicator }) => { onClick={closePopover} data-test-subj={ADD_TO_NEW_CASE_TEST_ID} />, + , ]; const button = ( diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/test_ids.ts b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/test_ids.ts index 7e5666283b218..37edc59e11e8b 100644 --- a/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/test_ids.ts +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/components/table/components/more_actions/test_ids.ts @@ -8,3 +8,4 @@ export const MORE_ACTIONS_TEST_ID = 'tiIndicatorTableMoreActionsButton'; export const ADD_TO_EXISTING_TEST_ID = 'tiIndicatorTableAddToExistingCaseContextMenu'; export const ADD_TO_NEW_CASE_TEST_ID = 'tiIndicatorTableAddToNewCaseContextMenu'; +export const ADD_TO_BLOCK_LIST_TEST_ID = 'tiIndicatorsTableAddToBlockListContextMenu'; diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/containers/block_list_provider.tsx b/x-pack/plugins/threat_intelligence/public/modules/indicators/containers/block_list_provider.tsx new file mode 100644 index 0000000000000..3bdd3be858af7 --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/containers/block_list_provider.tsx @@ -0,0 +1,25 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { createContext, Dispatch, FC, SetStateAction, useState } from 'react'; + +export interface BlockListContextValue { + blockListIndicatorValue: string; + setBlockListIndicatorValue: Dispatch>; +} + +export const BlockListContext = createContext(undefined); + +export const BlockListProvider: FC = ({ children }) => { + const [blockListIndicatorValue, setBlockListIndicatorValue] = useState(''); + + const context: BlockListContextValue = { + blockListIndicatorValue, + setBlockListIndicatorValue, + }; + return {children}; +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/hooks/use_block_list_context.ts b/x-pack/plugins/threat_intelligence/public/modules/indicators/hooks/use_block_list_context.ts new file mode 100644 index 0000000000000..7aad9bd41745a --- /dev/null +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/hooks/use_block_list_context.ts @@ -0,0 +1,22 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useContext } from 'react'; +import { BlockListContext, BlockListContextValue } from '../containers/block_list_provider'; + +/** + * Hook to retrieve {@link BlockListContext} + */ +export const useBlockListContext = (): BlockListContextValue => { + const contextValue = useContext(BlockListContext); + + if (!contextValue) { + throw new Error('BlockListContext can only be used within BlockListContext provider'); + } + + return contextValue; +}; diff --git a/x-pack/plugins/threat_intelligence/public/modules/indicators/pages/indicators.tsx b/x-pack/plugins/threat_intelligence/public/modules/indicators/pages/indicators.tsx index aaac18f3fb215..005538fe383e9 100644 --- a/x-pack/plugins/threat_intelligence/public/modules/indicators/pages/indicators.tsx +++ b/x-pack/plugins/threat_intelligence/public/modules/indicators/pages/indicators.tsx @@ -6,6 +6,9 @@ */ import React, { FC, VFC } from 'react'; +import { useBlockListContext } from '../hooks/use_block_list_context'; +import { BlockListProvider } from '../containers/block_list_provider'; +import { BlockListFlyout } from '../../block_list/containers/flyout'; import { IndicatorsBarChartWrapper } from '../components/barchart'; import { IndicatorsTable } from '../components/table'; import { useAggregatedIndicators, useIndicators, useSourcererDataView } from '../hooks'; @@ -22,12 +25,16 @@ import { QueryBar } from '../../query_bar/query_bar'; const IndicatorsPageProviders: FC = ({ children }) => ( - {children} + + {children} + ); const IndicatorsPageContent: VFC = () => { + const { blockListIndicatorValue } = useBlockListContext(); + const { browserFields, indexPattern } = useSourcererDataView(); const columnSettings = useColumnSettings(); @@ -101,6 +108,8 @@ const IndicatorsPageContent: VFC = () => { onChangeItemsPerPage={onChangeItemsPerPage} onChangePage={onChangePage} /> + + {blockListIndicatorValue && } ); diff --git a/x-pack/plugins/threat_intelligence/public/types.ts b/x-pack/plugins/threat_intelligence/public/types.ts index 9b11c705a20d0..73051c0f0e285 100644 --- a/x-pack/plugins/threat_intelligence/public/types.ts +++ b/x-pack/plugins/threat_intelligence/public/types.ts @@ -5,7 +5,7 @@ * 2.0. */ -import { ComponentType, ReactElement, ReactNode, VFC } from 'react'; +import { ComponentType, NamedExoticComponent, ReactElement, ReactNode, VFC } from 'react'; import { CoreStart } from '@kbn/core/public'; import { DataPublicPluginStart } from '@kbn/data-plugin/public'; import { @@ -22,6 +22,7 @@ import { Store } from 'redux'; import { DataProvider } from '@kbn/timelines-plugin/common'; import { Start as InspectorPluginStart } from '@kbn/inspector-plugin/public'; import { CasesUiSetup, CasesUiStart } from '@kbn/cases-plugin/public/types'; +import { CreateExceptionListItemSchema } from '@kbn/securitysolution-io-ts-list-types'; export interface SecuritySolutionDataViewBase extends DataViewBase { fields: Array; @@ -57,6 +58,7 @@ export type Services = { export interface LicenseAware { isEnterprise(): boolean; + isPlatinumPlus(): boolean; } export type BrowserFields = Readonly>>; @@ -74,6 +76,18 @@ export interface UseInvestigateInTimelineProps { to: string; } +export interface BlockListFlyoutProps { + apiClient: unknown; + item: CreateExceptionListItemSchema; + policies: unknown[]; + FormComponent: NamedExoticComponent; + onClose: () => void; +} + +export interface BlockListFormProps { + item: CreateExceptionListItemSchema; +} + /** * Methods exposed from the security solution to the threat intelligence application. */ @@ -124,4 +138,14 @@ export interface SecuritySolutionPluginContext { * Deregister stale query */ deregisterQuery: (query: { id: string }) => void; + + blockList: { + exceptionListApiClient: unknown; + useSetUrlParams: () => ( + params: Record, + replace?: boolean | undefined + ) => void; + getFlyoutComponent: () => NamedExoticComponent; + getFormComponent: () => NamedExoticComponent; + }; } diff --git a/x-pack/plugins/threat_intelligence/tsconfig.json b/x-pack/plugins/threat_intelligence/tsconfig.json index a8e1b2a96b37d..3006da321be78 100644 --- a/x-pack/plugins/threat_intelligence/tsconfig.json +++ b/x-pack/plugins/threat_intelligence/tsconfig.json @@ -31,6 +31,7 @@ "@kbn/kibana-react-plugin", "@kbn/utility-types", "@kbn/ui-theme", + "@kbn/securitysolution-io-ts-list-types" ], "exclude": [ "target/**/*", diff --git a/x-pack/plugins/translations/translations/fr-FR.json b/x-pack/plugins/translations/translations/fr-FR.json index 57409227d5965..320a1850940e9 100644 --- a/x-pack/plugins/translations/translations/fr-FR.json +++ b/x-pack/plugins/translations/translations/fr-FR.json @@ -3988,7 +3988,7 @@ "indexPatternFieldEditor.editor.flyoutEditFieldSubtitle": "Vue de données : {patternName}", "indexPatternFieldEditor.editor.form.source.scriptFieldHelpText": "Les champs d'exécution sans script récupèrent les valeurs de {source}. Si un champ n'existe pas dans _source, la recherche ne renvoie pas de valeur. {learnMoreLink}", "indexPatternFieldEditor.editor.form.valueDescription": "Définissez une valeur pour le champ au lieu de la récupérer à partir du champ portant le même nom dans {source}.", - "indexPatternFieldEditor.fieldPreview.subTitle": "Depuis : {from}", + "indexPatternFieldEditor.fieldPreview.subTitle": "Depuis : {documentSource}", "indexPatternFieldEditor.number.numeralLabel": "Modèle de format Numeral.js (par défaut : {defaultPattern})", "indexPatternFieldEditor.cancelField.confirmationModal.cancelButtonLabel": "Annuler", "indexPatternFieldEditor.cancelField.confirmationModal.description": "Les modifications apportées à votre champ seront ignorées. Voulez-vous vraiment continuer ?", @@ -18271,9 +18271,7 @@ "xpack.lens.app.cancel": "Annuler", "xpack.lens.app.cancelButtonAriaLabel": "Retour à la dernière application sans enregistrer les modifications", "xpack.lens.app.docLoadingError": "Erreur lors du chargement du document enregistré", - "xpack.lens.app.downloadButtonAriaLabel": "Télécharger les données en fichier CSV", "xpack.lens.app.downloadButtonFormulasWarning": "Votre fichier CSV contient des caractères que les applications de feuilles de calcul pourraient considérer comme des formules.", - "xpack.lens.app.downloadCSV": "Télécharger au format CSV", "xpack.lens.app.exploreDataInDiscover": "Explorer les données dans Discover", "xpack.lens.app.exploreDataInDiscoverDrilldown": "Ouvrir dans Discover", "xpack.lens.app.exploreDataInDiscoverDrilldown.newTabConfig": "Ouvrir dans un nouvel onglet", diff --git a/x-pack/plugins/translations/translations/ja-JP.json b/x-pack/plugins/translations/translations/ja-JP.json index 628469236e026..d3eaf8657b1db 100644 --- a/x-pack/plugins/translations/translations/ja-JP.json +++ b/x-pack/plugins/translations/translations/ja-JP.json @@ -3985,7 +3985,7 @@ "indexPatternFieldEditor.editor.flyoutEditFieldSubtitle": "データビュー:{patternName}", "indexPatternFieldEditor.editor.form.source.scriptFieldHelpText": "スクリプトがないランタイムフィールドは、{source}から値を取得します。フィールドが_sourceに存在しない場合は、検索リクエストは値を返しません。{learnMoreLink}", "indexPatternFieldEditor.editor.form.valueDescription": "{source}の同じ名前のフィールドから取得するのではなく、フィールドの値を設定します。", - "indexPatternFieldEditor.fieldPreview.subTitle": "開始:{from}", + "indexPatternFieldEditor.fieldPreview.subTitle": "開始:{documentSource}", "indexPatternFieldEditor.number.numeralLabel": "Numeral.js のフォーマットパターン(デフォルト:{defaultPattern})", "indexPatternFieldEditor.cancelField.confirmationModal.cancelButtonLabel": "キャンセル", "indexPatternFieldEditor.cancelField.confirmationModal.description": "フィールドの変更は破棄されます。続行しますか?", @@ -18254,9 +18254,7 @@ "xpack.lens.app.cancel": "キャンセル", "xpack.lens.app.cancelButtonAriaLabel": "変更を保存せずに最後に使用していたアプリに戻る", "xpack.lens.app.docLoadingError": "保存されたドキュメントの保存中にエラーが発生", - "xpack.lens.app.downloadButtonAriaLabel": "データを CSV ファイルとしてダウンロード", "xpack.lens.app.downloadButtonFormulasWarning": "CSVには、スプレッドシートアプリケーションで式と解釈される可能性のある文字が含まれています。", - "xpack.lens.app.downloadCSV": "CSV をダウンロード", "xpack.lens.app.exploreDataInDiscover": "Discoverでデータを探索", "xpack.lens.app.exploreDataInDiscoverDrilldown": "Discoverで開く", "xpack.lens.app.exploreDataInDiscoverDrilldown.newTabConfig": "新しいタブで開く", diff --git a/x-pack/plugins/translations/translations/zh-CN.json b/x-pack/plugins/translations/translations/zh-CN.json index 702d973eaf2b9..d287418196d63 100644 --- a/x-pack/plugins/translations/translations/zh-CN.json +++ b/x-pack/plugins/translations/translations/zh-CN.json @@ -3990,7 +3990,7 @@ "indexPatternFieldEditor.editor.flyoutEditFieldSubtitle": "数据视图:{patternName}", "indexPatternFieldEditor.editor.form.source.scriptFieldHelpText": "没有脚本的运行时字段从 {source} 中检索值。如果字段在 _source 中不存在,搜索请求将不返回值。{learnMoreLink}", "indexPatternFieldEditor.editor.form.valueDescription": "为字段设置值,而非从在 {source} 中同名的字段检索值。", - "indexPatternFieldEditor.fieldPreview.subTitle": "自: {from}", + "indexPatternFieldEditor.fieldPreview.subTitle": "自: {documentSource}", "indexPatternFieldEditor.number.numeralLabel": "Numeral.js 格式模式(默认值:{defaultPattern})", "indexPatternFieldEditor.cancelField.confirmationModal.cancelButtonLabel": "取消", "indexPatternFieldEditor.cancelField.confirmationModal.description": "将会丢弃对您的字段所做的更改,是否确定要继续?", @@ -18278,9 +18278,7 @@ "xpack.lens.app.cancel": "取消", "xpack.lens.app.cancelButtonAriaLabel": "返回到上一个应用而不保存更改", "xpack.lens.app.docLoadingError": "加载已保存文档时出错", - "xpack.lens.app.downloadButtonAriaLabel": "将数据下载为 CSV 文件", "xpack.lens.app.downloadButtonFormulasWarning": "您的 CSV 包含电子表格应用程序可能解释为公式的字符。", - "xpack.lens.app.downloadCSV": "下载为 CSV", "xpack.lens.app.exploreDataInDiscover": "在 Discover 中浏览数据", "xpack.lens.app.exploreDataInDiscoverDrilldown": "在 Discover 中打开", "xpack.lens.app.exploreDataInDiscoverDrilldown.newTabConfig": "在新选项卡中打开", diff --git a/x-pack/plugins/triggers_actions_ui/.storybook/context/http.ts b/x-pack/plugins/triggers_actions_ui/.storybook/context/http.ts index 049900bd30f4d..c02abc1994715 100644 --- a/x-pack/plugins/triggers_actions_ui/.storybook/context/http.ts +++ b/x-pack/plugins/triggers_actions_ui/.storybook/context/http.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { DecoratorFn } from '@storybook/react'; import { action } from '@storybook/addon-actions'; import type { HttpStart, HttpFetchOptions, HttpHandler } from '@kbn/core/public'; @@ -15,7 +15,7 @@ import { } from '../../public/application/sections/rule_details/components/test_helpers'; const getMockRule = () => { - const id = uuid.v4(); + const id = uuidv4(); return { id, name: `test rule - ${id}`, diff --git a/x-pack/plugins/triggers_actions_ui/.storybook/decorator.tsx b/x-pack/plugins/triggers_actions_ui/.storybook/decorator.tsx index bb6586fcb9a45..5d8452ba8c201 100644 --- a/x-pack/plugins/triggers_actions_ui/.storybook/decorator.tsx +++ b/x-pack/plugins/triggers_actions_ui/.storybook/decorator.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { action } from '@storybook/addon-actions'; import { DecoratorFn } from '@storybook/react'; import { EMPTY, of } from 'rxjs'; @@ -29,7 +29,7 @@ const queryClient = new QueryClient(); const handler = (type: string, ...rest: any[]) => { action(`${type} Toast`)(rest); - return { id: uuid() }; + return { id: uuidv4() }; }; const notifications: NotificationsStart = { diff --git a/x-pack/plugins/triggers_actions_ui/public/application/action_type_registry.mock.ts b/x-pack/plugins/triggers_actions_ui/public/application/action_type_registry.mock.ts index 8260f208f353d..ad1bc979ba239 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/action_type_registry.mock.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/action_type_registry.mock.ts @@ -6,7 +6,7 @@ */ import React, { lazy } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ActionTypeModel, ActionTypeRegistryContract } from '../types'; const createActionTypeRegistryMock = () => { @@ -26,7 +26,7 @@ const mockedActionParamsFields = lazy(async () => ({ })); const createMockActionTypeModel = (actionType: Partial = {}): ActionTypeModel => { - const id = uuid.v4(); + const id = uuidv4(); return { id, iconClass: `iconClass-${id}`, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_flapping_form_section.tsx b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_flapping_form_section.tsx new file mode 100644 index 0000000000000..bfde62591f626 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_flapping_form_section.tsx @@ -0,0 +1,213 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { memo } from 'react'; +import { i18n } from '@kbn/i18n'; +import { FormattedMessage } from '@kbn/i18n-react'; +import { + EuiFlexGroup, + EuiFlexItem, + EuiFormRow, + EuiFormRowProps, + EuiIconTip, + EuiRange, + EuiRangeProps, + EuiSpacer, + EuiTitle, + EuiText, + EuiPanel, +} from '@elastic/eui'; +import { + RulesSettingsFlappingProperties, + MIN_LOOK_BACK_WINDOW, + MIN_STATUS_CHANGE_THRESHOLD, + MAX_LOOK_BACK_WINDOW, + MAX_STATUS_CHANGE_THRESHOLD, +} from '@kbn/alerting-plugin/common'; +import { useKibana } from '../../../common/lib/kibana'; + +type OnChangeKey = keyof Omit; + +const lookBackWindowLabel = i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.flapping.lookBackWindowLabel', + { + defaultMessage: 'Rule run look back window', + } +); + +const statusChangeThresholdLabel = i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.flapping.statusChangeThresholdLabel', + { + defaultMessage: 'Alert status change threshold', + } +); + +const getLookBackWindowLabelRuleRuns = (amount: number) => { + return i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.flapping.lookBackWindowLabelRuleRuns', + { + defaultMessage: '{amount, number} rule {amount, plural, one {run} other {runs}}', + values: { amount }, + } + ); +}; + +const getStatusChangeThresholdRuleRuns = (amount: number) => { + return i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.flapping.statusChangeThresholdTimes', + { + defaultMessage: '{amount, number} {amount, plural, one {time} other {times}}', + values: { amount }, + } + ); +}; + +export interface RulesSettingsRangeProps { + label: EuiFormRowProps['label']; + labelPopoverText?: string; + min: number; + max: number; + value: number; + disabled?: EuiRangeProps['disabled']; + onChange?: EuiRangeProps['onChange']; +} + +export const RulesSettingsFlappingTitle = () => { + return ( + +
    + +
    +
    + ); +}; + +export const RulesSettingsFlappingDescription = () => { + return ( + + + + ); +}; + +export const RulesSettingsRange = memo((props: RulesSettingsRangeProps) => { + const { label, labelPopoverText, min, max, value, disabled, onChange, ...rest } = props; + + const renderLabel = () => { + return ( +
    + {label} +   + +
    + ); + }; + + return ( + + + + ); +}); + +export interface RulesSettingsFlappingFormSectionProps { + flappingSettings: RulesSettingsFlappingProperties; + compressed?: boolean; + onChange: (key: OnChangeKey, value: number) => void; +} + +export const RulesSettingsFlappingFormSection = memo( + (props: RulesSettingsFlappingFormSectionProps) => { + const { flappingSettings, compressed = false, onChange } = props; + + const { lookBackWindow, statusChangeThreshold } = flappingSettings; + + const { + application: { capabilities }, + } = useKibana().services; + + const { + rulesSettings: { writeFlappingSettingsUI }, + } = capabilities; + + const canWriteFlappingSettings = writeFlappingSettingsUI; + + return ( + + {compressed && ( + <> + + + + + + + + + + + + + )} + + onChange('lookBackWindow', parseInt(e.currentTarget.value, 10))} + label={lookBackWindowLabel} + disabled={!canWriteFlappingSettings} + /> + + + onChange('statusChangeThreshold', parseInt(e.currentTarget.value, 10))} + label={statusChangeThresholdLabel} + disabled={!canWriteFlappingSettings} + /> + + + + + {getLookBackWindowLabelRuleRuns(lookBackWindow)}
    , + statusChangeThreshold: ( + {getStatusChangeThresholdRuleRuns(statusChangeThreshold)} + ), + }} + /> + + + + + ); + } +); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.test.tsx new file mode 100644 index 0000000000000..e2e454e644ac0 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.test.tsx @@ -0,0 +1,150 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; +import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; +import { render, cleanup, waitFor } from '@testing-library/react'; +import userEvent from '@testing-library/user-event'; +import { coreMock } from '@kbn/core/public/mocks'; +import { RulesSettingsFlapping } from '@kbn/alerting-plugin/common'; +import { RulesSettingsLink } from './rules_settings_link'; +import { useKibana } from '../../../common/lib/kibana'; +import { getFlappingSettings } from '../../lib/rule_api'; +import { updateFlappingSettings } from '../../lib/rule_api'; + +jest.mock('../../../common/lib/kibana'); +jest.mock('../../lib/rule_api/get_flapping_settings', () => ({ + getFlappingSettings: jest.fn(), +})); +jest.mock('../../lib/rule_api/update_flapping_settings', () => ({ + updateFlappingSettings: jest.fn(), +})); + +const queryClient = new QueryClient({ + defaultOptions: { + queries: { + retry: false, + cacheTime: 0, + }, + }, +}); + +const useKibanaMock = useKibana as jest.Mocked; + +const mocks = coreMock.createSetup(); + +const getFlappingSettingsMock = getFlappingSettings as unknown as jest.MockedFunction< + typeof getFlappingSettings +>; +const updateFlappingSettingsMock = updateFlappingSettings as unknown as jest.MockedFunction< + typeof updateFlappingSettings +>; + +const mockFlappingSetting: RulesSettingsFlapping = { + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 11, + createdBy: 'test user', + updatedBy: 'test user', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), +}; + +const RulesSettingsLinkWithProviders: React.FunctionComponent<{}> = () => ( + + + + + +); + +describe('rules_settings_link', () => { + beforeEach(async () => { + const [ + { + application: { capabilities }, + }, + ] = await mocks.getStartServices(); + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: true, + writeFlappingSettingsUI: true, + readFlappingSettingsUI: true, + }, + }; + getFlappingSettingsMock.mockResolvedValue(mockFlappingSetting); + updateFlappingSettingsMock.mockResolvedValue(mockFlappingSetting); + }); + + afterEach(() => { + jest.clearAllMocks(); + queryClient.clear(); + cleanup(); + }); + + test('renders the rules setting link correctly', async () => { + const result = render(); + await waitFor(() => { + expect(result.getByText('Settings')).toBeInTheDocument(); + }); + expect(result.getByText('Settings')).not.toBeDisabled(); + expect(result.queryByTestId('rulesSettingsModal')).toBe(null); + }); + + test('clicking the settings link opens the rules settings modal', async () => { + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('rulesSettingsModal')).toBe(null); + }); + + userEvent.click(result.getByText('Settings')); + + await waitFor(() => { + expect(result.queryByTestId('rulesSettingsModal')).not.toBe(null); + }); + }); + + test('link is hidden when provided with insufficient read permissions', async () => { + const [ + { + application: { capabilities }, + }, + ] = await mocks.getStartServices(); + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: false, + writeFlappingSettingsUI: true, + readFlappingSettingsUI: true, + }, + }; + + let result = render(); + await waitFor(() => { + expect(result.queryByTestId('rulesSettingsLink')).toBe(null); + }); + + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: true, + writeFlappingSettingsUI: true, + readFlappingSettingsUI: false, + }, + }; + + result = render(); + await waitFor(() => { + expect(result.queryByTestId('rulesSettingsLink')).toBe(null); + }); + }); +}); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.tsx b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.tsx new file mode 100644 index 0000000000000..bb72db2bc4163 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_link.tsx @@ -0,0 +1,41 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { useState } from 'react'; +import { EuiButtonEmpty } from '@elastic/eui'; +import { FormattedMessage } from '@kbn/i18n-react'; +import { RulesSettingsModal } from './rules_settings_modal'; +import { useKibana } from '../../../common/lib/kibana'; + +export const RulesSettingsLink = () => { + const [isVisible, setIsVisible] = useState(false); + const { + application: { capabilities }, + } = useKibana().services; + + const { show, readFlappingSettingsUI } = capabilities.rulesSettings; + + if (!show || !readFlappingSettingsUI) { + return null; + } + + return ( + <> + setIsVisible(true)} + iconType="gear" + data-test-subj="rulesSettingsLink" + > + + + setIsVisible(false)} /> + + ); +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.test.tsx new file mode 100644 index 0000000000000..6915a46123a40 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.test.tsx @@ -0,0 +1,264 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React from 'react'; +import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; +import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; +import { render, fireEvent, cleanup, waitFor } from '@testing-library/react'; +import userEvent from '@testing-library/user-event'; +import { coreMock } from '@kbn/core/public/mocks'; +import { IToasts } from '@kbn/core/public'; +import { RulesSettingsFlapping } from '@kbn/alerting-plugin/common'; +import { RulesSettingsModal, RulesSettingsModalProps } from './rules_settings_modal'; +import { useKibana } from '../../../common/lib/kibana'; +import { getFlappingSettings } from '../../lib/rule_api/get_flapping_settings'; +import { updateFlappingSettings } from '../../lib/rule_api/update_flapping_settings'; + +jest.mock('../../../common/lib/kibana'); +jest.mock('../../lib/rule_api/get_flapping_settings', () => ({ + getFlappingSettings: jest.fn(), +})); +jest.mock('../../lib/rule_api/update_flapping_settings', () => ({ + updateFlappingSettings: jest.fn(), +})); + +const queryClient = new QueryClient({ + defaultOptions: { + queries: { + retry: false, + cacheTime: 0, + }, + }, +}); + +const useKibanaMock = useKibana as jest.Mocked; + +const mocks = coreMock.createSetup(); + +const getFlappingSettingsMock = getFlappingSettings as unknown as jest.MockedFunction< + typeof getFlappingSettings +>; +const updateFlappingSettingsMock = updateFlappingSettings as unknown as jest.MockedFunction< + typeof updateFlappingSettings +>; + +const mockFlappingSetting: RulesSettingsFlapping = { + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 10, + createdBy: 'test user', + updatedBy: 'test user', + createdAt: new Date().toISOString(), + updatedAt: new Date().toISOString(), +}; + +const modalProps: RulesSettingsModalProps = { + isVisible: true, + setUpdatingRulesSettings: jest.fn(), + onClose: jest.fn(), + onSave: jest.fn(), +}; + +const RulesSettingsModalWithProviders: React.FunctionComponent = ( + props +) => ( + + + + + +); + +describe('rules_settings_modal', () => { + beforeEach(async () => { + const [ + { + application: { capabilities }, + }, + ] = await mocks.getStartServices(); + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: true, + writeFlappingSettingsUI: true, + readFlappingSettingsUI: true, + }, + }; + + useKibanaMock().services.notifications.toasts = { + addSuccess: jest.fn(), + addError: jest.fn(), + addDanger: jest.fn(), + addWarning: jest.fn(), + } as unknown as IToasts; + + getFlappingSettingsMock.mockResolvedValue(mockFlappingSetting); + updateFlappingSettingsMock.mockResolvedValue(mockFlappingSetting); + }); + + afterEach(() => { + jest.clearAllMocks(); + queryClient.clear(); + cleanup(); + }); + + test('renders flapping settings correctly', async () => { + const result = render(); + expect(getFlappingSettingsMock).toHaveBeenCalledTimes(1); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + expect(result.getByTestId('rulesSettingsModalEnableSwitch').getAttribute('aria-checked')).toBe( + 'true' + ); + expect(result.getByTestId('lookBackWindowRangeInput').getAttribute('value')).toBe('10'); + expect(result.getByTestId('statusChangeThresholdRangeInput').getAttribute('value')).toBe('10'); + + expect(result.getByTestId('rulesSettingsModalCancelButton')).toBeInTheDocument(); + expect(result.getByTestId('rulesSettingsModalSaveButton').getAttribute('disabled')).toBeFalsy(); + }); + + test('can save flapping settings', async () => { + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + const lookBackWindowInput = result.getByTestId('lookBackWindowRangeInput'); + const statusChangeThresholdInput = result.getByTestId('statusChangeThresholdRangeInput'); + + fireEvent.change(lookBackWindowInput, { target: { value: 20 } }); + fireEvent.change(statusChangeThresholdInput, { target: { value: 5 } }); + + expect(lookBackWindowInput.getAttribute('value')).toBe('20'); + expect(statusChangeThresholdInput.getAttribute('value')).toBe('5'); + + // Try saving + userEvent.click(result.getByTestId('rulesSettingsModalSaveButton')); + + await waitFor(() => { + expect(modalProps.setUpdatingRulesSettings).toHaveBeenCalledWith(true); + }); + expect(modalProps.onClose).toHaveBeenCalledTimes(1); + expect(updateFlappingSettingsMock).toHaveBeenCalledWith( + expect.objectContaining({ + flappingSettings: { + enabled: true, + lookBackWindow: 20, + statusChangeThreshold: 5, + }, + }) + ); + expect(useKibanaMock().services.notifications.toasts.addSuccess).toHaveBeenCalledTimes(1); + expect(modalProps.setUpdatingRulesSettings).toHaveBeenCalledWith(true); + expect(modalProps.onSave).toHaveBeenCalledTimes(1); + }); + + test('should prevent statusChangeThreshold from being greater than lookBackWindow', async () => { + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + const lookBackWindowInput = result.getByTestId('lookBackWindowRangeInput'); + const statusChangeThresholdInput = result.getByTestId('statusChangeThresholdRangeInput'); + + // Change lookBackWindow to a smaller value + fireEvent.change(lookBackWindowInput, { target: { value: 5 } }); + // statusChangeThresholdInput gets pinned to be 5 + expect(statusChangeThresholdInput.getAttribute('value')).toBe('5'); + + // Try making statusChangeThreshold bigger + fireEvent.change(statusChangeThresholdInput, { target: { value: 20 } }); + // Still pinned + expect(statusChangeThresholdInput.getAttribute('value')).toBe('5'); + + fireEvent.change(statusChangeThresholdInput, { target: { value: 3 } }); + expect(statusChangeThresholdInput.getAttribute('value')).toBe('3'); + }); + + test('handles errors when saving settings', async () => { + updateFlappingSettingsMock.mockRejectedValue('failed!'); + + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + // Try saving + userEvent.click(result.getByTestId('rulesSettingsModalSaveButton')); + await waitFor(() => { + expect(modalProps.setUpdatingRulesSettings).toHaveBeenCalledWith(true); + }); + expect(modalProps.onClose).toHaveBeenCalledTimes(1); + expect(useKibanaMock().services.notifications.toasts.addDanger).toHaveBeenCalledTimes(1); + expect(modalProps.setUpdatingRulesSettings).toHaveBeenCalledWith(true); + expect(modalProps.onSave).toHaveBeenCalledTimes(1); + }); + + test('displays flapping detection off prompt when flapping is disabled', async () => { + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + expect(result.queryByTestId('rulesSettingsModalFlappingOffPrompt')).toBe(null); + userEvent.click(result.getByTestId('rulesSettingsModalEnableSwitch')); + expect(result.queryByTestId('rulesSettingsModalFlappingOffPrompt')).not.toBe(null); + }); + + test('form elements are disabled when provided with insufficient write permissions', async () => { + const [ + { + application: { capabilities }, + }, + ] = await mocks.getStartServices(); + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: true, + writeFlappingSettingsUI: false, + readFlappingSettingsUI: true, + }, + }; + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + expect(result.getByTestId('rulesSettingsModalEnableSwitch')).toBeDisabled(); + expect(result.getByTestId('lookBackWindowRangeInput')).toBeDisabled(); + expect(result.getByTestId('statusChangeThresholdRangeInput')).toBeDisabled(); + expect(result.getByTestId('rulesSettingsModalSaveButton')).toBeDisabled(); + }); + + test('form elements are not visible when provided with insufficient read permissions', async () => { + const [ + { + application: { capabilities }, + }, + ] = await mocks.getStartServices(); + useKibanaMock().services.application.capabilities = { + ...capabilities, + rulesSettings: { + save: true, + show: false, + writeFlappingSettingsUI: true, + readFlappingSettingsUI: false, + }, + }; + + const result = render(); + await waitFor(() => { + expect(result.queryByTestId('centerJustifiedSpinner')).toBe(null); + }); + + expect(result.getByTestId('rulesSettingsErrorPrompt')).toBeInTheDocument(); + }); +}); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.tsx b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.tsx new file mode 100644 index 0000000000000..3b9e5d9ecf0ae --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/components/rules_setting/rules_settings_modal.tsx @@ -0,0 +1,299 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import React, { memo, useState } from 'react'; +import { RulesSettingsFlappingProperties } from '@kbn/alerting-plugin/common'; +import { i18n } from '@kbn/i18n'; +import { FormattedMessage } from '@kbn/i18n-react'; +import { + EuiButton, + EuiButtonEmpty, + EuiCallOut, + EuiHorizontalRule, + EuiFlexGroup, + EuiFlexItem, + EuiForm, + EuiModal, + EuiModalHeader, + EuiModalBody, + EuiModalFooter, + EuiModalHeaderTitle, + EuiSpacer, + EuiSwitch, + EuiSwitchProps, + EuiPanel, + EuiText, + EuiEmptyPrompt, +} from '@elastic/eui'; +import { useKibana } from '../../../common/lib/kibana'; +import { + RulesSettingsFlappingFormSection, + RulesSettingsFlappingFormSectionProps, + RulesSettingsFlappingTitle, +} from './rules_settings_flapping_form_section'; +import { useGetFlappingSettings } from '../../hooks/use_get_flapping_settings'; +import { useUpdateFlappingSettings } from '../../hooks/use_update_flapping_settings'; +import { CenterJustifiedSpinner } from '../center_justified_spinner'; + +const flappingDescription = i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.modal.flappingDetectionDescription', + { + defaultMessage: + 'Alerts that go quickly go between active and recovered are considered flapping. Detecting these changes and minimizing new alert generation can help reduce unwanted noise in your alerting system.', + } +); + +const flappingEnableLabel = i18n.translate( + 'xpack.triggersActionsUI.rulesSettings.modal.enableFlappingLabel', + { + defaultMessage: 'Enabled flapping detection (recommended)', + } +); + +export const RulesSettingsErrorPrompt = memo(() => { + return ( + + + + } + body={ +

    + +

    + } + /> + ); +}); + +interface RulesSettingsModalFormLeftProps { + settings: RulesSettingsFlappingProperties; + onChange: EuiSwitchProps['onChange']; + isSwitchDisabled: boolean; +} + +export const RulesSettingsModalFormLeft = memo((props: RulesSettingsModalFormLeftProps) => { + const { settings, onChange, isSwitchDisabled } = props; + + return ( + + + + +

    {flappingDescription}

    +
    +
    + + + +
    +
    + ); +}); + +interface RulesSettingsModalFormRightProps { + settings: RulesSettingsFlappingProperties; + onChange: RulesSettingsFlappingFormSectionProps['onChange']; +} + +export const RulesSettingsModalFormRight = memo((props: RulesSettingsModalFormRightProps) => { + const { settings, onChange } = props; + + if (!settings) { + return null; + } + if (!settings.enabled) { + return ( + + + + + + + + ); + } + + return ( + + + + ); +}); + +export interface RulesSettingsModalProps { + isVisible: boolean; + setUpdatingRulesSettings?: (isUpdating: boolean) => void; + onClose: () => void; + onSave?: () => void; +} + +export const RulesSettingsModal = memo((props: RulesSettingsModalProps) => { + const { isVisible, onClose, setUpdatingRulesSettings, onSave } = props; + + const { + application: { capabilities }, + } = useKibana().services; + const { + rulesSettings: { show, save, writeFlappingSettingsUI, readFlappingSettingsUI }, + } = capabilities; + + const [settings, setSettings] = useState(); + + const { isLoading, isError: hasError } = useGetFlappingSettings({ + enabled: isVisible, + onSuccess: (fetchedSettings) => { + if (!settings) { + setSettings({ + enabled: fetchedSettings.enabled, + lookBackWindow: fetchedSettings.lookBackWindow, + statusChangeThreshold: fetchedSettings.statusChangeThreshold, + }); + } + }, + }); + + const { mutate } = useUpdateFlappingSettings({ + onSave, + onClose, + setUpdatingRulesSettings, + }); + + // In the future when we have more settings sub-features, we should + // disassociate the rule settings capabilities (save, show) from the + // sub-feature capabilities (writeXSettingsUI). + const canWriteFlappingSettings = save && writeFlappingSettingsUI && !hasError; + const canShowFlappingSettings = show && readFlappingSettingsUI; + + const handleSettingsChange = ( + key: keyof RulesSettingsFlappingProperties, + value: number | boolean + ) => { + if (!settings) { + return; + } + + const newSettings = { + ...settings, + [key]: value, + }; + + setSettings({ + ...newSettings, + statusChangeThreshold: Math.min( + newSettings.lookBackWindow, + newSettings.statusChangeThreshold + ), + }); + }; + + const handleSave = () => { + if (!settings) { + return; + } + mutate(settings); + }; + + if (!isVisible) { + return null; + } + + const maybeRenderForm = () => { + if (hasError || !canShowFlappingSettings) { + return ; + } + if (!settings || isLoading) { + return ; + } + return ( + + + + + + + + + handleSettingsChange('enabled', e.target.checked)} + /> + handleSettingsChange(key, value)} + /> + + + ); + }; + + return ( + + + +

    + +

    +
    +
    + + + + {maybeRenderForm()} + + + + + + + + + + + +
    + ); +}); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_flapping_settings.ts b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_flapping_settings.ts new file mode 100644 index 0000000000000..23f4af9e9daa7 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_flapping_settings.ts @@ -0,0 +1,53 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; +import { useQuery } from '@tanstack/react-query'; +import { RulesSettingsFlapping } from '@kbn/alerting-plugin/common'; +import { useKibana } from '../../common/lib/kibana'; +import { getFlappingSettings } from '../lib/rule_api'; + +interface UseGetFlappingSettingsProps { + enabled: boolean; + onSuccess: (settings: RulesSettingsFlapping) => void; +} + +export const useGetFlappingSettings = (props: UseGetFlappingSettingsProps) => { + const { enabled, onSuccess } = props; + const { + http, + notifications: { toasts }, + } = useKibana().services; + + const queryFn = () => { + return getFlappingSettings({ http }); + }; + + const onErrorFn = () => { + toasts.addDanger( + i18n.translate('xpack.triggersActionsUI.rulesSettings.modal.getRulesSettingsError', { + defaultMessage: 'Failed to get rules Settings.', + }) + ); + }; + + const { data, isFetching, isError, isLoadingError, isLoading } = useQuery({ + queryKey: ['getFlappingSettings'], + queryFn, + onError: onErrorFn, + onSuccess, + enabled, + refetchOnWindowFocus: false, + retry: false, + }); + + return { + isLoading: isLoading || isFetching, + isError: isError || isLoadingError, + data, + }; +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.test.ts index ee10a0cad6df2..a57ed7b675b9a 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.test.ts @@ -8,7 +8,10 @@ import { renderHook } from '@testing-library/react-hooks'; import { ValidFeatureId } from '@kbn/rule-data-utils'; import { useKibana } from '../../common/lib/kibana'; -import { mockAlertSummaryResponse, mockAlertSummaryTimeRange } from '../mock/alert_summary_widget'; +import { + mockedAlertSummaryResponse, + mockedAlertSummaryTimeRange, +} from '../mock/alert_summary_widget'; import { useLoadAlertSummary } from './use_load_alert_summary'; jest.mock('../../common/lib/kibana'); @@ -28,13 +31,13 @@ describe('useLoadAlertSummary', () => { it('should return the mocked data from API', async () => { mockedPostAPI.mockResolvedValue({ - ...mockAlertSummaryResponse, + ...mockedAlertSummaryResponse, }); const { result, waitForNextUpdate } = renderHook(() => useLoadAlertSummary({ featureIds, - timeRange: mockAlertSummaryTimeRange, + timeRange: mockedAlertSummaryTimeRange, }) ); expect(result.current).toEqual({ @@ -51,27 +54,27 @@ describe('useLoadAlertSummary', () => { const { alertSummary, error } = result.current; expect(alertSummary).toEqual({ - ...mockAlertSummaryResponse, + ...mockedAlertSummaryResponse, }); expect(error).toBeFalsy(); }); it('should call API with correct input', async () => { const ruleId = 'c95bc120-1d56-11ed-9cc7-e7214ada1128'; - const { utcFrom, utcTo, fixedInterval } = mockAlertSummaryTimeRange; + const { utcFrom, utcTo, fixedInterval } = mockedAlertSummaryTimeRange; const filter = { term: { 'kibana.alert.rule.uuid': ruleId, }, }; mockedPostAPI.mockResolvedValue({ - ...mockAlertSummaryResponse, + ...mockedAlertSummaryResponse, }); const { waitForNextUpdate } = renderHook(() => useLoadAlertSummary({ featureIds, - timeRange: mockAlertSummaryTimeRange, + timeRange: mockedAlertSummaryTimeRange, filter, }) ); @@ -100,7 +103,7 @@ describe('useLoadAlertSummary', () => { const { result, waitForNextUpdate } = renderHook(() => useLoadAlertSummary({ featureIds, - timeRange: mockAlertSummaryTimeRange, + timeRange: mockedAlertSummaryTimeRange, }) ); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.ts b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.ts index 25c670d787a09..e3dbeb2a3b525 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_alert_summary.ts @@ -12,19 +12,10 @@ import { AsApiContract } from '@kbn/actions-plugin/common'; import { HttpSetup } from '@kbn/core/public'; import { BASE_RAC_ALERTS_API_PATH } from '@kbn/rule-registry-plugin/common/constants'; import { useKibana } from '../../common/lib/kibana'; - -export interface AlertSummaryTimeRange { - utcFrom: string; - utcTo: string; - // fixed_interval condition in ES query such as '1m', '1d' - fixedInterval: string; - title: JSX.Element | string; -} - -export interface Alert { - key: number; - doc_count: number; -} +import { + Alert, + AlertSummaryTimeRange, +} from '../sections/rule_details/components/alert_summary/types'; interface UseLoadAlertSummaryProps { featureIds?: ValidFeatureId[]; @@ -75,8 +66,7 @@ export function useLoadAlertSummary({ featureIds, timeRange, filter }: UseLoadAl }); if (!isCancelledRef.current) { - setAlertSummary((oldState) => ({ - ...oldState, + setAlertSummary(() => ({ alertSummary: { activeAlertCount, activeAlerts, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_flapping_settings.ts b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_flapping_settings.ts new file mode 100644 index 0000000000000..d5f978db9d3c0 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_flapping_settings.ts @@ -0,0 +1,57 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { i18n } from '@kbn/i18n'; +import { useMutation } from '@tanstack/react-query'; +import { RulesSettingsFlappingProperties } from '@kbn/alerting-plugin/common'; +import { useKibana } from '../../common/lib/kibana'; +import { updateFlappingSettings } from '../lib/rule_api'; + +interface UseUpdateFlappingSettingsProps { + onClose: () => void; + onSave?: () => void; + setUpdatingRulesSettings?: (isUpdating: boolean) => void; +} + +export const useUpdateFlappingSettings = (props: UseUpdateFlappingSettingsProps) => { + const { onSave, onClose, setUpdatingRulesSettings } = props; + + const { + http, + notifications: { toasts }, + } = useKibana().services; + + const mutationFn = (flappingSettings: RulesSettingsFlappingProperties) => { + return updateFlappingSettings({ http, flappingSettings }); + }; + + return useMutation({ + mutationFn, + onMutate: () => { + onClose(); + setUpdatingRulesSettings?.(true); + }, + onSuccess: () => { + toasts.addSuccess( + i18n.translate('xpack.triggersActionsUI.rulesSettings.modal.updateRulesSettingsSuccess', { + defaultMessage: 'Rules settings updated successfully.', + }) + ); + }, + onError: () => { + toasts.addDanger( + i18n.translate('xpack.triggersActionsUI.rulesSettings.modal.updateRulesSettingsFailure', { + defaultMessage: 'Failed to update rules settings.', + }) + ); + }, + onSettled: () => { + setUpdatingRulesSettings?.(false); + onSave?.(); + }, + }); +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/has_mustache_tokens.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/has_mustache_tokens.test.ts index 45988aaa081d9..dc769af8ec9b5 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/has_mustache_tokens.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/has_mustache_tokens.test.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { hasMustacheTokens } from './has_mustache_tokens'; @@ -15,7 +15,7 @@ describe('hasMustacheTokens', () => { }); test('returns false for string without tokens', () => { - expect(hasMustacheTokens(`some random string ${uuid.v4()}`)).toBe(false); + expect(hasMustacheTokens(`some random string ${uuidv4()}`)).toBe(false); }); test('returns true when a template token is present', () => { diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_flapping_settings.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_flapping_settings.ts new file mode 100644 index 0000000000000..68947de984fb4 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_flapping_settings.ts @@ -0,0 +1,16 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { HttpSetup } from '@kbn/core/public'; +import { RulesSettingsFlapping } from '@kbn/alerting-plugin/common'; +import { INTERNAL_BASE_ALERTING_API_PATH } from '../../constants'; + +export const getFlappingSettings = ({ http }: { http: HttpSetup }) => { + return http.get( + `${INTERNAL_BASE_ALERTING_API_PATH}/rules/settings/_flapping` + ); +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_rule.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_rule.test.ts index 5a2a4661ef7f8..bedc7a13b2325 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_rule.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/get_rule.test.ts @@ -7,13 +7,13 @@ import { httpServiceMock } from '@kbn/core/public/mocks'; import { loadRule } from './get_rule'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; const http = httpServiceMock.createStartContract(); describe('loadRule', () => { test('should call get API with base parameters', async () => { - const ruleId = `${uuid.v4()}/`; + const ruleId = `${uuidv4()}/`; const ruleIdEncoded = encodeURIComponent(ruleId); const resolvedValue = { id: '1/', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/index.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/index.ts index f1d65768802ec..74157ac200ce7 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/index.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/index.ts @@ -46,3 +46,5 @@ export { runSoon } from './run_soon'; export { bulkDeleteRules } from './bulk_delete'; export { bulkEnableRules } from './bulk_enable'; export { bulkDisableRules } from './bulk_disable'; +export { getFlappingSettings } from './get_flapping_settings'; +export { updateFlappingSettings } from './update_flapping_settings'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/resolve_rule.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/resolve_rule.test.ts index 7c86c68e99e80..de2773e3e22b3 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/resolve_rule.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/resolve_rule.test.ts @@ -7,13 +7,13 @@ import { httpServiceMock } from '@kbn/core/public/mocks'; import { resolveRule } from './resolve_rule'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; const http = httpServiceMock.createStartContract(); describe('resolveRule', () => { test('should call get API with base parameters', async () => { - const ruleId = `${uuid.v4()}/`; + const ruleId = `${uuidv4()}/`; const ruleIdEncoded = encodeURIComponent(ruleId); const resolvedValue = { id: '1/', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/state.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/state.test.ts index 9932cccf76c41..40047259de4d9 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/state.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/state.test.ts @@ -7,7 +7,7 @@ import { httpServiceMock } from '@kbn/core/public/mocks'; import { loadRuleState } from './state'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; const http = httpServiceMock.createStartContract(); @@ -15,7 +15,7 @@ describe('loadRuleState', () => { beforeEach(() => jest.resetAllMocks()); test('should call get API with base parameters', async () => { - const ruleId = uuid.v4(); + const ruleId = uuidv4(); const resolvedValue = { alertTypeState: { some: 'value', @@ -40,7 +40,7 @@ describe('loadRuleState', () => { }); test('should parse RuleInstances', async () => { - const ruleId = uuid.v4(); + const ruleId = uuidv4(); const resolvedValue = { alertTypeState: { some: 'value', @@ -92,7 +92,7 @@ describe('loadRuleState', () => { }); test('should handle empty response from api', async () => { - const ruleId = uuid.v4(); + const ruleId = uuidv4(); http.get.mockResolvedValueOnce(''); expect(await loadRuleState({ http, ruleId })).toEqual({}); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/update_flapping_settings.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/update_flapping_settings.ts new file mode 100644 index 0000000000000..f38393b591d72 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/rule_api/update_flapping_settings.ts @@ -0,0 +1,34 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { HttpSetup } from '@kbn/core/public'; +import { + RulesSettingsFlapping, + RulesSettingsFlappingProperties, +} from '@kbn/alerting-plugin/common'; +import { INTERNAL_BASE_ALERTING_API_PATH } from '../../constants'; + +export const updateFlappingSettings = ({ + http, + flappingSettings, +}: { + http: HttpSetup; + flappingSettings: RulesSettingsFlappingProperties; +}) => { + let body: string; + try { + body = JSON.stringify(flappingSettings); + } catch (e) { + throw new Error(`Unable to parse flapping settings update params: ${e}`); + } + return http.post( + `${INTERNAL_BASE_ALERTING_API_PATH}/rules/settings/_flapping`, + { + body, + } + ); +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/lib/value_validators.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/lib/value_validators.test.ts index 6587fc669b97e..ecd377f6976f9 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/lib/value_validators.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/lib/value_validators.test.ts @@ -12,7 +12,7 @@ import { getConnectorWithInvalidatedFields, getRuleWithInvalidatedFields, } from './value_validators'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Rule, IErrorObject, UserConfiguredActionConnector } from '../../types'; describe('throwIfAbsent', () => { @@ -38,32 +38,32 @@ describe('throwIfAbsent', () => { describe('throwIfIsntContained', () => { test('throws if value is absent', () => { expect(() => { - throwIfIsntContained(new Set([uuid.v4()]), 'OMG no value', (val) => val)([uuid.v4()]); + throwIfIsntContained(new Set([uuidv4()]), 'OMG no value', (val) => val)([uuidv4()]); }).toThrowErrorMatchingInlineSnapshot(`"OMG no value"`); }); test('throws if value is absent using custom message', () => { - const id = uuid.v4(); + const id = uuidv4(); expect(() => { throwIfIsntContained( new Set([id]), (value: string) => `OMG no ${value}`, (val) => val - )([uuid.v4()]); + )([uuidv4()]); }).toThrow(`OMG no ${id}`); }); test('returns values if value is present', () => { - const id = uuid.v4(); - const values = [uuid.v4(), uuid.v4(), id, uuid.v4()]; + const id = uuidv4(); + const values = [uuidv4(), uuidv4(), id, uuidv4()]; expect( throwIfIsntContained(new Set([id]), 'OMG no value', (val) => val)(values) ).toEqual(values); }); test('returns values if multiple values is present', () => { - const [firstId, secondId] = [uuid.v4(), uuid.v4()]; - const values = [uuid.v4(), uuid.v4(), secondId, uuid.v4(), firstId]; + const [firstId, secondId] = [uuidv4(), uuidv4()]; + const values = [uuidv4(), uuidv4(), secondId, uuidv4(), firstId]; expect( throwIfIsntContained( new Set([firstId, secondId]), @@ -74,7 +74,7 @@ describe('throwIfIsntContained', () => { }); test('allows a custom value extractor', () => { - const [firstId, secondId] = [uuid.v4(), uuid.v4()]; + const [firstId, secondId] = [uuidv4(), uuidv4()]; const values = [ { id: firstId, some: 'prop' }, { id: secondId, someOther: 'prop' }, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/mock/alert_summary_widget/index.ts b/x-pack/plugins/triggers_actions_ui/public/application/mock/alert_summary_widget/index.ts index aaeb820ff136b..c94a137535381 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/mock/alert_summary_widget/index.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/mock/alert_summary_widget/index.ts @@ -5,9 +5,14 @@ * 2.0. */ -import { AlertSummaryTimeRange } from '../../hooks/use_load_alert_summary'; +import { LIGHT_THEME } from '@elastic/charts'; +import { EUI_CHARTS_THEME_LIGHT } from '@elastic/eui/dist/eui_charts_theme'; +import { + AlertSummaryTimeRange, + ChartThemes, +} from '../../sections/rule_details/components/alert_summary/types'; -export const mockAlertSummaryResponse = { +export const mockedAlertSummaryResponse = { activeAlertCount: 2, activeAlerts: [ { key: 1671108000000, doc_count: 0 }, @@ -48,9 +53,14 @@ export const mockAlertSummaryResponse = { ], }; -export const mockAlertSummaryTimeRange: AlertSummaryTimeRange = { +export const mockedAlertSummaryTimeRange: AlertSummaryTimeRange = { utcFrom: 'mockedUtcFrom', utcTo: 'mockedUtcTo', fixedInterval: 'mockedFixedInterval', title: 'mockedTitle', }; + +export const mockedChartThemes: ChartThemes = { + theme: EUI_CHARTS_THEME_LIGHT.theme, + baseTheme: LIGHT_THEME, +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.test.tsx index 26bc284f679bc..d283526c9b55b 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.test.tsx @@ -4,19 +4,24 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import React from 'react'; +import React, { useReducer } from 'react'; -import { render } from '@testing-library/react'; +import { fireEvent, render, screen, within } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import { waitForEuiPopoverOpen } from '@elastic/eui/lib/test/rtl'; import { EcsFieldsResponse } from '@kbn/rule-registry-plugin/common/search_strategy'; import { AlertsTable } from './alerts_table'; -import { AlertsField, AlertsTableProps } from '../../../types'; +import { AlertsField, AlertsTableProps, BulkActionsState, RowSelectionState } from '../../../types'; import { EuiButtonIcon, EuiFlexItem } from '@elastic/eui'; import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; +import { BulkActionsContext } from './bulk_actions/context'; +import { bulkActionsReducer } from './bulk_actions/reducer'; jest.mock('@kbn/data-plugin/public'); +jest.mock('@kbn/kibana-react-plugin/public/ui_settings/use_ui_setting', () => ({ + useUiSetting$: jest.fn((value: string) => ['0,0']), +})); const columns = [ { @@ -73,6 +78,15 @@ describe('AlertsTable', () => { jest.fn().mockImplementation((props) => { return `${props.colIndex}:${props.rowIndex}`; }), + useBulkActions: () => [ + { + label: 'Fake Bulk Action', + key: 'fakeBulkAction', + 'data-test-subj': 'fake-bulk-action', + disableOnQuery: false, + onClick: () => {}, + }, + ], }; const tableProps = { @@ -84,7 +98,6 @@ describe('AlertsTable', () => { pageSize: 1, pageSizeOptions: [1, 10, 20, 50, 100], leadingControlColumns: [], - showCheckboxes: false, showExpandToDetails: true, trailingControlColumns: [], alerts, @@ -99,11 +112,29 @@ describe('AlertsTable', () => { browserFields: {}, }; - const AlertsTableWithLocale: React.FunctionComponent = (props) => ( - - - - ); + const defaultBulkActionsState = { + rowSelection: new Map(), + isAllSelected: false, + areAllVisibleRowsSelected: false, + rowCount: 2, + }; + + const AlertsTableWithLocale: React.FunctionComponent< + AlertsTableProps & { initialBulkActionsState?: BulkActionsState } + > = (props) => { + const initialBulkActionsState = useReducer( + bulkActionsReducer, + props.initialBulkActionsState || defaultBulkActionsState + ); + + return ( + + + + + + ); + }; describe('Alerts table UI', () => { it('should support sorting', async () => { @@ -253,6 +284,78 @@ describe('AlertsTable', () => { expect(queryByTestId('expandColumnHeaderLabel')).toBe(null); expect(queryByTestId('expandColumnCellOpenFlyoutButton')).toBe(null); }); + + describe('row loading state on action', () => { + let mockedFn: jest.Mock; + let customTableProps: AlertsTableProps; + + beforeEach(() => { + mockedFn = jest.fn(); + customTableProps = { + ...tableProps, + pageSize: 2, + alertsTableConfiguration: { + ...alertsTableConfiguration, + useActionsColumn: () => { + return { + renderCustomActionsRow: mockedFn.mockReturnValue( + <> + + {}} + size="s" + data-test-subj="testActionColumn" + /> + + + ), + }; + }, + }, + }; + }); + + it('should show the row loader when callback triggered', async () => { + render(); + fireEvent.click((await screen.findAllByTestId('testActionColumn'))[0]); + + // the callback given to our clients to run when they want to update the loading state + mockedFn.mock.calls[0][3](true); + + expect(await screen.findAllByTestId('row-loader')).toHaveLength(1); + const selectedOptions = await screen.findAllByTestId('dataGridRowCell'); + + // first row, first column + expect(within(selectedOptions[0]).getByLabelText('Loading')).toBeDefined(); + expect(within(selectedOptions[0]).queryByRole('checkbox')).not.toBeInTheDocument(); + + // second row, first column + expect(within(selectedOptions[4]).queryByLabelText('Loading')).not.toBeInTheDocument(); + expect(within(selectedOptions[4]).getByRole('checkbox')).toBeDefined(); + }); + + it('should show the row loader when callback triggered with false', async () => { + const initialBulkActionsState = { + ...defaultBulkActionsState, + rowSelection: new Map([[0, { isLoading: true }]]), + }; + + render( + + ); + fireEvent.click((await screen.findAllByTestId('testActionColumn'))[0]); + + // the callback given to our clients to run when they want to update the loading state + mockedFn.mock.calls[0][3](false); + + expect(screen.queryByTestId('row-loader')).not.toBeInTheDocument(); + }); + }); }); }); }); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.tsx index bfc94a19000d6..288ca1f625954 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table.tsx @@ -17,7 +17,7 @@ import { EuiDataGridStyle, EuiLoadingContent, } from '@elastic/eui'; -import { useSorting, usePagination, useBulkActions } from './hooks'; +import { useSorting, usePagination, useBulkActions, useActionsColumn } from './hooks'; import { AlertsTableProps } from '../../../types'; import { ALERTS_TABLE_CONTROL_COLUMNS_ACTIONS_LABEL, @@ -28,7 +28,7 @@ import './alerts_table.scss'; import { getToolbarVisibility } from './toolbar'; export const ACTIVE_ROW_CLASS = 'alertsTableActiveRow'; -const DEFAULT_ACTIONS_COLUMNS_WIDTH = 75; + const AlertsFlyout = lazy(() => import('./alerts_flyout')); const GridStyles: EuiDataGridStyle = { border: 'none', @@ -50,16 +50,17 @@ const AlertsTable: React.FunctionComponent = (props: AlertsTab } = alertsData; const { sortingColumns, onSort } = useSorting(onSortChange, sortingFields); - const { useActionsColumn = () => ({ renderCustomActionsRow: undefined, width: undefined }) } = - props.alertsTableConfiguration; - const { renderCustomActionsRow, width: actionsColumnWidth = DEFAULT_ACTIONS_COLUMNS_WIDTH } = - useActionsColumn(); + const { renderCustomActionsRow, actionsColumnWidth, getSetIsActionLoadingCallback } = + useActionsColumn({ + options: props.alertsTableConfiguration.useActionsColumn, + }); const { isBulkActionsColumnActive, getBulkActionsLeadingControlColumn, bulkActionsState, bulkActions, + setIsBulkActionsLoading, } = useBulkActions({ alerts, useBulkActionsConfig: props.alertsTableConfiguration.useBulkActions, @@ -112,6 +113,7 @@ const AlertsTable: React.FunctionComponent = (props: AlertsTab onResetColumns, browserFields, controls: props.controls, + setIsBulkActionsLoading, }); }, [ bulkActionsState, @@ -125,6 +127,7 @@ const AlertsTable: React.FunctionComponent = (props: AlertsTab onResetColumns, browserFields, props.controls, + setIsBulkActionsLoading, ])(); const leadingControlColumns = useMemo(() => { @@ -170,7 +173,12 @@ const AlertsTable: React.FunctionComponent = (props: AlertsTab )} {renderCustomActionsRow && alerts[visibleRowIndex] && - renderCustomActionsRow(alerts[visibleRowIndex], handleFlyoutAlert, props.id)} + renderCustomActionsRow( + alerts[visibleRowIndex], + handleFlyoutAlert, + props.id, + getSetIsActionLoadingCallback(visibleRowIndex) + )} ); }, @@ -195,6 +203,7 @@ const AlertsTable: React.FunctionComponent = (props: AlertsTab props.showExpandToDetails, renderCustomActionsRow, setFlyoutAlertIndex, + getSetIsActionLoadingCallback, ]); useEffect(() => { diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table_state.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table_state.tsx index a35fab760a2f0..a7f6c91a8f5d7 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table_state.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/alerts_table_state.tsx @@ -31,6 +31,7 @@ import { AlertsTableProps, BulkActionsReducerAction, BulkActionsState, + RowSelectionState, } from '../../../types'; import { ALERTS_TABLE_CONF_ERROR_MESSAGE, ALERTS_TABLE_CONF_ERROR_TITLE } from './translations'; import { TypeRegistry } from '../../type_registry'; @@ -178,7 +179,7 @@ const AlertsTableState = ({ }, []); const initialBulkActionsState = useReducer(bulkActionsReducer, { - rowSelection: new Set(), + rowSelection: new Map(), isAllSelected: false, areAllVisibleRowsSelected: false, rowCount: alerts.length, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/bulk_actions.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/bulk_actions.test.tsx index 43743d09d381a..8eab96f14d23e 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/bulk_actions.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/bulk_actions.test.tsx @@ -6,14 +6,18 @@ */ import React, { useReducer } from 'react'; -import { render, within } from '@testing-library/react'; -import userEvent from '@testing-library/user-event'; +import { render, screen, within, fireEvent } from '@testing-library/react'; import { waitForEuiPopoverOpen } from '@elastic/eui/lib/test/rtl'; import { EcsFieldsResponse } from '@kbn/rule-registry-plugin/common/search_strategy'; import { BulkActionsContext } from './context'; import { AlertsTable } from '../alerts_table'; -import { AlertsField, AlertsTableProps, BulkActionsState } from '../../../../types'; +import { + AlertsField, + AlertsTableProps, + BulkActionsState, + RowSelectionState, +} from '../../../../types'; import { bulkActionsReducer } from './reducer'; import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; @@ -121,7 +125,7 @@ describe('AlertsTable.BulkActions', () => { }; const defaultBulkActionsState = { - rowSelection: new Set(), + rowSelection: new Map(), isAllSelected: false, areAllVisibleRowsSelected: false, rowCount: 2, @@ -167,32 +171,33 @@ describe('AlertsTable.BulkActions', () => { describe('and click on select all', () => { it('should check that all rows are selected', async () => { - const { getAllByTestId, getByTestId } = render( - - ); - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; + render(); + let bulkActionsCells = screen.getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; expect(bulkActionsCells[0].checked).toBeFalsy(); expect(bulkActionsCells[1].checked).toBeFalsy(); - userEvent.click(getByTestId('bulk-actions-header')); + fireEvent.click(screen.getByTestId('bulk-actions-header')); + bulkActionsCells = screen.getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; expect(bulkActionsCells[0].checked).toBeTruthy(); expect(bulkActionsCells[1].checked).toBeTruthy(); }); - it('should show the right amount of alerts selected', () => { + it('should show the right amount of alerts selected', async () => { const props = { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, areAllVisibleRowsSelected: true, - rowSelection: new Set([0, 1]), + rowSelection: new Map([ + [0, { isLoading: false }], + [1, { isLoading: false }], + ]), }, }; - const { getByTestId } = render(); - const { getByText } = within(getByTestId('selectedShowBulkActionsButton')); - expect(getByText('Selected 2 alerts')).toBeDefined(); + render(); + expect(await screen.findByText('Selected 2 alerts')).toBeDefined(); }); describe('and clicking on a single row', () => { @@ -203,23 +208,29 @@ describe('AlertsTable.BulkActions', () => { initialBulkActionsState: { ...defaultBulkActionsState, areAllVisibleRowsSelected: true, - rowSelection: new Set([0, 1]), + rowSelection: new Map([ + [0, { isLoading: false }], + [1, { isLoading: false }], + ]), }, }; - const { getAllByTestId, getByTestId } = render( - - ); - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - const columnHeader = getByTestId('bulk-actions-header') as HTMLInputElement; - expect(columnHeader.checked).toBeTruthy(); - - userEvent.click(bulkActionsCells[1]); - expect(columnHeader.checked).toBeFalsy(); + render(); + const bulkActionsCells = screen.getAllByTestId( + 'bulk-actions-row-cell' + ) as HTMLInputElement[]; + expect( + (screen.getByTestId('bulk-actions-header') as HTMLInputElement).checked + ).toBeTruthy(); + + fireEvent.click(bulkActionsCells[1]); + expect( + (screen.getByTestId('bulk-actions-header') as HTMLInputElement).checked + ).toBeFalsy(); }); }); describe('and its a page with count of alerts different than page size', () => { - it('should show the right amount of alerts selected', () => { + it('should show the right amount of alerts selected', async () => { const secondPageAlerts = [ { [AlertsField.name]: ['five'], @@ -241,58 +252,64 @@ describe('AlertsTable.BulkActions', () => { initialBulkActionsState: { ...defaultBulkActionsState, areAllVisibleRowsSelected: true, - rowSelection: new Set([0]), + rowSelection: new Map([[0, { isLoading: false }]]), }, }; - const { getByTestId, getAllByTestId } = render( - - ); - const { getByText } = within(getByTestId('selectedShowBulkActionsButton')); - expect(getByText('Selected 1 alert')).toBeDefined(); - expect(getAllByTestId('bulk-actions-row-cell').length).toBe(1); + render(); + + expect(await screen.findByText('Selected 1 alert')).toBeDefined(); + expect((await screen.findAllByTestId('bulk-actions-row-cell')).length).toBe(1); }); }); }); describe('and clicking unselect all', () => { - it('should uncheck all rows', () => { + it('should uncheck all rows', async () => { // state after having already clicked on select all before const props = { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, areAllVisibleRowsSelected: true, - rowSelection: new Set([0, 1]), + rowSelection: new Map([ + [0, { isLoading: false }], + [1, { isLoading: false }], + ]), }, }; - const { getAllByTestId, getByTestId } = render( - - ); - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - expect(bulkActionsCells[0].checked).toBeTruthy(); - expect(bulkActionsCells[1].checked).toBeTruthy(); - - userEvent.click(getByTestId('bulk-actions-header')); - - expect(bulkActionsCells[0].checked).toBeFalsy(); - expect(bulkActionsCells[1].checked).toBeFalsy(); + render(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0].checked + ).toBeTruthy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1].checked + ).toBeTruthy(); + + fireEvent.click(await screen.findByTestId('bulk-actions-header')); + + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0].checked + ).toBeFalsy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1].checked + ).toBeFalsy(); }); }); describe('and a row is selected', () => { - it('should show the toolbar', () => { - const { queryByTestId, getAllByTestId, getByTestId } = render( - - ); + it('should show the toolbar', async () => { + render(); - expect(queryByTestId('selectedShowBulkActionsButton')).toBeNull(); - expect(queryByTestId('selectAllAlertsButton')).toBeNull(); + expect(screen.queryByTestId('selectedShowBulkActionsButton')).toBeNull(); + expect(screen.queryByTestId('selectAllAlertsButton')).toBeNull(); - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - userEvent.click(bulkActionsCells[0]); + const bulkActionsCells = screen.getAllByTestId( + 'bulk-actions-row-cell' + ) as HTMLInputElement[]; + fireEvent.click(bulkActionsCells[0]); - expect(getByTestId('selectedShowBulkActionsButton')).toBeDefined(); - expect(getByTestId('selectAllAlertsButton')).toBeDefined(); + expect(await screen.findByTestId('selectedShowBulkActionsButton')).toBeDefined(); + expect(await screen.findByTestId('selectAllAlertsButton')).toBeDefined(); }); describe('and the last remaining row is unchecked', () => { @@ -302,7 +319,7 @@ describe('AlertsTable.BulkActions', () => { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, - rowSelection: new Set([0]), + rowSelection: new Map([[0, { isLoading: false }]]), }, }; const { queryByTestId, getAllByTestId, getByTestId } = render( @@ -313,7 +330,7 @@ describe('AlertsTable.BulkActions', () => { expect(getByTestId('selectAllAlertsButton')).toBeDefined(); const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - userEvent.click(bulkActionsCells[0]); + fireEvent.click(bulkActionsCells[0]); expect(queryByTestId('selectAllAlertsButton')).toBeNull(); expect(queryByTestId('selectedShowBulkActionsButton')).toBeNull(); @@ -329,11 +346,10 @@ describe('AlertsTable.BulkActions', () => { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, - rowSelection: new Set([1]), + rowSelection: new Map([[1, { isLoading: false }]]), }, alertsTableConfiguration: { ...alertsTableConfiguration, - useBulkActions: () => [ { label: 'Fake Bulk Action', @@ -346,84 +362,182 @@ describe('AlertsTable.BulkActions', () => { }, }; - const { getByText, getByTestId } = render( - - ); + render(); - userEvent.click(getByTestId('selectedShowBulkActionsButton')); + fireEvent.click(await screen.findByTestId('selectedShowBulkActionsButton')); await waitForEuiPopoverOpen(); - userEvent.click(getByText('Fake Bulk Action')); - expect(mockedFn.mock.calls[0]).toEqual([ - [ - { + fireEvent.click(await screen.findByText('Fake Bulk Action')); + expect(mockedFn.mock.calls[0][0]).toEqual([ + { + _id: 'alert1', + _index: 'idx1', + data: [ + { + field: 'kibana.alert.rule.name', + value: ['three'], + }, + { + field: 'kibana.alert.rule.uuid', + value: ['uuidtwo'], + }, + ], + ecs: { _id: 'alert1', _index: 'idx1', - data: [ - { - field: 'kibana.alert.rule.name', - value: ['three'], - }, + }, + }, + ]); + expect(mockedFn.mock.calls[0][1]).toEqual(false); + expect(mockedFn.mock.calls[0][2]).toBeDefined(); // it's a callback + }); + + describe('and the callback to represent the loading state is executed', () => { + let mockedFn: jest.Mock; + let props: AlertsTableProps; + + beforeEach(() => { + mockedFn = jest.fn(); + props = { + ...tablePropsWithBulkActions, + alertsTableConfiguration: { + ...alertsTableConfiguration, + useBulkActions: () => [ { - field: 'kibana.alert.rule.uuid', - value: ['uuidtwo'], + label: 'Fake Bulk Action', + key: 'fakeBulkAction', + 'data-test-subj': 'fake-bulk-action', + disableOnQuery: false, + onClick: mockedFn, }, ], - ecs: { - _id: 'alert1', - _index: 'idx1', - }, }, - ], - false, - ]); + }; + }); + + it('should show the loading state on each selected row', async () => { + const initialBulkActionsState = { + ...defaultBulkActionsState, + rowSelection: new Map([[1, { isLoading: false }]]), + }; + render( + + ); + fireEvent.click(await screen.findByTestId('selectedShowBulkActionsButton')); + await waitForEuiPopoverOpen(); + + fireEvent.click(await screen.findByText('Fake Bulk Action')); + + // the callback given to our clients to run when they want to update the loading state + mockedFn.mock.calls[0][2](true); + + expect(await screen.findAllByTestId('row-loader')).toHaveLength(1); + const selectedOptions = await screen.findAllByTestId('dataGridRowCell'); + // first row, first column + expect(within(selectedOptions[0]).queryByLabelText('Loading')).not.toBeInTheDocument(); + expect(within(selectedOptions[0]).getByRole('checkbox')).toBeDefined(); + + // second row, first column + expect(within(selectedOptions[4]).getByLabelText('Loading')).toBeDefined(); + expect(within(selectedOptions[4]).queryByRole('checkbox')).not.toBeInTheDocument(); + }); + + it('should hide the loading state on each selected row', async () => { + const initialBulkActionsState = { + ...defaultBulkActionsState, + rowSelection: new Map([[1, { isLoading: true }]]), + }; + render( + + ); + fireEvent.click(await screen.findByTestId('selectedShowBulkActionsButton')); + await waitForEuiPopoverOpen(); + + fireEvent.click(await screen.findByText('Fake Bulk Action')); + + // the callback given to our clients to run when they want to update the loading state + mockedFn.mock.calls[0][2](false); + + expect(screen.queryByTestId('row-loader')).not.toBeInTheDocument(); + }); }); }); describe('and select all is clicked', () => { - it('should check all the visible rows', () => { + it('should check all the visible rows', async () => { const props = { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, - rowSelection: new Set([0]), + rowSelection: new Map([[0, { isLoading: false }]]), }, }; - const { getAllByTestId, getByTestId } = render( - - ); - - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - expect(bulkActionsCells[0].checked).toBeTruthy(); - expect(bulkActionsCells[1].checked).toBeFalsy(); - userEvent.click(getByTestId('selectAllAlertsButton')); - expect(bulkActionsCells[0].checked).toBeTruthy(); - expect(bulkActionsCells[1].checked).toBeTruthy(); + render(); + + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0] + .checked + ).toBeTruthy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1] + .checked + ).toBeFalsy(); + + fireEvent.click(screen.getByTestId('selectAllAlertsButton')); + + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0] + .checked + ).toBeTruthy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1] + .checked + ).toBeTruthy(); }); describe('and clear the selection is clicked', () => { - it('should turn off the toolbar', () => { + it('should turn off the toolbar', async () => { const props = { ...tablePropsWithBulkActions, initialBulkActionsState: { ...defaultBulkActionsState, areAllVisibleRowsSelected: true, isAllSelected: true, - rowSelection: new Set([0, 1]), + rowSelection: new Map([ + [0, { isLoading: false }], + [1, { isLoading: false }], + ]), }, }; - const { getAllByTestId, getByTestId } = render( - - ); - - const bulkActionsCells = getAllByTestId('bulk-actions-row-cell') as HTMLInputElement[]; - expect(bulkActionsCells[0].checked).toBeTruthy(); - expect(bulkActionsCells[1].checked).toBeTruthy(); - userEvent.click(getByTestId('selectAllAlertsButton')); - expect(bulkActionsCells[0].checked).toBeFalsy(); - expect(bulkActionsCells[1].checked).toBeFalsy(); + render(); + + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0] + .checked + ).toBeTruthy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1] + .checked + ).toBeTruthy(); + + fireEvent.click(screen.getByTestId('selectAllAlertsButton')); + + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[0] + .checked + ).toBeFalsy(); + expect( + ((await screen.findAllByTestId('bulk-actions-row-cell')) as HTMLInputElement[])[1] + .checked + ).toBeFalsy(); }); }); @@ -436,7 +550,10 @@ describe('AlertsTable.BulkActions', () => { ...defaultBulkActionsState, isAllSelected: true, rowCount: 2, - rowSelection: new Set([0, 1]), + rowSelection: new Map([ + [0, { isLoading: false }], + [1, { isLoading: false }], + ]), }, alertsTableConfiguration: { ...alertsTableConfiguration, @@ -456,51 +573,50 @@ describe('AlertsTable.BulkActions', () => { ); - userEvent.click(getByTestId('selectedShowBulkActionsButton')); + fireEvent.click(getByTestId('selectedShowBulkActionsButton')); await waitForEuiPopoverOpen(); - userEvent.click(getByText('Fake Bulk Action')); - expect(mockedFn.mock.calls[0]).toEqual([ - [ - { + fireEvent.click(getByText('Fake Bulk Action')); + expect(mockedFn.mock.calls[0][0]).toEqual([ + { + _id: 'alert0', + _index: 'idx0', + data: [ + { + field: 'kibana.alert.rule.name', + value: ['one'], + }, + { + field: 'kibana.alert.rule.uuid', + value: ['uuidone'], + }, + ], + ecs: { _id: 'alert0', _index: 'idx0', - data: [ - { - field: 'kibana.alert.rule.name', - value: ['one'], - }, - { - field: 'kibana.alert.rule.uuid', - value: ['uuidone'], - }, - ], - ecs: { - _id: 'alert0', - _index: 'idx0', - }, }, - { + }, + { + _id: 'alert1', + _index: 'idx1', + data: [ + { + field: 'kibana.alert.rule.name', + value: ['three'], + }, + { + field: 'kibana.alert.rule.uuid', + value: ['uuidtwo'], + }, + ], + ecs: { _id: 'alert1', _index: 'idx1', - data: [ - { - field: 'kibana.alert.rule.name', - value: ['three'], - }, - { - field: 'kibana.alert.rule.uuid', - value: ['uuidtwo'], - }, - ], - ecs: { - _id: 'alert1', - _index: 'idx1', - }, }, - ], - true, + }, ]); + expect(mockedFn.mock.calls[0][1]).toEqual(true); + expect(mockedFn.mock.calls[0][2]).toBeDefined(); }); }); }); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/components/row_cell.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/components/row_cell.tsx index 303141d98b247..75bd47ba1ffad 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/components/row_cell.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/components/row_cell.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { EuiCheckbox } from '@elastic/eui'; +import { EuiCheckbox, EuiLoadingSpinner } from '@elastic/eui'; import React, { ChangeEvent } from 'react'; import { useContext } from 'react'; import { BulkActionsVerbs } from '../../../../../types'; @@ -14,6 +14,11 @@ import { BulkActionsContext } from '../context'; const BulkActionsRowCellComponent = ({ rowIndex }: { rowIndex: number }) => { const [{ rowSelection }, updateSelectedRows] = useContext(BulkActionsContext); const isChecked = rowSelection.has(rowIndex); + const isLoading = isChecked && rowSelection.get(rowIndex)?.isLoading; + + if (isLoading) { + return ; + } return ( void; } // Duplicated just for legacy reasons. Timelines plugin will be removed but @@ -40,9 +41,9 @@ const containerStyles = { display: 'inline-block', position: 'relative' } as con const selectedIdsToTimelineItemMapper = ( alerts: EcsFieldsResponse[], - rowSelection: Set + rowSelection: RowSelection ): TimelineItem[] => { - return Array.from(rowSelection.values()).map((rowIndex: number) => { + return Array.from(rowSelection.keys()).map((rowIndex: number) => { const alert = alerts[rowIndex]; return { _id: alert._id, @@ -61,7 +62,8 @@ const selectedIdsToTimelineItemMapper = ( const useBulkActionsToMenuItemMapper = ( items: BulkActionsConfig[], - alerts: EcsFieldsResponse[] + alerts: EcsFieldsResponse[], + setIsBulkActionsLoading: (loading: boolean) => void ) => { const [{ isAllSelected, rowSelection }] = useContext(BulkActionsContext); @@ -76,25 +78,30 @@ const useBulkActionsToMenuItemMapper = ( disabled={isDisabled} onClick={() => { const selectedAlertIds = selectedIdsToTimelineItemMapper(alerts, rowSelection); - item.onClick(selectedAlertIds, isAllSelected); + item.onClick(selectedAlertIds, isAllSelected, setIsBulkActionsLoading); }} > {isDisabled && item.disabledLabel ? item.disabledLabel : item.label} ); }), - [alerts, isAllSelected, items, rowSelection] + [alerts, isAllSelected, items, rowSelection, setIsBulkActionsLoading] ); return bulkActionsItems; }; -const BulkActionsComponent: React.FC = ({ totalItems, items, alerts }) => { +const BulkActionsComponent: React.FC = ({ + totalItems, + items, + alerts, + setIsBulkActionsLoading, +}) => { const [{ rowSelection, isAllSelected }, updateSelectedRows] = useContext(BulkActionsContext); const [isActionsPopoverOpen, setIsActionsPopoverOpen] = useState(false); const [defaultNumberFormat] = useUiSetting$(DEFAULT_NUMBER_FORMAT); const [showClearSelection, setShowClearSelectiong] = useState(false); - const bulkActionItems = useBulkActionsToMenuItemMapper(items, alerts); + const bulkActionItems = useBulkActionsToMenuItemMapper(items, alerts, setIsBulkActionsLoading); useEffect(() => { setShowClearSelectiong(isAllSelected); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/context.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/context.ts index cafc06a98bb85..85e88815beace 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/context.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/context.ts @@ -6,13 +6,13 @@ */ import { createContext } from 'react'; -import { BulkActionsReducerAction, BulkActionsState } from '../../../../types'; +import { BulkActionsReducerAction, BulkActionsState, RowSelectionState } from '../../../../types'; export const BulkActionsContext = createContext< [BulkActionsState, React.Dispatch] >([ { - rowSelection: new Set(), + rowSelection: new Map(), isAllSelected: false, areAllVisibleRowsSelected: false, rowCount: 0, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/reducer.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/reducer.ts index 4d624dbadfc29..db9c8523fb0af 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/reducer.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/bulk_actions/reducer.ts @@ -7,21 +7,22 @@ import { BulkActionsReducerAction, BulkActionsState, BulkActionsVerbs } from '../../../../types'; -const getAllRowsInPage = (rowCount: number) => new Set(Array.from(Array(rowCount).keys())); +const getAllRowsInPage = (rowCount: number) => + new Map(Array.from(Array(rowCount).keys()).map((idx) => [idx, { isLoading: false }])); export const bulkActionsReducer = ( currentState: BulkActionsState, - { action, rowIndex, rowCount }: BulkActionsReducerAction + { action, rowIndex, rowCount, isLoading = false }: BulkActionsReducerAction ): BulkActionsState => { const { rowSelection, rowCount: currentRowCount } = currentState; const nextState = { ...currentState }; if (action === BulkActionsVerbs.add && rowIndex !== undefined) { - const nextRowSelection = new Set(rowSelection); - nextRowSelection.add(rowIndex); + const nextRowSelection = new Map(rowSelection); + nextRowSelection.set(rowIndex, { isLoading }); nextState.rowSelection = nextRowSelection; } else if (action === BulkActionsVerbs.delete && rowIndex !== undefined) { - const nextRowSelection = new Set(rowSelection); + const nextRowSelection = new Map(rowSelection); nextRowSelection.delete(rowIndex); nextState.rowSelection = nextRowSelection; } else if (action === BulkActionsVerbs.selectCurrentPage) { @@ -30,10 +31,17 @@ export const bulkActionsReducer = ( nextState.rowSelection = getAllRowsInPage(currentRowCount); nextState.isAllSelected = true; } else if (action === BulkActionsVerbs.clear) { - nextState.rowSelection = new Set(); + nextState.rowSelection = new Map(); nextState.isAllSelected = false; } else if (action === BulkActionsVerbs.rowCountUpdate && rowCount !== undefined) { nextState.rowCount = rowCount; + } else if (action === BulkActionsVerbs.updateAllLoadingState) { + const nextRowSelection = new Map( + Array.from(rowSelection.keys()).map((idx: number) => [idx, { isLoading }]) + ); + nextState.rowSelection = nextRowSelection; + } else if (action === BulkActionsVerbs.updateRowLoadingState && rowIndex !== undefined) { + nextState.rowSelection.set(rowIndex, { isLoading }); } nextState.areAllVisibleRowsSelected = nextState.rowSelection.size === nextState.rowCount; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/index.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/index.ts index 6c89cec2d59db..3ce3b5ae5cd9a 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/index.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/index.ts @@ -12,3 +12,4 @@ export type { UseFetchAlerts } from './use_fetch_alerts'; export { useFetchAlerts } from './use_fetch_alerts'; export { DefaultSort } from './constants'; export { useBulkActions } from './use_bulk_actions'; +export { useActionsColumn } from './use_actions_column'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_actions_column.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_actions_column.ts new file mode 100644 index 0000000000000..679fe79b0b036 --- /dev/null +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_actions_column.ts @@ -0,0 +1,48 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { useContext } from 'react'; +import { UseActionsColumnRegistry, BulkActionsVerbs } from '../../../../types'; +import { BulkActionsContext } from '../bulk_actions/context'; + +const DEFAULT_ACTIONS_COLUMNS_WIDTH = 75; + +interface UseActionsColumnProps { + options?: UseActionsColumnRegistry; +} + +export const useActionsColumn = ({ options }: UseActionsColumnProps) => { + const [, updateBulkActionsState] = useContext(BulkActionsContext); + + const useUserActionsColumn = options + ? options + : () => ({ + renderCustomActionsRow: undefined, + width: undefined, + }); + + const { renderCustomActionsRow, width: actionsColumnWidth = DEFAULT_ACTIONS_COLUMNS_WIDTH } = + useUserActionsColumn(); + + // we save the rowIndex when creating the function to be used by the clients + // so they don't have to manage it + const getSetIsActionLoadingCallback = + (rowIndex: number) => + (isLoading: boolean = true) => { + updateBulkActionsState({ + action: BulkActionsVerbs.updateRowLoadingState, + rowIndex, + isLoading, + }); + }; + + return { + renderCustomActionsRow, + actionsColumnWidth, + getSetIsActionLoadingCallback, + }; +}; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_actions.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_actions.ts index 0ea19b93e0915..a6cdfe8af2249 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_actions.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_actions.ts @@ -28,6 +28,7 @@ export interface UseBulkActions { getBulkActionsLeadingControlColumn: GetLeadingControlColumn; bulkActionsState: BulkActionsState; bulkActions: BulkActionsConfig[]; + setIsBulkActionsLoading: (isLoading: boolean) => void; } export function useBulkActions({ @@ -43,10 +44,15 @@ export function useBulkActions({ updateBulkActionsState({ action: BulkActionsVerbs.rowCountUpdate, rowCount: alerts.length }); }, [alerts, updateBulkActionsState]); + const setIsBulkActionsLoading = (isLoading: boolean = true) => { + updateBulkActionsState({ action: BulkActionsVerbs.updateAllLoadingState, isLoading }); + }; + return { isBulkActionsColumnActive, getBulkActionsLeadingControlColumn, bulkActionsState, bulkActions, + setIsBulkActionsLoading, }; } diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/toolbar/toolbar_visibility.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/toolbar/toolbar_visibility.tsx index 3c1d259d0b971..da451195c18a6 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/toolbar/toolbar_visibility.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/toolbar/toolbar_visibility.tsx @@ -13,7 +13,7 @@ import { EcsFieldsResponse } from '@kbn/rule-registry-plugin/common/search_strat import React, { lazy, Suspense } from 'react'; import { BrowserFields } from '@kbn/rule-registry-plugin/common'; import { AlertsCount } from './components/alerts_count/alerts_count'; -import { BulkActionsConfig } from '../../../../types'; +import { BulkActionsConfig, RowSelection } from '../../../../types'; import { LastUpdatedAt } from './components/last_updated_at'; import { FieldBrowser } from '../../field_browser'; @@ -89,11 +89,12 @@ export const getToolbarVisibility = ({ onToggleColumn, onResetColumns, browserFields, + setIsBulkActionsLoading, controls, }: { bulkActions: BulkActionsConfig[]; alertsCount: number; - rowSelection: Set; + rowSelection: RowSelection; alerts: EcsFieldsResponse[]; isLoading: boolean; updatedAt: number; @@ -101,6 +102,7 @@ export const getToolbarVisibility = ({ onToggleColumn: (columnId: string) => void; onResetColumns: () => void; browserFields: any; + setIsBulkActionsLoading: (isLoading: boolean) => void; controls?: EuiDataGridToolBarAdditionalControlsOptions; }): EuiDataGridToolBarVisibilityOptions => { const selectedRowsCount = rowSelection.size; @@ -128,7 +130,12 @@ export const getToolbarVisibility = ({ <> - + ), diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/common/components/with_bulk_rule_api_operations.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/common/components/with_bulk_rule_api_operations.test.tsx index dbe65577844e0..280e7f140f78f 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/common/components/with_bulk_rule_api_operations.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/common/components/with_bulk_rule_api_operations.test.tsx @@ -7,7 +7,7 @@ import * as React from 'react'; import { shallow, mount } from 'enzyme'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { withBulkRuleOperations, ComponentOpts } from './with_bulk_rule_api_operations'; import * as ruleApi from '../../../lib/rule_api'; import { SortField } from '../../../lib/rule_api/load_execution_log_aggregations'; @@ -210,7 +210,7 @@ describe('with_bulk_rule_api_operations', () => { }; const ExtendedComponent = withBulkRuleOperations(ComponentToExtend); - const ruleId = uuid.v4(); + const ruleId = uuidv4(); const component = mount(); component.find('button').simulate('click'); @@ -225,7 +225,7 @@ describe('with_bulk_rule_api_operations', () => { }; const ExtendedComponent = withBulkRuleOperations(ComponentToExtend); - const ruleId = uuid.v4(); + const ruleId = uuidv4(); const component = mount(); component.find('button').simulate('click'); @@ -317,9 +317,9 @@ describe('with_bulk_rule_api_operations', () => { function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/alert_summary_widget.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/alert_summary_widget.test.tsx index 721118c8a8dcf..738076dcb3c34 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/alert_summary_widget.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/alert_summary_widget.test.tsx @@ -10,7 +10,10 @@ import { render } from '@testing-library/react'; import { __IntlProvider as IntlProvider } from '@kbn/i18n-react'; import { AlertSummaryWidget } from './alert_summary_widget'; import { AlertSummaryWidgetProps } from './types'; -import { mockAlertSummaryTimeRange } from '../../../../mock/alert_summary_widget'; +import { + mockedAlertSummaryTimeRange, + mockedChartThemes, +} from '../../../../mock/alert_summary_widget'; import { useLoadAlertSummary } from '../../../../hooks/use_load_alert_summary'; jest.mock('@kbn/kibana-react-plugin/public/ui_settings/use_ui_setting', () => ({ @@ -39,7 +42,7 @@ const useLoadAlertSummaryMock = useLoadAlertSummary as jest.Mock; describe('AlertSummaryWidget', () => { const mockedTimeRange = { - ...mockAlertSummaryTimeRange, + ...mockedAlertSummaryTimeRange, title:

    mockedTimeRangeTitle

    , }; @@ -47,6 +50,7 @@ describe('AlertSummaryWidget', () => { render( {}, timeRange, + chartThemes, }: AlertSummaryWidgetProps) => { const { alertSummary: { activeAlertCount, activeAlerts, recoveredAlertCount, recoveredAlerts }, @@ -41,6 +42,8 @@ export const AlertSummaryWidget = ({ activeAlerts={activeAlerts} recoveredAlertCount={recoveredAlertCount} recoveredAlerts={recoveredAlerts} + dateFormat={timeRange.dateFormat} + chartThemes={chartThemes} /> ) : ( ); }; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_state_info.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_state_info.tsx index 84db4ed4a78cb..440d1613afbe1 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_state_info.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_state_info.tsx @@ -15,16 +15,12 @@ import { EuiText, useEuiTheme, } from '@elastic/eui'; -import { - EUI_CHARTS_THEME_DARK, - EUI_CHARTS_THEME_LIGHT, - EUI_SPARKLINE_THEME_PARTIAL, -} from '@elastic/eui/dist/eui_charts_theme'; -import { useUiSetting } from '@kbn/kibana-react-plugin/public'; +import { EUI_SPARKLINE_THEME_PARTIAL } from '@elastic/eui/dist/eui_charts_theme'; import React from 'react'; -import { Alert } from '../../../../../hooks/use_load_alert_summary'; +import { Alert, ChartThemes } from '../types'; interface AlertStateInfoProps { + chartThemes: ChartThemes; count: number; data: Alert[]; dataTestSubj: string; @@ -41,14 +37,14 @@ export const AlertStateInfo = ({ domain, id, stroke, + chartThemes: { theme, baseTheme }, title, }: AlertStateInfoProps) => { - const isDarkMode = useUiSetting('theme:darkMode'); const { euiTheme } = useEuiTheme(); - const theme = [ + const chartTheme = [ + theme, EUI_SPARKLINE_THEME_PARTIAL, { - ...(isDarkMode ? EUI_CHARTS_THEME_DARK.theme : EUI_CHARTS_THEME_LIGHT.theme), chartMargins: { left: 10, right: 10, @@ -62,7 +58,7 @@ export const AlertStateInfo = ({ -

    {count}

    +

    {count}

    {title} @@ -70,7 +66,7 @@ export const AlertStateInfo = ({
    - + void; } export const AlertsSummaryWidgetCompact = ({ activeAlertCount, activeAlerts, + chartThemes, recoveredAlertCount, recoveredAlerts, timeRangeTitle, @@ -88,11 +90,13 @@ export const AlertsSummaryWidgetCompact = ({ onClick={(event: React.MouseEvent) => handleClick(event, ALERT_STATUS_ACTIVE) } + data-test-subj="activeAlerts" > ) => handleClick(event, ALERT_STATUS_RECOVERED) } + data-test-subj="recoveredAlerts" > ({ useUiSetting: jest.fn(() => false), @@ -20,7 +23,11 @@ describe('AlertSummaryWidgetFullSize', () => { const renderComponent = (props: Partial = {}) => render( - + ); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_summary_widget_full_size.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_summary_widget_full_size.tsx index 4d8d7cc564e22..e1e3815a159c0 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_summary_widget_full_size.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/alert_summary/components/alert_summary_widget_full_size.tsx @@ -5,12 +5,6 @@ * 2.0. */ -import { - EUI_CHARTS_THEME_DARK, - EUI_CHARTS_THEME_LIGHT, - EUI_SPARKLINE_THEME_PARTIAL, -} from '@elastic/eui/dist/eui_charts_theme'; -import { useUiSetting } from '@kbn/kibana-react-plugin/public'; import moment from 'moment'; import React from 'react'; import { Axis, Chart, CurveType, LineSeries, Position, ScaleType, Settings } from '@elastic/charts'; @@ -23,32 +17,31 @@ import { RECOVERED_COLOR, TOOLTIP_DATE_FORMAT, } from './constants'; -import { Alert } from '../../../../../hooks/use_load_alert_summary'; +import { Alert, ChartThemes } from '../types'; export interface AlertsSummaryWidgetFullSizeProps { activeAlertCount: number; activeAlerts: Alert[]; + chartThemes: ChartThemes; recoveredAlertCount: number; recoveredAlerts: Alert[]; + dateFormat?: string; } export const AlertsSummaryWidgetFullSize = ({ activeAlertCount, activeAlerts, + chartThemes: { theme, baseTheme }, + dateFormat, recoveredAlertCount, recoveredAlerts, }: AlertsSummaryWidgetFullSizeProps) => { - const isDarkMode = useUiSetting('theme:darkMode'); const { euiTheme } = useEuiTheme(); const chartTheme = [ - EUI_SPARKLINE_THEME_PARTIAL, + theme, { - ...(isDarkMode ? EUI_CHARTS_THEME_DARK.theme : EUI_CHARTS_THEME_LIGHT.theme), - chartMargins: { - left: 10, - right: 10, - top: 10, - bottom: 10, + chartPaddings: { + top: 7, }, }, ]; @@ -103,10 +96,11 @@ export const AlertsSummaryWidgetFullSize = ({ moment(tooltip.value).format(TOOLTIP_DATE_FORMAT), + headerFormatter: (tooltip) => + moment(tooltip.value).format(dateFormat || TOOLTIP_DATE_FORMAT), }} /> void; timeRange: AlertSummaryTimeRange; + chartThemes: ChartThemes; } diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_action_error_log_flyout.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_action_error_log_flyout.test.tsx index dee90d8ceb9f0..d306b53a232a7 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_action_error_log_flyout.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_action_error_log_flyout.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { act } from 'react-dom/test-utils'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; import { RuleActionErrorLogFlyout } from './rule_action_error_log_flyout'; @@ -43,8 +43,8 @@ const mockErrorLogResponse = { }; const mockExecution: any = { - id: uuid.v4(), - rule_id: uuid.v4(), + id: uuidv4(), + rule_id: uuidv4(), timestamp: '2022-03-20T07:40:44-07:00', duration: 5000000, status: 'success', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details.test.tsx index 54830bd09fe56..4318412fe5261 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details.test.tsx @@ -6,7 +6,7 @@ */ import * as React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { shallow } from 'enzyme'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; import { act } from '@testing-library/react'; @@ -193,7 +193,7 @@ describe('rule_details', () => { actions: [ { group: 'default', - id: uuid.v4(), + id: uuidv4(), params: {}, actionTypeId: '.server-log', }, @@ -231,13 +231,13 @@ describe('rule_details', () => { actions: [ { group: 'default', - id: uuid.v4(), + id: uuidv4(), params: {}, actionTypeId: '.server-log', }, { group: 'default', - id: uuid.v4(), + id: uuidv4(), params: {}, actionTypeId: '.email', }, @@ -355,7 +355,7 @@ describe('rule_details', () => { actions: [ { group: 'default', - id: uuid.v4(), + id: uuidv4(), params: {}, actionTypeId: '.server-log', }, @@ -395,7 +395,7 @@ describe('rule_details', () => { actions: [ { group: 'default', - id: uuid.v4(), + id: uuidv4(), params: {}, actionTypeId: '.server-log', }, @@ -796,9 +796,9 @@ describe('rule_details', () => { function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: ALERTS_FEATURE_ID, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details_route.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details_route.test.tsx index 46d127479031f..1d0be2b9ae834 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details_route.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_details_route.test.tsx @@ -6,7 +6,7 @@ */ import * as React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { shallow } from 'enzyme'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; import { act } from 'react-dom/test-utils'; @@ -153,7 +153,7 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -204,7 +204,7 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -247,7 +247,7 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -293,7 +293,7 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -343,7 +343,7 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -351,7 +351,7 @@ describe('getRuleData useEffect handler', () => { }); const ruleType = { - id: uuid.v4(), + id: uuidv4(), name: 'type name', }; @@ -396,13 +396,13 @@ describe('getRuleData useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: availableConnectorType.id, params: {}, }, { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: missingConnectorType.id, params: {}, }, @@ -410,7 +410,7 @@ describe('getRuleData useEffect handler', () => { }); const ruleType = { - id: uuid.v4(), + id: uuidv4(), name: 'type name', }; @@ -472,9 +472,9 @@ function mockRouterProps(rule: Rule) { } function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_event_log_list.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_event_log_list.test.tsx index 96d9c0013fe4e..00e702fb42e75 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_event_log_list.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_event_log_list.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { act } from 'react-dom/test-utils'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; import { useKibana } from '../../../../common/lib/kibana'; @@ -634,7 +634,7 @@ describe.skip('rule_event_log_list', () => { loadExecutionLogAggregationsMock.mockResolvedValue({ data: [ { - id: uuid.v4(), + id: uuidv4(), timestamp: '2022-03-20T07:40:44-07:00', duration: 5000000, status: 'success', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_route.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_route.test.tsx index a29fc2a2ee9a3..ab8d28d4a0c0e 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_route.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/rule_route.test.tsx @@ -6,7 +6,7 @@ */ import * as React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { shallow } from 'enzyme'; import { ToastsApi } from '@kbn/core/public'; import { RuleRoute, getRuleSummary } from './rule_route'; @@ -63,7 +63,7 @@ describe('getRuleState useEffect handler', () => { actions: [ { group: '', - id: uuid.v4(), + id: uuidv4(), actionTypeId: connectorType.id, params: {}, }, @@ -103,9 +103,9 @@ function mockStateSetter() { function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/test_helpers.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/test_helpers.ts index b7a6876535a64..6cc06dbd80d40 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/test_helpers.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/test_helpers.ts @@ -5,12 +5,12 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Rule, RuleSummary, RuleType } from '../../../../types'; export const getMockLogResponse = () => { return { - id: uuid.v4(), + id: uuidv4(), timestamp: '2022-03-20T07:40:44-07:00', duration: 5000000, status: 'success', @@ -36,9 +36,9 @@ export const mockLogResponse: any = { export function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/view_in_app.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/view_in_app.test.tsx index ee29facf60579..7744846863bec 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/view_in_app.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_details/components/view_in_app.test.tsx @@ -6,7 +6,7 @@ */ import * as React from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { mount, ReactWrapper } from 'enzyme'; import { act } from 'react-dom/test-utils'; @@ -71,9 +71,9 @@ function waitForUseEffect() { function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_add.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_add.test.tsx index 4b1b4330b9071..5467dc38c35fb 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_add.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_add.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import React, { FunctionComponent } from 'react'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; import { act } from 'react-dom/test-utils'; @@ -370,9 +370,9 @@ describe('rule_add', () => { function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_errors.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_errors.test.tsx index 9747e42dcf3ca..babd4ce594b8c 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_errors.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rule_form/rule_errors.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import React, { Fragment } from 'react'; import { validateBaseProperties, @@ -244,9 +244,9 @@ function mockRuleTypeModel(overloads: Partial = {}): RuleTypeMode function mockRule(overloads: Partial = {}): Rule { return { - id: uuid.v4(), + id: uuidv4(), enabled: true, - name: `rule-${uuid.v4()}`, + name: `rule-${uuidv4()}`, tags: [], ruleTypeId: '.noop', consumer: 'consumer', diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rule_snooze/scheduler.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rule_snooze/scheduler.tsx index 4b559e262424d..7ef4aefecc28c 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rule_snooze/scheduler.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rule_snooze/scheduler.tsx @@ -9,7 +9,7 @@ import React, { useState, useCallback, useMemo } from 'react'; import moment, { Moment } from 'moment'; import { i18n } from '@kbn/i18n'; import { useUiSetting } from '@kbn/kibana-react-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { EuiDatePicker, EuiDatePickerRange, @@ -224,7 +224,7 @@ const RuleSnoozeSchedulerPanel: React.FunctionComponent = ({ count: 1, }; onSaveSchedule({ - id: initialSchedule?.id ?? uuid.v4(), + id: initialSchedule?.id ?? uuidv4(), rRule: { dtstart: startDT.toISOString(), tzid: selectedTimezone[0].label ?? defaultTz, diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rules_list.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rules_list.tsx index d87a1d4f3a831..360d54c6e4bf0 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rules_list.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/rules_list/components/rules_list.tsx @@ -97,6 +97,7 @@ import { MULTIPLE_RULE_TITLE, } from '../translations'; import { useBulkOperationToast } from '../../../hooks/use_bulk_operation_toast'; +import { RulesSettingsLink } from '../../../components/rules_setting/rules_settings_link'; import { useRulesListUiState as useUiState } from '../../../hooks/use_rules_list_ui_state'; // Directly lazy import the flyouts because the suspendedComponentWithProps component @@ -614,11 +615,15 @@ export const RulesList = ({ if (!setHeaderActions) return; if (showHeaderWithoutCreateButton) { - setHeaderActions([]); + setHeaderActions([, ]); return; } if (showHeaderWithCreateButton) { - setHeaderActions([, ]); + setHeaderActions([ + , + , + , + ]); return; } setHeaderActions(); diff --git a/x-pack/plugins/triggers_actions_ui/public/index.ts b/x-pack/plugins/triggers_actions_ui/public/index.ts index 23057e35fdef3..6763f9b1921d7 100644 --- a/x-pack/plugins/triggers_actions_ui/public/index.ts +++ b/x-pack/plugins/triggers_actions_ui/public/index.ts @@ -41,6 +41,7 @@ export type { FieldBrowserProps, RuleDefinitionProps, RulesListVisibleColumns, + AlertSummaryTimeRange, } from './types'; export type { diff --git a/x-pack/plugins/triggers_actions_ui/public/types.ts b/x-pack/plugins/triggers_actions_ui/public/types.ts index 4954c12e252a7..d35db04f58b88 100644 --- a/x-pack/plugins/triggers_actions_ui/public/types.ts +++ b/x-pack/plugins/triggers_actions_ui/public/types.ts @@ -68,6 +68,7 @@ import type { RuleEventLogListProps, RuleEventLogListOptions, } from './application/sections/rule_details/components/rule_event_log_list'; +import { AlertSummaryTimeRange } from './application/sections/rule_details/components/alert_summary/types'; import type { CreateConnectorFlyoutProps } from './application/sections/action_connector_form/create_connector_flyout'; import type { EditConnectorFlyoutProps } from './application/sections/action_connector_form/edit_connector_flyout'; import type { RulesListNotifyBadgeProps } from './application/sections/rules_list/components/rules_list_notify_badge'; @@ -129,6 +130,7 @@ export type { GetFieldTableColumns, BrowserFieldItem, RulesListVisibleColumns, + AlertSummaryTimeRange, }; export type { ActionType, AsApiContract }; export { @@ -509,9 +511,23 @@ export interface BulkActionsConfig { 'data-test-subj'?: string; disableOnQuery: boolean; disabledLabel?: string; - onClick: (selectedIds: TimelineItem[], isAllSelected: boolean) => void; + onClick: ( + selectedIds: TimelineItem[], + isAllSelected: boolean, + setIsBulkActionsLoading: (isLoading: boolean) => void + ) => void; } +export type UseActionsColumnRegistry = () => { + renderCustomActionsRow: ( + alert: EcsFieldsResponse, + setFlyoutAlert: (data: unknown) => void, + id?: string, + setIsActionLoading?: (isLoading: boolean) => void + ) => JSX.Element; + width?: number; +}; + export type UseBulkActionsRegistry = () => BulkActionsConfig[]; export interface AlertsTableConfigurationRegistry { @@ -525,14 +541,7 @@ export interface AlertsTableConfigurationRegistry { }; sort?: SortCombinations[]; getRenderCellValue?: GetRenderCellValue; - useActionsColumn?: () => { - renderCustomActionsRow: ( - alert: EcsFieldsResponse, - setFlyoutAlert: (data: unknown) => void, - id?: string - ) => JSX.Element; - width?: number; - }; + useActionsColumn?: UseActionsColumnRegistry; useBulkActions?: UseBulkActionsRegistry; usePersistentControls?: () => { right?: ReactNode; @@ -546,21 +555,30 @@ export enum BulkActionsVerbs { selectCurrentPage = 'selectCurrentPage', selectAll = 'selectAll', rowCountUpdate = 'rowCountUpdate', + updateRowLoadingState = 'updateRowLoadingState', + updateAllLoadingState = 'updateAllLoadingState', } export interface BulkActionsReducerAction { action: BulkActionsVerbs; rowIndex?: number; rowCount?: number; + isLoading?: boolean; } export interface BulkActionsState { - rowSelection: Set; + rowSelection: Map; isAllSelected: boolean; areAllVisibleRowsSelected: boolean; rowCount: number; } +export type RowSelection = Map; + +export interface RowSelectionState { + isLoading: boolean; +} + export type RuleStatus = 'enabled' | 'disabled' | 'snoozed'; export enum RRuleFrequency { diff --git a/x-pack/plugins/upgrade_assistant/public/application/components/kibana_deprecations/kibana_deprecations.tsx b/x-pack/plugins/upgrade_assistant/public/application/components/kibana_deprecations/kibana_deprecations.tsx index 33a29ff15864c..aa5a0cc27c939 100644 --- a/x-pack/plugins/upgrade_assistant/public/application/components/kibana_deprecations/kibana_deprecations.tsx +++ b/x-pack/plugins/upgrade_assistant/public/application/components/kibana_deprecations/kibana_deprecations.tsx @@ -6,7 +6,7 @@ */ import React, { useEffect, useState, useCallback, useMemo } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { withRouter, RouteComponentProps } from 'react-router-dom'; import { EuiPageContent_Deprecated as EuiPageContent, @@ -140,7 +140,7 @@ export const KibanaDeprecations = withRouter(({ history }: RouteComponentProps) // Only show deprecations in the table that fetched successfully filteredDeprecations.push({ ...deprecation, - id: uuid.v4(), // Associate an unique ID with each deprecation to track resolution state + id: uuidv4(), // Associate an unique ID with each deprecation to track resolution state filterType: deprecation.deprecationType ?? 'uncategorized', // deprecationType is currently optional, in order to correctly handle sort/filter, we default any undefined types to "uncategorized" }); }); diff --git a/x-pack/plugins/ux/public/components/app/rum_dashboard/charts/visitor_breakdown_chart.tsx b/x-pack/plugins/ux/public/components/app/rum_dashboard/charts/visitor_breakdown_chart.tsx index 87c3779365677..d9475932296f4 100644 --- a/x-pack/plugins/ux/public/components/app/rum_dashboard/charts/visitor_breakdown_chart.tsx +++ b/x-pack/plugins/ux/public/components/app/rum_dashboard/charts/visitor_breakdown_chart.tsx @@ -17,7 +17,7 @@ import { import { EuiText } from '@elastic/eui'; import { ProcessorEvent } from '@kbn/observability-plugin/common'; import { DataView } from '@kbn/data-views-plugin/public'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { TRANSACTION_PAGE_LOAD } from '../../../../../common/transaction_types'; import { PROCESSOR_EVENT, @@ -58,7 +58,7 @@ export function VisitorBreakdownChart({ }: Props) { const kibana = useKibanaServices(); const LensEmbeddableComponent = kibana.lens.EmbeddableComponent; - const [localDataViewId] = useState(uuid.v4()); + const [localDataViewId] = useState(uuidv4()); const lensAttributes = useMemo( () => diff --git a/x-pack/plugins/ux/public/components/app/rum_dashboard/visitor_breakdown_map/embedded_map.tsx b/x-pack/plugins/ux/public/components/app/rum_dashboard/visitor_breakdown_map/embedded_map.tsx index a89320ee02ae5..219eb75494068 100644 --- a/x-pack/plugins/ux/public/components/app/rum_dashboard/visitor_breakdown_map/embedded_map.tsx +++ b/x-pack/plugins/ux/public/components/app/rum_dashboard/visitor_breakdown_map/embedded_map.tsx @@ -6,7 +6,7 @@ */ import React, { useEffect, useState, useRef } from 'react'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import styled from 'styled-components'; import { MapEmbeddable, MapEmbeddableInput } from '@kbn/maps-plugin/public'; @@ -66,7 +66,7 @@ export function EmbeddedMapComponent() { const input: MapEmbeddableInput = { attributes: { title: '' }, - id: uuid.v4(), + id: uuidv4(), filters: mapFilters, viewMode: ViewMode.VIEW, isLayerTOCOpen: false, diff --git a/x-pack/plugins/watcher/__jest__/client_integration/watch_create_threshold_page.test.tsx b/x-pack/plugins/watcher/__jest__/client_integration/watch_create_threshold_page.test.tsx index 034b5542137c6..d7df7efd7be12 100644 --- a/x-pack/plugins/watcher/__jest__/client_integration/watch_create_threshold_page.test.tsx +++ b/x-pack/plugins/watcher/__jest__/client_integration/watch_create_threshold_page.test.tsx @@ -26,14 +26,12 @@ const ES_FIELDS = [{ name: '@timestamp', type: 'date' }]; // Since watchID's are dynamically created, we have to mock // the function that generates them in order to be able to match // against it. -jest.mock('uuid/v4', () => { - // eslint-disable-next-line @typescript-eslint/no-var-requires - const { WATCH_ID: watchId } = require('./helpers/jest_constants'); - - return function () { - return watchId; - }; -}); +jest.mock('uuid', () => ({ + v4: () => { + // eslint-disable-next-line @typescript-eslint/no-var-requires + return require('./helpers/jest_constants').WATCH_ID; + }, +})); const SETTINGS = { action_types: { diff --git a/x-pack/plugins/watcher/public/application/models/watch/json_watch.js b/x-pack/plugins/watcher/public/application/models/watch/json_watch.js index b55765e9f536f..01dcce0b67842 100644 --- a/x-pack/plugins/watcher/public/application/models/watch/json_watch.js +++ b/x-pack/plugins/watcher/public/application/models/watch/json_watch.js @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { get } from 'lodash'; import { i18n } from '@kbn/i18n'; @@ -19,7 +19,7 @@ import { defaultWatch } from './default_watch'; export class JsonWatch extends BaseWatch { constructor(props = {}) { props.type = WATCH_TYPES.JSON; - props.id = typeof props.id === 'undefined' ? uuid.v4() : props.id; + props.id = typeof props.id === 'undefined' ? uuidv4() : props.id; super(props); const existingWatch = get(props, 'watch'); this.watch = existingWatch ? existingWatch : defaultWatch; diff --git a/x-pack/plugins/watcher/public/application/models/watch/threshold_watch.js b/x-pack/plugins/watcher/public/application/models/watch/threshold_watch.js index 4aa8d18b8af53..a2ab997932b96 100644 --- a/x-pack/plugins/watcher/public/application/models/watch/threshold_watch.js +++ b/x-pack/plugins/watcher/public/application/models/watch/threshold_watch.js @@ -6,7 +6,7 @@ */ import { BaseWatch } from './base_watch'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { WATCH_TYPES, SORT_ORDERS, COMPARATORS } from '../../../../common/constants'; import { getTimeUnitLabel } from '../../lib/get_time_unit_label'; import { i18n } from '@kbn/i18n'; @@ -31,7 +31,7 @@ const DEFAULT_VALUES = { */ export class ThresholdWatch extends BaseWatch { constructor(props = {}) { - props.id = props.id || uuid.v4(); + props.id = props.id || uuidv4(); props.type = WATCH_TYPES.THRESHOLD; super(props); diff --git a/x-pack/test/accessibility/apps/cross_cluster_replication.ts b/x-pack/test/accessibility/apps/cross_cluster_replication.ts index 8081c8fd142b0..bc81770de9f4b 100644 --- a/x-pack/test/accessibility/apps/cross_cluster_replication.ts +++ b/x-pack/test/accessibility/apps/cross_cluster_replication.ts @@ -53,9 +53,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { ); }); it('follower index flyout', async () => { - // https://github.com/elastic/kibana/issues/135503 - // Skipping this snapshot because there is an existing a11y violation. - // await a11y.testAppSnapshot(); + await a11y.testAppSnapshot(); await testSubjects.click('closeFlyoutButton'); await retry.waitFor('follower index table to be visible', async () => { return await (await find.byCssSelector('table')).isDisplayed(); @@ -86,9 +84,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { ); }); it('auto follower index flyout', async () => { - // https://github.com/elastic/kibana/issues/135506 - // Skipping this snapshot because there is an existing a11y violation. - // await a11y.testAppSnapshot(); + await a11y.testAppSnapshot(); await testSubjects.click('closeFlyoutButton'); await retry.waitFor('auto follower index table to be visible', async () => { return await (await find.byCssSelector('table')).isDisplayed(); diff --git a/x-pack/test/accessibility/apps/dashboard_panel_options.ts b/x-pack/test/accessibility/apps/dashboard_panel_options.ts index 5f323ee092dbc..da66f03054b08 100644 --- a/x-pack/test/accessibility/apps/dashboard_panel_options.ts +++ b/x-pack/test/accessibility/apps/dashboard_panel_options.ts @@ -80,7 +80,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { }); it('dashboard panel- more options in view mode', async () => { - await dashboardPanelActions.toggleContextMenu(header); await dashboardPanelActions.openContextMenuMorePanel(header); await a11y.testAppSnapshot(); }); @@ -89,7 +88,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { await dashboardPanelActions.openContextMenuMorePanel(header); await dashboardPanelActions.clickExpandPanelToggle(); await a11y.testAppSnapshot(); - await dashboardPanelActions.toggleContextMenu(header); await dashboardPanelActions.openContextMenuMorePanel(header); await dashboardPanelActions.clickExpandPanelToggle(); }); diff --git a/x-pack/test/accessibility/apps/snapshot_and_restore.ts b/x-pack/test/accessibility/apps/snapshot_and_restore.ts index aac70396b461d..c5f0f52c9c9fe 100644 --- a/x-pack/test/accessibility/apps/snapshot_and_restore.ts +++ b/x-pack/test/accessibility/apps/snapshot_and_restore.ts @@ -106,9 +106,8 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { await a11y.testAppSnapshot(); }); it('submit page four and flyout', async () => { - // Commenting out this snapshot as this is reported. https://github.com/elastic/kibana/issues/134514 await PageObjects.snapshotRestore.submitNewPolicy(); - // await a11y.testAppSnapshot(); + await a11y.testAppSnapshot(); }); it('policy table with data', async () => { await PageObjects.snapshotRestore.closeFlyout(); diff --git a/x-pack/test/alerting_api_integration/common/plugins/alerts/server/alert_types.ts b/x-pack/test/alerting_api_integration/common/plugins/alerts/server/alert_types.ts index b13499e72dbe7..9360441c3d5ac 100644 --- a/x-pack/test/alerting_api_integration/common/plugins/alerts/server/alert_types.ts +++ b/x-pack/test/alerting_api_integration/common/plugins/alerts/server/alert_types.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Logger } from '@kbn/logging'; import { CoreSetup } from '@kbn/core/server'; import { schema, TypeOf } from '@kbn/config-schema'; @@ -293,7 +293,7 @@ function getExceedsAlertLimitRuleType() { const alertsToCreate = limit ? limit : 25; range(alertsToCreate) - .map(() => uuid.v4()) + .map(() => uuidv4()) .forEach((id: string) => { services.alertFactory.create(id).scheduleActions('default'); }); diff --git a/x-pack/test/alerting_api_integration/common/plugins/alerts/server/routes.ts b/x-pack/test/alerting_api_integration/common/plugins/alerts/server/routes.ts index 783bf6a89a0b9..135d3c02b9f8f 100644 --- a/x-pack/test/alerting_api_integration/common/plugins/alerts/server/routes.ts +++ b/x-pack/test/alerting_api_integration/common/plugins/alerts/server/routes.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { CoreSetup, RequestHandlerContext, @@ -326,14 +326,14 @@ export function defineRoutes( const createAPIKeyResult = security && (await security.authc.apiKeys.grantAsInternalUser(req, { - name: `alerts_fixture:enqueue_action:${uuid.v4()}`, + name: `alerts_fixture:enqueue_action:${uuidv4()}`, role_descriptors: {}, })); await actionsClient.enqueueExecution({ id: req.params.id, spaceId: spaces ? spaces.spacesService.getSpaceId(req) : 'default', - executionId: uuid.v4(), + executionId: uuidv4(), apiKey: createAPIKeyResult ? Buffer.from(`${createAPIKeyResult.id}:${createAPIKeyResult.api_key}`).toString( 'base64' diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/disable.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/disable.ts index df9fc34e17014..a645d89998093 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/disable.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/disable.ts @@ -26,7 +26,8 @@ export default function createDisableAlertTests({ getService }: FtrProviderConte const supertest = getService('supertest'); const supertestWithoutAuth = getService('supertestWithoutAuth'); - describe('disable', () => { + // Failing: See https://github.com/elastic/kibana/issues/141849 + describe.skip('disable', () => { const objectRemover = new ObjectRemover(supertest); after(() => objectRemover.removeAll()); diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find.ts index 156a39577e60b..b4fbd37d5a1e8 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find.ts @@ -8,7 +8,7 @@ import expect from '@kbn/expect'; import { SuperTest, Test } from 'supertest'; import { chunk, omit } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { UserAtSpaceScenarios } from '../../../scenarios'; import { getUrlPrefix, getTestRuleData, ObjectRemover } from '../../../../common/lib'; import { FtrProviderContext } from '../../../../common/ftr_provider_context'; @@ -315,7 +315,7 @@ const findTestUtils = ( }); it('should handle find alert request with fields appropriately', async () => { - const myTag = uuid.v4(); + const myTag = uuidv4(); const { body: createdAlert } = await supertest .post(`${getUrlPrefix(space.id)}/api/alerting/rule`) .set('kbn-xsrf', 'foo') @@ -398,7 +398,7 @@ const findTestUtils = ( }); it('should handle find alert request with executionStatus field appropriately', async () => { - const myTag = uuid.v4(); + const myTag = uuidv4(); const { body: createdAlert } = await supertest .post(`${getUrlPrefix(space.id)}/api/alerting/rule`) .set('kbn-xsrf', 'foo') diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find_with_post.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find_with_post.ts index e3ee01c3271ec..4bb1c43a29b52 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find_with_post.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group1/tests/alerting/find_with_post.ts @@ -8,7 +8,7 @@ import expect from '@kbn/expect'; import { SuperTest, Test } from 'supertest'; import { chunk, omit } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { UserAtSpaceScenarios } from '../../../scenarios'; import { getUrlPrefix, getTestRuleData, ObjectRemover } from '../../../../common/lib'; import { FtrProviderContext } from '../../../../common/ftr_provider_context'; @@ -329,7 +329,7 @@ const findTestUtils = ( }); it('should handle find alert request with fields appropriately', async () => { - const myTag = uuid.v4(); + const myTag = uuidv4(); const { body: createdAlert } = await supertest .post(`${getUrlPrefix(space.id)}/api/alerting/rule`) .set('kbn-xsrf', 'foo') @@ -418,7 +418,7 @@ const findTestUtils = ( }); it('should handle find alert request with executionStatus field appropriately', async () => { - const myTag = uuid.v4(); + const myTag = uuidv4(); const { body: createdAlert } = await supertest .post(`${getUrlPrefix(space.id)}/api/alerting/rule`) .set('kbn-xsrf', 'foo') diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group2/tests/alerting/alerts.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group2/tests/alerting/alerts.ts index 9ddaf8c660d40..9fb84117347df 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/group2/tests/alerting/alerts.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group2/tests/alerting/alerts.ts @@ -33,7 +33,8 @@ export default function alertTests({ getService }: FtrProviderContext) { const esTestIndexTool = new ESTestIndexTool(es, retry); const taskManagerUtils = new TaskManagerUtils(es, retry); - describe('alerts', () => { + // FLAKY: https://github.com/elastic/kibana/issues/148092 + describe.skip('alerts', () => { const authorizationIndex = '.kibana-test-authorization'; const alertAsDataIndex = '.internal.alerts-observability.test.alerts.alerts-default-000001'; const objectRemover = new ObjectRemover(supertest); diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/get_flapping_settings.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/get_flapping_settings.ts new file mode 100644 index 0000000000000..80e0a3e4a5986 --- /dev/null +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/get_flapping_settings.ts @@ -0,0 +1,60 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { DEFAULT_FLAPPING_SETTINGS } from '@kbn/alerting-plugin/common'; +import { UserAtSpaceScenarios } from '../../../scenarios'; +import { getUrlPrefix } from '../../../../common/lib'; +import { FtrProviderContext } from '../../../../common/ftr_provider_context'; + +// eslint-disable-next-line import/no-default-export +export default function getFlappingSettingsTests({ getService }: FtrProviderContext) { + const supertestWithoutAuth = getService('supertestWithoutAuth'); + + describe('getFlappingSettings', () => { + for (const scenario of UserAtSpaceScenarios) { + const { user, space } = scenario; + describe(scenario.id, () => { + it('should handle get flapping settings request appropriately', async () => { + const response = await supertestWithoutAuth + .get(`${getUrlPrefix(space.id)}/internal/alerting/rules/settings/_flapping`) + .auth(user.username, user.password); + + switch (scenario.id) { + case 'no_kibana_privileges at space1': + case 'space_1_all at space2': + case 'space_1_all_with_restricted_fixture at space1': + case 'space_1_all_alerts_none_actions at space1': + expect(response.statusCode).to.eql(403); + expect(response.body).to.eql({ + error: 'Forbidden', + message: 'Forbidden', + statusCode: 403, + }); + break; + case 'global_read at space1': + case 'superuser at space1': + case 'space_1_all at space1': + expect(response.statusCode).to.eql(200); + expect(response.body.enabled).to.eql(DEFAULT_FLAPPING_SETTINGS.enabled); + expect(response.body.lookBackWindow).to.eql(DEFAULT_FLAPPING_SETTINGS.lookBackWindow); + expect(response.body.statusChangeThreshold).to.eql( + DEFAULT_FLAPPING_SETTINGS.statusChangeThreshold + ); + expect(response.body.createdBy).to.be.a('string'); + expect(response.body.updatedBy).to.be.a('string'); + expect(Date.parse(response.body.createdAt)).to.be.greaterThan(0); + expect(Date.parse(response.body.updatedAt)).to.be.greaterThan(0); + break; + default: + throw new Error(`Scenario untested: ${JSON.stringify(scenario)}`); + } + }); + }); + } + }); +} diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/index.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/index.ts index 0dd1ec2531733..0c6b4f815c9dc 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/index.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/index.ts @@ -25,6 +25,8 @@ export default function alertingTests({ loadTestFile, getService }: FtrProviderC loadTestFile(require.resolve('./bulk_enable')); loadTestFile(require.resolve('./bulk_disable')); loadTestFile(require.resolve('./clone')); + loadTestFile(require.resolve('./get_flapping_settings')); + loadTestFile(require.resolve('./update_flapping_settings')); }); }); } diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/update_flapping_settings.ts b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/update_flapping_settings.ts new file mode 100644 index 0000000000000..29c82ee5e642e --- /dev/null +++ b/x-pack/test/alerting_api_integration/security_and_spaces/group3/tests/alerting/update_flapping_settings.ts @@ -0,0 +1,154 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { DEFAULT_FLAPPING_SETTINGS } from '@kbn/alerting-plugin/common'; +import { UserAtSpaceScenarios, Superuser } from '../../../scenarios'; +import { getUrlPrefix } from '../../../../common/lib'; +import { FtrProviderContext } from '../../../../common/ftr_provider_context'; + +const resetRulesSettings = (supertestWithoutAuth: any, space: string) => { + return supertestWithoutAuth + .post(`${getUrlPrefix(space)}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(Superuser.username, Superuser.password) + .send(DEFAULT_FLAPPING_SETTINGS); +}; + +// eslint-disable-next-line import/no-default-export +export default function updateFlappingSettingsTest({ getService }: FtrProviderContext) { + const supertestWithoutAuth = getService('supertestWithoutAuth'); + + describe('updateFlappingSettings', () => { + afterEach(async () => { + await resetRulesSettings(supertestWithoutAuth, 'space1'); + await resetRulesSettings(supertestWithoutAuth, 'space2'); + }); + + for (const scenario of UserAtSpaceScenarios) { + const { user, space } = scenario; + describe(scenario.id, () => { + it('should handle update flapping settings request appropriately', async () => { + const response = await supertestWithoutAuth + .post(`${getUrlPrefix(space.id)}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(user.username, user.password) + .send({ + enabled: false, + lookBackWindow: 20, + statusChangeThreshold: 20, + }); + + switch (scenario.id) { + case 'no_kibana_privileges at space1': + case 'global_read at space1': + case 'space_1_all at space2': + case 'space_1_all_with_restricted_fixture at space1': + case 'space_1_all_alerts_none_actions at space1': + expect(response.statusCode).to.eql(403); + expect(response.body).to.eql({ + error: 'Forbidden', + message: 'Forbidden', + statusCode: 403, + }); + break; + case 'superuser at space1': + case 'space_1_all at space1': + expect(response.statusCode).to.eql(200); + expect(response.body.enabled).to.eql(false); + expect(response.body.lookBackWindow).to.eql(20); + expect(response.body.statusChangeThreshold).to.eql(20); + expect(response.body.createdBy).to.eql(user.username); + expect(response.body.updatedBy).to.eql(user.username); + expect(Date.parse(response.body.createdAt)).to.be.greaterThan(0); + expect(Date.parse(response.body.updatedAt)).to.be.greaterThan(0); + break; + default: + throw new Error(`Scenario untested: ${JSON.stringify(scenario)}`); + } + }); + }); + } + + it('should error if provided with invalid inputs', async () => { + let response = await supertestWithoutAuth + .post(`${getUrlPrefix('space1')}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(Superuser.username, Superuser.password) + .send({ + enabled: true, + lookBackWindow: 200, + statusChangeThreshold: 200, + }) + .expect(400); + + expect(response.body.message).to.eql( + 'Invalid lookBackWindow value, must be between 2 and 20, but got: 200.' + ); + + response = await supertestWithoutAuth + .post(`${getUrlPrefix('space1')}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(Superuser.username, Superuser.password) + .send({ + enabled: true, + lookBackWindow: 20, + statusChangeThreshold: 200, + }) + .expect(400); + + expect(response.body.message).to.eql( + 'Invalid statusChangeThreshold value, must be between 2 and 20, but got: 200.' + ); + + response = await supertestWithoutAuth + .post(`${getUrlPrefix('space1')}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(Superuser.username, Superuser.password) + .send({ + enabled: true, + lookBackWindow: 5, + statusChangeThreshold: 10, + }) + .expect(400); + + expect(response.body.message).to.eql( + 'Invalid values,lookBackWindow (5) must be equal to or greater than statusChangeThreshold (10).' + ); + }); + + describe('updateFlappingSettings for other spaces', () => { + it('should update specific isolated settings depending on space', async () => { + // Update the rules setting in space1 + const postResponse = await supertestWithoutAuth + .post(`${getUrlPrefix('space1')}/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .auth(Superuser.username, Superuser.password) + .send({ + enabled: false, + lookBackWindow: 20, + statusChangeThreshold: 20, + }); + + expect(postResponse.statusCode).to.eql(200); + expect(postResponse.body.enabled).to.eql(false); + expect(postResponse.body.lookBackWindow).to.eql(20); + expect(postResponse.body.statusChangeThreshold).to.eql(20); + + // Get the rules settings in space2 + const getResponse = await supertestWithoutAuth + .get(`${getUrlPrefix('space2')}/internal/alerting/rules/settings/_flapping`) + .auth(Superuser.username, Superuser.password); + + expect(getResponse.statusCode).to.eql(200); + expect(getResponse.body.enabled).to.eql(true); + expect(getResponse.body.lookBackWindow).to.eql(20); + expect(getResponse.body.statusChangeThreshold).to.eql(4); + }); + }); + }); +} diff --git a/x-pack/test/alerting_api_integration/security_and_spaces/scenarios.ts b/x-pack/test/alerting_api_integration/security_and_spaces/scenarios.ts index bfa4968e2e4b5..9e0bc69a4175b 100644 --- a/x-pack/test/alerting_api_integration/security_and_spaces/scenarios.ts +++ b/x-pack/test/alerting_api_integration/security_and_spaces/scenarios.ts @@ -5,6 +5,10 @@ * 2.0. */ +import { + READ_FLAPPING_SETTINGS_SUB_FEATURE_ID, + ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID, +} from '@kbn/alerting-plugin/common'; import { ES_TEST_INDEX_NAME } from '@kbn/alerting-api-integration-helpers'; import { Space, User } from '../common/types'; @@ -51,6 +55,7 @@ const GlobalRead: User = { alertsFixture: ['read'], alertsRestrictedFixture: ['read'], actionsSimulators: ['read'], + rulesSettings: ['read', READ_FLAPPING_SETTINGS_SUB_FEATURE_ID], }, spaces: ['*'], }, @@ -78,6 +83,7 @@ const Space1All: User = { actions: ['all'], alertsFixture: ['all'], actionsSimulators: ['all'], + rulesSettings: ['all', ALL_FLAPPING_SETTINGS_SUB_FEATURE_ID], }, spaces: ['space1'], }, diff --git a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/builtin_alert_types/lib/create_test_data.ts b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/builtin_alert_types/lib/create_test_data.ts index 589b70cc2edc5..ee8811cf98f28 100644 --- a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/builtin_alert_types/lib/create_test_data.ts +++ b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/builtin_alert_types/lib/create_test_data.ts @@ -6,7 +6,7 @@ */ import type { Client } from '@elastic/elasticsearch'; import { times } from 'lodash'; -import { v4 as uuid } from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ESTestIndexTool, ES_TEST_INDEX_NAME } from '@kbn/alerting-api-integration-helpers'; // default end date @@ -113,7 +113,7 @@ async function createEsDocument( }; const response = await es.index({ - id: uuid(), + id: uuidv4(), index: indexName, refresh: 'wait_for', op_type: 'create', diff --git a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/bulk_edit.ts b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/bulk_edit.ts index 318bfce017edc..0fcee156b8047 100644 --- a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/bulk_edit.ts +++ b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/bulk_edit.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type { SanitizedRule } from '@kbn/alerting-plugin/common'; import { Spaces } from '../../scenarios'; import { @@ -20,7 +20,7 @@ import { FtrProviderContext } from '../../../common/ftr_provider_context'; const getSnoozeSchedule = () => { return { - id: uuid.v4(), + id: uuidv4(), duration: 28800000, rRule: { dtstart: '2022-09-19T11:49:59.329Z', diff --git a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/disable.ts b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/disable.ts index d4149c9cf2fb8..dab57143e0b6d 100644 --- a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/disable.ts +++ b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/disable.ts @@ -26,7 +26,8 @@ export default function createDisableRuleTests({ getService }: FtrProviderContex const retry = getService('retry'); const supertest = getService('supertest'); - describe('disable', () => { + // Failing: See https://github.com/elastic/kibana/issues/141864 + describe.skip('disable', () => { const objectRemover = new ObjectRemover(supertestWithoutAuth); const ruleUtils = new RuleUtils({ space: Spaces.space1, supertestWithoutAuth }); diff --git a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/snooze.ts b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/snooze.ts index a7301d1467bf7..d4ae41f547014 100644 --- a/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/snooze.ts +++ b/x-pack/test/alerting_api_integration/spaces_only/tests/alerting/snooze.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { Spaces } from '../../scenarios'; import { FtrProviderContext } from '../../../common/ftr_provider_context'; import { @@ -261,7 +261,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext .send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }) .expect(204); @@ -270,7 +270,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext .send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }) .expect(204); @@ -279,7 +279,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext .send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }) .expect(204); @@ -289,7 +289,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext .send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }) .expect(204); @@ -299,7 +299,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext .send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }) .expect(204); @@ -308,7 +308,7 @@ export default function createSnoozeRuleTests({ getService }: FtrProviderContext const response = await alertUtils.getSnoozeRequest(createdRule.id).send({ snooze_schedule: { ...SNOOZE_SCHEDULE, - id: uuid.v4(), + id: uuidv4(), }, }); expect(response.statusCode).to.eql(400); diff --git a/x-pack/test/api_integration/apis/features/features/features.ts b/x-pack/test/api_integration/apis/features/features/features.ts index ce937a5e4618e..57012451eeb45 100644 --- a/x-pack/test/api_integration/apis/features/features/features.ts +++ b/x-pack/test/api_integration/apis/features/features/features.ts @@ -118,6 +118,7 @@ export default function ({ getService }: FtrProviderContext) { 'logs', 'maps', 'osquery', + 'rulesSettings', 'uptime', 'siem', 'securitySolutionCases', diff --git a/x-pack/test/api_integration/apis/maps/get_grid_tile.js b/x-pack/test/api_integration/apis/maps/get_grid_tile.js index 6f35ca27cb926..0b3a454da814c 100644 --- a/x-pack/test/api_integration/apis/maps/get_grid_tile.js +++ b/x-pack/test/api_integration/apis/maps/get_grid_tile.js @@ -21,7 +21,8 @@ function findFeature(layer, callbackFn) { export default function ({ getService }) { const supertest = getService('supertest'); - describe('getGridTile', () => { + // FAILING ES PROMOTION: https://github.com/elastic/kibana/issues/149068 + describe.skip('getGridTile', () => { const URL = `/api/maps/mvt/getGridTile/3/2/3.pbf\ ?geometryFieldName=geo.coordinates\ &hasLabels=false\ diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json index 5272e1a84d3d8..c2fec825e4b28 100644 --- a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json +++ b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_empty.json @@ -12,5 +12,12 @@ "timedOut": false }, "products": {} + }, + "packageErrors": { + "execution": { + "errors": [], + "timedOut": false + }, + "products": {} } } \ No newline at end of file diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js index 55e697e9e5f1f..fe3bf897fa45d 100644 --- a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js +++ b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_beats.js @@ -122,5 +122,12 @@ export const esBeatsResponse = (date = moment().format('YYYY.MM.DD')) => { }, }, }, + packageErrors: { + execution: { + errors: [], + timedOut: false, + }, + products: {}, + }, }; }; diff --git a/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js new file mode 100644 index 0000000000000..0caa0ac5c0256 --- /dev/null +++ b/x-pack/test/api_integration/apis/monitoring/_health/fixtures/response_es_package.js @@ -0,0 +1,49 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +export const esPackageResponse = () => { + return { + monitoredClusters: { + clusters: { + standalone: {}, + }, + execution: { + timedOut: false, + errors: [], + }, + }, + metricbeatErrors: { + execution: { + errors: [], + timedOut: false, + }, + products: {}, + }, + packageErrors: { + execution: { + errors: [], + timedOut: false, + }, + products: { + elasticsearch: { + 'elasticsearch.stack_monitoring.node_stats': [ + { + lastSeen: '2023-01-13T15:11:40.458Z', + message: + 'error making http request: Get "http://localhost:9200/_nodes/_local/stats": dial tcp [::1]:9200: connect: cannot assign requested address', + }, + { + lastSeen: '2023-01-13T15:11:30.458Z', + message: + 'error making http request: Get "http://localhost:9200/_nodes/_local/stats": dial tcp 127.0.0.1:9200: connect: connection refused', + }, + ], + }, + }, + }, + }; +}; diff --git a/x-pack/test/api_integration/apis/monitoring/_health/index.js b/x-pack/test/api_integration/apis/monitoring/_health/index.js index 95e4db48d7f73..ba7ee0378e7a0 100644 --- a/x-pack/test/api_integration/apis/monitoring/_health/index.js +++ b/x-pack/test/api_integration/apis/monitoring/_health/index.js @@ -12,7 +12,10 @@ import { getLifecycleMethods } from '../data_stream'; import emptyResponse from './fixtures/response_empty.json'; import { esBeatsResponse } from './fixtures/response_es_beats'; +import { esPackageResponse } from './fixtures/response_es_package'; +const ELASTICSEARCH_PACKAGE_ARCHIVE = + 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error'; const METRICBEAT_ARCHIVE = 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/metricbeat_8'; export default function ({ getService }) { @@ -36,7 +39,7 @@ export default function ({ getService }) { }); }); - describe('with data', () => { + describe('with metricbeat data', () => { const archives = [ 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_es_8', 'x-pack/test/api_integration/apis/monitoring/es_archives/_health/monitoring_beats_8', @@ -82,5 +85,32 @@ export default function ({ getService }) { }); }); }); + + describe('with integration package data', () => { + const timeRange = { + min: '2023-01-10T14:46:10.461Z', + max: '2023-01-15T22:30:00.000Z', + }; + const archives = [ELASTICSEARCH_PACKAGE_ARCHIVE]; + const { setup, tearDown } = getLifecycleMethods(getService); + + before('load archive', () => { + return setup(archives); + }); + + after('unload archive', () => { + return tearDown([ELASTICSEARCH_PACKAGE_ARCHIVE]); + }); + + it('returns the state of the monitoring documents', async () => { + const { body } = await supertest + .get(`/api/monitoring/v1/_health?min=${timeRange.min}&max=${timeRange.max}`) + .set('kbn-xsrf', 'xxx') + .expect(200); + + delete body.settings; + expect(body).to.eql(esPackageResponse()); + }); + }); }); } diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz b/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz new file mode 100644 index 0000000000000..76dba68666e4d Binary files /dev/null and b/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/data.json.gz differ diff --git a/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json b/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json new file mode 100644 index 0000000000000..44f4d4ee042f2 --- /dev/null +++ b/x-pack/test/api_integration/apis/monitoring/es_archives/_health/elasticsearch_package_error/mappings.json @@ -0,0 +1,1440 @@ +{ + "type": "data_stream", + "value": { + "data_stream": "metrics-elasticsearch.stack_monitoring.node_stats-default", + "template": { + "_meta": { + "managed": true, + "managed_by": "fleet", + "package": { + "name": "elasticsearch" + } + }, + "data_stream": { + "allow_custom_routing": false, + "hidden": false + }, + "index_patterns": [ + "metrics-elasticsearch.stack_monitoring.node_stats-*" + ], + "name": "metrics-elasticsearch.stack_monitoring.node_stats", + "priority": 200, + "template": { + "mappings": { + "_meta": { + "managed": true, + "managed_by": "fleet", + "package": { + "name": "elasticsearch" + } + }, + "date_detection": false, + "dynamic": false, + "dynamic_templates": [ + { + "strings_as_keyword": { + "mapping": { + "ignore_above": 1024, + "type": "keyword" + }, + "match_mapping_type": "string" + } + } + ], + "properties": { + "@timestamp": { + "type": "date" + }, + "cluster_uuid": { + "path": "elasticsearch.cluster.id", + "type": "alias" + }, + "data_stream": { + "properties": { + "dataset": { + "type": "constant_keyword" + }, + "namespace": { + "type": "constant_keyword" + }, + "type": { + "type": "constant_keyword" + } + } + }, + "ecs": { + "properties": { + "version": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "elasticsearch": { + "properties": { + "cluster": { + "properties": { + "id": { + "ignore_above": 1024, + "type": "keyword" + }, + "name": { + "ignore_above": 1024, + "type": "keyword" + }, + "state": { + "properties": { + "id": { + "ignore_above": 1024, + "type": "keyword" + } + } + } + } + }, + "node": { + "properties": { + "id": { + "ignore_above": 1024, + "type": "keyword" + }, + "master": { + "type": "boolean" + }, + "mlockall": { + "type": "boolean" + }, + "name": { + "ignore_above": 1024, + "type": "keyword" + }, + "stats": { + "properties": { + "fs": { + "properties": { + "io_stats": { + "properties": { + "total": { + "properties": { + "operations": { + "properties": { + "count": { + "type": "long" + } + } + }, + "read": { + "properties": { + "operations": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "write": { + "properties": { + "operations": { + "properties": { + "count": { + "type": "long" + } + } + } + } + } + } + } + } + }, + "summary": { + "properties": { + "available": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "free": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "total": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "total": { + "properties": { + "available_in_bytes": { + "type": "long" + }, + "total_in_bytes": { + "type": "long" + } + } + } + } + }, + "indexing_pressure": { + "properties": { + "memory": { + "properties": { + "current": { + "properties": { + "all": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "combined_coordinating_and_primary": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "coordinating": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "primary": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "replica": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "limit_in_bytes": { + "type": "long" + }, + "total": { + "properties": { + "all": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "combined_coordinating_and_primary": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "coordinating": { + "properties": { + "bytes": { + "type": "long" + }, + "rejections": { + "type": "long" + } + } + }, + "primary": { + "properties": { + "bytes": { + "type": "long" + }, + "rejections": { + "type": "long" + } + } + }, + "replica": { + "properties": { + "bytes": { + "type": "long" + }, + "rejections": { + "type": "long" + } + } + } + } + } + } + } + } + }, + "indices": { + "properties": { + "bulk": { + "properties": { + "avg_size": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "avg_time": { + "properties": { + "ms": { + "type": "long" + } + } + }, + "operations": { + "properties": { + "total": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "total_size": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "total_time": { + "properties": { + "ms": { + "type": "long" + } + } + } + } + }, + "docs": { + "properties": { + "count": { + "type": "long" + }, + "deleted": { + "type": "long" + } + } + }, + "fielddata": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "indexing": { + "properties": { + "index_time": { + "properties": { + "ms": { + "type": "long" + } + } + }, + "index_total": { + "properties": { + "count": { + "type": "long" + } + } + }, + "throttle_time": { + "properties": { + "ms": { + "type": "long" + } + } + } + } + }, + "query_cache": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "request_cache": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "search": { + "properties": { + "query_time": { + "properties": { + "ms": { + "type": "long" + } + } + }, + "query_total": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "segments": { + "properties": { + "count": { + "type": "long" + }, + "doc_values": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "fixed_bit_set": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "index_writer": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "norms": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "points": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "stored_fields": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "term_vectors": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "terms": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "version_map": { + "properties": { + "memory": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + } + } + }, + "store": { + "properties": { + "size": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + } + } + }, + "ingest": { + "properties": { + "total": { + "properties": { + "count": { + "type": "long" + }, + "current": { + "type": "long" + }, + "failed": { + "type": "long" + }, + "time_in_millis": { + "type": "long" + } + } + } + } + }, + "jvm": { + "properties": { + "gc": { + "properties": { + "collectors": { + "properties": { + "old": { + "properties": { + "collection": { + "properties": { + "count": { + "type": "long" + }, + "ms": { + "type": "long" + } + } + } + } + }, + "young": { + "properties": { + "collection": { + "properties": { + "count": { + "type": "long" + }, + "ms": { + "type": "long" + } + } + } + } + } + } + } + } + }, + "mem": { + "properties": { + "heap": { + "properties": { + "max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "used": { + "properties": { + "bytes": { + "type": "long" + }, + "pct": { + "type": "double" + } + } + } + } + }, + "pools": { + "properties": { + "old": { + "properties": { + "max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak_max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "used": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "survivor": { + "properties": { + "max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak_max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "used": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + }, + "young": { + "properties": { + "max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "peak_max": { + "properties": { + "bytes": { + "type": "long" + } + } + }, + "used": { + "properties": { + "bytes": { + "type": "long" + } + } + } + } + } + } + } + } + } + } + }, + "os": { + "properties": { + "cgroup": { + "properties": { + "cpu": { + "properties": { + "cfs": { + "properties": { + "quota": { + "properties": { + "us": { + "type": "long" + } + } + } + } + }, + "stat": { + "properties": { + "elapsed_periods": { + "properties": { + "count": { + "type": "long" + } + } + }, + "time_throttled": { + "properties": { + "ns": { + "type": "long" + } + } + }, + "times_throttled": { + "properties": { + "count": { + "type": "long" + } + } + } + } + } + } + }, + "cpuacct": { + "properties": { + "usage": { + "properties": { + "ns": { + "type": "long" + } + } + } + } + }, + "memory": { + "properties": { + "control_group": { + "ignore_above": 1024, + "type": "keyword" + }, + "limit": { + "properties": { + "bytes": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "usage": { + "properties": { + "bytes": { + "ignore_above": 1024, + "type": "keyword" + } + } + } + } + } + } + }, + "cpu": { + "properties": { + "load_avg": { + "properties": { + "1m": { + "type": "half_float" + } + } + } + } + } + } + }, + "process": { + "properties": { + "cpu": { + "properties": { + "pct": { + "type": "double" + } + } + } + } + }, + "thread_pool": { + "properties": { + "bulk": { + "properties": { + "queue": { + "properties": { + "count": { + "type": "long" + } + } + }, + "rejected": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "get": { + "properties": { + "queue": { + "properties": { + "count": { + "type": "long" + } + } + }, + "rejected": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "index": { + "properties": { + "queue": { + "properties": { + "count": { + "type": "long" + } + } + }, + "rejected": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "search": { + "properties": { + "queue": { + "properties": { + "count": { + "type": "long" + } + } + }, + "rejected": { + "properties": { + "count": { + "type": "long" + } + } + } + } + }, + "write": { + "properties": { + "queue": { + "properties": { + "count": { + "type": "long" + } + } + }, + "rejected": { + "properties": { + "count": { + "type": "long" + } + } + } + } + } + } + } + } + } + } + } + } + }, + "error": { + "properties": { + "message": { + "type": "match_only_text" + } + } + }, + "event": { + "properties": { + "agent_id_status": { + "ignore_above": 1024, + "type": "keyword" + }, + "dataset": { + "ignore_above": 1024, + "type": "keyword" + }, + "duration": { + "type": "long" + }, + "ingested": { + "format": "strict_date_time_no_millis||strict_date_optional_time||epoch_millis", + "type": "date" + }, + "module": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "host": { + "properties": { + "name": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "metricset": { + "properties": { + "name": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "node_stats": { + "properties": { + "fs": { + "properties": { + "io_stats": { + "properties": { + "total": { + "properties": { + "operations": { + "path": "elasticsearch.node.stats.fs.io_stats.total.operations.count", + "type": "alias" + }, + "read_operations": { + "path": "elasticsearch.node.stats.fs.io_stats.total.read.operations.count", + "type": "alias" + }, + "write_operations": { + "path": "elasticsearch.node.stats.fs.io_stats.total.write.operations.count", + "type": "alias" + } + } + } + } + }, + "summary": { + "properties": { + "available": { + "properties": { + "bytes": { + "path": "elasticsearch.node.stats.fs.summary.available.bytes", + "type": "alias" + } + } + }, + "total": { + "properties": { + "bytes": { + "path": "elasticsearch.node.stats.fs.summary.total.bytes", + "type": "alias" + } + } + } + } + }, + "total": { + "properties": { + "available_in_bytes": { + "path": "elasticsearch.node.stats.fs.summary.available.bytes", + "type": "alias" + }, + "total_in_bytes": { + "path": "elasticsearch.node.stats.fs.summary.total.bytes", + "type": "alias" + } + } + } + } + }, + "indices": { + "properties": { + "docs": { + "properties": { + "count": { + "path": "elasticsearch.node.stats.indices.docs.count", + "type": "alias" + } + } + }, + "fielddata": { + "properties": { + "memory_size_in_bytes": { + "path": "elasticsearch.node.stats.indices.fielddata.memory.bytes", + "type": "alias" + } + } + }, + "indexing": { + "properties": { + "index_time_in_millis": { + "path": "elasticsearch.node.stats.indices.indexing.index_time.ms", + "type": "alias" + }, + "index_total": { + "path": "elasticsearch.node.stats.indices.indexing.index_total.count", + "type": "alias" + }, + "throttle_time_in_millis": { + "path": "elasticsearch.node.stats.indices.indexing.throttle_time.ms", + "type": "alias" + } + } + }, + "query_cache": { + "properties": { + "memory_size_in_bytes": { + "path": "elasticsearch.node.stats.indices.query_cache.memory.bytes", + "type": "alias" + } + } + }, + "request_cache": { + "properties": { + "memory_size_in_bytes": { + "path": "elasticsearch.node.stats.indices.request_cache.memory.bytes", + "type": "alias" + } + } + }, + "search": { + "properties": { + "query_time_in_millis": { + "path": "elasticsearch.node.stats.indices.search.query_time.ms", + "type": "alias" + }, + "query_total": { + "path": "elasticsearch.node.stats.indices.search.query_total.count", + "type": "alias" + } + } + }, + "segments": { + "properties": { + "count": { + "path": "elasticsearch.node.stats.indices.segments.count", + "type": "alias" + }, + "doc_values_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.doc_values.memory.bytes", + "type": "alias" + }, + "fixed_bit_set_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.fixed_bit_set.memory.bytes", + "type": "alias" + }, + "index_writer_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.index_writer.memory.bytes", + "type": "alias" + }, + "memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.memory.bytes", + "type": "alias" + }, + "norms_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.norms.memory.bytes", + "type": "alias" + }, + "points_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.points.memory.bytes", + "type": "alias" + }, + "stored_fields_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.stored_fields.memory.bytes", + "type": "alias" + }, + "term_vectors_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.term_vectors.memory.bytes", + "type": "alias" + }, + "terms_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.terms.memory.bytes", + "type": "alias" + }, + "version_map_memory_in_bytes": { + "path": "elasticsearch.node.stats.indices.segments.version_map.memory.bytes", + "type": "alias" + } + } + }, + "store": { + "properties": { + "size": { + "properties": { + "bytes": { + "path": "elasticsearch.node.stats.indices.store.size.bytes", + "type": "alias" + } + } + }, + "size_in_bytes": { + "path": "elasticsearch.node.stats.indices.store.size.bytes", + "type": "alias" + } + } + } + } + }, + "jvm": { + "properties": { + "gc": { + "properties": { + "collectors": { + "properties": { + "old": { + "properties": { + "collection_count": { + "path": "elasticsearch.node.stats.jvm.gc.collectors.old.collection.count", + "type": "alias" + }, + "collection_time_in_millis": { + "path": "elasticsearch.node.stats.jvm.gc.collectors.old.collection.ms", + "type": "alias" + } + } + }, + "young": { + "properties": { + "collection_count": { + "path": "elasticsearch.node.stats.jvm.gc.collectors.young.collection.count", + "type": "alias" + }, + "collection_time_in_millis": { + "path": "elasticsearch.node.stats.jvm.gc.collectors.young.collection.ms", + "type": "alias" + } + } + } + } + } + } + }, + "mem": { + "properties": { + "heap_max_in_bytes": { + "path": "elasticsearch.node.stats.jvm.mem.heap.max.bytes", + "type": "alias" + }, + "heap_used_in_bytes": { + "path": "elasticsearch.node.stats.jvm.mem.heap.used.bytes", + "type": "alias" + }, + "heap_used_percent": { + "path": "elasticsearch.node.stats.jvm.mem.heap.used.pct", + "type": "alias" + } + } + } + } + }, + "node_id": { + "path": "elasticsearch.node.id", + "type": "alias" + }, + "os": { + "properties": { + "cgroup": { + "properties": { + "cpu": { + "properties": { + "cfs_quota_micros": { + "path": "elasticsearch.node.stats.os.cgroup.cpu.cfs.quota.us", + "type": "alias" + }, + "stat": { + "properties": { + "number_of_elapsed_periods": { + "path": "elasticsearch.node.stats.os.cgroup.cpu.stat.elapsed_periods.count", + "type": "alias" + }, + "number_of_times_throttled": { + "path": "elasticsearch.node.stats.os.cgroup.cpu.stat.times_throttled.count", + "type": "alias" + }, + "time_throttled_nanos": { + "path": "elasticsearch.node.stats.os.cgroup.cpu.stat.time_throttled.ns", + "type": "alias" + } + } + } + } + }, + "cpuacct": { + "properties": { + "usage_nanos": { + "path": "elasticsearch.node.stats.os.cgroup.cpuacct.usage.ns", + "type": "alias" + } + } + }, + "memory": { + "properties": { + "control_group": { + "path": "elasticsearch.node.stats.os.cgroup.memory.control_group", + "type": "alias" + }, + "limit_in_bytes": { + "path": "elasticsearch.node.stats.os.cgroup.memory.limit.bytes", + "type": "alias" + }, + "usage_in_bytes": { + "path": "elasticsearch.node.stats.os.cgroup.memory.usage.bytes", + "type": "alias" + } + } + } + } + }, + "cpu": { + "properties": { + "load_average": { + "properties": { + "1m": { + "path": "elasticsearch.node.stats.os.cpu.load_avg.1m", + "type": "alias" + } + } + } + } + } + } + }, + "process": { + "properties": { + "cpu": { + "properties": { + "percent": { + "path": "elasticsearch.node.stats.process.cpu.pct", + "type": "alias" + } + } + } + } + }, + "thread_pool": { + "properties": { + "bulk": { + "properties": { + "queue": { + "path": "elasticsearch.node.stats.thread_pool.bulk.queue.count", + "type": "alias" + }, + "rejected": { + "path": "elasticsearch.node.stats.thread_pool.bulk.rejected.count", + "type": "alias" + } + } + }, + "get": { + "properties": { + "queue": { + "path": "elasticsearch.node.stats.thread_pool.get.queue.count", + "type": "alias" + }, + "rejected": { + "path": "elasticsearch.node.stats.thread_pool.get.rejected.count", + "type": "alias" + } + } + }, + "index": { + "properties": { + "queue": { + "path": "elasticsearch.node.stats.thread_pool.index.queue.count", + "type": "alias" + }, + "rejected": { + "path": "elasticsearch.node.stats.thread_pool.index.rejected.count", + "type": "alias" + } + } + }, + "search": { + "properties": { + "queue": { + "path": "elasticsearch.node.stats.thread_pool.search.queue.count", + "type": "alias" + }, + "rejected": { + "path": "elasticsearch.node.stats.thread_pool.search.rejected.count", + "type": "alias" + } + } + }, + "write": { + "properties": { + "queue": { + "path": "elasticsearch.node.stats.thread_pool.write.queue.count", + "type": "alias" + }, + "rejected": { + "path": "elasticsearch.node.stats.thread_pool.write.rejected.count", + "type": "alias" + } + } + } + } + } + } + }, + "service": { + "properties": { + "address": { + "ignore_above": 1024, + "type": "keyword" + }, + "name": { + "ignore_above": 1024, + "type": "keyword" + }, + "type": { + "ignore_above": 1024, + "type": "keyword" + } + } + }, + "source_node": { + "properties": { + "name": { + "path": "elasticsearch.node.name", + "type": "alias" + }, + "uuid": { + "path": "elasticsearch.node.id", + "type": "alias" + } + } + }, + "timestamp": { + "path": "@timestamp", + "type": "alias" + } + } + }, + "settings": { + "index": { + "codec": "best_compression", + "final_pipeline": ".fleet_final_pipeline-1", + "lifecycle": { + "name": "metrics" + }, + "mapping": { + "total_fields": { + "limit": "10000" + } + }, + "query": { + "default_field": [ + "metricset.name", + "ecs.version", + "event.dataset", + "event.module", + "host.name", + "service.address", + "service.type", + "service.name", + "error.message", + "elasticsearch.node.stats.os.cgroup.memory.control_group", + "elasticsearch.node.stats.os.cgroup.memory.limit.bytes", + "elasticsearch.node.stats.os.cgroup.memory.usage.bytes", + "elasticsearch.node.id", + "elasticsearch.node.name", + "elasticsearch.cluster.name", + "elasticsearch.cluster.id", + "elasticsearch.cluster.state.id" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/x-pack/test/api_integration/apis/security/privileges.ts b/x-pack/test/api_integration/apis/security/privileges.ts index 5e2c0dcc25742..ba81febadfece 100644 --- a/x-pack/test/api_integration/apis/security/privileges.ts +++ b/x-pack/test/api_integration/apis/security/privileges.ts @@ -92,6 +92,14 @@ export default function ({ getService }: FtrProviderContext) { ], filesManagement: ['all', 'read', 'minimal_all', 'minimal_read'], filesSharedImage: ['all', 'read', 'minimal_all', 'minimal_read'], + rulesSettings: [ + 'all', + 'read', + 'minimal_all', + 'minimal_read', + 'allFlappingSettings', + 'readFlappingSettings', + ], }, reserved: ['fleet-setup', 'ml_user', 'ml_admin', 'ml_apm_user', 'monitoring'], }; diff --git a/x-pack/test/api_integration/apis/security/privileges_basic.ts b/x-pack/test/api_integration/apis/security/privileges_basic.ts index 63f0b922a30e0..36cb665c838f4 100644 --- a/x-pack/test/api_integration/apis/security/privileges_basic.ts +++ b/x-pack/test/api_integration/apis/security/privileges_basic.ts @@ -47,6 +47,7 @@ export default function ({ getService }: FtrProviderContext) { actions: ['all', 'read', 'minimal_all', 'minimal_read'], filesManagement: ['all', 'read', 'minimal_all', 'minimal_read'], filesSharedImage: ['all', 'read', 'minimal_all', 'minimal_read'], + rulesSettings: ['all', 'read', 'minimal_all', 'minimal_read'], }, global: ['all', 'read'], space: ['all', 'read'], @@ -161,6 +162,14 @@ export default function ({ getService }: FtrProviderContext) { 'packs_all', 'packs_read', ], + rulesSettings: [ + 'all', + 'read', + 'minimal_all', + 'minimal_read', + 'allFlappingSettings', + 'readFlappingSettings', + ], }, reserved: ['fleet-setup', 'ml_user', 'ml_admin', 'ml_apm_user', 'monitoring'], }; diff --git a/x-pack/test/api_integration/apis/security_solution/saved_objects/helpers.ts b/x-pack/test/api_integration/apis/security_solution/saved_objects/helpers.ts index e7abf13b2e3d6..30b72531b50dd 100644 --- a/x-pack/test/api_integration/apis/security_solution/saved_objects/helpers.ts +++ b/x-pack/test/api_integration/apis/security_solution/saved_objects/helpers.ts @@ -6,7 +6,7 @@ */ import type SuperTest from 'supertest'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { TimelineType } from '@kbn/security-solution-plugin/common/types/timeline'; export const createBasicTimeline = async ( @@ -36,7 +36,7 @@ export const createBasicTimelineTemplate = async ( version: null, timeline: { title: titleToSaved, - templateTimelineId: uuid.v4(), + templateTimelineId: uuidv4(), templateTimelineVersion: 1, timelineType: TimelineType.template, }, diff --git a/x-pack/test/api_integration/apis/synthetics/add_monitor.ts b/x-pack/test/api_integration/apis/synthetics/add_monitor.ts index e736a5cf79306..1ac7a4c8dbf53 100644 --- a/x-pack/test/api_integration/apis/synthetics/add_monitor.ts +++ b/x-pack/test/api_integration/apis/synthetics/add_monitor.ts @@ -5,7 +5,7 @@ * 2.0. */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { omit } from 'lodash'; import { secretKeys } from '@kbn/synthetics-plugin/common/constants/monitor_management'; import { ConfigKey, DataStream, HTTPFields } from '@kbn/synthetics-plugin/common/runtime_types'; @@ -277,7 +277,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('handles private location errors and immediately deletes monitor if integration policy is unable to be saved', async () => { - const name = `Monitor with private location ${uuid.v4()}`; + const name = `Monitor with private location ${uuidv4()}`; const newMonitor = { name, type: 'http', @@ -294,8 +294,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; try { await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); @@ -343,8 +343,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const password = `${username}-password`; const roleName = 'uptime-role'; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; const EXPECTED_NAMESPACE = formatKibanaNamespace(SPACE_ID); const monitor = { ...httpMonitorJson, @@ -391,8 +391,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const password = `${username}-password`; const roleName = 'uptime-role'; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; const monitor = { ...httpMonitorJson, [ConfigKey.NAMESPACE]: 'default', @@ -439,8 +439,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const password = `${username}-password`; const roleName = 'uptime-role'; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; const monitor = httpMonitorJson; let monitorId = ''; diff --git a/x-pack/test/api_integration/apis/synthetics/add_monitor_private_location.ts b/x-pack/test/api_integration/apis/synthetics/add_monitor_private_location.ts index de91acb57f321..91e0ed1d5e1df 100644 --- a/x-pack/test/api_integration/apis/synthetics/add_monitor_private_location.ts +++ b/x-pack/test/api_integration/apis/synthetics/add_monitor_private_location.ts @@ -5,7 +5,7 @@ * 2.0. */ import semver from 'semver'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { ConfigKey, HTTPFields } from '@kbn/synthetics-plugin/common/runtime_types'; import { API_URLS } from '@kbn/synthetics-plugin/common/constants'; import { formatKibanaNamespace } from '@kbn/synthetics-plugin/common/formatters'; @@ -242,12 +242,12 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const password = `${username}-password`; const roleName = 'uptime-role'; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; let monitorId = ''; const monitor = { ...httpMonitorJson, - name: `Test monitor ${uuid.v4()}`, + name: `Test monitor ${uuidv4()}`, [ConfigKey.NAMESPACE]: 'default', locations: [ { @@ -335,7 +335,7 @@ export default function ({ getService }: FtrProviderContext) { const monitor = { ...httpMonitorJson, - name: `Test monitor ${uuid.v4()}`, + name: `Test monitor ${uuidv4()}`, [ConfigKey.NAMESPACE]: 'default', locations: [ { diff --git a/x-pack/test/api_integration/apis/synthetics/add_monitor_project.ts b/x-pack/test/api_integration/apis/synthetics/add_monitor_project.ts index 080d23e46900a..6f83ba3c5be20 100644 --- a/x-pack/test/api_integration/apis/synthetics/add_monitor_project.ts +++ b/x-pack/test/api_integration/apis/synthetics/add_monitor_project.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import { ConfigKey, ProjectMonitorsRequest } from '@kbn/synthetics-plugin/common/runtime_types'; import { API_URLS } from '@kbn/synthetics-plugin/common/constants'; @@ -38,7 +38,7 @@ export default function ({ getService }: FtrProviderContext) { const setUniqueIds = (request: ProjectMonitorsRequest) => { return { ...request, - monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuid.v4() })), + monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuidv4() })), }; }; @@ -100,7 +100,7 @@ export default function ({ getService }: FtrProviderContext) { it('project monitors - handles browser monitors', async () => { const successfulMonitors = [projectMonitors.monitors[0]]; - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -214,7 +214,7 @@ export default function ({ getService }: FtrProviderContext) { it('project monitors - allows throttling false for browser monitors', async () => { const successfulMonitors = [projectMonitors.monitors[0]]; - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -258,7 +258,7 @@ export default function ({ getService }: FtrProviderContext) { it('project monitors - handles http monitors', async () => { const kibanaVersion = await kibanaServer.version.get(); const successfulMonitors = [httpProjectMonitors.monitors[1]]; - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -378,7 +378,7 @@ export default function ({ getService }: FtrProviderContext) { it('project monitors - handles tcp monitors', async () => { const successfulMonitors = [tcpProjectMonitors.monitors[0], tcpProjectMonitors.monitors[1]]; const kibanaVersion = await kibanaServer.version.get(); - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -485,7 +485,7 @@ export default function ({ getService }: FtrProviderContext) { it('project monitors - handles icmp monitors', async () => { const successfulMonitors = [icmpProjectMonitors.monitors[0], icmpProjectMonitors.monitors[1]]; const kibanaVersion = await kibanaServer.version.get(); - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -587,7 +587,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - returns a list of successfully created monitors', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest .put(API_URLS.SYNTHETICS_MONITORS_PROJECT_UPDATE.replace('{projectName}', project)) @@ -610,7 +610,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - returns a list of successfully updated monitors', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest @@ -639,7 +639,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - validates monitor type', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { const { body } = await supertest @@ -693,12 +693,12 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - saves space as data stream namespace', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); try { await security.role.create(roleName, { @@ -747,12 +747,12 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - formats custom id appropriately', async () => { - const project = `test project ${uuid.v4()}`; + const project = `test project ${uuidv4()}`; const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); try { await security.role.create(roleName, { @@ -802,7 +802,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - is able to decrypt monitor when updated after hydration', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest .put(API_URLS.SYNTHETICS_MONITORS_PROJECT_UPDATE.replace('{projectName}', project)) @@ -862,7 +862,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - is able to enable and disable monitors', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest @@ -902,7 +902,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - returns a failed monitor when user defines a private location without fleet permissions', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; const secondMonitor = { ...projectMonitors.monitors[0], @@ -985,7 +985,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - returns a successful monitor when user defines a private location with fleet permissions', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; const secondMonitor = { ...projectMonitors.monitors[0], id: 'test-id-2', @@ -1036,7 +1036,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('creates integration policies for project monitors with private locations', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest @@ -1099,7 +1099,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('deletes integration policies for project monitors when private location is removed from the monitor - lightweight', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; const monitorRequest = { monitors: [ @@ -1162,7 +1162,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('deletes integration policies for project monitors when private location is removed from the monitor', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest @@ -1244,7 +1244,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('handles updating package policies when project monitors are updated', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest @@ -1340,7 +1340,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('handles location formatting for both private and public locations', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest .put(API_URLS.SYNTHETICS_MONITORS_PROJECT_UPDATE.replace('{projectName}', project)) @@ -1390,7 +1390,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('only allows 250 requests at a time', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; const monitors = []; for (let i = 0; i < 251; i++) { monitors.push({ @@ -1421,7 +1421,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('project monitors - cannot update a monitor of one type to another type', async () => { - const project = `test-project-${uuid.v4()}`; + const project = `test-project-${uuidv4()}`; try { await supertest diff --git a/x-pack/test/api_integration/apis/synthetics/add_monitor_project_legacy.ts b/x-pack/test/api_integration/apis/synthetics/add_monitor_project_legacy.ts index ce4760f258583..ccf7fd0a97518 100644 --- a/x-pack/test/api_integration/apis/synthetics/add_monitor_project_legacy.ts +++ b/x-pack/test/api_integration/apis/synthetics/add_monitor_project_legacy.ts @@ -5,7 +5,7 @@ * 2.0. */ import fetch, { BodyInit, HeadersInit, Response } from 'node-fetch'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import { format as formatUrl } from 'url'; import { @@ -45,7 +45,7 @@ export default function ({ getService }: FtrProviderContext) { const setUniqueIds = (request: LegacyProjectMonitorsRequest) => { return { ...request, - monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuid.v4() })), + monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuidv4() })), }; }; @@ -824,8 +824,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); try { await security.role.create(roleName, { @@ -961,8 +961,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); try { await security.role.create(roleName, { @@ -1015,8 +1015,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); try { await security.role.create(roleName, { diff --git a/x-pack/test/api_integration/apis/synthetics/delete_monitor.ts b/x-pack/test/api_integration/apis/synthetics/delete_monitor.ts index 38c86e7d7b31f..c735bb130a78f 100644 --- a/x-pack/test/api_integration/apis/synthetics/delete_monitor.ts +++ b/x-pack/test/api_integration/apis/synthetics/delete_monitor.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { HTTPFields, MonitorFields } from '@kbn/synthetics-plugin/common/runtime_types'; import { API_URLS } from '@kbn/synthetics-plugin/common/constants'; import expect from '@kbn/expect'; @@ -102,7 +102,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('handles private location errors and does not delete the monitor if integration policy is unable to be deleted', async () => { - const name = `Monitor with a private location ${uuid.v4()}`; + const name = `Monitor with a private location ${uuidv4()}`; const newMonitor = { name, type: 'http', @@ -119,8 +119,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; let monitorId = ''; try { diff --git a/x-pack/test/api_integration/apis/synthetics/delete_monitor_project.ts b/x-pack/test/api_integration/apis/synthetics/delete_monitor_project.ts index b8ae0d4b5e0e2..8ba507beb7e4c 100644 --- a/x-pack/test/api_integration/apis/synthetics/delete_monitor_project.ts +++ b/x-pack/test/api_integration/apis/synthetics/delete_monitor_project.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { format as formatUrl } from 'url'; import { ConfigKey, ProjectMonitorsRequest } from '@kbn/synthetics-plugin/common/runtime_types'; import { INSUFFICIENT_FLEET_PERMISSIONS } from '@kbn/synthetics-plugin/server/synthetics_service/project_monitor/project_monitor_formatter'; @@ -38,7 +38,7 @@ export default function ({ getService }: FtrProviderContext) { const setUniqueIds = (request: ProjectMonitorsRequest) => { return { ...request, - monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuid.v4() })), + monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuidv4() })), }; }; @@ -268,8 +268,8 @@ export default function ({ getService }: FtrProviderContext) { it('does not delete monitors from the same project in a different space project', async () => { const monitors = [...projectMonitors.monitors]; const project = 'test-brower-suite'; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; const secondSpaceProjectMonitorApiRoute = `${kibanaServerUrl}/s/${SPACE_ID}${API_URLS.SYNTHETICS_MONITORS_PROJECT_LEGACY}`; await kibanaServer.spaces.create({ id: SPACE_ID, name: SPACE_NAME }); diff --git a/x-pack/test/api_integration/apis/synthetics/edit_monitor.ts b/x-pack/test/api_integration/apis/synthetics/edit_monitor.ts index 0ed7f83de204d..2f2f7e75a7aab 100644 --- a/x-pack/test/api_integration/apis/synthetics/edit_monitor.ts +++ b/x-pack/test/api_integration/apis/synthetics/edit_monitor.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { omit } from 'lodash'; import { SimpleSavedObject } from '@kbn/core/public'; import { secretKeys } from '@kbn/synthetics-plugin/common/constants/monitor_management'; @@ -312,8 +312,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; let monitorId = ''; try { diff --git a/x-pack/test/api_integration/apis/synthetics/get_monitor_overview.ts b/x-pack/test/api_integration/apis/synthetics/get_monitor_overview.ts index a37facf4cbe8e..96183756af6c3 100644 --- a/x-pack/test/api_integration/apis/synthetics/get_monitor_overview.ts +++ b/x-pack/test/api_integration/apis/synthetics/get_monitor_overview.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { SimpleSavedObject } from '@kbn/core/public'; import { ConfigKey, @@ -27,8 +27,8 @@ export default function ({ getService }: FtrProviderContext) { const username = 'admin'; const roleName = `synthetics_admin`; const password = `${username}-password`; - const SPACE_ID = `test-space-${uuid.v4()}`; - const SPACE_NAME = `test-space-name ${uuid.v4()}`; + const SPACE_ID = `test-space-${uuidv4()}`; + const SPACE_NAME = `test-space-name ${uuidv4()}`; let _monitors: MonitorFields[]; let monitors: MonitorFields[]; diff --git a/x-pack/test/api_integration/apis/synthetics/get_monitor_project.ts b/x-pack/test/api_integration/apis/synthetics/get_monitor_project.ts index 2719f9f4ef911..d24a3775bbf44 100644 --- a/x-pack/test/api_integration/apis/synthetics/get_monitor_project.ts +++ b/x-pack/test/api_integration/apis/synthetics/get_monitor_project.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import type SuperTest from 'supertest'; import { format as formatUrl } from 'url'; import { @@ -39,7 +39,7 @@ export default function ({ getService }: FtrProviderContext) { const setUniqueIds = (request: LegacyProjectMonitorsRequest) => { return { ...request, - monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuid.v4() })), + monitors: request.monitors.map((monitor) => ({ ...monitor, id: uuidv4() })), }; }; diff --git a/x-pack/test/api_integration/apis/uptime/rest/helper/make_checks.ts b/x-pack/test/api_integration/apis/uptime/rest/helper/make_checks.ts index a6ff54ccc7eb2..4f0b6daede4a3 100644 --- a/x-pack/test/api_integration/apis/uptime/rest/helper/make_checks.ts +++ b/x-pack/test/api_integration/apis/uptime/rest/helper/make_checks.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { merge, flattenDeep } from 'lodash'; import type { Client } from '@elastic/elasticsearch'; import { makePing } from './make_ping'; @@ -37,7 +37,7 @@ export const makeCheck = async ({ }: CheckProps): Promise<{ monitorId: string; docs: any }> => { const cgFields = { monitor: { - check_group: fields.monitor?.check_group || uuid.v4(), + check_group: fields.monitor?.check_group || uuidv4(), }, }; diff --git a/x-pack/test/api_integration/apis/uptime/rest/helper/make_ping.ts b/x-pack/test/api_integration/apis/uptime/rest/helper/make_ping.ts index e663aa36cadc5..d7259f85c60eb 100644 --- a/x-pack/test/api_integration/apis/uptime/rest/helper/make_ping.ts +++ b/x-pack/test/api_integration/apis/uptime/rest/helper/make_ping.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { merge } from 'lodash'; import type { Client } from '@elastic/elasticsearch'; import { makeTls, TlsProps } from './make_tls'; @@ -89,7 +89,7 @@ export const makePing = async ( }, ip: '127.0.0.1', id: monitorId, - check_group: uuid.v4(), + check_group: uuidv4(), type: 'http', status: 'up', timespan: { diff --git a/x-pack/test/api_integration/apis/uptime/rest/uptime_zip_url_deprecation.ts b/x-pack/test/api_integration/apis/uptime/rest/uptime_zip_url_deprecation.ts index 1b34a713944e7..1a9fd56d01b17 100644 --- a/x-pack/test/api_integration/apis/uptime/rest/uptime_zip_url_deprecation.ts +++ b/x-pack/test/api_integration/apis/uptime/rest/uptime_zip_url_deprecation.ts @@ -5,7 +5,7 @@ * 2.0. */ import expect from '@kbn/expect'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../ftr_provider_context'; @@ -73,7 +73,7 @@ export default function (providerContext: FtrProviderContext) { .post(`/api/fleet/agent_policies`) .set('kbn-xsrf', 'xxxx') .send({ - name: `Test policy ${uuid()}`, + name: `Test policy ${uuidv4()}`, namespace: 'default', }) .expect(200); @@ -84,7 +84,7 @@ export default function (providerContext: FtrProviderContext) { .post(`/api/fleet/package_policies`) .set('kbn-xsrf', 'xxxx') .send({ - name: `synthetics-test ${uuid()}`, + name: `synthetics-test ${uuidv4()}`, description: '', namespace: 'default', policy_id: agentPolicyId, @@ -121,7 +121,7 @@ export default function (providerContext: FtrProviderContext) { .post(`/api/fleet/package_policies`) .set('kbn-xsrf', 'xxxx') .send({ - name: `synthetics-test ${uuid()}`, + name: `synthetics-test ${uuidv4()}`, description: '', namespace: 'default', policy_id: agentPolicyId, diff --git a/x-pack/test/apm_api_integration/common/config.ts b/x-pack/test/apm_api_integration/common/config.ts index 82dd9d5b8b26f..b1991a837335c 100644 --- a/x-pack/test/apm_api_integration/common/config.ts +++ b/x-pack/test/apm_api_integration/common/config.ts @@ -58,6 +58,8 @@ type ApmApiClientKey = | 'createAndAllAgentKeysUser' | 'monitorClusterAndIndicesUser'; +export type ApmApiClient = Record>>; + export interface CreateTest { testFiles: string[]; servers: any; @@ -66,9 +68,7 @@ export interface CreateTest { apmFtrConfig: () => ApmFtrConfig; registry: ({ getService }: FtrProviderContext) => ReturnType; synthtraceEsClient: (context: InheritedFtrProviderContext) => Promise; - apmApiClient: ( - context: InheritedFtrProviderContext - ) => Record>>; + apmApiClient: (context: InheritedFtrProviderContext) => ApmApiClient; ml: ({ getService }: FtrProviderContext) => ReturnType; }; junit: { reportName: string }; diff --git a/x-pack/test/apm_api_integration/tests/mobile/mobile_http_requests_chart.spec.ts b/x-pack/test/apm_api_integration/tests/mobile/mobile_http_requests_chart.spec.ts new file mode 100644 index 0000000000000..33467b486704f --- /dev/null +++ b/x-pack/test/apm_api_integration/tests/mobile/mobile_http_requests_chart.spec.ts @@ -0,0 +1,141 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { ENVIRONMENT_ALL } from '@kbn/apm-plugin/common/environment_filter_values'; +import { FtrProviderContext } from '../../common/ftr_provider_context'; +import { generateMobileData } from './generate_mobile_data'; + +export default function ApiTest({ getService }: FtrProviderContext) { + const apmApiClient = getService('apmApiClient'); + const registry = getService('registry'); + const synthtraceEsClient = getService('synthtraceEsClient'); + + const start = new Date('2023-01-01T00:00:00.000Z').getTime(); + const end = new Date('2023-01-01T02:00:00.000Z').getTime(); + + async function getHttpRequestsChart({ + environment = ENVIRONMENT_ALL.value, + kuery = '', + serviceName, + transactionType = 'mobile', + offset, + }: { + environment?: string; + kuery?: string; + serviceName: string; + transactionType?: string; + offset?: string; + }) { + return await apmApiClient.readUser({ + endpoint: 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/http_requests', + params: { + path: { serviceName }, + query: { + environment, + start: new Date(start).toISOString(), + end: new Date(end).toISOString(), + kuery, + transactionType, + offset, + }, + }, + }); + } + + registry.when('without data loaded', { config: 'basic', archives: [] }, () => { + describe('when no data', () => { + it('handles empty state', async () => { + const response = await getHttpRequestsChart({ serviceName: 'foo' }); + expect(response.body.currentPeriod).to.eql([]); + expect(response.body.previousPeriod).to.eql([]); + expect(response.status).to.be(200); + }); + }); + }); + + registry.when('with data loaded', { config: 'basic', archives: [] }, () => { + before(async () => { + await generateMobileData({ + synthtraceEsClient, + start, + end, + }); + }); + + after(() => synthtraceEsClient.clean()); + + describe('when data is loaded', () => { + it('returns timeseries for http requests chart', async () => { + const response = await getHttpRequestsChart({ serviceName: 'synth-android', offset: '1d' }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.some( + (item: { x: number; y?: number | null }) => item.y === 0 && item.x + ) + ).to.eql(true); + expect(response.body.previousPeriod[0].y).to.eql(0); + }); + + it('returns only current period timeseries when offset is not available', async () => { + const response = await getHttpRequestsChart({ serviceName: 'synth-android' }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.some( + (item: { x: number; y?: number | null }) => item.y === 0 && item.x + ) + ).to.eql(true); + + expect(response.body.currentPeriod[0].y).to.eql(0); + expect(response.body.previousPeriod).to.eql([]); + }); + }); + + describe('when filters are applied', () => { + it('returns empty state for filters', async () => { + const response = await getHttpRequestsChart({ + serviceName: 'synth-android', + environment: 'production', + kuery: `app.version:"none"`, + }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.every( + (item: { x: number; y?: number | null }) => item.y === 0 + ) + ).to.eql(true); + expect( + response.body.previousPeriod.every( + (item: { x: number; y?: number | null }) => item.y === 0 + ) + ).to.eql(true); + }); + + it('returns the correct values when filter is applied', async () => { + const response = await getHttpRequestsChart({ + serviceName: 'synth-android', + environment: 'production', + kuery: `network.connection.type:"wifi"`, + }); + + const ntcCell = await getHttpRequestsChart({ + serviceName: 'synth-android', + environment: 'production', + kuery: `network.connection.type:"cell"`, + }); + + expect(response.status).to.be(200); + expect(ntcCell.status).to.be(200); + expect(response.body.currentPeriod[0].y).to.eql(0); + expect(ntcCell.body.currentPeriod[0].y).to.eql(0); + }); + }); + }); +} diff --git a/x-pack/test/apm_api_integration/tests/mobile/mobile_sessions_chart.spec.ts b/x-pack/test/apm_api_integration/tests/mobile/mobile_sessions_chart.spec.ts new file mode 100644 index 0000000000000..fe3c9863af8d5 --- /dev/null +++ b/x-pack/test/apm_api_integration/tests/mobile/mobile_sessions_chart.spec.ts @@ -0,0 +1,141 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { ENVIRONMENT_ALL } from '@kbn/apm-plugin/common/environment_filter_values'; +import { FtrProviderContext } from '../../common/ftr_provider_context'; +import { generateMobileData } from './generate_mobile_data'; + +export default function ApiTest({ getService }: FtrProviderContext) { + const apmApiClient = getService('apmApiClient'); + const registry = getService('registry'); + const synthtraceEsClient = getService('synthtraceEsClient'); + + const start = new Date('2023-01-01T00:00:00.000Z').getTime(); + const end = new Date('2023-01-01T02:00:00.000Z').getTime(); + + async function getSessionsChart({ + environment = ENVIRONMENT_ALL.value, + kuery = '', + serviceName, + transactionType = 'mobile', + offset, + }: { + environment?: string; + kuery?: string; + serviceName: string; + transactionType?: string; + offset?: string; + }) { + return await apmApiClient.readUser({ + endpoint: 'GET /internal/apm/mobile-services/{serviceName}/transactions/charts/sessions', + params: { + path: { serviceName }, + query: { + environment, + start: new Date(start).toISOString(), + end: new Date(end).toISOString(), + offset, + kuery, + transactionType, + }, + }, + }); + } + + registry.when('without data loaded', { config: 'basic', archives: [] }, () => { + describe('when no data', () => { + it('handles empty state', async () => { + const response = await getSessionsChart({ serviceName: 'foo' }); + expect(response.body.currentPeriod).to.eql([]); + expect(response.body.previousPeriod).to.eql([]); + expect(response.status).to.be(200); + }); + }); + }); + + registry.when('with data loaded', { config: 'basic', archives: [] }, () => { + before(async () => { + await generateMobileData({ + synthtraceEsClient, + start, + end, + }); + }); + + after(() => synthtraceEsClient.clean()); + + describe('when data is loaded', () => { + it('returns timeseries for sessions chart', async () => { + const response = await getSessionsChart({ serviceName: 'synth-android', offset: '1d' }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.some( + (item: { x: number; y?: number | null }) => item.x && item.y + ) + ).to.eql(true); + + expect(response.body.currentPeriod[0].y).to.eql(8); + expect(response.body.previousPeriod[0].y).to.eql(0); + }); + + it('returns only current period timeseries when offset is not available', async () => { + const response = await getSessionsChart({ serviceName: 'synth-android' }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.some( + (item: { x: number; y?: number | null }) => item.x && item.y + ) + ).to.eql(true); + + expect(response.body.currentPeriod[0].y).to.eql(8); + expect(response.body.previousPeriod).to.eql([]); + }); + }); + + describe('when filters are applied', () => { + it('returns empty state for filters', async () => { + const response = await getSessionsChart({ + serviceName: 'synth-android', + environment: 'production', + kuery: `app.version:"none"`, + }); + + expect( + response.body.currentPeriod.every( + (item: { x: number; y?: number | null }) => item.y === 0 + ) + ).to.eql(true); + expect( + response.body.previousPeriod.every( + (item: { x: number; y?: number | null }) => item.y === 0 + ) + ).to.eql(true); + }); + + it('returns the correct values filter is applied', async () => { + const response = await getSessionsChart({ + serviceName: 'synth-android', + environment: 'production', + kuery: `transaction.name : "Start View - View Appearing"`, + }); + + expect(response.status).to.be(200); + expect( + response.body.currentPeriod.some( + (item: { x: number; y?: number | null }) => item.x && item.y + ) + ).to.eql(true); + + expect(response.body.currentPeriod[0].y).to.eql(2); + expect(response.body.previousPeriod).to.eql([]); + }); + }); + }); +} diff --git a/x-pack/test/apm_api_integration/tests/mobile/mobile_stats.spec.ts b/x-pack/test/apm_api_integration/tests/mobile/mobile_stats.spec.ts index c21839a5058b2..32ff956a70007 100644 --- a/x-pack/test/apm_api_integration/tests/mobile/mobile_stats.spec.ts +++ b/x-pack/test/apm_api_integration/tests/mobile/mobile_stats.spec.ts @@ -149,7 +149,7 @@ export default function ApiTest({ getService }: FtrProviderContext) { }); expect(response.sessions.value).to.eql(3); - expect(response.requests.value).to.eql(6); + expect(response.requests.value).to.eql(0); expect(response.crashCount.value).to.eql(0); expect(response.maxLoadTime.value).to.eql(null); }); diff --git a/x-pack/test/apm_api_integration/tests/service_groups/save_service_group.spec.ts b/x-pack/test/apm_api_integration/tests/service_groups/save_service_group.spec.ts index 8eeb4b43f7d30..b3dfdcdeb515a 100644 --- a/x-pack/test/apm_api_integration/tests/service_groups/save_service_group.spec.ts +++ b/x-pack/test/apm_api_integration/tests/service_groups/save_service_group.spec.ts @@ -8,85 +8,44 @@ import expect from '@kbn/expect'; import { ApmApiError } from '../../common/apm_api_supertest'; import { FtrProviderContext } from '../../common/ftr_provider_context'; import { expectToReject } from '../../common/utils/expect_to_reject'; +import { + createServiceGroupApi, + deleteAllServiceGroups, + getServiceGroupsApi, +} from './service_groups_api_methods'; export default function ApiTest({ getService }: FtrProviderContext) { const registry = getService('registry'); const apmApiClient = getService('apmApiClient'); - async function createServiceGroupApi({ - serviceGroupId, - groupName, - kuery, - description, - color, - }: { - serviceGroupId?: string; - groupName: string; - kuery: string; - description?: string; - color?: string; - }) { - const response = await apmApiClient.writeUser({ - endpoint: 'POST /internal/apm/service-group', - params: { - query: { - serviceGroupId, - }, - body: { - groupName, - kuery, - description, - color, - }, - }, - }); - return response; - } - - async function getServiceGroupsApi() { - return apmApiClient.writeUser({ - endpoint: 'GET /internal/apm/service-groups', - }); - } - - async function deleteAllServiceGroups() { - return await getServiceGroupsApi().then((response) => { - const promises = response.body.serviceGroups.map((item) => { - if (item.id) { - return apmApiClient.writeUser({ - endpoint: 'DELETE /internal/apm/service-group', - params: { query: { serviceGroupId: item.id } }, - }); - } - }); - return Promise.all(promises); - }); - } - registry.when('Service group create', { config: 'basic', archives: [] }, () => { - afterEach(deleteAllServiceGroups); + afterEach(async () => { + await deleteAllServiceGroups(apmApiClient); + }); it('creates a new service group', async () => { const serviceGroup = { groupName: 'synthbeans', kuery: 'service.name: synth*', }; - const createResponse = await createServiceGroupApi(serviceGroup); + const createResponse = await createServiceGroupApi({ apmApiClient, ...serviceGroup }); expect(createResponse.status).to.be(200); expect(createResponse.body).to.have.property('id'); expect(createResponse.body).to.have.property('groupName', serviceGroup.groupName); expect(createResponse.body).to.have.property('kuery', serviceGroup.kuery); expect(createResponse.body).to.have.property('updatedAt'); - const serviceGroupsResponse = await getServiceGroupsApi(); + const serviceGroupsResponse = await getServiceGroupsApi(apmApiClient); expect(serviceGroupsResponse.body.serviceGroups.length).to.be(1); }); it('handles invalid fields with error response', async () => { - const err = await expectToReject(() => - createServiceGroupApi({ - groupName: 'synthbeans', - kuery: 'service.name: synth* or transaction.type: request', - }) + const err = await expectToReject( + async () => + await createServiceGroupApi({ + apmApiClient, + groupName: 'synthbeans', + kuery: 'service.name: synth* or transaction.type: request', + }) ); expect(err.res.status).to.be(400); diff --git a/x-pack/test/apm_api_integration/tests/service_groups/service_group_count/service_group_count.spec.ts b/x-pack/test/apm_api_integration/tests/service_groups/service_group_count/service_group_count.spec.ts index 95911cfbb8d8b..69e3d7678ca9e 100644 --- a/x-pack/test/apm_api_integration/tests/service_groups/service_group_count/service_group_count.spec.ts +++ b/x-pack/test/apm_api_integration/tests/service_groups/service_group_count/service_group_count.spec.ts @@ -4,10 +4,15 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import expect from '@kbn/expect'; import { ApmRuleType } from '@kbn/apm-plugin/common/rules/apm_rule_types'; +import expect from '@kbn/expect'; import { FtrProviderContext } from '../../../common/ftr_provider_context'; import { waitForActiveAlert } from '../../../common/utils/wait_for_active_alert'; +import { + createServiceGroupApi, + deleteAllServiceGroups, + getServiceGroupCounts, +} from '../service_groups_api_methods'; import { generateData } from './generate_data'; export default function ApiTest({ getService }: FtrProviderContext) { @@ -21,61 +26,6 @@ export default function ApiTest({ getService }: FtrProviderContext) { const start = Date.now() - 24 * 60 * 60 * 1000; const end = Date.now(); - async function getServiceGroupCounts() { - return apmApiClient.readUser({ - endpoint: 'GET /internal/apm/service-group/counts', - }); - } - - async function saveServiceGroup({ - serviceGroupId, - groupName, - kuery, - description, - color, - }: { - serviceGroupId?: string; - groupName: string; - kuery: string; - description?: string; - color?: string; - }) { - return apmApiClient.writeUser({ - endpoint: 'POST /internal/apm/service-group', - params: { - query: { - serviceGroupId, - }, - body: { - groupName, - kuery, - description, - color, - }, - }, - }); - } - - async function getServiceGroupsApi() { - return apmApiClient.writeUser({ - endpoint: 'GET /internal/apm/service-groups', - }); - } - - async function deleteAllServiceGroups() { - return await getServiceGroupsApi().then((response) => { - const promises = response.body.serviceGroups.map((item) => { - if (item.id) { - return apmApiClient.writeUser({ - endpoint: 'DELETE /internal/apm/service-group', - params: { query: { serviceGroupId: item.id } }, - }); - } - }); - return Promise.all(promises); - }); - } - async function createRule() { return supertest .post(`/api/alerting/rule`) @@ -100,64 +50,62 @@ export default function ApiTest({ getService }: FtrProviderContext) { }); } - registry.when( - 'Service group counts', - { config: 'basic', archives: [] }, - () => { - let synthbeansServiceGroupId: string; - let opbeansServiceGroupId: string; + registry.when('Service group counts', { config: 'basic', archives: [] }, () => { + let synthbeansServiceGroupId: string; + let opbeansServiceGroupId: string; + before(async () => { + const [, { body: synthbeansServiceGroup }, { body: opbeansServiceGroup }] = await Promise.all( + [ + generateData({ start, end, synthtraceEsClient }), + createServiceGroupApi({ + apmApiClient, + groupName: 'synthbeans', + kuery: 'service.name: synth*', + }), + createServiceGroupApi({ + apmApiClient, + groupName: 'opbeans', + kuery: 'service.name: opbeans*', + }), + ] + ); + synthbeansServiceGroupId = synthbeansServiceGroup.id; + opbeansServiceGroupId = opbeansServiceGroup.id; + }); + + after(async () => { + await deleteAllServiceGroups(apmApiClient); + await synthtraceEsClient.clean(); + }); + + it('returns the correct number of services', async () => { + const response = await getServiceGroupCounts(apmApiClient); + expect(response.status).to.be(200); + expect(Object.keys(response.body).length).to.be(2); + expect(response.body[synthbeansServiceGroupId]).to.have.property('services', 2); + expect(response.body[opbeansServiceGroupId]).to.have.property('services', 1); + }); + + describe('with alerts', () => { + let ruleId: string; before(async () => { - const [, { body: synthbeansServiceGroup }, { body: opbeansServiceGroup }] = - await Promise.all([ - generateData({ start, end, synthtraceEsClient }), - saveServiceGroup({ - groupName: 'synthbeans', - kuery: 'service.name: synth*', - }), - saveServiceGroup({ - groupName: 'opbeans', - kuery: 'service.name: opbeans*', - }), - ]); - synthbeansServiceGroupId = synthbeansServiceGroup.id; - opbeansServiceGroupId = opbeansServiceGroup.id; + const { body: createdRule } = await createRule(); + ruleId = createdRule.id; + await waitForActiveAlert({ ruleId, esClient, log }); }); after(async () => { - await deleteAllServiceGroups(); - await synthtraceEsClient.clean(); + await supertest.delete(`/api/alerting/rule/${ruleId}`).set('kbn-xsrf', 'true'); + await esDeleteAllIndices('.alerts*'); }); - it('returns the correct number of services', async () => { - const response = await getServiceGroupCounts(); + it('returns the correct number of alerts', async () => { + const response = await getServiceGroupCounts(apmApiClient); expect(response.status).to.be(200); expect(Object.keys(response.body).length).to.be(2); - expect(response.body[synthbeansServiceGroupId]).to.have.property('services', 2); - expect(response.body[opbeansServiceGroupId]).to.have.property('services', 1); + expect(response.body[synthbeansServiceGroupId]).to.have.property('alerts', 1); + expect(response.body[opbeansServiceGroupId]).to.have.property('alerts', 0); }); - - describe('with alerts', () => { - let ruleId: string; - before(async () => { - const { body: createdRule } = await createRule(); - ruleId = createdRule.id; - await waitForActiveAlert({ ruleId, esClient, log }); - }); - - after(async () => { - await supertest.delete(`/api/alerting/rule/${ruleId}`).set('kbn-xsrf', 'true'); - await esDeleteAllIndices('.alerts*'); - }); - - it('returns the correct number of alerts', async () => { - const response = await getServiceGroupCounts(); - expect(response.status).to.be(200); - expect(Object.keys(response.body).length).to.be(2); - expect(response.body[synthbeansServiceGroupId]).to.have.property('alerts', 1); - expect(response.body[opbeansServiceGroupId]).to.have.property('alerts', 0); - }); - }); - }, - true // skipped Failing: See https://github.com/elastic/kibana/issues/147473 - ); + }); + }); } diff --git a/x-pack/test/apm_api_integration/tests/service_groups/service_groups_api_methods.ts b/x-pack/test/apm_api_integration/tests/service_groups/service_groups_api_methods.ts new file mode 100644 index 0000000000000..2d0e5405cc3d1 --- /dev/null +++ b/x-pack/test/apm_api_integration/tests/service_groups/service_groups_api_methods.ts @@ -0,0 +1,66 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { ApmApiClient } from '../../common/config'; + +export async function getServiceGroupsApi(apmApiClient: ApmApiClient) { + return apmApiClient.writeUser({ + endpoint: 'GET /internal/apm/service-groups', + }); +} + +export async function createServiceGroupApi({ + apmApiClient, + serviceGroupId, + groupName, + kuery, + description, + color, +}: { + apmApiClient: ApmApiClient; + serviceGroupId?: string; + groupName: string; + kuery: string; + description?: string; + color?: string; +}) { + const response = await apmApiClient.writeUser({ + endpoint: 'POST /internal/apm/service-group', + params: { + query: { + serviceGroupId, + }, + body: { + groupName, + kuery, + description, + color, + }, + }, + }); + return response; +} + +export async function getServiceGroupCounts(apmApiClient: ApmApiClient) { + return apmApiClient.readUser({ + endpoint: 'GET /internal/apm/service-group/counts', + }); +} + +export async function deleteAllServiceGroups(apmApiClient: ApmApiClient) { + return await getServiceGroupsApi(apmApiClient).then((response) => { + const promises = response.body.serviceGroups.map((item) => { + if (item.id) { + return apmApiClient.writeUser({ + endpoint: 'DELETE /internal/apm/service-group', + params: { query: { serviceGroupId: item.id } }, + }); + } + }); + return Promise.all(promises); + }); +} diff --git a/x-pack/test/apm_api_integration/tests/service_overview/dependencies/es_utils.ts b/x-pack/test/apm_api_integration/tests/service_overview/dependencies/es_utils.ts index 622b0127a396c..08549609f3b67 100644 --- a/x-pack/test/apm_api_integration/tests/service_overview/dependencies/es_utils.ts +++ b/x-pack/test/apm_api_integration/tests/service_overview/dependencies/es_utils.ts @@ -6,7 +6,7 @@ */ import { MappingTypeMapping } from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export function createServiceDependencyDocs({ time, @@ -42,7 +42,7 @@ export function createServiceDependencyDocs({ agentName: string; }; }) { - const spanId = uuid.v4(); + const spanId = uuidv4(); return [ { diff --git a/x-pack/test/apm_api_integration/tests/settings/agent_configuration/agent_configuration.spec.ts b/x-pack/test/apm_api_integration/tests/settings/agent_configuration/agent_configuration.spec.ts index d914d86e7689a..3644c37b7a945 100644 --- a/x-pack/test/apm_api_integration/tests/settings/agent_configuration/agent_configuration.spec.ts +++ b/x-pack/test/apm_api_integration/tests/settings/agent_configuration/agent_configuration.spec.ts @@ -383,8 +383,7 @@ export default function agentConfigurationTests({ getService }: FtrProviderConte expect(await waitFor(hasBeenAppliedByAgent)).to.be(true); }); }); - }, - true + } ); registry.when('Agent configurations through fleet', { config: 'basic', archives: [] }, () => { @@ -530,12 +529,12 @@ async function expectStatusCode( try { response = await fn(); } catch (e) { - if (e && e.response && e.response.status) { - if (e.response.status === statusCode) { + if (e && e.res && e.res.status) { + if (e.res.status === statusCode) { return; } throw new Error( - `Expected a [${statusCode}] response, got [${e.response.status}]: ${inspect(e.response)}` + `Expected a [${statusCode}] response, got [${e.res.status}]: ${inspect(e.res)}` ); } else { throw new Error( diff --git a/x-pack/test/apm_api_integration/tests/span_links/data_generator.ts b/x-pack/test/apm_api_integration/tests/span_links/data_generator.ts index 05b1095db5f61..f647a3e554b5d 100644 --- a/x-pack/test/apm_api_integration/tests/span_links/data_generator.ts +++ b/x-pack/test/apm_api_integration/tests/span_links/data_generator.ts @@ -6,7 +6,7 @@ */ import { apm, timerange } from '@kbn/apm-synthtrace-client'; import { SpanLink } from '@kbn/apm-plugin/typings/es_schemas/raw/fields/span_links'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; function getProducerInternalOnly() { const producerInternalOnlyInstance = apm @@ -125,7 +125,7 @@ function getProducerConsumer({ producerExternalOnlySpanBLink: SpanLink; producerExternalOnlyTransactionBLink: SpanLink; }) { - const externalTraceId = uuid.v4(); + const externalTraceId = uuidv4(); const producerConsumerInstance = apm .service({ name: 'producer-consumer', environment: 'production', agentName: 'ruby' }) diff --git a/x-pack/test/apm_api_integration/tests/traces/trace_by_id.spec.ts b/x-pack/test/apm_api_integration/tests/traces/trace_by_id.spec.ts index 9a01c39576432..b055bcf276438 100644 --- a/x-pack/test/apm_api_integration/tests/traces/trace_by_id.spec.ts +++ b/x-pack/test/apm_api_integration/tests/traces/trace_by_id.spec.ts @@ -52,7 +52,7 @@ export default function ApiTest({ getService }: FtrProviderContext) { errorDocs: [], spanLinksCountById: {}, traceItemCount: 0, - maxTraceItems: 1000, + maxTraceItems: 5000, }, }); }); diff --git a/x-pack/test/cases_api_integration/common/lib/connectors.ts b/x-pack/test/cases_api_integration/common/lib/connectors.ts new file mode 100644 index 0000000000000..4948495ddf665 --- /dev/null +++ b/x-pack/test/cases_api_integration/common/lib/connectors.ts @@ -0,0 +1,324 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import getPort from 'get-port'; +import http from 'http'; + +import type SuperTest from 'supertest'; +import { + CASES_INTERNAL_URL, + CASE_CONFIGURE_CONNECTORS_URL, +} from '@kbn/cases-plugin/common/constants'; +import { + CasesConfigureResponse, + CaseConnector, + ConnectorTypes, + CasePostRequest, + CaseResponse, + GetCaseConnectorsResponse, +} from '@kbn/cases-plugin/common/api'; +import { ActionResult, FindActionResult } from '@kbn/actions-plugin/server/types'; +import { User } from './authentication/types'; +import { superUser } from './authentication/users'; +import { getPostCaseRequest } from './mock'; +import { ObjectRemover as ActionsRemover } from '../../../alerting_api_integration/common/lib'; +import { getServiceNowServer } from '../../../alerting_api_integration/common/plugins/actions_simulators/server/plugin'; +import { RecordingServiceNowSimulator } from '../../../alerting_api_integration/common/plugins/actions_simulators/server/servicenow_simulation'; +import { + createConfiguration, + getConfigurationRequest, + createCase, + getSpaceUrlPrefix, +} from './utils'; + +export const getResilientConnector = () => ({ + name: 'Resilient Connector', + connector_type_id: '.resilient', + secrets: { + apiKeyId: 'id', + apiKeySecret: 'secret', + }, + config: { + apiUrl: 'http://some.non.existent.com', + orgId: 'pkey', + }, +}); + +export const getWebhookConnector = () => ({ + name: 'A generic Webhook action', + connector_type_id: '.webhook', + secrets: { + user: 'user', + password: 'password', + }, + config: { + headers: { + 'Content-Type': 'text/plain', + }, + url: 'http://some.non.existent.com', + }, +}); + +export const getEmailConnector = () => ({ + name: 'An email action', + connector_type_id: '.email', + config: { + service: '__json', + from: 'bob@example.com', + }, + secrets: { + user: 'bob', + password: 'supersecret', + }, +}); + +export const getServiceNowOAuthConnector = () => ({ + name: 'ServiceNow OAuth Connector', + connector_type_id: '.servicenow', + secrets: { + clientSecret: 'xyz', + privateKey: '-----BEGIN RSA PRIVATE KEY-----\nddddddd\n-----END RSA PRIVATE KEY-----', + }, + config: { + apiUrl: 'http://some.non.existent.com', + usesTableApi: false, + isOAuth: true, + clientId: 'abc', + userIdentifierValue: 'elastic', + jwtKeyId: 'def', + }, +}); + +export const getJiraConnector = () => ({ + name: 'Jira Connector', + connector_type_id: '.jira', + secrets: { + email: 'elastic@elastic.co', + apiToken: 'token', + }, + config: { + apiUrl: 'http://some.non.existent.com', + projectKey: 'pkey', + }, +}); + +export const getCasesWebhookConnector = () => ({ + name: 'Cases Webhook Connector', + connector_type_id: '.cases-webhook', + secrets: { + user: 'user', + password: 'pass', + }, + config: { + createCommentJson: '{"body":{{{case.comment}}}}', + createCommentMethod: 'post', + createCommentUrl: 'http://some.non.existent.com/{{{external.system.id}}}/comment', + createIncidentJson: + '{"fields":{"summary":{{{case.title}}},"description":{{{case.description}}},"project":{"key":"ROC"},"issuetype":{"id":"10024"}}}', + createIncidentMethod: 'post', + createIncidentResponseKey: 'id', + createIncidentUrl: 'http://some.non.existent.com/', + getIncidentResponseExternalTitleKey: 'key', + hasAuth: true, + headers: { [`content-type`]: 'application/json' }, + viewIncidentUrl: 'http://some.non.existent.com/browse/{{{external.system.title}}}', + getIncidentUrl: 'http://some.non.existent.com/{{{external.system.id}}}', + updateIncidentJson: + '{"fields":{"summary":{{{case.title}}},"description":{{{case.description}}},"project":{"key":"ROC"},"issuetype":{"id":"10024"}}}', + updateIncidentMethod: 'put', + updateIncidentUrl: 'http://some.non.existent.com/{{{external.system.id}}}', + }, +}); + +export const getServiceNowSIRConnector = () => ({ + name: 'ServiceNow SIR Connector', + connector_type_id: '.servicenow-sir', + secrets: { + username: 'admin', + password: 'password', + }, + config: { + apiUrl: 'http://some.non.existent.com', + usesTableApi: false, + }, +}); + +export const getServiceNowConnector = () => ({ + name: 'ServiceNow Connector', + connector_type_id: '.servicenow', + secrets: { + username: 'admin', + password: 'password', + }, + config: { + apiUrl: 'http://some.non.existent.com', + usesTableApi: false, + }, +}); + +export const getRecordingServiceNowSimulatorServer = async (): Promise<{ + server: RecordingServiceNowSimulator; + url: string; +}> => { + const simulator = await RecordingServiceNowSimulator.start(); + const url = await startServiceNowSimulatorListening(simulator.server); + + return { server: simulator, url }; +}; + +const startServiceNowSimulatorListening = async (server: http.Server) => { + const port = await getPort({ port: getPort.makeRange(9000, 9100) }); + if (!server.listening) { + server.listen(port); + } + const url = `http://localhost:${port}`; + + return url; +}; + +export const getServiceNowSimulationServer = async (): Promise<{ + server: http.Server; + url: string; +}> => { + const server = await getServiceNowServer(); + const url = await startServiceNowSimulatorListening(server); + + return { server, url }; +}; + +export const getCaseConnectors = async ({ + supertest, + expectedHttpCode = 200, + auth = { user: superUser, space: null }, +}: { + supertest: SuperTest.SuperTest; + expectedHttpCode?: number; + auth?: { user: User; space: string | null }; +}): Promise => { + const { body: connectors } = await supertest + .get(`${getSpaceUrlPrefix(auth.space)}${CASE_CONFIGURE_CONNECTORS_URL}/_find`) + .auth(auth.user.username, auth.user.password) + .expect(expectedHttpCode); + + return connectors; +}; + +export const createCaseWithConnector = async ({ + supertest, + configureReq = {}, + serviceNowSimulatorURL, + actionsRemover, + auth = { user: superUser, space: null }, + createCaseReq = getPostCaseRequest(), + headers = {}, +}: { + supertest: SuperTest.SuperTest; + serviceNowSimulatorURL: string; + actionsRemover: ActionsRemover; + configureReq?: Record; + auth?: { user: User; space: string | null } | null; + createCaseReq?: CasePostRequest; + headers?: Record; +}): Promise<{ + postedCase: CaseResponse; + connector: CreateConnectorResponse; + configuration: CasesConfigureResponse; +}> => { + const connector = await createConnector({ + supertest, + req: { + ...getServiceNowConnector(), + config: { apiUrl: serviceNowSimulatorURL }, + }, + auth: auth ?? undefined, + }); + + actionsRemover.add(auth?.space ?? 'default', connector.id, 'action', 'actions'); + + const [configuration, postedCase] = await Promise.all([ + createConfiguration( + supertest, + { + ...getConfigurationRequest({ + id: connector.id, + name: connector.name, + type: connector.connector_type_id as ConnectorTypes, + }), + ...configureReq, + }, + 200, + auth ?? undefined + ), + createCase( + supertest, + { + ...createCaseReq, + connector: { + id: connector.id, + name: connector.name, + type: connector.connector_type_id, + fields: { + urgency: '2', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + } as CaseConnector, + }, + 200, + auth, + headers + ), + ]); + + return { postedCase, connector, configuration }; +}; + +export type CreateConnectorResponse = Omit & { + connector_type_id: string; +}; + +export const createConnector = async ({ + supertest, + req, + expectedHttpCode = 200, + auth = { user: superUser, space: null }, +}: { + supertest: SuperTest.SuperTest; + req: Record; + expectedHttpCode?: number; + auth?: { user: User; space: string | null }; +}): Promise => { + const { body: connector } = await supertest + .post(`${getSpaceUrlPrefix(auth.space)}/api/actions/connector`) + .auth(auth.user.username, auth.user.password) + .set('kbn-xsrf', 'true') + .send(req) + .expect(expectedHttpCode); + + return connector; +}; + +export const getConnectors = async ({ + supertest, + caseId, + expectedHttpCode = 200, + auth = { user: superUser, space: null }, +}: { + supertest: SuperTest.SuperTest; + caseId: string; + expectedHttpCode?: number; + auth?: { user: User; space: string | null }; +}): Promise => { + const { body: connectors } = await supertest + .get(`${getSpaceUrlPrefix(auth.space)}${CASES_INTERNAL_URL}/${caseId}/_connectors`) + .auth(auth.user.username, auth.user.password) + .expect(expectedHttpCode); + + return connectors; +}; diff --git a/x-pack/test/cases_api_integration/common/lib/utils.ts b/x-pack/test/cases_api_integration/common/lib/utils.ts index 1af320a5d5c97..58dc567431546 100644 --- a/x-pack/test/cases_api_integration/common/lib/utils.ts +++ b/x-pack/test/cases_api_integration/common/lib/utils.ts @@ -6,8 +6,6 @@ */ import { omit } from 'lodash'; -import getPort from 'get-port'; -import http from 'http'; import expect from '@kbn/expect'; import type * as estypes from '@elastic/elasticsearch/lib/api/typesWithBodyKey'; @@ -19,7 +17,6 @@ import type SuperTest from 'supertest'; import { CASES_INTERNAL_URL, CASES_URL, - CASE_CONFIGURE_CONNECTORS_URL, CASE_CONFIGURE_URL, CASE_REPORTERS_URL, CASE_STATUS_URL, @@ -57,16 +54,13 @@ import { } from '@kbn/cases-plugin/common/api'; import { getCaseUserActionUrl } from '@kbn/cases-plugin/common/api/helpers'; import { SignalHit } from '@kbn/security-solution-plugin/server/lib/detection_engine/signals/types'; -import { ActionResult, FindActionResult } from '@kbn/actions-plugin/server/types'; +import { ActionResult } from '@kbn/actions-plugin/server/types'; import { ESCasesConfigureAttributes } from '@kbn/cases-plugin/server/services/configure/types'; import { ESCaseAttributes } from '@kbn/cases-plugin/server/services/cases/types'; import type { SavedObjectsRawDocSource } from '@kbn/core/server'; import { User } from './authentication/types'; import { superUser } from './authentication/users'; -import { getPostCaseRequest, postCaseReq } from './mock'; -import { ObjectRemover as ActionsRemover } from '../../../alerting_api_integration/common/lib'; -import { getServiceNowServer } from '../../../alerting_api_integration/common/plugins/actions_simulators/server/plugin'; -import { RecordingServiceNowSimulator } from '../../../alerting_api_integration/common/plugins/actions_simulators/server/servicenow_simulation'; +import { postCaseReq } from './mock'; function toArray(input: T | T[]): T[] { if (Array.isArray(input)) { @@ -209,77 +203,6 @@ export const getConfigurationOutput = ( }; }; -export const getServiceNowConnector = () => ({ - name: 'ServiceNow Connector', - connector_type_id: '.servicenow', - secrets: { - username: 'admin', - password: 'password', - }, - config: { - apiUrl: 'http://some.non.existent.com', - usesTableApi: false, - }, -}); - -export const getServiceNowOAuthConnector = () => ({ - name: 'ServiceNow OAuth Connector', - connector_type_id: '.servicenow', - secrets: { - clientSecret: 'xyz', - privateKey: '-----BEGIN RSA PRIVATE KEY-----\nddddddd\n-----END RSA PRIVATE KEY-----', - }, - config: { - apiUrl: 'http://some.non.existent.com', - usesTableApi: false, - isOAuth: true, - clientId: 'abc', - userIdentifierValue: 'elastic', - jwtKeyId: 'def', - }, -}); - -export const getJiraConnector = () => ({ - name: 'Jira Connector', - connector_type_id: '.jira', - secrets: { - email: 'elastic@elastic.co', - apiToken: 'token', - }, - config: { - apiUrl: 'http://some.non.existent.com', - projectKey: 'pkey', - }, -}); - -export const getCasesWebhookConnector = () => ({ - name: 'Cases Webhook Connector', - connector_type_id: '.cases-webhook', - secrets: { - user: 'user', - password: 'pass', - }, - config: { - createCommentJson: '{"body":{{{case.comment}}}}', - createCommentMethod: 'post', - createCommentUrl: 'http://some.non.existent.com/{{{external.system.id}}}/comment', - createIncidentJson: - '{"fields":{"summary":{{{case.title}}},"description":{{{case.description}}},"project":{"key":"ROC"},"issuetype":{"id":"10024"}}}', - createIncidentMethod: 'post', - createIncidentResponseKey: 'id', - createIncidentUrl: 'http://some.non.existent.com/', - getIncidentResponseExternalTitleKey: 'key', - hasAuth: true, - headers: { [`content-type`]: 'application/json' }, - viewIncidentUrl: 'http://some.non.existent.com/browse/{{{external.system.title}}}', - getIncidentUrl: 'http://some.non.existent.com/{{{external.system.id}}}', - updateIncidentJson: - '{"fields":{"summary":{{{case.title}}},"description":{{{case.description}}},"project":{"key":"ROC"},"issuetype":{"id":"10024"}}}', - updateIncidentMethod: 'put', - updateIncidentUrl: 'http://some.non.existent.com/{{{external.system.id}}}', - }, -}); - export const getMappings = () => [ { source: 'title', @@ -298,60 +221,6 @@ export const getMappings = () => [ }, ]; -export const getResilientConnector = () => ({ - name: 'Resilient Connector', - connector_type_id: '.resilient', - secrets: { - apiKeyId: 'id', - apiKeySecret: 'secret', - }, - config: { - apiUrl: 'http://some.non.existent.com', - orgId: 'pkey', - }, -}); - -export const getServiceNowSIRConnector = () => ({ - name: 'ServiceNow SIR Connector', - connector_type_id: '.servicenow-sir', - secrets: { - username: 'admin', - password: 'password', - }, - config: { - apiUrl: 'http://some.non.existent.com', - usesTableApi: false, - }, -}); - -export const getWebhookConnector = () => ({ - name: 'A generic Webhook action', - connector_type_id: '.webhook', - secrets: { - user: 'user', - password: 'password', - }, - config: { - headers: { - 'Content-Type': 'text/plain', - }, - url: 'http://some.non.existent.com', - }, -}); - -export const getEmailConnector = () => ({ - name: 'An email action', - connector_type_id: '.email', - config: { - service: '__json', - from: 'bob@example.com', - }, - secrets: { - user: 'bob', - password: 'supersecret', - }, -}); - interface CommonSavedObjectAttributes { id?: string | null; created_at?: string | null; @@ -589,76 +458,6 @@ export const getCaseSavedObjectsFromES = async ({ es }: { es: Client }) => { return configure; }; -export const createCaseWithConnector = async ({ - supertest, - configureReq = {}, - serviceNowSimulatorURL, - actionsRemover, - auth = { user: superUser, space: null }, - createCaseReq = getPostCaseRequest(), - headers = {}, -}: { - supertest: SuperTest.SuperTest; - serviceNowSimulatorURL: string; - actionsRemover: ActionsRemover; - configureReq?: Record; - auth?: { user: User; space: string | null } | null; - createCaseReq?: CasePostRequest; - headers?: Record; -}): Promise<{ - postedCase: CaseResponse; - connector: CreateConnectorResponse; - configuration: CasesConfigureResponse; -}> => { - const connector = await createConnector({ - supertest, - req: { - ...getServiceNowConnector(), - config: { apiUrl: serviceNowSimulatorURL }, - }, - auth: auth ?? undefined, - }); - - actionsRemover.add(auth?.space ?? 'default', connector.id, 'action', 'actions'); - const configuration = await createConfiguration( - supertest, - { - ...getConfigurationRequest({ - id: connector.id, - name: connector.name, - type: connector.connector_type_id as ConnectorTypes, - }), - ...configureReq, - }, - 200, - auth ?? undefined - ); - - const postedCase = await createCase( - supertest, - { - ...createCaseReq, - connector: { - id: connector.id, - name: connector.name, - type: connector.connector_type_id, - fields: { - urgency: '2', - impact: '2', - severity: '2', - category: 'software', - subcategory: 'os', - }, - } as CaseConnector, - }, - 200, - auth, - headers - ); - - return { postedCase, connector, configuration }; -}; - export const createCase = async ( supertest: SuperTest.SuperTest, params: CasePostRequest, @@ -979,44 +778,6 @@ export type CreateConnectorResponse = Omit & { connector_type_id: string; }; -export const createConnector = async ({ - supertest, - req, - expectedHttpCode = 200, - auth = { user: superUser, space: null }, -}: { - supertest: SuperTest.SuperTest; - req: Record; - expectedHttpCode?: number; - auth?: { user: User; space: string | null }; -}): Promise => { - const { body: connector } = await supertest - .post(`${getSpaceUrlPrefix(auth.space)}/api/actions/connector`) - .auth(auth.user.username, auth.user.password) - .set('kbn-xsrf', 'true') - .send(req) - .expect(expectedHttpCode); - - return connector; -}; - -export const getCaseConnectors = async ({ - supertest, - expectedHttpCode = 200, - auth = { user: superUser, space: null }, -}: { - supertest: SuperTest.SuperTest; - expectedHttpCode?: number; - auth?: { user: User; space: string | null }; -}): Promise => { - const { body: connectors } = await supertest - .get(`${getSpaceUrlPrefix(auth.space)}${CASE_CONFIGURE_CONNECTORS_URL}/_find`) - .auth(auth.user.username, auth.user.password) - .expect(expectedHttpCode); - - return connectors; -}; - export const updateConfiguration = async ( supertest: SuperTest.SuperTest, id: string, @@ -1265,36 +1026,6 @@ export const getAlertsAttachedToCase = async ({ return theCase; }; -export const getRecordingServiceNowSimulatorServer = async (): Promise<{ - server: RecordingServiceNowSimulator; - url: string; -}> => { - const simulator = await RecordingServiceNowSimulator.start(); - const url = await startServiceNowSimulatorListening(simulator.server); - - return { server: simulator, url }; -}; - -const startServiceNowSimulatorListening = async (server: http.Server) => { - const port = await getPort({ port: getPort.makeRange(9000, 9100) }); - if (!server.listening) { - server.listen(port); - } - const url = `http://localhost:${port}`; - - return url; -}; - -export const getServiceNowSimulationServer = async (): Promise<{ - server: http.Server; - url: string; -}> => { - const server = await getServiceNowServer(); - const url = await startServiceNowSimulatorListening(server); - - return { server, url }; -}; - /** * Extracts the warning value a warning header that is formatted according to RFC 7234. * For example for the string 299 Kibana-8.1.0 "Deprecation endpoint", the return value is Deprecation endpoint. diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/cases/push_case.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/cases/push_case.ts index a78f70710dbad..536863dc95d0a 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/cases/push_case.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/cases/push_case.ts @@ -15,13 +15,13 @@ import { deleteComments, deleteConfiguration, getConfigurationRequest, - getServiceNowConnector, - createConnector, createConfiguration, createCase, pushCase, } from '../../../../common/lib/utils'; +import { getServiceNowConnector, createConnector } from '../../../../common/lib/connectors'; + // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { const supertest = getService('supertest'); diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/configure/get_connectors.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/configure/get_connectors.ts index 57854075c20fb..f91826f431d86 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/configure/get_connectors.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/basic/configure/get_connectors.ts @@ -8,7 +8,7 @@ import expect from '@kbn/expect'; import { FtrProviderContext } from '../../../../../common/ftr_provider_context'; -import { getCaseConnectors } from '../../../../common/lib/utils'; +import { getCaseConnectors } from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/common/configure/post_configure.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/common/configure/post_configure.ts index 47744830ec8b8..43cb5b21c978d 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/common/configure/post_configure.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/common/configure/post_configure.ts @@ -94,6 +94,11 @@ export default ({ getService }: FtrProviderContext): void => { source: 'description', target: 'description', }, + { + action_type: 'overwrite', + source: 'tags', + target: 'labels', + }, { action_type: 'append', source: 'comments', diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/no_public_base_url/push.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/no_public_base_url/push.ts index fe039eed5a023..715029434324a 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/no_public_base_url/push.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/no_public_base_url/push.ts @@ -18,13 +18,11 @@ import { import { FtrProviderContext } from '../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../alerting_api_integration/common/lib'; +import { pushCase, deleteAllCaseItems, bulkCreateAttachments } from '../../../common/lib/utils'; import { - pushCase, - deleteAllCaseItems, createCaseWithConnector, getRecordingServiceNowSimulatorServer, - bulkCreateAttachments, -} from '../../../common/lib/utils'; +} from '../../../common/lib/connectors'; import { RecordingServiceNowSimulator } from '../../../../alerting_api_integration/common/plugins/actions_simulators/server/servicenow_simulation'; // eslint-disable-next-line import/no-default-export diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/push_case.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/push_case.ts index e1051a3b5de12..a50c11ff41407 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/push_case.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/push_case.ts @@ -34,20 +34,22 @@ import { updateCase, deleteAllCaseItems, superUserSpace1Auth, - createCaseWithConnector, - createConnector, - getServiceNowConnector, getConnectorMappingsFromES, getCase, - getServiceNowSimulationServer, createConfiguration, getSignalsWithES, delay, calculateDuration, - getRecordingServiceNowSimulatorServer, getComment, bulkCreateAttachments, } from '../../../../common/lib/utils'; +import { + getServiceNowConnector, + createCaseWithConnector, + getRecordingServiceNowSimulatorServer, + getServiceNowSimulationServer, + createConnector, +} from '../../../../common/lib/connectors'; import { globalRead, noKibanaPrivileges, diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/user_actions/get_all_user_actions.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/user_actions/get_all_user_actions.ts index 77ac223a07592..81a6253076d2e 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/user_actions/get_all_user_actions.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/cases/user_actions/get_all_user_actions.ts @@ -13,17 +13,19 @@ import { FtrProviderContext } from '../../../../../common/ftr_provider_context'; import { defaultUser, getPostCaseRequest } from '../../../../../common/lib/mock'; import { createCase, - createCaseWithConnector, deleteCasesByESQuery, deleteCasesUserActions, deleteComments, deleteConfiguration, getCaseUserActions, - getServiceNowSimulationServer, pushCase, updateCase, updateConfiguration, } from '../../../../../common/lib/utils'; +import { + createCaseWithConnector, + getServiceNowSimulationServer, +} from '../../../../../common/lib/connectors'; import { ObjectRemover as ActionsRemover } from '../../../../../../alerting_api_integration/common/lib'; import { setupSuperUserProfile } from '../../../../../common/lib/user_profiles'; diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_configure.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_configure.ts index 3809806d9ec11..8b29db8e0f9b6 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_configure.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_configure.ts @@ -12,15 +12,17 @@ import { FtrProviderContext } from '../../../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; import { - getServiceNowConnector, - createConnector, createConfiguration, getConfiguration, getConfigurationRequest, removeServerGeneratedPropertiesFromSavedObject, getConfigurationOutput, - getServiceNowSimulationServer, } from '../../../../common/lib/utils'; +import { + getServiceNowConnector, + getServiceNowSimulationServer, + createConnector, +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_connectors.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_connectors.ts index 5ed6163a01543..32dc2173b4ec7 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_connectors.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/get_connectors.ts @@ -11,15 +11,15 @@ import { FtrProviderContext } from '../../../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; import { getServiceNowConnector, + getServiceNowSIRConnector, getServiceNowOAuthConnector, getJiraConnector, getResilientConnector, createConnector, - getServiceNowSIRConnector, getEmailConnector, getCaseConnectors, getCasesWebhookConnector, -} from '../../../../common/lib/utils'; +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/patch_configure.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/patch_configure.ts index 6fd90d0620fd2..0bec95a51b745 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/patch_configure.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/patch_configure.ts @@ -18,10 +18,12 @@ import { deleteConfiguration, createConfiguration, updateConfiguration, +} from '../../../../common/lib/utils'; +import { getServiceNowConnector, createConnector, getServiceNowSimulationServer, -} from '../../../../common/lib/utils'; +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/post_configure.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/post_configure.ts index f9df2610dca29..561008b71bd14 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/post_configure.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/configure/post_configure.ts @@ -17,10 +17,12 @@ import { getConfigurationOutput, deleteConfiguration, createConfiguration, - createConnector, +} from '../../../../common/lib/utils'; +import { getServiceNowConnector, getServiceNowSimulationServer, -} from '../../../../common/lib/utils'; + createConnector, +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/index.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/index.ts index becac642b1c2e..beb0c8e64045c 100644 --- a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/index.ts +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/index.ts @@ -38,6 +38,7 @@ export default ({ loadTestFile, getService }: FtrProviderContext): void => { // Internal routes loadTestFile(require.resolve('./internal/suggest_user_profiles')); + loadTestFile(require.resolve('./internal/get_connectors')); // Common loadTestFile(require.resolve('../common')); diff --git a/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/internal/get_connectors.ts b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/internal/get_connectors.ts new file mode 100644 index 0000000000000..bb4d9e8b99b8c --- /dev/null +++ b/x-pack/test/cases_api_integration/security_and_spaces/tests/trial/internal/get_connectors.ts @@ -0,0 +1,676 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import http from 'http'; +import expect from '@kbn/expect'; + +import { ActionTypes, CaseSeverity, ConnectorTypes } from '@kbn/cases-plugin/common/api'; +import { + globalRead, + noKibanaPrivileges, + obsOnly, + obsOnlyRead, + obsSec, + obsSecRead, + secOnly, + secOnlyRead, + superUser, +} from '../../../../common/lib/authentication/users'; +import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; +import { FtrProviderContext } from '../../../../common/ftr_provider_context'; +import { + createCase, + createComment, + deleteAllCaseItems, + getCaseUserActions, + pushCase, + updateCase, +} from '../../../../common/lib/utils'; +import { getPostCaseRequest, postCommentUserReq } from '../../../../common/lib/mock'; +import { + createCaseWithConnector, + createConnector, + getConnectors, + getJiraConnector, + getServiceNowConnector, + getServiceNowSimulationServer, +} from '../../../../common/lib/connectors'; + +// eslint-disable-next-line import/no-default-export +export default ({ getService }: FtrProviderContext): void => { + const supertest = getService('supertest'); + const es = getService('es'); + const actionsRemover = new ActionsRemover(supertest); + + describe('get_connectors', () => { + let serviceNowSimulatorURL: string = ''; + let serviceNowServer: http.Server; + + before(async () => { + const { server, url } = await getServiceNowSimulationServer(); + serviceNowServer = server; + serviceNowSimulatorURL = url; + }); + + afterEach(async () => { + await deleteAllCaseItems(es); + await actionsRemover.removeAll(); + }); + + after(async () => { + serviceNowServer.close(); + }); + + it('does not return the connectors for a case that does not have connectors', async () => { + const postedCase = await createCase(supertest, getPostCaseRequest()); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + expect(Object.keys(connectors).length).to.be(0); + }); + + it('retrieves multiple connectors', async () => { + const [{ postedCase, connector: serviceNowConnector }, jiraConnector] = await Promise.all([ + createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }), + createConnector({ + supertest, + req: { + ...getJiraConnector(), + }, + }), + ]); + + actionsRemover.add('default', jiraConnector.id, 'action', 'actions'); + + const theCase = await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: serviceNowConnector.id, + }); + + await updateCase({ + supertest, + params: { + cases: [ + { + id: theCase.id, + version: theCase.version, + connector: { + id: jiraConnector.id, + name: 'Jira', + type: ConnectorTypes.jira, + fields: { issueType: 'Task', priority: null, parent: null }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: theCase.id, supertest }); + expect(Object.keys(connectors).length).to.be(2); + expect(connectors[serviceNowConnector.id].id).to.be(serviceNowConnector.id); + expect(connectors[jiraConnector.id].id).to.be(jiraConnector.id); + }); + + describe('retrieving fields', () => { + it('retrieves a single connector using the create case user action', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const theCase = await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + const connectors = await getConnectors({ caseId: theCase.id, supertest }); + const snConnector = connectors[connector.id]; + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].fields).to.eql({ + category: 'software', + impact: '2', + severity: '2', + subcategory: 'os', + urgency: '2', + }); + + expect(snConnector.needsToBePushed).to.be(false); + expect(snConnector.name).to.be('ServiceNow Connector'); + expect(snConnector.id).to.be(connector.id); + }); + + it('retrieves a single connector using the connector user action', async () => { + const postedCase = await createCase(supertest, getPostCaseRequest()); + + const jiraConnector = await createConnector({ + supertest, + req: { + ...getJiraConnector(), + }, + }); + + actionsRemover.add('default', jiraConnector.id, 'action', 'actions'); + + await updateCase({ + supertest, + params: { + cases: [ + { + id: postedCase.id, + version: postedCase.version, + connector: { + id: jiraConnector.id, + name: 'Jira', + type: ConnectorTypes.jira, + fields: { issueType: 'Task', priority: null, parent: null }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[jiraConnector.id].id).to.be(jiraConnector.id); + }); + + it('returns the fields of the connector update after a case was created with a connector', async () => { + const { postedCase, connector: serviceNowConnector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + // change urgency to 3 + await updateCase({ + supertest, + params: { + cases: [ + { + id: postedCase.id, + version: postedCase.version, + connector: { + id: serviceNowConnector.id, + name: 'SN', + type: ConnectorTypes.serviceNowITSM, + fields: { + urgency: '3', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[serviceNowConnector.id].fields).to.eql({ + urgency: '3', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }); + }); + }); + + describe('push', () => { + describe('latestPushDate', () => { + it('does not set latestPushDate when the connector has not been used to push', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors).to.have.property(connector.id); + expect(connectors[connector.id].latestPushDate).to.be(undefined); + }); + + it('sets latestPushDate to the most recent push date', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + await createComment({ + supertest, + caseId: postedCase.id, + params: postCommentUserReq, + }); + + await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + const [userActions, connectors] = await Promise.all([ + getCaseUserActions({ supertest, caseID: postedCase.id }), + getConnectors({ caseId: postedCase.id, supertest }), + ]); + + const pushes = userActions.filter((ua) => ua.type === ActionTypes.pushed); + const latestPush = pushes[pushes.length - 1]; + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].latestPushDate).to.eql(latestPush.created_at); + }); + }); + + describe('hasBeenPushed', () => { + it('sets hasBeenPushed to false when the connector has not been used to push', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].hasBeenPushed).to.be(false); + }); + + it('sets hasBeenPushed to true when the connector was used to push', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].hasBeenPushed).to.be(true); + }); + }); + + describe('needsToBePushed', () => { + it('sets needs to push to true when a push has not occurred', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].id).to.be(connector.id); + expect(connectors[connector.id].needsToBePushed).to.be(true); + }); + + it('sets needs to push to false when a push has occurred', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].id).to.be(connector.id); + expect(connectors[connector.id].needsToBePushed).to.be(false); + }); + + it('sets needs to push to true when a comment was created after the last push', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + await createComment({ + supertest, + caseId: postedCase.id, + params: postCommentUserReq, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].id).to.be(connector.id); + expect(connectors[connector.id].needsToBePushed).to.be(true); + }); + + it('sets needs to push to false when the severity of a case was changed after the last push', async () => { + const { postedCase, connector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const pushedCase = await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: connector.id, + }); + + await updateCase({ + supertest, + params: { + cases: [ + { + id: pushedCase.id, + version: pushedCase.version, + severity: CaseSeverity.CRITICAL, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[connector.id].id).to.be(connector.id); + expect(connectors[connector.id].needsToBePushed).to.be(false); + }); + + it('sets needs to push to false the service now connector and true for jira', async () => { + const { postedCase, connector: serviceNowConnector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const [pushedCase, jiraConnector] = await Promise.all([ + pushCase({ + supertest, + caseId: postedCase.id, + connectorId: serviceNowConnector.id, + }), + createConnector({ + supertest, + req: { + ...getJiraConnector(), + }, + }), + ]); + + actionsRemover.add('default', jiraConnector.id, 'action', 'actions'); + + await updateCase({ + supertest, + params: { + cases: [ + { + id: pushedCase.id, + version: pushedCase.version, + connector: { + id: jiraConnector.id, + name: 'Jira', + type: ConnectorTypes.jira, + fields: { issueType: 'Task', priority: null, parent: null }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(2); + expect(connectors[serviceNowConnector.id].id).to.be(serviceNowConnector.id); + expect(connectors[serviceNowConnector.id].needsToBePushed).to.be(false); + expect(connectors[jiraConnector.id].id).to.be(jiraConnector.id); + expect(connectors[jiraConnector.id].needsToBePushed).to.be(true); + }); + + describe('changing connector fields', () => { + it('sets needs to push to false when the latest connector fields matches those used in the push', async () => { + const postedCase = await createCase(supertest, getPostCaseRequest()); + + const serviceNowConnector = await createConnector({ + supertest, + req: { + ...getServiceNowConnector(), + config: { apiUrl: serviceNowSimulatorURL }, + }, + }); + + actionsRemover.add('default', serviceNowConnector.id, 'action', 'actions'); + + const updatedCasesServiceNow = await updateCase({ + supertest, + params: { + cases: [ + { + id: postedCase.id, + version: postedCase.version, + connector: { + id: serviceNowConnector.id, + name: 'SN', + type: ConnectorTypes.serviceNowITSM, + fields: { + urgency: '2', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + }, + }, + ], + }, + }); + + const pushedCase = await pushCase({ + supertest, + caseId: updatedCasesServiceNow[0].id, + connectorId: serviceNowConnector.id, + }); + + // switch urgency to 3 + const updatedCases = await updateCase({ + supertest, + params: { + cases: [ + { + id: pushedCase.id, + version: pushedCase.version, + connector: { + id: serviceNowConnector.id, + name: 'SN', + type: ConnectorTypes.serviceNowITSM, + fields: { + urgency: '3', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + }, + }, + ], + }, + }); + + // switch urgency back to 2 + await updateCase({ + supertest, + params: { + cases: [ + { + id: updatedCases[0].id, + version: updatedCases[0].version, + connector: { + id: serviceNowConnector.id, + name: 'SN', + type: ConnectorTypes.serviceNowITSM, + fields: { + urgency: '2', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[serviceNowConnector.id].id).to.be(serviceNowConnector.id); + expect(connectors[serviceNowConnector.id].needsToBePushed).to.be(false); + }); + + it('sets needs to push to true when the latest connector fields do not match those used in the push', async () => { + const { postedCase, connector: serviceNowConnector } = await createCaseWithConnector({ + supertest, + serviceNowSimulatorURL, + actionsRemover, + }); + + const pushedCase = await pushCase({ + supertest, + caseId: postedCase.id, + connectorId: serviceNowConnector.id, + }); + + // switch urgency to 3 + await updateCase({ + supertest, + params: { + cases: [ + { + id: pushedCase.id, + version: pushedCase.version, + connector: { + id: serviceNowConnector.id, + name: 'SN', + type: ConnectorTypes.serviceNowITSM, + fields: { + urgency: '3', + impact: '2', + severity: '2', + category: 'software', + subcategory: 'os', + }, + }, + }, + ], + }, + }); + + const connectors = await getConnectors({ caseId: postedCase.id, supertest }); + + expect(Object.keys(connectors).length).to.be(1); + expect(connectors[serviceNowConnector.id].id).to.be(serviceNowConnector.id); + expect(connectors[serviceNowConnector.id].needsToBePushed).to.be(true); + }); + }); + }); + }); + + describe('rbac', () => { + const supertestWithoutAuth = getService('supertestWithoutAuth'); + + it('should retrieve the connectors for a case', async () => { + const { postedCase, connector: serviceNowConnector } = await createCaseWithConnector({ + supertest: supertestWithoutAuth, + serviceNowSimulatorURL, + actionsRemover, + auth: { user: superUser, space: 'space1' }, + createCaseReq: getPostCaseRequest({ owner: 'securitySolutionFixture' }), + }); + + for (const user of [globalRead, superUser, secOnly, secOnlyRead, obsSec, obsSecRead]) { + const connectors = await getConnectors({ + supertest: supertestWithoutAuth, + caseId: postedCase.id, + auth: { user, space: 'space1' }, + }); + + expect(Object.keys(connectors).length).to.eql(1); + expect(connectors[serviceNowConnector.id].id).to.eql(serviceNowConnector.id); + } + }); + + it('should not get connectors for a case when the user does not have access to the owner', async () => { + const { postedCase } = await createCaseWithConnector({ + supertest: supertestWithoutAuth, + serviceNowSimulatorURL, + actionsRemover, + auth: { user: superUser, space: 'space1' }, + createCaseReq: getPostCaseRequest({ owner: 'securitySolutionFixture' }), + }); + + for (const user of [noKibanaPrivileges, obsOnly, obsOnlyRead]) { + await getConnectors({ + supertest: supertestWithoutAuth, + caseId: postedCase.id, + expectedHttpCode: 403, + auth: { user, space: 'space1' }, + }); + } + }); + + it('should not get a case in a space the user does not have permissions to', async () => { + const { postedCase } = await createCaseWithConnector({ + supertest: supertestWithoutAuth, + serviceNowSimulatorURL, + actionsRemover, + auth: { user: superUser, space: 'space2' }, + createCaseReq: getPostCaseRequest({ owner: 'securitySolutionFixture' }), + }); + + await getConnectors({ + supertest: supertestWithoutAuth, + caseId: postedCase.id, + expectedHttpCode: 403, + auth: { user: secOnly, space: 'space2' }, + }); + }); + }); + }); +}; diff --git a/x-pack/test/cases_api_integration/spaces_only/tests/trial/cases/push_case.ts b/x-pack/test/cases_api_integration/spaces_only/tests/trial/cases/push_case.ts index 09cbc2b9ad18b..5d97cea038d5f 100644 --- a/x-pack/test/cases_api_integration/spaces_only/tests/trial/cases/push_case.ts +++ b/x-pack/test/cases_api_integration/spaces_only/tests/trial/cases/push_case.ts @@ -12,13 +12,12 @@ import { FtrProviderContext } from '../../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; import { nullUser } from '../../../../common/lib/mock'; +import { pushCase, deleteAllCaseItems, getAuthWithSuperUser } from '../../../../common/lib/utils'; + import { - pushCase, - deleteAllCaseItems, createCaseWithConnector, - getAuthWithSuperUser, getServiceNowSimulationServer, -} from '../../../../common/lib/utils'; +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_configure.ts b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_configure.ts index c68437968e0da..025e7ba08308f 100644 --- a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_configure.ts +++ b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_configure.ts @@ -12,16 +12,18 @@ import { FtrProviderContext } from '../../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; import { - getServiceNowConnector, - createConnector, createConfiguration, getConfiguration, getConfigurationRequest, removeServerGeneratedPropertiesFromSavedObject, getConfigurationOutput, getAuthWithSuperUser, - getServiceNowSimulationServer, } from '../../../../common/lib/utils'; +import { + getServiceNowConnector, + createConnector, + getServiceNowSimulationServer, +} from '../../../../common/lib/connectors'; import { nullUser } from '../../../../common/lib/mock'; // eslint-disable-next-line import/no-default-export diff --git a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_connectors.ts b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_connectors.ts index 5ec6db8bd62fb..2d5269baaf270 100644 --- a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_connectors.ts +++ b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/get_connectors.ts @@ -9,19 +9,18 @@ import expect from '@kbn/expect'; import { FtrProviderContext } from '../../../../common/ftr_provider_context'; import { ObjectRemover as ActionsRemover } from '../../../../../alerting_api_integration/common/lib'; +import { getAuthWithSuperUser, getActionsSpace } from '../../../../common/lib/utils'; import { getServiceNowConnector, - getServiceNowOAuthConnector, - getJiraConnector, - getResilientConnector, - createConnector, getServiceNowSIRConnector, - getAuthWithSuperUser, - getCaseConnectors, - getActionsSpace, getEmailConnector, + getCaseConnectors, getCasesWebhookConnector, -} from '../../../../common/lib/utils'; + getServiceNowOAuthConnector, + getJiraConnector, + createConnector, + getResilientConnector, +} from '../../../../common/lib/connectors'; // eslint-disable-next-line import/no-default-export export default ({ getService }: FtrProviderContext): void => { diff --git a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/patch_configure.ts b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/patch_configure.ts index e984cab68f9dd..54423a3195672 100644 --- a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/patch_configure.ts +++ b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/patch_configure.ts @@ -18,12 +18,14 @@ import { deleteConfiguration, createConfiguration, updateConfiguration, - getServiceNowConnector, - createConnector, getAuthWithSuperUser, getActionsSpace, - getServiceNowSimulationServer, } from '../../../../common/lib/utils'; +import { + getServiceNowConnector, + createConnector, + getServiceNowSimulationServer, +} from '../../../../common/lib/connectors'; import { nullUser } from '../../../../common/lib/mock'; // eslint-disable-next-line import/no-default-export diff --git a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/post_configure.ts b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/post_configure.ts index 4a8ffe56d35eb..97e80e790312e 100644 --- a/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/post_configure.ts +++ b/x-pack/test/cases_api_integration/spaces_only/tests/trial/configure/post_configure.ts @@ -17,12 +17,14 @@ import { getConfigurationOutput, deleteConfiguration, createConfiguration, - createConnector, - getServiceNowConnector, getAuthWithSuperUser, getActionsSpace, - getServiceNowSimulationServer, } from '../../../../common/lib/utils'; +import { + getServiceNowConnector, + createConnector, + getServiceNowSimulationServer, +} from '../../../../common/lib/connectors'; import { nullUser } from '../../../../common/lib/mock'; // eslint-disable-next-line import/no-default-export diff --git a/x-pack/test/detection_engine_api_integration/security_and_spaces/group10/get_rule_execution_results.ts b/x-pack/test/detection_engine_api_integration/security_and_spaces/group10/get_rule_execution_results.ts index 1e19f79189e11..96f710ad32e9f 100644 --- a/x-pack/test/detection_engine_api_integration/security_and_spaces/group10/get_rule_execution_results.ts +++ b/x-pack/test/detection_engine_api_integration/security_and_spaces/group10/get_rule_execution_results.ts @@ -10,7 +10,7 @@ import dateMath from '@kbn/datemath'; import expect from '@kbn/expect'; import moment from 'moment'; import { set } from '@kbn/safer-lodash-set'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { getRuleExecutionResultsUrl, RuleExecutionStatus, @@ -128,7 +128,7 @@ export default ({ getService }: FtrProviderContext) => { }); it('should return execution events for a rule that has executed in a failure state with a gap', async () => { - const rule = getRuleForSignalTesting(['auditbeat-*'], uuid.v4(), false); + const rule = getRuleForSignalTesting(['auditbeat-*'], uuidv4(), false); const { id } = await createRule(supertest, log, rule); const start = dateMath.parse('now')?.utc().toISOString(); @@ -176,7 +176,7 @@ export default ({ getService }: FtrProviderContext) => { // For details, see: https://github.com/elastic/kibana/issues/131382 it('should return execution events ordered by @timestamp desc when a status filter is active and there are more than 1000 executions', async () => { - const rule = getRuleForSignalTesting(['auditbeat-*'], uuid.v4(), false); + const rule = getRuleForSignalTesting(['auditbeat-*'], uuidv4(), false); const { id } = await createRule(supertest, log, rule); // Daterange for which we'll generate execution events between @@ -193,7 +193,7 @@ export default ({ getService }: FtrProviderContext) => { // Create 1000 successful executions const events = dateTimes.slice(0, 1000).flatMap((dateTime) => { - const executionId = uuid.v4(); + const executionId = uuidv4(); return cloneDeep(successfulExecution).map((e, i) => { set(e, '@timestamp', dateTime); set(e, 'event.start', dateTime); @@ -209,7 +209,7 @@ export default ({ getService }: FtrProviderContext) => { // Create 2 failed executions const failedEvents = dateTimes.slice(1000).flatMap((dateTime) => { - const executionId = uuid.v4(); + const executionId = uuidv4(); return cloneDeep(failedRanAfterDisabled).map((e, i) => { set(e, '@timestamp', dateTime); set(e, 'event.start', dateTime); diff --git a/x-pack/test/detection_engine_api_integration/utils/install_detection_rules_package_from_fleet.ts b/x-pack/test/detection_engine_api_integration/utils/install_detection_rules_package_from_fleet.ts new file mode 100644 index 0000000000000..72408d8fd2af1 --- /dev/null +++ b/x-pack/test/detection_engine_api_integration/utils/install_detection_rules_package_from_fleet.ts @@ -0,0 +1,61 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { epmRouteService } from '@kbn/fleet-plugin/common'; +import { InstallPackageResponse } from '@kbn/fleet-plugin/common/types'; +import type { ToolingLog } from '@kbn/tooling-log'; +import type SuperTest from 'supertest'; + +/** + * Installed the security_detection_engine package via fleet API. Will + * @param supertest The supertest deps + * @param log The tooling logger + * @param version The version to install, e.g. '8.4.1' + * @param overrideExistingPackage Whether or not to force the install + */ +export const installDetectionRulesPackageFromFleet = async ( + supertest: SuperTest.SuperTest, + log: ToolingLog, + version: string, + overrideExistingPackage: true +): Promise => { + const response = await supertest + .post(epmRouteService.getInstallPath('security_detection_engine', version)) + .set('kbn-xsrf', 'true') + .send({ + force: overrideExistingPackage, + }); + if (response.status !== 200) { + log.error( + `Did not get an expected 200 "ok" when installing 'security_detection_engine' fleet package'. body: ${JSON.stringify( + response.body + )}, status: ${JSON.stringify(response.status)}` + ); + } + return response.body; +}; + +/** + * Returns the `--xpack.securitySolution.prebuiltRulesPackageVersion=8.3.1` setting + * as configured in the kbnServerArgs from the test's config.ts. + * @param kbnServerArgs Kibana server args within scope + */ +export const getPrebuiltRulesPackageVersionFromServerArgs = (kbnServerArgs: string[]): string => { + const re = + /--xpack\.securitySolution\.prebuiltRulesPackageVersion=(?.*)/; + for (const serverArg of kbnServerArgs) { + const match = re.exec(serverArg); + const prebuiltRulesPackageVersion = match?.groups?.prebuiltRulesPackageVersion; + if (prebuiltRulesPackageVersion) { + return prebuiltRulesPackageVersion; + } + } + + throw Error( + 'xpack.securitySolution.prebuiltRulesPackageVersion is not set in the server arguments' + ); +}; diff --git a/x-pack/test/fleet_api_integration/apis/agent_policy/agent_policy.ts b/x-pack/test/fleet_api_integration/apis/agent_policy/agent_policy.ts index b8703cd5a1380..c437197f9cafb 100644 --- a/x-pack/test/fleet_api_integration/apis/agent_policy/agent_policy.ts +++ b/x-pack/test/fleet_api_integration/apis/agent_policy/agent_policy.ts @@ -58,6 +58,7 @@ export default function (providerContext: FtrProviderContext) { const { body } = await supertest.get(`/api/fleet/agent_policies/${createdPolicy.id}`); expect(body.item.is_managed).to.equal(false); + expect(body.item.inactivity_timeout).to.equal(1209600); expect(body.item.status).to.be('active'); }); @@ -624,6 +625,7 @@ export default function (providerContext: FtrProviderContext) { revision: 2, schema_version: FLEET_AGENT_POLICIES_SCHEMA_VERSION, updated_by: 'elastic', + inactivity_timeout: 1209600, package_policies: [], }); }); @@ -787,6 +789,7 @@ export default function (providerContext: FtrProviderContext) { updated_by: 'elastic', package_policies: [], monitoring_enabled: ['logs', 'metrics'], + inactivity_timeout: 1209600, }); const listResponseAfterUpdate = await fetchPackageList(); diff --git a/x-pack/test/fleet_api_integration/apis/agents/actions.ts b/x-pack/test/fleet_api_integration/apis/agents/actions.ts index 6118f6d6239d2..0e592cf9281fd 100644 --- a/x-pack/test/fleet_api_integration/apis/agents/actions.ts +++ b/x-pack/test/fleet_api_integration/apis/agents/actions.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; import { testUsers } from '../test_users'; @@ -111,11 +111,11 @@ export default function (providerContext: FtrProviderContext) { }); it('should return a 200 and create a CANCEL action if the action exists', async () => { - const actionId = uuid(); + const actionId = uuidv4(); await es.create({ index: '.fleet-actions', refresh: 'wait_for', - id: uuid(), + id: uuidv4(), body: { '@timestamp': new Date().toISOString(), expiration: new Date().toISOString(), diff --git a/x-pack/test/fleet_api_integration/apis/agents/unenroll.ts b/x-pack/test/fleet_api_integration/apis/agents/unenroll.ts index 7f778d77f1a51..934cd16040cf6 100644 --- a/x-pack/test/fleet_api_integration/apis/agents/unenroll.ts +++ b/x-pack/test/fleet_api_integration/apis/agents/unenroll.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; import { setupFleetAndAgents } from './services'; @@ -32,13 +32,13 @@ export default function (providerContext: FtrProviderContext) { await getService('supertest').post(`/api/fleet/setup`).set('kbn-xsrf', 'xxx').send(); const accessAPIKeyBody = await esClient.security.createApiKey({ body: { - name: `test access api key: ${uuid.v4()}`, + name: `test access api key: ${uuidv4()}`, }, }); accessAPIKeyId = accessAPIKeyBody.id; const outputAPIKeyBody = await esClient.security.createApiKey({ body: { - name: `test output api key: ${uuid.v4()}`, + name: `test output api key: ${uuidv4()}`, }, }); outputAPIKeyId = outputAPIKeyBody.id; diff --git a/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts b/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts index 86e91d6707c5a..3231b9d9a438a 100644 --- a/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts +++ b/x-pack/test/fleet_api_integration/apis/epm/install_prerelease.ts @@ -4,7 +4,7 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ - +import expect from '@kbn/expect'; import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; import { skipIfNoDockerRegistry } from '../../helpers'; import { setupFleetAndAgents } from '../agents/services'; @@ -39,5 +39,64 @@ export default function (providerContext: FtrProviderContext) { .set('kbn-xsrf', 'xxxx') .expect(200); }); + + const pkg = 'endpoint'; + const gaVersion = '8.6.1'; + const betaVersion = '8.7.0-next'; + + afterEach(async () => { + await deletePackage(pkg, gaVersion); + await deletePackage(pkg, betaVersion); + }); + + it('should install the GA package correctly', async function () { + const response = await supertest + .post(`/api/fleet/epm/packages/${pkg}/${gaVersion}`) + .set('kbn-xsrf', 'xxxx') + .send({ force: true }) + .expect(200); + + expect(response.body.items.find((item: any) => item.id.includes(gaVersion))); + }); + + it('should install the GA package when no version is provided', async function () { + const response = await supertest + .post(`/api/fleet/epm/packages/${pkg}`) + .set('kbn-xsrf', 'xxxx') + .send({ force: true }) + .expect(200); + + expect(response.body.items.find((item: any) => item.id.includes(gaVersion))); + }); + + it('should install the beta package when no version is provided and prerelease is true', async function () { + const response = await supertest + .post(`/api/fleet/epm/packages/${pkg}?prerelease=true`) + .set('kbn-xsrf', 'xxxx') + .send({ force: true }) // using force to ignore package verification error + .expect(200); + + expect(response.body.items.find((item: any) => item.id.includes(betaVersion))); + }); + + it('should bulk install the beta packages when prerelease is true', async function () { + const response = await supertest + .post(`/api/fleet/epm/packages/_bulk?prerelease=true`) + .set('kbn-xsrf', 'xxxx') + .send({ packages: ['endpoint'], force: true }) + .expect(200); + + expect(response.body.items[0].version).equal(betaVersion); + }); + + it('should bulk install the GA packages when prerelease is not set', async function () { + const response = await supertest + .post(`/api/fleet/epm/packages/_bulk`) + .set('kbn-xsrf', 'xxxx') + .send({ packages: ['endpoint'], force: true }) + .expect(200); + + expect(response.body.items[0].version).equal(gaVersion); + }); }); } diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip new file mode 100644 index 0000000000000..2002c1c8c2002 Binary files /dev/null and b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/endpoint/endpoint-8.7.0-next.zip differ diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/agent/input/input.yml.hbs b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/agent/input/input.yml.hbs new file mode 100644 index 0000000000000..1ba86fa98a2f8 --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/agent/input/input.yml.hbs @@ -0,0 +1,18 @@ +paths: +{{#each paths}} + - {{this}} +{{/each}} + +{{#if tags}} +tags: +{{#each tags as |tag i|}} + - {{tag}} +{{/each}} +{{/if}} + +{{#if pipeline}} +pipeline: {{pipeline}} +{{/if}} + +data_stream: + dataset: {{data_stream.dataset}} \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/changelog.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/changelog.yml new file mode 100644 index 0000000000000..20fdaba3bd1c3 --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/changelog.yml @@ -0,0 +1,6 @@ +# newer versions go on top +- version: "1.2.0-beta" + changes: + - description: Initial draft of the package + type: enhancement + link: https://github.com/elastic/package-spec/pull/325 diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/docs/README.md b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/docs/README.md new file mode 100644 index 0000000000000..9f29c89e0f5ef --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/docs/README.md @@ -0,0 +1 @@ +# Custom Logs \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/fields/input.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/fields/input.yml new file mode 100644 index 0000000000000..f5851c64b6b3a --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/fields/input.yml @@ -0,0 +1,4 @@ +- name: input.name + type: constant_keyword + description: Sample field to be added. + value: logs \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-logo.svg b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-logo.svg new file mode 100644 index 0000000000000..6268dd88f3b3d --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-screenshot.png b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-screenshot.png new file mode 100644 index 0000000000000..d7a56a3ecc078 Binary files /dev/null and b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/img/sample-screenshot.png differ diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/manifest.yml new file mode 100644 index 0000000000000..5c0811e80e65c --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.0.0/manifest.yml @@ -0,0 +1,45 @@ +format_version: 1.0.0 +name: input_package_upgrade +title: Custom Logs +description: >- + A version of the custom_logs input pkg designed to test upgrade behaviour +type: input +version: 1.0.0 +license: basic +categories: + - custom +policy_templates: + - name: logs + type: logs + title: Custom log file + description: Collect your custom log files. + input: logfile + template_path: input.yml.hbs + vars: + - name: paths + type: text + title: Paths + multi: true + required: true + show_user: true + - name: tags + type: text + title: Tags + multi: true + required: true + show_user: false + - name: ignore_older + type: text + title: Ignore events older than + required: false + default: 72h +icons: + - src: "/img/sample-logo.svg" + type: "image/svg+xml" +screenshots: + - src: "/img/sample-screenshot.png" + title: "Sample screenshot" + size: "600x600" + type: "image/png" +owner: + github: elastic/integrations \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/agent/input/input.yml.hbs b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/agent/input/input.yml.hbs new file mode 100644 index 0000000000000..1ba86fa98a2f8 --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/agent/input/input.yml.hbs @@ -0,0 +1,18 @@ +paths: +{{#each paths}} + - {{this}} +{{/each}} + +{{#if tags}} +tags: +{{#each tags as |tag i|}} + - {{tag}} +{{/each}} +{{/if}} + +{{#if pipeline}} +pipeline: {{pipeline}} +{{/if}} + +data_stream: + dataset: {{data_stream.dataset}} \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/changelog.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/changelog.yml new file mode 100644 index 0000000000000..53a8cc6ad57bb --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/changelog.yml @@ -0,0 +1,12 @@ +# newer versions go on top +- version: "1.1.0" + changes: + - description: Add elasticsearch key to manifest + type: enhancement + link: https://github.com/elastic/package-spec/pull/325 +# newer versions go on top +- version: "1.0.0" + changes: + - description: Initial draft of the package + type: enhancement + link: https://github.com/elastic/package-spec/pull/325 diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/docs/README.md b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/docs/README.md new file mode 100644 index 0000000000000..9f29c89e0f5ef --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/docs/README.md @@ -0,0 +1 @@ +# Custom Logs \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/fields/input.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/fields/input.yml new file mode 100644 index 0000000000000..f5851c64b6b3a --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/fields/input.yml @@ -0,0 +1,4 @@ +- name: input.name + type: constant_keyword + description: Sample field to be added. + value: logs \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-logo.svg b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-logo.svg new file mode 100644 index 0000000000000..6268dd88f3b3d --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-logo.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-screenshot.png b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-screenshot.png new file mode 100644 index 0000000000000..d7a56a3ecc078 Binary files /dev/null and b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/img/sample-screenshot.png differ diff --git a/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/manifest.yml b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/manifest.yml new file mode 100644 index 0000000000000..af623137f15cd --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/fixtures/test_packages/input_package_upgrade/1.1.0/manifest.yml @@ -0,0 +1,57 @@ +format_version: 1.0.0 +name: input_package_upgrade +title: Custom Logs +description: >- + A version of the custom_logs input pkg designed to test upgrade behaviour +type: input +version: 1.1.0 +license: basic +categories: + - custom +policy_templates: + - name: logs + type: logs + title: Custom log file + description: Collect your custom log files. + input: logfile + template_path: input.yml.hbs + vars: + - name: paths + type: text + title: Paths + multi: true + required: true + show_user: true + - name: tags + type: text + title: Tags + multi: true + required: true + show_user: false + - name: ignore_older + type: text + title: Ignore events older than + required: false + default: 72h +icons: + - src: "/img/sample-logo.svg" + type: "image/svg+xml" +screenshots: + - src: "/img/sample-screenshot.png" + title: "Sample screenshot" + size: "600x600" + type: "image/png" +owner: + github: elastic/integrations +elasticsearch: + index_template: + mappings: + properties: + '@timestamp': + ignore_malformed: false + type: date + dynamic_templates: + - data_stream_to_constant: + mapping: + type: constant_keyword + path_match: data_stream.* \ No newline at end of file diff --git a/x-pack/test/fleet_api_integration/apis/fleet_telemetry.ts b/x-pack/test/fleet_api_integration/apis/fleet_telemetry.ts index 21d1bc646c5c8..04b8d80fdbee1 100644 --- a/x-pack/test/fleet_api_integration/apis/fleet_telemetry.ts +++ b/x-pack/test/fleet_api_integration/apis/fleet_telemetry.ts @@ -110,6 +110,7 @@ export default function (providerContext: FtrProviderContext) { await generateAgent(providerContext, 'healthy', `agent-${++agentCount}`, agentPolicy.id); await generateAgent(providerContext, 'offline', `agent-${++agentCount}`, agentPolicy.id); await generateAgent(providerContext, 'error', `agent-${++agentCount}`, agentPolicy.id); + await generateAgent(providerContext, 'inactive', `agent-${++agentCount}`, agentPolicy.id); await generateAgent(providerContext, 'degraded', `agent-${++agentCount}`, agentPolicy.i); await generateAgent( providerContext, @@ -137,7 +138,7 @@ export default function (providerContext: FtrProviderContext) { unhealthy: 3, offline: 1, unenrolled: 0, - inactive: 0, + inactive: 1, updating: 1, total_all_statuses: 8, }); diff --git a/x-pack/test/fleet_api_integration/apis/index.js b/x-pack/test/fleet_api_integration/apis/index.js index 60235bb6fc482..99be7518fd882 100644 --- a/x-pack/test/fleet_api_integration/apis/index.js +++ b/x-pack/test/fleet_api_integration/apis/index.js @@ -31,6 +31,7 @@ export default function ({ loadTestFile, getService }) { loadTestFile(require.resolve('./package_policy/get')); loadTestFile(require.resolve('./package_policy/delete')); loadTestFile(require.resolve('./package_policy/upgrade')); + loadTestFile(require.resolve('./package_policy/input_package_create_upgrade')); // Agent policies loadTestFile(require.resolve('./agent_policy')); diff --git a/x-pack/test/fleet_api_integration/apis/package_policy/create.ts b/x-pack/test/fleet_api_integration/apis/package_policy/create.ts index 21a5fa0f6dc2a..ed5122d02eb4f 100644 --- a/x-pack/test/fleet_api_integration/apis/package_policy/create.ts +++ b/x-pack/test/fleet_api_integration/apis/package_policy/create.ts @@ -7,7 +7,7 @@ import type { Client } from '@elastic/elasticsearch'; import expect from '@kbn/expect'; import { Installation } from '@kbn/fleet-plugin/common'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; import { skipIfNoDockerRegistry } from '../../helpers'; @@ -44,7 +44,7 @@ export default function (providerContext: FtrProviderContext) { .post(`/api/fleet/agent_policies`) .set('kbn-xsrf', 'xxxx') .send({ - name: `Test policy ${uuid()}`, + name: `Test policy ${uuidv4()}`, namespace: 'default', }) .expect(200); @@ -287,7 +287,7 @@ export default function (providerContext: FtrProviderContext) { .post(`/api/fleet/agent_policies`) .set('kbn-xsrf', 'xxxx') .send({ - name: `Test policy ${uuid()}`, + name: `Test policy ${uuidv4()}`, namespace: 'default', }); const otherAgentPolicyId = agentPolicyResponse.item.id; diff --git a/x-pack/test/fleet_api_integration/apis/package_policy/input_package_create_upgrade.ts b/x-pack/test/fleet_api_integration/apis/package_policy/input_package_create_upgrade.ts new file mode 100644 index 0000000000000..5765fc3832099 --- /dev/null +++ b/x-pack/test/fleet_api_integration/apis/package_policy/input_package_create_upgrade.ts @@ -0,0 +1,388 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import expect from '@kbn/expect'; +import { sortBy } from 'lodash'; +import { FtrProviderContext } from '../../../api_integration/ftr_provider_context'; +import { skipIfNoDockerRegistry } from '../../helpers'; +import { setupFleetAndAgents } from '../agents/services'; +const PACKAGE_NAME = 'input_package_upgrade'; +const START_VERSION = '1.0.0'; +const UPGRADE_VERSION = '1.1.0'; + +const expectIdArraysEqual = (arr1: any[], arr2: any[]) => { + expect(sortBy(arr1, 'id')).to.eql(sortBy(arr2, 'id')); +}; +export default function (providerContext: FtrProviderContext) { + const { getService } = providerContext; + const supertest = getService('supertest'); + const es = getService('es'); + const uninstallPackage = async (name: string, version: string) => { + await supertest.delete(`/api/fleet/epm/packages/${name}/${version}`).set('kbn-xsrf', 'xxxx'); + }; + + const installPackage = async (name: string, version: string) => { + return await supertest + .post(`/api/fleet/epm/packages/${name}/${version}`) + .set('kbn-xsrf', 'xxxx') + .send({ force: true }) + .expect(200); + }; + + const getInstallationSavedObject = async (name: string, version: string) => { + const res = await supertest.get(`/api/fleet/epm/packages/${name}-${version}`).expect(200); + return res.body.item.savedObject.attributes; + }; + + const createPackagePolicyWithDataset = async ( + agentPolicyId: string, + dataset: string, + expectStatusCode = 200, + force = false + ) => { + const policy = { + force, + policy_id: agentPolicyId, + package: { + name: PACKAGE_NAME, + version: START_VERSION, + }, + name: 'test-policy-' + dataset, + description: '', + namespace: 'default', + inputs: { + 'logs-logfile': { + enabled: true, + streams: { + 'input_package_upgrade.logs': { + enabled: true, + vars: { + paths: ['/tmp/test/log'], + tags: ['tag1'], + ignore_older: '72h', + 'data_stream.dataset': dataset, + }, + }, + }, + }, + }, + }; + const res = await supertest + .post(`/api/fleet/package_policies`) + .set('kbn-xsrf', 'xxxx') + .send(policy) + .expect(expectStatusCode); + + return res.body.item; + }; + + const deletePackagePolicy = (id: string) => { + return supertest + .delete(`/api/fleet/package_policies/${id}`) + .set('kbn-xsrf', 'xxxx') + .expect(200); + }; + + const createAgentPolicy = async (name = 'Input Package Test 3') => { + const res = await supertest + .post(`/api/fleet/agent_policies`) + .set('kbn-xsrf', 'xxxx') + .send({ + name, + namespace: 'default', + }) + .expect(200); + return res.body.item; + }; + + const deleteAgentPolicy = async (agentPolicyId: string) => { + if (!agentPolicyId) return; + return supertest + .post(`/api/fleet/agent_policies/delete`) + .set('kbn-xsrf', 'xxxx') + .send({ agentPolicyId }); + }; + + const getComponentTemplate = async (name: string) => { + try { + const { component_templates: templates } = await es.cluster.getComponentTemplate({ name }); + + return templates?.[0] || null; + } catch (e) { + if (e.statusCode === 404) { + return null; + } + + throw e; + } + }; + + const getIndexTemplate = async (name: string) => { + try { + const { index_templates: templates } = await es.indices.getIndexTemplate({ name }); + + return templates?.[0]?.index_template || null; + } catch (e) { + if (e.statusCode === 404) { + return null; + } + } + }; + + const createFakeFleetIndexTemplate = async (dataset: string, pkgName = PACKAGE_NAME) => { + const templateName = `logs-${dataset}`; + const template = { + name: templateName, + index_patterns: [`${templateName}-*`], + priority: 200, + _meta: { + package: { + name: pkgName, + }, + managed_by: 'fleet', + managed: true, + }, + data_stream: {}, + template: { + settings: { + number_of_shards: 1, + }, + mappings: { + properties: {}, + }, + }, + }; + await es.indices.putIndexTemplate(template); + }; + + const createFakeFleetDataStream = async (dataset: string, pkgName = PACKAGE_NAME) => { + const indexName = `logs-${dataset}-default`; + await createFakeFleetIndexTemplate(dataset, pkgName); + + await es.index({ + index: indexName, + body: { + '@timestamp': new Date().toISOString(), + message: 'test', + }, + }); + }; + + const deleteDataStream = async (templateName: string) => { + await es.indices.deleteDataStream({ name: templateName + '-default' }); + await deleteIndexTemplate(templateName); + }; + + const deleteIndexTemplate = async (templateName: string) => { + await es.indices.deleteIndexTemplate({ name: templateName }); + }; + + describe('Package Policy - input package behavior', async function () { + skipIfNoDockerRegistry(providerContext); + + let agentPolicyId: string; + const packagePolicyIds: string[] = []; + before(async () => { + installPackage(PACKAGE_NAME, START_VERSION); + const agentPolicy = await createAgentPolicy(); + agentPolicyId = agentPolicy.id; + }); + + after(async () => { + await deleteAgentPolicy(agentPolicyId); + }); + setupFleetAndAgents(providerContext); + + it('should not have created any ES assets on install', async () => { + const installation = await getInstallationSavedObject(PACKAGE_NAME, START_VERSION); + expect(installation.installed_es).to.eql([]); + }); + + it('should create index templates and update installed_es on package policy creation', async () => { + const packagePolicy = await createPackagePolicyWithDataset(agentPolicyId, 'dataset1'); + packagePolicyIds.push(packagePolicy.id); + const installation = await getInstallationSavedObject(PACKAGE_NAME, START_VERSION); + expectIdArraysEqual(installation.installed_es, [ + { id: 'logs-dataset1-1.0.0', type: 'ingest_pipeline' }, + { id: 'logs-dataset1', type: 'index_template' }, + { id: 'logs-dataset1@package', type: 'component_template' }, + { id: 'logs-dataset1@custom', type: 'component_template' }, + ]); + + // now check the package component template was created correctly + const packageComponentTemplate = await getComponentTemplate('logs-dataset1@package'); + expect(packageComponentTemplate).eql({ + name: 'logs-dataset1@package', + component_template: { + template: { + settings: { + index: { + lifecycle: { name: 'logs' }, + codec: 'best_compression', + default_pipeline: 'logs-dataset1-1.0.0', + mapping: { total_fields: { limit: '10000' } }, + }, + }, + mappings: { + properties: { + input: { + properties: { + name: { + type: 'constant_keyword', + value: 'logs', + }, + }, + }, + }, + }, + }, + _meta: { + package: { name: 'input_package_upgrade' }, + managed_by: 'fleet', + managed: true, + }, + }, + }); + }); + + it('should create index templates and update installed_es on second package policy creation', async () => { + const packagePolicy = await createPackagePolicyWithDataset(agentPolicyId, 'dataset2'); + packagePolicyIds.push(packagePolicy.id); + const installation = await getInstallationSavedObject(PACKAGE_NAME, START_VERSION); + expectIdArraysEqual(installation.installed_es, [ + { id: 'logs-dataset1-1.0.0', type: 'ingest_pipeline' }, + { id: 'logs-dataset1', type: 'index_template' }, + { id: 'logs-dataset1@package', type: 'component_template' }, + { id: 'logs-dataset1@custom', type: 'component_template' }, + { id: 'logs-dataset2-1.0.0', type: 'ingest_pipeline' }, + { id: 'logs-dataset2', type: 'index_template' }, + { id: 'logs-dataset2@package', type: 'component_template' }, + { id: 'logs-dataset2@custom', type: 'component_template' }, + ]); + }); + + it('should allow data to be sent to existing stream if owned by package and should not create templates', async () => { + await createFakeFleetDataStream('dataset3'); + + const packagePolicy = await createPackagePolicyWithDataset(agentPolicyId, 'dataset3'); + packagePolicyIds.push(packagePolicy.id); + const installation = await getInstallationSavedObject(PACKAGE_NAME, START_VERSION); + expectIdArraysEqual(installation.installed_es, [ + { id: 'logs-dataset1-1.0.0', type: 'ingest_pipeline' }, + { id: 'logs-dataset1', type: 'index_template' }, + { id: 'logs-dataset1@package', type: 'component_template' }, + { id: 'logs-dataset1@custom', type: 'component_template' }, + { id: 'logs-dataset2-1.0.0', type: 'ingest_pipeline' }, + { id: 'logs-dataset2', type: 'index_template' }, + { id: 'logs-dataset2@package', type: 'component_template' }, + { id: 'logs-dataset2@custom', type: 'component_template' }, + ]); + + const dataset3PkgComponentTemplate = await getComponentTemplate('logs-dataset3@package'); + expect(dataset3PkgComponentTemplate).eql(null); + + await deleteDataStream('logs-dataset3'); + }); + + it('should not allow data to be sent to existing stream if not owned by package', async () => { + await createFakeFleetDataStream('dataset4', 'different_package'); + + const expectedStatusCode = 400; + await createPackagePolicyWithDataset(agentPolicyId, 'dataset4', expectedStatusCode); + + const dataset4PkgComponentTemplate = await getComponentTemplate('logs-dataset4@package'); + expect(dataset4PkgComponentTemplate).eql(null); + + await deleteDataStream('logs-dataset4'); + }); + + it('should not allow existing index template to be overwritten if not owned by package', async () => { + await createFakeFleetIndexTemplate('dataset4', 'different_package'); + + const expectedStatusCode = 400; + await createPackagePolicyWithDataset(agentPolicyId, 'dataset4', expectedStatusCode); + + const dataset4PkgComponentTemplate = await getComponentTemplate('logs-dataset4@package'); + expect(dataset4PkgComponentTemplate).eql(null); + + await deleteIndexTemplate('logs-dataset4'); + }); + + it('should allow data to be sent to existing stream if not owned by package if force flag provided', async () => { + await createFakeFleetDataStream('dataset5', 'different_package'); + + const expectedStatusCode = 200; + const force = true; + await createPackagePolicyWithDataset(agentPolicyId, 'dataset5', expectedStatusCode, force); + + const dataset5PkgComponentTemplate = await getComponentTemplate('logs-dataset5@package'); + expect(dataset5PkgComponentTemplate).eql(null); + + const dataset5IndexTemplate = await getIndexTemplate('logs-dataset5'); + expect(dataset5IndexTemplate?._meta?.package?.name).eql('different_package'); + + await deleteDataStream('logs-dataset5'); + }); + + it('should not override existing index template with no associated streams ', async () => { + await createFakeFleetIndexTemplate('dataset6', 'different_package'); + + const expectedStatusCode = 200; + const force = true; + await createPackagePolicyWithDataset(agentPolicyId, 'dataset6', expectedStatusCode, force); + + const dataset6PkgComponentTemplate = await getComponentTemplate('logs-dataset6@package'); + expect(dataset6PkgComponentTemplate).eql(null); + + const dataset6IndexTemplate = await getIndexTemplate('logs-dataset6'); + expect(dataset6IndexTemplate?._meta?.package?.name).eql('different_package'); + + await deleteIndexTemplate('logs-dataset6'); + }); + + it('should update all index templates created by package policies when the package is upgraded', async () => { + // version 1.1.0 of the test package introduces elasticsearch mappings to the index + // templates, upgrading the package should add this field to both package component templates + await installPackage(PACKAGE_NAME, UPGRADE_VERSION); + + const dataset1PkgComponentTemplate = await getComponentTemplate('logs-dataset1@package'); + expect(dataset1PkgComponentTemplate).not.eql(null); + const mappingsWithTimestamp = { + '@timestamp': { ignore_malformed: false, type: 'date' }, + input: { + properties: { + name: { + type: 'constant_keyword', + value: 'logs', + }, + }, + }, + }; + expect(dataset1PkgComponentTemplate!.component_template.template?.mappings?.properties).eql( + mappingsWithTimestamp + ); + + const dataset2PkgComponentTemplate = await getComponentTemplate('logs-dataset2@package'); + expect(dataset2PkgComponentTemplate).not.eql(null); + expect(dataset2PkgComponentTemplate!.component_template.template?.mappings?.properties).eql( + mappingsWithTimestamp + ); + }); + it('should delete all index templates created by package policies when the package is uninstalled', async () => { + for (const packagePolicyId of packagePolicyIds) { + await deletePackagePolicy(packagePolicyId); + } + await deleteAgentPolicy(agentPolicyId); + await uninstallPackage(PACKAGE_NAME, UPGRADE_VERSION); + + const dataset1PkgComponentTemplate = await getComponentTemplate('logs-dataset1@package'); + expect(dataset1PkgComponentTemplate).eql(null); + + const dataset2PkgComponentTemplate = await getComponentTemplate('logs-dataset2@package'); + expect(dataset2PkgComponentTemplate).eql(null); + }); + }); +} diff --git a/x-pack/test/fleet_api_integration/apis/package_policy/update.ts b/x-pack/test/fleet_api_integration/apis/package_policy/update.ts index 7f128071d4008..9c4b35030ced3 100644 --- a/x-pack/test/fleet_api_integration/apis/package_policy/update.ts +++ b/x-pack/test/fleet_api_integration/apis/package_policy/update.ts @@ -95,7 +95,7 @@ export default function (providerContext: FtrProviderContext) { paths: { type: 'text', value: ['/tmp/test.log'] }, tags: { type: 'text', value: ['tag1'] }, ignore_older: { value: '72h', type: 'text' }, - 'data_stream.dataset': { type: 'text', value: 'generic' }, + 'data_stream.dataset': { type: 'text', value: 'input_package_test' }, }, }, ], diff --git a/x-pack/test/fleet_api_integration/helpers.ts b/x-pack/test/fleet_api_integration/helpers.ts index c0f1543ee6e85..50bf8ba1ad7e4 100644 --- a/x-pack/test/fleet_api_integration/helpers.ts +++ b/x-pack/test/fleet_api_integration/helpers.ts @@ -52,7 +52,17 @@ export async function generateAgent( data = { policy_revision_idx: 1, last_checkin_status: 'degraded' }; break; case 'offline': - data = { policy_revision_idx: 1, last_checkin: '2017-06-07T18:59:04.498Z' }; + // default inactivity timeout is 2 weeks + // anything less + above offline timeout will be offline + const oneWeekAgoTimestamp = new Date().getTime() - 7 * 24 * 60 * 60 * 1000; + data = { policy_revision_idx: 1, last_checkin: new Date(oneWeekAgoTimestamp).toISOString() }; + break; + case 'inactive': + const threeWeeksAgoTimestamp = new Date().getTime() - 21 * 24 * 60 * 60 * 1000; + data = { + policy_revision_idx: 1, + last_checkin: new Date(threeWeeksAgoTimestamp).toISOString(), + }; break; // Agent with last checkin status as error and currently unenrolling => should displayd updating status case 'error-unenrolling': diff --git a/x-pack/test/functional/apps/canvas/embeddables/lens.ts b/x-pack/test/functional/apps/canvas/embeddables/lens.ts index 97b128c430e50..1c6e0bb2c7075 100644 --- a/x-pack/test/functional/apps/canvas/embeddables/lens.ts +++ b/x-pack/test/functional/apps/canvas/embeddables/lens.ts @@ -88,7 +88,7 @@ export default function canvasLensTest({ getService, getPageObjects }: FtrProvid it('edits lens by-value embeddable', async () => { const originalEmbeddableCount = await PageObjects.canvas.getEmbeddableCount(); - await dashboardPanelActions.toggleContextMenu(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.lens.saveAndReturn(); await retry.try(async () => { diff --git a/x-pack/test/functional/apps/canvas/embeddables/maps.ts b/x-pack/test/functional/apps/canvas/embeddables/maps.ts index 3a2034b7dfecf..1cdcb644448a8 100644 --- a/x-pack/test/functional/apps/canvas/embeddables/maps.ts +++ b/x-pack/test/functional/apps/canvas/embeddables/maps.ts @@ -36,7 +36,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('edits map by-value embeddable', async () => { const originalEmbeddableCount = await PageObjects.canvas.getEmbeddableCount(); - await dashboardPanelActions.toggleContextMenu(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.maps.saveMap('canvas test map'); const embeddableCount = await PageObjects.canvas.getEmbeddableCount(); diff --git a/x-pack/test/functional/apps/canvas/embeddables/visualization.ts b/x-pack/test/functional/apps/canvas/embeddables/visualization.ts index 09f2fba9810f3..1296bd1e51c8f 100644 --- a/x-pack/test/functional/apps/canvas/embeddables/visualization.ts +++ b/x-pack/test/functional/apps/canvas/embeddables/visualization.ts @@ -71,7 +71,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('edits tsvb by-value embeddable', async () => { const originalEmbeddableCount = await PageObjects.canvas.getEmbeddableCount(); - await dashboardPanelActions.toggleContextMenu(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.visualize.saveVisualizationAndReturn(); await retry.try(async () => { @@ -93,7 +93,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('edits vega by-value embeddable', async () => { const originalEmbeddableCount = await PageObjects.canvas.getEmbeddableCount(); - await dashboardPanelActions.toggleContextMenu(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.visualize.saveVisualizationAndReturn(); await retry.try(async () => { diff --git a/x-pack/test/functional/apps/dashboard/group1/feature_controls/dashboard_security.ts b/x-pack/test/functional/apps/dashboard/group1/feature_controls/dashboard_security.ts index 3a33f14d682a6..45d20b92c1e2b 100644 --- a/x-pack/test/functional/apps/dashboard/group1/feature_controls/dashboard_security.ts +++ b/x-pack/test/functional/apps/dashboard/group1/feature_controls/dashboard_security.ts @@ -130,7 +130,6 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { it(`does not allow a visualization to be edited`, async () => { await PageObjects.dashboard.gotoDashboardEditMode('A Dashboard'); - await panelActions.openContextMenu(); await panelActions.expectMissingEditPanelAction(); }); @@ -141,7 +140,6 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { it(`does not allow a map to be edited`, async () => { await PageObjects.dashboard.gotoDashboardEditMode('dashboard with map'); - await panelActions.openContextMenu(); await panelActions.expectMissingEditPanelAction(); }); }); @@ -187,14 +185,12 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { it(`allows a visualization to be edited`, async () => { await PageObjects.common.navigateToApp('dashboard'); await PageObjects.dashboard.gotoDashboardEditMode('A Dashboard'); - await panelActions.openContextMenu(); await panelActions.expectExistsEditPanelAction(); }); it(`allows a map to be edited`, async () => { await PageObjects.common.navigateToApp('dashboard'); await PageObjects.dashboard.gotoDashboardEditMode('dashboard with map'); - await panelActions.openContextMenu(); await panelActions.expectExistsEditPanelAction(); }); diff --git a/x-pack/test/functional/apps/dashboard/group2/dashboard_maps_by_value.ts b/x-pack/test/functional/apps/dashboard/group2/dashboard_maps_by_value.ts index c1224b604364d..949aaa65008c5 100644 --- a/x-pack/test/functional/apps/dashboard/group2/dashboard_maps_by_value.ts +++ b/x-pack/test/functional/apps/dashboard/group2/dashboard_maps_by_value.ts @@ -45,6 +45,7 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { await PageObjects.dashboard.switchToEditMode(); } + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.maps.clickAddLayer(); await PageObjects.maps.selectEMSBoundariesSource(); diff --git a/x-pack/test/functional/apps/lens/group1/ad_hoc_data_view.ts b/x-pack/test/functional/apps/lens/group1/ad_hoc_data_view.ts index af590ace3a0e5..74a736309095d 100644 --- a/x-pack/test/functional/apps/lens/group1/ad_hoc_data_view.ts +++ b/x-pack/test/functional/apps/lens/group1/ad_hoc_data_view.ts @@ -169,6 +169,32 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { expect(metricData[0].title).to.eql('Average of bytes'); }); + it('should be possible to share a URL of a visualization with adhoc dataViews', async () => { + const url = await PageObjects.lens.getUrl('snapshot'); + await browser.openNewTab(); + + const [lensWindowHandler] = await browser.getAllWindowHandles(); + + await browser.navigateTo(url); + // check that it's the same configuration in the new URL when ready + await PageObjects.header.waitUntilLoadingHasFinished(); + expect( + await PageObjects.lens.getDimensionTriggerText('lnsMetric_primaryMetricDimensionPanel') + ).to.eql('Average of bytes'); + await browser.closeCurrentWindow(); + await browser.switchToWindow(lensWindowHandler); + }); + + it('should be possible to download a visualization with adhoc dataViews', async () => { + await PageObjects.lens.setCSVDownloadDebugFlag(true); + await PageObjects.lens.openCSVDownloadShare(); + + const csv = await PageObjects.lens.getCSVContent(); + expect(csv).to.be.ok(); + expect(Object.keys(csv!)).to.have.length(1); + await PageObjects.lens.setCSVDownloadDebugFlag(false); + }); + it('should navigate to discover correctly', async () => { await testSubjects.clickWhenNotDisabledWithoutRetry(`lnsApp_openInDiscover`); @@ -230,6 +256,9 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { // adhoc data view should be persisted after refresh await browser.refresh(); await checkDiscoverNavigationResult(); + + await browser.closeCurrentWindow(); + await browser.switchToWindow(daashboardHandle); }); }); } diff --git a/x-pack/test/functional/apps/lens/group1/smokescreen.ts b/x-pack/test/functional/apps/lens/group1/smokescreen.ts index c01fd3a848aaf..5470b99bcd8f2 100644 --- a/x-pack/test/functional/apps/lens/group1/smokescreen.ts +++ b/x-pack/test/functional/apps/lens/group1/smokescreen.ts @@ -680,27 +680,6 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { expect(await PageObjects.lens.getFirstLayerIndexPattern()).to.equal(indexPatternString); }); - it('should show a download button only when the configuration is valid', async () => { - await PageObjects.visualize.navigateToNewVisualization(); - await PageObjects.visualize.clickVisType('lens'); - await PageObjects.lens.goToTimeRange(); - await PageObjects.lens.switchToVisualization('pie'); - await PageObjects.lens.configureDimension({ - dimension: 'lnsPie_sliceByDimensionPanel > lns-empty-dimension', - operation: 'date_histogram', - field: '@timestamp', - }); - // incomplete configuration should not be downloadable - expect(await testSubjects.isEnabled('lnsApp_downloadCSVButton')).to.eql(false); - - await PageObjects.lens.configureDimension({ - dimension: 'lnsPie_sizeByDimensionPanel > lns-empty-dimension', - operation: 'average', - field: 'bytes', - }); - expect(await testSubjects.isEnabled('lnsApp_downloadCSVButton')).to.eql(true); - }); - it('should allow filtering by legend on an xy chart', async () => { await PageObjects.visualize.navigateToNewVisualization(); await PageObjects.visualize.clickVisType('lens'); diff --git a/x-pack/test/functional/apps/lens/group1/text_based_languages.ts b/x-pack/test/functional/apps/lens/group1/text_based_languages.ts index 2050bead5a91f..e425b2fe71839 100644 --- a/x-pack/test/functional/apps/lens/group1/text_based_languages.ts +++ b/x-pack/test/functional/apps/lens/group1/text_based_languages.ts @@ -18,6 +18,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { 'dashboard', 'common', ]); + const browser = getService('browser'); const elasticChart = getService('elasticChart'); const queryBar = getService('queryBar'); const testSubjects = getService('testSubjects'); @@ -93,6 +94,35 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { assertMatchesExpectedData(data!); }); + it('should be possible to share a URL of a visualization with text-based language', async () => { + const url = await PageObjects.lens.getUrl('snapshot'); + await browser.openNewTab(); + + const [lensWindowHandler] = await browser.getAllWindowHandles(); + + await browser.navigateTo(url); + // check that it's the same configuration in the new URL when ready + await PageObjects.header.waitUntilLoadingHasFinished(); + expect( + await PageObjects.lens.getDimensionTriggerText('lnsXY_xDimensionPanel', 0, true) + ).to.eql('extension'); + expect( + await PageObjects.lens.getDimensionTriggerText('lnsXY_yDimensionPanel', 0, true) + ).to.eql('average'); + await browser.closeCurrentWindow(); + await browser.switchToWindow(lensWindowHandler); + }); + + it('should be possible to download a visualization with text-based language', async () => { + await PageObjects.lens.setCSVDownloadDebugFlag(true); + await PageObjects.lens.openCSVDownloadShare(); + + const csv = await PageObjects.lens.getCSVContent(); + expect(csv).to.be.ok(); + expect(Object.keys(csv!)).to.have.length(1); + await PageObjects.lens.setCSVDownloadDebugFlag(false); + }); + it('should allow adding an text based languages chart to a dashboard', async () => { await PageObjects.lens.switchToVisualization('lnsMetric'); @@ -158,5 +188,48 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { const metricData = await PageObjects.lens.getMetricVisualizationData(); expect(metricData[0].title).to.eql('average'); }); + + it('should be possible to share a URL of a visualization with text-based language that points to an index pattern', async () => { + // TODO: there's some state leakage in Lens when passing from a XY chart to new Metric chart + // which generates a wrong state (even tho it looks to work, starting fresh with such state breaks the editor) + await PageObjects.lens.removeLayer(); + await PageObjects.lens.switchToVisualization('bar'); + await PageObjects.header.waitUntilLoadingHasFinished(); + await PageObjects.lens.configureTextBasedLanguagesDimension({ + dimension: 'lnsXY_xDimensionPanel > lns-empty-dimension', + field: 'extension', + }); + + await PageObjects.lens.configureTextBasedLanguagesDimension({ + dimension: 'lnsXY_yDimensionPanel > lns-empty-dimension', + field: 'average', + }); + const url = await PageObjects.lens.getUrl('snapshot'); + await browser.openNewTab(); + + const [lensWindowHandler] = await browser.getAllWindowHandles(); + + await browser.navigateTo(url); + // check that it's the same configuration in the new URL when ready + await PageObjects.header.waitUntilLoadingHasFinished(); + expect( + await PageObjects.lens.getDimensionTriggerText('lnsXY_xDimensionPanel', 0, true) + ).to.eql('extension'); + expect( + await PageObjects.lens.getDimensionTriggerText('lnsXY_yDimensionPanel', 0, true) + ).to.eql('average'); + await browser.closeCurrentWindow(); + await browser.switchToWindow(lensWindowHandler); + }); + + it('should be possible to download a visualization with text-based language that points to an index pattern', async () => { + await PageObjects.lens.setCSVDownloadDebugFlag(true); + await PageObjects.lens.openCSVDownloadShare(); + + const csv = await PageObjects.lens.getCSVContent(); + expect(csv).to.be.ok(); + expect(Object.keys(csv!)).to.have.length(1); + await PageObjects.lens.setCSVDownloadDebugFlag(false); + }); }); } diff --git a/x-pack/test/functional/apps/lens/group2/index.ts b/x-pack/test/functional/apps/lens/group2/index.ts index 20cb355735666..277b415a9ab49 100644 --- a/x-pack/test/functional/apps/lens/group2/index.ts +++ b/x-pack/test/functional/apps/lens/group2/index.ts @@ -78,6 +78,7 @@ export default ({ getService, loadTestFile, getPageObjects }: FtrProviderContext loadTestFile(require.resolve('./epoch_millis')); loadTestFile(require.resolve('./show_underlying_data')); loadTestFile(require.resolve('./show_underlying_data_dashboard')); + loadTestFile(require.resolve('./share')); loadTestFile(require.resolve('./tsdb')); }); }; diff --git a/x-pack/test/functional/apps/lens/group2/share.ts b/x-pack/test/functional/apps/lens/group2/share.ts new file mode 100644 index 0000000000000..02febbd1ce4ee --- /dev/null +++ b/x-pack/test/functional/apps/lens/group2/share.ts @@ -0,0 +1,142 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { FtrProviderContext } from '../../../ftr_provider_context'; + +export default function ({ getService, getPageObjects }: FtrProviderContext) { + const PageObjects = getPageObjects(['visualize', 'lens', 'common', 'header']); + const browser = getService('browser'); + const filterBarService = getService('filterBar'); + const queryBar = getService('queryBar'); + + describe('lens share tests', () => { + before(async () => { + await PageObjects.visualize.gotoVisualizationLandingPage(); + }); + + after(async () => { + await PageObjects.lens.setCSVDownloadDebugFlag(false); + }); + + it('should disable the share button if no request is made', async () => { + await PageObjects.visualize.navigateToNewVisualization(); + await PageObjects.visualize.clickVisType('lens'); + await PageObjects.lens.goToTimeRange(); + + expect(await PageObjects.lens.isShareable()).to.eql(false); + }); + + it('should keep the button disabled for incomplete configuration', async () => { + await PageObjects.lens.configureDimension({ + dimension: 'lnsXY_xDimensionPanel > lns-empty-dimension', + operation: 'date_histogram', + field: '@timestamp', + }); + expect(await PageObjects.lens.isShareable()).to.eql(false); + }); + + it('should make the share button avaialble as soon as a valid configuration is generated', async () => { + await PageObjects.lens.configureDimension({ + dimension: 'lnsXY_yDimensionPanel > lns-empty-dimension', + operation: 'average', + field: 'bytes', + }); + + expect(await PageObjects.lens.isShareable()).to.eql(true); + }); + + it('should enable both download and URL sharing for valid configuration', async () => { + await PageObjects.lens.clickShareMenu(); + + expect(await PageObjects.lens.isShareActionEnabled('csvDownload')); + expect(await PageObjects.lens.isShareActionEnabled('permalinks')); + }); + + it('should provide only snapshot url sharing if visualization is not saved yet', async () => { + await PageObjects.lens.openPermalinkShare(); + + const options = await PageObjects.lens.getAvailableUrlSharingOptions(); + expect(options).eql(['snapshot']); + }); + + it('should basically work for snapshot', async () => { + const url = await PageObjects.lens.getUrl('snapshot'); + await browser.openNewTab(); + + const [lensWindowHandler] = await browser.getAllWindowHandles(); + + await browser.navigateTo(url); + // check that it's the same configuration in the new URL when ready + await PageObjects.header.waitUntilLoadingHasFinished(); + expect(await PageObjects.lens.getDimensionTriggerText('lnsXY_yDimensionPanel')).to.eql( + 'Average of bytes' + ); + await browser.closeCurrentWindow(); + await browser.switchToWindow(lensWindowHandler); + }); + + it('should provide also saved object url sharing if the visualization is shared', async () => { + await PageObjects.lens.save('ASavedVisualizationToShare'); + await PageObjects.lens.openPermalinkShare(); + + const options = await PageObjects.lens.getAvailableUrlSharingOptions(); + expect(options).eql(['snapshot', 'savedObject']); + }); + + it('should preserve filter and query when sharing', async () => { + await filterBarService.addFilter({ field: 'bytes', operation: 'is', value: '1' }); + await queryBar.setQuery('host.keyword www.elastic.co'); + await queryBar.submitQuery(); + await PageObjects.header.waitUntilLoadingHasFinished(); + + const url = await PageObjects.lens.getUrl('snapshot'); + await browser.openNewTab(); + + const [lensWindowHandler] = await browser.getAllWindowHandles(); + + await browser.navigateTo(url); + // check that it's the same configuration in the new URL when ready + await PageObjects.header.waitUntilLoadingHasFinished(); + expect(await filterBarService.getFiltersLabel()).to.eql(['bytes: 1']); + expect(await queryBar.getQueryString()).to.be('host.keyword www.elastic.co'); + await browser.closeCurrentWindow(); + await browser.switchToWindow(lensWindowHandler); + }); + + it('should be able to download CSV data of the current visualization', async () => { + await PageObjects.lens.setCSVDownloadDebugFlag(true); + await PageObjects.lens.openCSVDownloadShare(); + + const csv = await PageObjects.lens.getCSVContent(); + expect(csv).to.be.ok(); + expect(Object.keys(csv!)).to.have.length(1); + }); + + it('should be able to download CSV of multi layer visualization', async () => { + await PageObjects.lens.createLayer(); + + await PageObjects.lens.configureDimension({ + dimension: 'lns-layerPanel-1 > lnsXY_xDimensionPanel > lns-empty-dimension', + operation: 'date_histogram', + field: '@timestamp', + }); + + await PageObjects.lens.configureDimension({ + dimension: 'lns-layerPanel-1 > lnsXY_yDimensionPanel > lns-empty-dimension', + operation: 'median', + field: 'bytes', + }); + + await PageObjects.lens.openCSVDownloadShare(); + + const csv = await PageObjects.lens.getCSVContent(); + expect(csv).to.be.ok(); + expect(Object.keys(csv!)).to.have.length(2); + }); + }); +} diff --git a/x-pack/test/functional/apps/lens/group2/show_underlying_data_dashboard.ts b/x-pack/test/functional/apps/lens/group2/show_underlying_data_dashboard.ts index 4cdc584e571ee..e51f78796da75 100644 --- a/x-pack/test/functional/apps/lens/group2/show_underlying_data_dashboard.ts +++ b/x-pack/test/functional/apps/lens/group2/show_underlying_data_dashboard.ts @@ -5,7 +5,7 @@ * 2.0. */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../ftr_provider_context'; export default function ({ getService, getPageObjects }: FtrProviderContext) { @@ -35,7 +35,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { await PageObjects.lens.goToTimeRange(); await PageObjects.lens.save('Embedded Visualization', true, false, false, 'new'); - await PageObjects.dashboard.saveDashboard(`Open in Discover Testing ${uuid()}`, { + await PageObjects.dashboard.saveDashboard(`Open in Discover Testing ${uuidv4()}`, { exitFromEditMode: true, }); @@ -58,13 +58,14 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('should show the open button for a compatible saved visualization with annotations and reference line', async () => { await PageObjects.dashboard.switchToEditMode(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await PageObjects.lens.createLayer('annotations'); await PageObjects.lens.createLayer('referenceLine'); await PageObjects.lens.save('Embedded Visualization', false); - await PageObjects.dashboard.saveDashboard(`Open in Discover Testing ${uuid()}`, { + await PageObjects.dashboard.saveDashboard(`Open in Discover Testing ${uuidv4()}`, { exitFromEditMode: true, }); @@ -87,6 +88,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { it('should bring both dashboard context and visualization context to discover', async () => { await PageObjects.dashboard.switchToEditMode(); + await dashboardPanelActions.openContextMenu(); await dashboardPanelActions.clickEdit(); await savedQueryManagementComponent.openSavedQueryManagementComponent(); await queryBar.switchQueryLanguage('lucene'); diff --git a/x-pack/test/functional/apps/maps/group4/file_upload/geojson.js b/x-pack/test/functional/apps/maps/group4/file_upload/geojson.js index 2f7abbec1debe..744235a023d3c 100644 --- a/x-pack/test/functional/apps/maps/group4/file_upload/geojson.js +++ b/x-pack/test/functional/apps/maps/group4/file_upload/geojson.js @@ -7,7 +7,7 @@ import expect from '@kbn/expect'; import path from 'path'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export default function ({ getPageObjects, getService }) { const PageObjects = getPageObjects(['geoFileUpload', 'maps']); @@ -45,7 +45,7 @@ export default function ({ getPageObjects, getService }) { }); it('should import geojson', async () => { - indexName = uuid(); + indexName = uuidv4(); await PageObjects.geoFileUpload.setIndexName(indexName); await PageObjects.geoFileUpload.uploadFile(); diff --git a/x-pack/test/functional/apps/maps/group4/file_upload/shapefile.js b/x-pack/test/functional/apps/maps/group4/file_upload/shapefile.js index 059e32861278a..c57a4ad69b9b5 100644 --- a/x-pack/test/functional/apps/maps/group4/file_upload/shapefile.js +++ b/x-pack/test/functional/apps/maps/group4/file_upload/shapefile.js @@ -7,7 +7,7 @@ import expect from '@kbn/expect'; import path from 'path'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; export default function ({ getPageObjects, getService }) { const PageObjects = getPageObjects(['geoFileUpload', 'maps']); @@ -51,7 +51,7 @@ export default function ({ getPageObjects, getService }) { }); it('should import shapefile', async () => { - indexName = uuid(); + indexName = uuidv4(); await PageObjects.geoFileUpload.setIndexName(indexName); await PageObjects.geoFileUpload.uploadFile(); diff --git a/x-pack/test/functional/page_objects/lens_page.ts b/x-pack/test/functional/page_objects/lens_page.ts index 49785c62e7310..10deb555fa359 100644 --- a/x-pack/test/functional/page_objects/lens_page.ts +++ b/x-pack/test/functional/page_objects/lens_page.ts @@ -11,6 +11,16 @@ import { WebElementWrapper } from '../../../../test/functional/services/lib/web_ import { FtrProviderContext } from '../ftr_provider_context'; import { logWrapper } from './log_wrapper'; +declare global { + interface Window { + /** + * Debug setting to test CSV download + */ + ELASTIC_LENS_CSV_DOWNLOAD_DEBUG?: boolean; + ELASTIC_LENS_CSV_CONTENT?: Record; + } +} + export function LensPageProvider({ getService, getPageObjects }: FtrProviderContext) { const log = getService('log'); const findService = getService('find'); @@ -963,8 +973,8 @@ export function LensPageProvider({ getService, getPageObjects }: FtrProviderCont * @param dimension - the selector of the dimension * @param index - the index of the dimension trigger in group */ - async getDimensionTriggerText(dimension: string, index = 0) { - const dimensionTexts = await this.getDimensionTriggersTexts(dimension); + async getDimensionTriggerText(dimension: string, index = 0, isTextBased: boolean = false) { + const dimensionTexts = await this.getDimensionTriggersTexts(dimension, isTextBased); return dimensionTexts[index]; }, /** @@ -972,9 +982,11 @@ export function LensPageProvider({ getService, getPageObjects }: FtrProviderCont * * @param dimension - the selector of the dimension */ - async getDimensionTriggersTexts(dimension: string) { + async getDimensionTriggersTexts(dimension: string, isTextBased: boolean = false) { return retry.try(async () => { - const dimensionElements = await testSubjects.findAll(`${dimension} > lns-dimensionTrigger`); + const dimensionElements = await testSubjects.findAll( + `${dimension} > lns-dimensionTrigger${isTextBased ? '-textBased' : ''}` + ); const dimensionTexts = await Promise.all( await dimensionElements.map(async (el) => await el.getVisibleText()) ); @@ -1652,5 +1664,83 @@ export function LensPageProvider({ getService, getPageObjects }: FtrProviderCont // map to testSubjId return Promise.all(allFieldsForType.map((el) => el.getAttribute('data-test-subj'))); }, + + async clickShareMenu() { + await testSubjects.click('lnsApp_shareButton'); + }, + + async isShareable() { + return await testSubjects.isEnabled('lnsApp_shareButton'); + }, + + async isShareActionEnabled(action: 'csvDownload' | 'permalinks') { + switch (action) { + case 'csvDownload': + return await testSubjects.isEnabled('sharePanel-CSVDownload'); + case 'permalinks': + return await testSubjects.isEnabled('sharePanel-Permalinks'); + } + }, + + async ensureShareMenuIsOpen(action: 'csvDownload' | 'permalinks') { + await this.clickShareMenu(); + + if (!(await testSubjects.exists('shareContextMenu'))) { + await this.clickShareMenu(); + } + if (!(await this.isShareActionEnabled(action))) { + throw Error(`${action} sharing feature is disabled`); + } + }, + + async openPermalinkShare() { + await this.ensureShareMenuIsOpen('permalinks'); + await testSubjects.click('sharePanel-Permalinks'); + }, + + async getAvailableUrlSharingOptions() { + if (!(await testSubjects.exists('shareUrlForm'))) { + await this.openPermalinkShare(); + } + const el = await testSubjects.find('shareUrlForm'); + const available = await el.findAllByCssSelector('input:not([disabled])'); + const ids = await Promise.all(available.map((node) => node.getAttribute('id'))); + return ids; + }, + + async getUrl(type: 'snapshot' | 'savedObject' = 'snapshot') { + if (!(await testSubjects.exists('shareUrlForm'))) { + await this.openPermalinkShare(); + } + const options = await this.getAvailableUrlSharingOptions(); + const optionIndex = options.findIndex((option) => option === type); + if (optionIndex < 0) { + throw Error(`Sharing URL of type ${type} is not available`); + } + const testSubFrom = `exportAs${type[0].toUpperCase()}${type.substring(1)}`; + await testSubjects.click(testSubFrom); + const copyButton = await testSubjects.find('copyShareUrlButton'); + const url = await copyButton.getAttribute('data-share-url'); + return url; + }, + + async openCSVDownloadShare() { + await this.ensureShareMenuIsOpen('csvDownload'); + await testSubjects.click('sharePanel-CSVDownload'); + }, + + async setCSVDownloadDebugFlag(value: boolean = true) { + await browser.execute<[boolean], void>((v) => { + window.ELASTIC_LENS_CSV_DOWNLOAD_DEBUG = v; + }, value); + }, + + async getCSVContent() { + await testSubjects.click('lnsApp_downloadCSVButton'); + return await browser.execute< + [void], + Record | undefined + >(() => window.ELASTIC_LENS_CSV_CONTENT); + }, }); } diff --git a/x-pack/test/functional/services/cases/create.ts b/x-pack/test/functional/services/cases/create.ts index 0b4c62f572f23..71aec28374f7a 100644 --- a/x-pack/test/functional/services/cases/create.ts +++ b/x-pack/test/functional/services/cases/create.ts @@ -6,7 +6,7 @@ */ import { CaseSeverity } from '@kbn/cases-plugin/common/api'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../ftr_provider_context'; import type { CasesCommon } from './common'; @@ -50,8 +50,8 @@ export function CasesCreateViewServiceProvider( * Doesn't do navigation. Only works if you are already inside a cases app page. */ async createCase({ - title = 'test-' + uuid.v4(), - description = 'desc' + uuid.v4(), + title = 'test-' + uuidv4(), + description = 'desc' + uuidv4(), tag = 'tagme', severity = CaseSeverity.LOW, owner, diff --git a/x-pack/test/functional/services/cases/helpers.ts b/x-pack/test/functional/services/cases/helpers.ts index 94ca32c3af932..6b7e39e8e50d8 100644 --- a/x-pack/test/functional/services/cases/helpers.ts +++ b/x-pack/test/functional/services/cases/helpers.ts @@ -6,13 +6,13 @@ */ import { CaseConnector, CasePostRequest } from '@kbn/cases-plugin/common/api'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export function generateRandomCaseWithoutConnector(): CasePostRequest { return { - title: 'random-' + uuid.v4(), - tags: ['test', uuid.v4()], - description: 'This is a description with id: ' + uuid.v4(), + title: 'random-' + uuidv4(), + tags: ['test', uuidv4()], + description: 'This is a description with id: ' + uuidv4(), connector: { id: 'none', name: 'none', diff --git a/x-pack/test/functional/services/observability/components/alert_search_bar.ts b/x-pack/test/functional/services/observability/components/alert_search_bar.ts new file mode 100644 index 0000000000000..12781afb67b4f --- /dev/null +++ b/x-pack/test/functional/services/observability/components/alert_search_bar.ts @@ -0,0 +1,38 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import dateMath from '@kbn/datemath'; +import { FtrProviderContext } from '../../../ftr_provider_context'; + +const FROM_SELECTOR = 'superDatePickerstartDatePopoverButton'; +const TO_SELECTOR = 'superDatePickerendDatePopoverButton'; + +export function ObservabilityAlertSearchBarProvider({ getService }: FtrProviderContext) { + const testSubjects = getService('testSubjects'); + + const getAbsoluteTimeRange = async () => { + // Since FTR uses UTC, with this format, we remove local browser timezone + const format = 'YYYY-MM-DDTHH:mm:ss.SSS'; + + const fromMoment = dateMath.parse( + await (await testSubjects.find(FROM_SELECTOR)).getVisibleText() + ); + const from = fromMoment!.format(format); + + const toMoment = dateMath.parse(await (await testSubjects.find(TO_SELECTOR)).getVisibleText()); + const to = toMoment!.format(format); + + return { + from, + to, + }; + }; + + return { + getAbsoluteTimeRange, + }; +} diff --git a/x-pack/test/functional/services/observability/components/alert_summary_widget.ts b/x-pack/test/functional/services/observability/components/alert_summary_widget.ts new file mode 100644 index 0000000000000..1d486a497c735 --- /dev/null +++ b/x-pack/test/functional/services/observability/components/alert_summary_widget.ts @@ -0,0 +1,40 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FtrProviderContext } from '../../../ftr_provider_context'; + +const COMPACT_COMPONENT_SELECTOR = 'alertSummaryWidgetCompact'; +const COMPACT_TIME_RANGE_TITLE_SELECTOR = 'timeRangeTitle'; +const COMPACT_ACTIVE_ALERTS_SELECTOR = 'activeAlerts'; +const COMPACT_RECOVERED_ALERTS_SELECTOR = 'recoveredAlerts'; + +export function ObservabilityAlertSummaryWidgetProvider({ getService }: FtrProviderContext) { + const testSubjects = getService('testSubjects'); + + const getCompactComponentSelectorOrFail = async () => { + return await testSubjects.existOrFail(COMPACT_COMPONENT_SELECTOR); + }; + + const getCompactTimeRangeTitle = async () => { + return (await testSubjects.find(COMPACT_TIME_RANGE_TITLE_SELECTOR)).getVisibleText(); + }; + + const getCompactActiveAlertSelector = async () => { + return await testSubjects.find(COMPACT_ACTIVE_ALERTS_SELECTOR); + }; + + const getCompactRecoveredAlertSelector = async () => { + return await testSubjects.find(COMPACT_RECOVERED_ALERTS_SELECTOR); + }; + + return { + getCompactComponentSelectorOrFail, + getCompactTimeRangeTitle, + getCompactActiveAlertSelector, + getCompactRecoveredAlertSelector, + }; +} diff --git a/x-pack/test/functional/services/observability/components/index.ts b/x-pack/test/functional/services/observability/components/index.ts new file mode 100644 index 0000000000000..0a11968a0cb56 --- /dev/null +++ b/x-pack/test/functional/services/observability/components/index.ts @@ -0,0 +1,21 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { ObservabilityAlertSearchBarProvider } from './alert_search_bar'; +import { ObservabilityAlertSummaryWidgetProvider } from './alert_summary_widget'; + +import { FtrProviderContext } from '../../../ftr_provider_context'; + +export function ObservabilityComponentsProvider(context: FtrProviderContext) { + const alertSearchBar = ObservabilityAlertSearchBarProvider(context); + const alertSummaryWidget = ObservabilityAlertSummaryWidgetProvider(context); + + return { + alertSearchBar, + alertSummaryWidget, + }; +} diff --git a/x-pack/test/functional/services/observability/index.ts b/x-pack/test/functional/services/observability/index.ts index 2b2c82c4f3728..db262cef8bf63 100644 --- a/x-pack/test/functional/services/observability/index.ts +++ b/x-pack/test/functional/services/observability/index.ts @@ -9,14 +9,17 @@ import { FtrProviderContext } from '../../ftr_provider_context'; import { ObservabilityUsersProvider } from './users'; import { ObservabilityAlertsProvider } from './alerts'; import { ObservabilityOverviewProvider } from './overview'; +import { ObservabilityComponentsProvider } from './components'; export function ObservabilityProvider(context: FtrProviderContext) { const alerts = ObservabilityAlertsProvider(context); + const components = ObservabilityComponentsProvider(context); const users = ObservabilityUsersProvider(context); const overview = ObservabilityOverviewProvider(context); return { alerts, + components, users, overview, }; diff --git a/x-pack/test/functional_with_es_ssl/apps/cases/create_case_form.ts b/x-pack/test/functional_with_es_ssl/apps/cases/create_case_form.ts index e601ce9381ed6..4a744071cb694 100644 --- a/x-pack/test/functional_with_es_ssl/apps/cases/create_case_form.ts +++ b/x-pack/test/functional_with_es_ssl/apps/cases/create_case_form.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { CaseSeverity } from '@kbn/cases-plugin/common/api'; import { FtrProviderContext } from '../../ftr_provider_context'; import { @@ -33,7 +33,7 @@ export default ({ getService, getPageObject }: FtrProviderContext) => { }); it('creates a case from the stack management page', async () => { - const caseTitle = 'test-' + uuid.v4(); + const caseTitle = 'test-' + uuidv4(); await cases.create.openCreateCasePage(); await cases.create.createCase({ title: caseTitle, @@ -73,7 +73,7 @@ export default ({ getService, getPageObject }: FtrProviderContext) => { }); it('creates a case with assignees', async () => { - const caseTitle = 'test-' + uuid.v4(); + const caseTitle = 'test-' + uuidv4(); await cases.create.openCreateCasePage(); await cases.create.setTitle(caseTitle); diff --git a/x-pack/test/functional_with_es_ssl/apps/cases/view_case.ts b/x-pack/test/functional_with_es_ssl/apps/cases/view_case.ts index 0d8eff8a37e6e..876857721966f 100644 --- a/x-pack/test/functional_with_es_ssl/apps/cases/view_case.ts +++ b/x-pack/test/functional_with_es_ssl/apps/cases/view_case.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { CaseStatuses } from '@kbn/cases-plugin/common'; import { CaseSeverity } from '@kbn/cases-plugin/common/api'; import { FtrProviderContext } from '../../ftr_provider_context'; @@ -32,7 +32,7 @@ export default ({ getPageObject, getService }: FtrProviderContext) => { createOneCaseBeforeDeleteAllAfter(getPageObject, getService); it('edits a case title from the case view page', async () => { - const newTitle = `test-${uuid.v4()}`; + const newTitle = `test-${uuidv4()}`; await testSubjects.click('editable-title-edit-icon'); await testSubjects.setValue('editable-title-input-field', newTitle); @@ -64,7 +64,7 @@ export default ({ getPageObject, getService }: FtrProviderContext) => { }); it('adds a tag to a case', async () => { - const tag = uuid.v4(); + const tag = uuidv4(); await testSubjects.click('tag-list-edit-button'); await comboBox.setCustom('comboBoxInput', tag); await testSubjects.click('edit-tags-submit'); diff --git a/x-pack/test/functional_with_es_ssl/apps/discover/search_source_alert.ts b/x-pack/test/functional_with_es_ssl/apps/discover/search_source_alert.ts index f583abef81994..7a6870c53685c 100644 --- a/x-pack/test/functional_with_es_ssl/apps/discover/search_source_alert.ts +++ b/x-pack/test/functional_with_es_ssl/apps/discover/search_source_alert.ts @@ -410,6 +410,9 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { await testSubjects.click('openEditRuleFlyoutButton'); await queryBar.setQuery('message:msg-1'); await filterBar.addFilter({ field: 'message.keyword', operation: 'is', value: 'msg-1' }); + await retry.waitFor('filters modal to become hidden', async () => { + return !(await testSubjects.exists('saveFilter')); + }); await testSubjects.click('thresholdPopover'); await testSubjects.setValue('alertThresholdInput', '1'); diff --git a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/details.ts b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/details.ts index 806844c71b57d..306f4c9e0af4c 100644 --- a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/details.ts +++ b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/details.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { omit, mapValues, range, flatten } from 'lodash'; import moment from 'moment'; import { asyncForEach } from '@kbn/std'; @@ -149,7 +149,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { describe('Rule Details', function () { describe('Header', function () { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); before(async () => { await pageObjects.common.navigateToApp('triggersActions'); const rule = await createRuleWithSmallInterval(testRunUuid); @@ -317,7 +317,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Edit rule button', function () { - const ruleName = uuid.v4(); + const ruleName = uuidv4(); const updatedRuleName = `Changed Rule Name ${ruleName}`; before(async () => { @@ -404,7 +404,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { const editButton = await testSubjects.find('openEditRuleFlyoutButton'); await editButton.click(); - await testSubjects.setValue('ruleNameInput', uuid.v4(), { + await testSubjects.setValue('ruleNameInput', uuidv4(), { clearWithKeyboard: true, }); @@ -422,7 +422,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Edit rule with deleted connector', function () { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); afterEach(async () => { await objectRemover.removeAll(); @@ -600,7 +600,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Edit rule with legacy rule-level notify values', function () { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); afterEach(async () => { await objectRemover.removeAll(); @@ -658,7 +658,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('View In App', function () { - const ruleName = uuid.v4(); + const ruleName = uuidv4(); beforeEach(async () => { await pageObjects.common.navigateToApp('triggersActions'); @@ -711,7 +711,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Alerts', function () { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); let rule: any; before(async () => { @@ -921,7 +921,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Alert Pagination', function () { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); let rule: any; before(async () => { @@ -996,7 +996,7 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => { }); describe('Execution log', () => { - const testRunUuid = uuid.v4(); + const testRunUuid = uuidv4(); let rule: any; before(async () => { diff --git a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/index.ts b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/index.ts index 00f008519f237..bf9f30f34bb3f 100644 --- a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/index.ts +++ b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/index.ts @@ -15,5 +15,6 @@ export default ({ loadTestFile, getService }: FtrProviderContext) => { loadTestFile(require.resolve('./details')); loadTestFile(require.resolve('./connectors')); loadTestFile(require.resolve('./logs_list')); + loadTestFile(require.resolve('./rules_settings')); }); }; diff --git a/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/rules_settings.ts b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/rules_settings.ts new file mode 100644 index 0000000000000..6b4297f2dc153 --- /dev/null +++ b/x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/rules_settings.ts @@ -0,0 +1,139 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { createAlert } from '../../lib/alert_api_actions'; +import { ObjectRemover } from '../../lib/object_remover'; +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default ({ getPageObjects, getService }: FtrProviderContext) => { + const testSubjects = getService('testSubjects'); + const supertest = getService('supertest'); + const pageObjects = getPageObjects(['common', 'triggersActionsUI', 'header', 'security']); + const browser = getService('browser'); + const objectRemover = new ObjectRemover(supertest); + const retry = getService('retry'); + + async function refreshAlertsList() { + await retry.try(async () => { + await pageObjects.common.navigateToApp('triggersActions'); + await testSubjects.click('triggersActions'); + const searchResults = await pageObjects.triggersActionsUI.getAlertsList(); + expect(searchResults).to.have.length(1); + }); + } + + async function dragRangeInput( + testId: string, + steps: number = 1, + direction: 'left' | 'right' = 'right' + ) { + const inputEl = await testSubjects.find(testId); + await inputEl.focus(); + const browserKey = direction === 'left' ? browser.keys.LEFT : browser.keys.RIGHT; + while (steps--) { + await browser.pressKeys(browserKey); + } + } + + describe('rules settings modal', () => { + before(async () => { + await supertest + .post(`/internal/alerting/rules/settings/_flapping`) + .set('kbn-xsrf', 'foo') + .send({ + enabled: true, + lookBackWindow: 10, + statusChangeThreshold: 10, + }) + .expect(200); + }); + + beforeEach(async () => { + await createAlert({ + supertest, + objectRemover, + }); + await refreshAlertsList(); + }); + + afterEach(async () => { + await objectRemover.removeAll(); + }); + + it('rules settings link should be enabled', async () => { + await testSubjects.existOrFail('rulesSettingsLink'); + const button = await testSubjects.find('rulesSettingsLink'); + const isDisabled = await button.getAttribute('disabled'); + expect(isDisabled).to.equal(null); + }); + + it('should allow the user to open up the rules settings modal', async () => { + await testSubjects.click('rulesSettingsLink'); + await testSubjects.existOrFail('rulesSettingsModal'); + await testSubjects.waitForDeleted('centerJustifiedSpinner'); + + // Flapping enabled by default + await testSubjects.missingOrFail('rulesSettingsModalFlappingOffPrompt'); + + await testSubjects.existOrFail('rulesSettingsModalEnableSwitch'); + await testSubjects.existOrFail('lookBackWindowRangeInput'); + await testSubjects.existOrFail('statusChangeThresholdRangeInput'); + + const lookBackWindowInput = await testSubjects.find('lookBackWindowRangeInput'); + const statusChangeThresholdInput = await testSubjects.find('statusChangeThresholdRangeInput'); + + const lookBackWindowValue = await lookBackWindowInput.getAttribute('value'); + const statusChangeThresholdValue = await statusChangeThresholdInput.getAttribute('value'); + + expect(lookBackWindowValue).to.eql('10'); + expect(statusChangeThresholdValue).to.eql('10'); + }); + + it('should allow the user to modify rules settings', async () => { + await testSubjects.click('rulesSettingsLink'); + await testSubjects.waitForDeleted('centerJustifiedSpinner'); + + await dragRangeInput('lookBackWindowRangeInput', 5, 'right'); + await dragRangeInput('statusChangeThresholdRangeInput', 5, 'left'); + + let lookBackWindowInput = await testSubjects.find('lookBackWindowRangeInput'); + let statusChangeThresholdInput = await testSubjects.find('statusChangeThresholdRangeInput'); + + let lookBackWindowValue = await lookBackWindowInput.getAttribute('value'); + let statusChangeThresholdValue = await statusChangeThresholdInput.getAttribute('value'); + + expect(lookBackWindowValue).to.eql('15'); + expect(statusChangeThresholdValue).to.eql('5'); + + await testSubjects.click('rulesSettingsModalEnableSwitch'); + await testSubjects.existOrFail('rulesSettingsModalFlappingOffPrompt'); + + // Save + await testSubjects.click('rulesSettingsModalSaveButton'); + await pageObjects.header.waitUntilLoadingHasFinished(); + await testSubjects.missingOrFail('rulesSettingsModal'); + + // Open up the modal again + await testSubjects.click('rulesSettingsLink'); + await testSubjects.waitForDeleted('centerJustifiedSpinner'); + + // Flapping initially disabled + await testSubjects.existOrFail('rulesSettingsModalFlappingOffPrompt'); + await testSubjects.click('rulesSettingsModalEnableSwitch'); + + lookBackWindowInput = await testSubjects.find('lookBackWindowRangeInput'); + statusChangeThresholdInput = await testSubjects.find('statusChangeThresholdRangeInput'); + + lookBackWindowValue = await lookBackWindowInput.getAttribute('value'); + statusChangeThresholdValue = await statusChangeThresholdInput.getAttribute('value'); + + expect(lookBackWindowValue).to.eql('15'); + expect(statusChangeThresholdValue).to.eql('5'); + }); + }); +}; diff --git a/x-pack/test/functional_with_es_ssl/lib/get_test_data.ts b/x-pack/test/functional_with_es_ssl/lib/get_test_data.ts index 51157932eee3d..bed34551d92ea 100644 --- a/x-pack/test/functional_with_es_ssl/lib/get_test_data.ts +++ b/x-pack/test/functional_with_es_ssl/lib/get_test_data.ts @@ -5,10 +5,10 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; export function generateUniqueKey() { - return uuid.v4().replace(/-/g, ''); + return uuidv4().replace(/-/g, ''); } export function getTestAlertData(overwrites = {}) { diff --git a/x-pack/test/observability_functional/apps/observability/feature_controls/observability_security.ts b/x-pack/test/observability_functional/apps/observability/feature_controls/observability_security.ts index 85512f8333038..436dcad75f305 100644 --- a/x-pack/test/observability_functional/apps/observability/feature_controls/observability_security.ts +++ b/x-pack/test/observability_functional/apps/observability/feature_controls/observability_security.ts @@ -20,6 +20,8 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { ]); const appsMenu = getService('appsMenu'); const testSubjects = getService('testSubjects'); + const config = getService('config'); + const kibanaServer = getService('kibanaServer'); describe('observability security feature controls', function () { this.tags(['skipFirefox']); @@ -29,6 +31,9 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) { after(async () => { await esArchiver.unload('x-pack/test/functional/es_archives/cases/default'); + // Since the above unload removes the default config, + // the following command will set it back to avoid changing the test environment + await kibanaServer.uiSettings.update(config.get('uiSettings.defaults')); }); it('Shows the no data page on load', async () => { diff --git a/x-pack/test/observability_functional/apps/observability/pages/rule_details_page.ts b/x-pack/test/observability_functional/apps/observability/pages/rule_details_page.ts index 6ab449873fc76..1447375c5745b 100644 --- a/x-pack/test/observability_functional/apps/observability/pages/rule_details_page.ts +++ b/x-pack/test/observability_functional/apps/observability/pages/rule_details_page.ts @@ -16,6 +16,7 @@ import { FtrProviderContext } from '../../../ftr_provider_context'; export default ({ getService }: FtrProviderContext) => { const testSubjects = getService('testSubjects'); + const browser = getService('browser'); const observability = getService('observability'); const supertest = getService('supertest'); const find = getService('find'); @@ -141,6 +142,48 @@ export default ({ getService }: FtrProviderContext) => { }); }); + describe('Alert summary widget component', () => { + before(async () => { + await observability.alerts.common.navigateToRuleDetailsByRuleId(uptimeRuleId); + }); + + it('shows component on the rule detils page', async () => { + await observability.components.alertSummaryWidget.getCompactComponentSelectorOrFail(); + + const timeRangeTitle = + await observability.components.alertSummaryWidget.getCompactTimeRangeTitle(); + expect(timeRangeTitle).to.be('Last 30 days'); + }); + + it('handles clicking on active correctly', async () => { + const activeAlerts = + await observability.components.alertSummaryWidget.getCompactActiveAlertSelector(); + await activeAlerts.click(); + + const url = await browser.getCurrentUrl(); + const { from, to } = await observability.components.alertSearchBar.getAbsoluteTimeRange(); + + expect(url.includes('tabId=alerts')).to.be(true); + expect(url.includes('status%3Aactive')).to.be(true); + expect(url.includes(from.replaceAll(':', '%3A'))).to.be(true); + expect(url.includes(to.replaceAll(':', '%3A'))).to.be(true); + }); + + it('handles clicking on recovered correctly', async () => { + const recoveredAlerts = + await observability.components.alertSummaryWidget.getCompactRecoveredAlertSelector(); + await recoveredAlerts.click(); + + const url = await browser.getCurrentUrl(); + const { from, to } = await observability.components.alertSearchBar.getAbsoluteTimeRange(); + + expect(url.includes('tabId=alerts')).to.be(true); + expect(url.includes('status%3Arecovered')).to.be(true); + expect(url.includes(from.replaceAll(':', '%3A'))).to.be(true); + expect(url.includes(to.replaceAll(':', '%3A'))).to.be(true); + }); + }); + describe('User permissions', () => { before(async () => { await observability.alerts.common.navigateToRuleDetailsByRuleId(logThresholdRuleId); diff --git a/x-pack/test/plugin_api_integration/test_suites/event_log/public_api_integration.ts b/x-pack/test/plugin_api_integration/test_suites/event_log/public_api_integration.ts index 961efb82a90d1..04c3907cde588 100644 --- a/x-pack/test/plugin_api_integration/test_suites/event_log/public_api_integration.ts +++ b/x-pack/test/plugin_api_integration/test_suites/event_log/public_api_integration.ts @@ -6,7 +6,7 @@ */ import { merge, omit, chunk, isEmpty } from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import moment from 'moment'; import { IEvent } from '@kbn/event-log-plugin/server'; @@ -41,7 +41,7 @@ export default function ({ getService }: FtrProviderContext) { describe(`namespace: ${namespaceName}`, () => { it('should allow querying for events by Saved Object', async () => { - const id = uuid.v4(); + const id = uuidv4(); const expectedEvents = [fakeEvent(namespace, id), fakeEvent(namespace, id)]; @@ -61,7 +61,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('should support pagination for events', async () => { - const id = uuid.v4(); + const id = uuidv4(); const expectedEvents = await logFakeEvents(namespace, id, 6); @@ -91,7 +91,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('should support sorting by event end', async () => { - const id = uuid.v4(); + const id = uuidv4(); const expectedEvents = await logFakeEvents(namespace, id, 6); @@ -108,7 +108,7 @@ export default function ({ getService }: FtrProviderContext) { }); it('should support date ranges for events', async () => { - const id = uuid.v4(); + const id = uuidv4(); // write a document that shouldn't be found in the inclusive date range search const firstEvent = fakeEvent(namespace, id); diff --git a/x-pack/test/plugin_api_integration/test_suites/event_log/service_api_integration.ts b/x-pack/test/plugin_api_integration/test_suites/event_log/service_api_integration.ts index 14c92d91138dd..2bd65ef5dcd3e 100644 --- a/x-pack/test/plugin_api_integration/test_suites/event_log/service_api_integration.ts +++ b/x-pack/test/plugin_api_integration/test_suites/event_log/service_api_integration.ts @@ -6,7 +6,7 @@ */ import _ from 'lodash'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import { IEvent } from '@kbn/event-log-plugin/server'; import { FtrProviderContext } from '../../ftr_provider_context'; @@ -232,8 +232,8 @@ export default function ({ getService }: FtrProviderContext) { } async function getTestProviderAction() { - const provider = `provider-${uuid.v4()}`; - const action = `action-${uuid.v4()}`; + const provider = `provider-${uuidv4()}`; + const action = `action-${uuidv4()}`; const response = await isProviderActionRegistered(provider, action); if (!response.body.isProviderActionRegistered) { @@ -244,7 +244,7 @@ export default function ({ getService }: FtrProviderContext) { } function getTestSavedObject() { - return { type: 'event_log_test', id: uuid.v4(), rel: 'primary' }; + return { type: 'event_log_test', id: uuidv4(), rel: 'primary' }; } async function logEvent(event: IEvent, savedObjectId: string) { diff --git a/x-pack/test/plugin_api_perf/plugins/task_manager_performance/server/plugin.ts b/x-pack/test/plugin_api_perf/plugins/task_manager_performance/server/plugin.ts index 9d0face98b862..62714e0201bbe 100644 --- a/x-pack/test/plugin_api_perf/plugins/task_manager_performance/server/plugin.ts +++ b/x-pack/test/plugin_api_perf/plugins/task_manager_performance/server/plugin.ts @@ -8,7 +8,7 @@ import { Plugin, CoreSetup, CoreStart } from '@kbn/core/server'; import { firstValueFrom, Subject } from 'rxjs'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import _ from 'lodash'; import stats from 'stats-lite'; import prettyMilliseconds from 'pretty-ms'; @@ -141,7 +141,7 @@ export class SampleTaskManagerFixturePlugin if (taskInstance.params && taskInstance.params.trackExecutionTimeline) { modifiedInstance.state = modifiedInstance.state || {}; modifiedInstance.state.perf = modifiedInstance.state.perf || {}; - modifiedInstance.state.perf.id = uuid.v4().replace(/-/gi, '_'); + modifiedInstance.state.perf.id = uuidv4().replace(/-/gi, '_'); performance.mark(`perfTask_schedule_${modifiedInstance.state.perf.id}`); } diff --git a/x-pack/test/rule_registry/spaces_only/tests/trial/get_summarized_alerts.ts b/x-pack/test/rule_registry/spaces_only/tests/trial/get_summarized_alerts.ts index 4a8e4ddddc9c0..c888269dfdb2b 100644 --- a/x-pack/test/rule_registry/spaces_only/tests/trial/get_summarized_alerts.ts +++ b/x-pack/test/rule_registry/spaces_only/tests/trial/get_summarized_alerts.ts @@ -8,7 +8,7 @@ import { type Subject, ReplaySubject } from 'rxjs'; import type { ElasticsearchClient, Logger, LogMeta } from '@kbn/core/server'; import sinon from 'sinon'; -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import { mappingFromFieldMap } from '@kbn/rule-registry-plugin/common/mapping_from_field_map'; import { @@ -186,7 +186,7 @@ export default function createGetSummarizedAlertsTest({ getService }: FtrProvide // Execute the rule the first time - this creates a new alert const preExecution1Start = new Date(); - const execution1Uuid = uuid.v4(); + const execution1Uuid = uuidv4(); const execution1Result = await executor({ ...options, startedAt: new Date(), @@ -206,7 +206,7 @@ export default function createGetSummarizedAlertsTest({ getService }: FtrProvide // Execute again to update the existing alert const preExecution2Start = new Date(); - const execution2Uuid = uuid.v4(); + const execution2Uuid = uuidv4(); const execution2Result = await executor({ ...options, startedAt: new Date(), @@ -225,7 +225,7 @@ export default function createGetSummarizedAlertsTest({ getService }: FtrProvide expect(execution2SummarizedAlerts.recovered.count).to.eql(0); // Execute again to recover the alert - const execution3Uuid = uuid.v4(); + const execution3Uuid = uuidv4(); await executor({ ...options, startedAt: new Date(), @@ -273,7 +273,7 @@ export default function createGetSummarizedAlertsTest({ getService }: FtrProvide }); it(`shouldn't return muted alerts`, async () => { - const ruleId = uuid.v4(); + const ruleId = uuidv4(); const id1 = 'host-01'; const id2 = 'host-02'; @@ -343,7 +343,7 @@ export default function createGetSummarizedAlertsTest({ getService }: FtrProvide ) => ({ wrapped: { shouldTriggerAlert }, trackedAlerts: alerts, trackedAlertsRecovered: {} }); // Execute the rule the first time - this creates a new alert - const execution1Uuid = uuid.v4(); + const execution1Uuid = uuidv4(); await executor({ ...options, startedAt: new Date(), diff --git a/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/details_view.ts b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/details_view.ts index 3257814eae2bf..da6e1f1216050 100644 --- a/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/details_view.ts +++ b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/details_view.ts @@ -14,7 +14,7 @@ export default function ({ getService }: FtrProviderContext) { const screenshotDirectories = ['response_ops_docs', 'stack_cases']; let CASE_ID: string; - describe('deatils view', function () { + describe('details view', function () { before(async () => { const { id: caseId } = await cases.api.createCase({ title: 'Web transactions', diff --git a/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/external_connections.ts b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/external_connections.ts new file mode 100644 index 0000000000000..4af31cfba2feb --- /dev/null +++ b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/external_connections.ts @@ -0,0 +1,23 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FtrProviderContext } from '../../../ftr_provider_context'; + +export default function ({ getService }: FtrProviderContext) { + const cases = getService('cases'); + const commonScreenshots = getService('commonScreenshots'); + + const screenshotDirectories = ['response_ops_docs', 'stack_cases']; + + describe('edit external connections', function () { + it('cases configure screenshot', async () => { + await cases.navigation.navigateToApp(); + await cases.navigation.navigateToConfigurationPage(); + await commonScreenshots.takeScreenshot('cases-connectors', screenshotDirectories, 1400, 1024); + }); + }); +} diff --git a/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/index.ts b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/index.ts index 45138204e52f5..497805b1f0085 100644 --- a/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/index.ts +++ b/x-pack/test/screenshot_creation/apps/response_ops_docs/stack_cases/index.ts @@ -11,5 +11,6 @@ export default function ({ loadTestFile }: FtrProviderContext) { describe('stack cases', function () { loadTestFile(require.resolve('./list_view')); loadTestFile(require.resolve('./details_view')); + loadTestFile(require.resolve('./external_connections')); }); } diff --git a/x-pack/test/search_sessions_integration/tests/apps/management/search_sessions/sessions_management.ts b/x-pack/test/search_sessions_integration/tests/apps/management/search_sessions/sessions_management.ts index cacc63ab94e57..38cc54e2131e5 100644 --- a/x-pack/test/search_sessions_integration/tests/apps/management/search_sessions/sessions_management.ts +++ b/x-pack/test/search_sessions_integration/tests/apps/management/search_sessions/sessions_management.ts @@ -6,7 +6,7 @@ */ import expect from '@kbn/expect'; -import uuid from 'uuid/v4'; +import { v4 as uuidv4 } from 'uuid'; import { FtrProviderContext } from '../../../../ftr_provider_context'; export default function ({ getService, getPageObjects }: FtrProviderContext) { @@ -44,7 +44,7 @@ export default function ({ getService, getPageObjects }: FtrProviderContext) { await PageObjects.dashboard.loadSavedDashboard('Not Delayed'); await PageObjects.dashboard.waitForRenderComplete(); await searchSessions.expectState('completed'); - const searchSessionName = `Session - ${uuid()}`; + const searchSessionName = `Session - ${uuidv4()}`; await searchSessions.save({ searchSessionName }); await searchSessions.expectState('backgroundCompleted'); diff --git a/x-pack/test/security_api_integration/saml_cloud.config.ts b/x-pack/test/security_api_integration/saml_cloud.config.ts new file mode 100644 index 0000000000000..73f06ddf82590 --- /dev/null +++ b/x-pack/test/security_api_integration/saml_cloud.config.ts @@ -0,0 +1,55 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { resolve } from 'path'; +import { FtrConfigProviderContext } from '@kbn/test'; +import { services } from './services'; + +export default async function ({ readConfigFile }: FtrConfigProviderContext) { + const xPackAPITestsConfig = await readConfigFile(require.resolve('../api_integration/config.ts')); + + const kibanaPort = xPackAPITestsConfig.get('servers.kibana.port'); + const idpPath = resolve(__dirname, './fixtures/saml/idp_metadata.xml'); + + return { + testFiles: [require.resolve('./tests/saml_cloud')], + servers: xPackAPITestsConfig.get('servers'), + security: { disableTestUser: true }, + services, + junit: { + reportName: 'X-Pack Security API Integration Tests (Cloud SAML)', + }, + + esTestCluster: { + ...xPackAPITestsConfig.get('esTestCluster'), + serverArgs: [ + ...xPackAPITestsConfig.get('esTestCluster.serverArgs'), + 'xpack.security.authc.token.enabled=true', + 'xpack.security.authc.token.timeout=15s', + 'xpack.security.authc.realms.saml.cloud-saml-kibana.order=0', + `xpack.security.authc.realms.saml.cloud-saml-kibana.idp.metadata.path=${idpPath}`, + 'xpack.security.authc.realms.saml.cloud-saml-kibana.idp.entity_id=http://www.elastic.co/saml1', + `xpack.security.authc.realms.saml.cloud-saml-kibana.sp.entity_id=http://localhost:${kibanaPort}`, + `xpack.security.authc.realms.saml.cloud-saml-kibana.sp.logout=http://localhost:${kibanaPort}/logout`, + `xpack.security.authc.realms.saml.cloud-saml-kibana.sp.acs=http://localhost:${kibanaPort}/api/security/saml/callback`, + 'xpack.security.authc.realms.saml.cloud-saml-kibana.attributes.principal=urn:oid:0.0.7', + ], + }, + + kbnTestServer: { + ...xPackAPITestsConfig.get('kbnTestServer'), + serverArgs: [ + ...xPackAPITestsConfig.get('kbnTestServer.serverArgs'), + '--xpack.cloud.id=ftr_fake_cloud_id', + `--xpack.security.authc.providers=${JSON.stringify({ + basic: { 'cloud-basic': { order: 0 } }, + saml: { 'cloud-saml-kibana': { order: 1, realm: 'cloud-saml-kibana' } }, + })}`, + ], + }, + }; +} diff --git a/x-pack/test/security_api_integration/session_concurrent_limit.config.ts b/x-pack/test/security_api_integration/session_concurrent_limit.config.ts new file mode 100644 index 0000000000000..7c9fcf6bc8bf2 --- /dev/null +++ b/x-pack/test/security_api_integration/session_concurrent_limit.config.ts @@ -0,0 +1,67 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { resolve } from 'path'; +import { FtrConfigProviderContext } from '@kbn/test'; +import { services } from './services'; + +// the default export of config files must be a config provider +// that returns an object with the projects config values +export default async function ({ readConfigFile }: FtrConfigProviderContext) { + const xPackAPITestsConfig = await readConfigFile(require.resolve('../api_integration/config.ts')); + + const kibanaPort = xPackAPITestsConfig.get('servers.kibana.port'); + const idpPath = resolve(__dirname, './fixtures/saml/idp_metadata.xml'); + + const testEndpointsPlugin = resolve(__dirname, '../security_functional/plugins/test_endpoints'); + + return { + testFiles: [resolve(__dirname, './tests/session_concurrent_limit')], + services, + servers: xPackAPITestsConfig.get('servers'), + esTestCluster: { + ...xPackAPITestsConfig.get('esTestCluster'), + serverArgs: [ + ...xPackAPITestsConfig.get('esTestCluster.serverArgs'), + 'xpack.security.authc.token.enabled=true', + 'xpack.security.authc.realms.native.native1.order=0', + 'xpack.security.authc.realms.saml.saml1.order=1', + `xpack.security.authc.realms.saml.saml1.idp.metadata.path=${idpPath}`, + 'xpack.security.authc.realms.saml.saml1.idp.entity_id=http://www.elastic.co/saml1', + `xpack.security.authc.realms.saml.saml1.sp.entity_id=http://localhost:${kibanaPort}`, + `xpack.security.authc.realms.saml.saml1.sp.logout=http://localhost:${kibanaPort}/logout`, + `xpack.security.authc.realms.saml.saml1.sp.acs=http://localhost:${kibanaPort}/api/security/saml/callback`, + 'xpack.security.authc.realms.saml.saml1.attributes.principal=urn:oid:0.0.7', + ], + }, + + kbnTestServer: { + ...xPackAPITestsConfig.get('kbnTestServer'), + serverArgs: [ + ...xPackAPITestsConfig.get('kbnTestServer.serverArgs'), + `--plugin-path=${testEndpointsPlugin}`, + '--xpack.security.session.concurrentSessions.maxSessions=2', + `--xpack.security.authc.providers=${JSON.stringify({ + basic: { basic1: { order: 0 } }, + saml: { saml1: { order: 1, realm: 'saml1' } }, + anonymous: { + anonymous1: { + order: 3, + credentials: { username: 'anonymous_user', password: 'changeme' }, + }, + }, + })}`, + // Exclude Uptime tasks to not interfere (additional ES load) with the session cleanup task. + `--xpack.task_manager.unsafe.exclude_task_types=${JSON.stringify(['UPTIME:*'])}`, + ], + }, + + junit: { + reportName: 'X-Pack Security API Integration Tests (Session Concurrent Limit)', + }, + }; +} diff --git a/x-pack/test/security_api_integration/tests/saml_cloud/index.ts b/x-pack/test/security_api_integration/tests/saml_cloud/index.ts new file mode 100644 index 0000000000000..a2b39ad247151 --- /dev/null +++ b/x-pack/test/security_api_integration/tests/saml_cloud/index.ts @@ -0,0 +1,14 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ loadTestFile }: FtrProviderContext) { + describe('security APIs - Cloud SAML', function () { + loadTestFile(require.resolve('./saml_login')); + }); +} diff --git a/x-pack/test/security_api_integration/tests/saml_cloud/saml_login.ts b/x-pack/test/security_api_integration/tests/saml_cloud/saml_login.ts new file mode 100644 index 0000000000000..7f5c5f824806c --- /dev/null +++ b/x-pack/test/security_api_integration/tests/saml_cloud/saml_login.ts @@ -0,0 +1,75 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import expect from '@kbn/expect'; +import { parse as parseCookie, Cookie } from 'tough-cookie'; +import { getSAMLResponse } from '../../fixtures/saml/saml_tools'; +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ getService }: FtrProviderContext) { + const randomness = getService('randomness'); + const supertest = getService('supertestWithoutAuth'); + const config = getService('config'); + + const kibanaServerConfig = config.get('servers.kibana'); + + function createSAMLResponse(options = {}) { + return getSAMLResponse({ + destination: `http://localhost:${kibanaServerConfig.port}/api/security/saml/callback`, + sessionIndex: String(randomness.naturalNumber()), + ...options, + }); + } + + async function checkSessionCookie(sessionCookie: Cookie, username = 'a@b.c') { + const apiResponse = await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(200); + + expect(apiResponse.body.username).to.be(username); + expect(apiResponse.body.elastic_cloud_user).to.be(true); + expect(apiResponse.body.authentication_realm).to.eql({ + type: 'saml', + name: 'cloud-saml-kibana', + }); + expect(apiResponse.body.authentication_provider).to.eql({ + type: 'saml', + name: 'cloud-saml-kibana', + }); + expect(apiResponse.body.authentication_type).to.be('token'); + } + + describe('Cloud SAML authentication', () => { + let sessionCookie: Cookie; + + beforeEach(async () => { + // Cloud SAML relies on IdP initiated login. + const samlAuthenticationResponse = await supertest + .post('/api/security/saml/callback') + .send({ SAMLResponse: await createSAMLResponse({ username: 'a@b.c' }) }) + .expect(302); + + expect(samlAuthenticationResponse.headers.location).to.be('/'); + + sessionCookie = parseCookie(samlAuthenticationResponse.headers['set-cookie'][0])!; + }); + + it('should properly set `elastic_cloud_user` user property', async () => { + // Same user, same provider - session ID hasn't changed and cookie should still be valid. + await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(200); + + // Check that all properties of the cloud saml user are properly set. + await checkSessionCookie(sessionCookie); + }); + }); +} diff --git a/x-pack/test/security_api_integration/tests/session_concurrent_limit/cleanup.ts b/x-pack/test/security_api_integration/tests/session_concurrent_limit/cleanup.ts new file mode 100644 index 0000000000000..f882e5197abf9 --- /dev/null +++ b/x-pack/test/security_api_integration/tests/session_concurrent_limit/cleanup.ts @@ -0,0 +1,388 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { parse as parseCookie, Cookie } from 'tough-cookie'; +import { setTimeout as setTimeoutAsync } from 'timers/promises'; +import expect from '@kbn/expect'; +import { adminTestUser } from '@kbn/test'; +import type { AuthenticationProvider } from '@kbn/security-plugin/common'; +import { + AggregateName, + AggregationsMultiTermsAggregate, + AggregationsMultiTermsBucket, + AggregationsTopHitsAggregate, + SearchTotalHits, +} from '@elastic/elasticsearch/lib/api/types'; +import { FtrProviderContext } from '../../ftr_provider_context'; +import { getSAMLRequestId, getSAMLResponse } from '../../fixtures/saml/saml_tools'; + +export default function ({ getService }: FtrProviderContext) { + const supertest = getService('supertestWithoutAuth'); + const es = getService('es'); + const security = getService('security'); + const esDeleteAllIndices = getService('esDeleteAllIndices'); + const config = getService('config'); + const log = getService('log'); + const randomness = getService('randomness'); + const testUser = { username: 'test_user', password: 'changeme' }; + const basicProvider = { type: 'basic', name: 'basic1' }; + const samlProvider = { type: 'saml', name: 'saml1' }; + const anonymousProvider = { type: 'anonymous', name: 'anonymous1' }; + const kibanaServerConfig = config.get('servers.kibana'); + + async function checkSessionCookie( + sessionCookie: Cookie, + username: string, + provider: AuthenticationProvider + ) { + const apiResponse = await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(200); + + expect(apiResponse.body.username).to.be(username); + expect(apiResponse.body.authentication_provider).to.eql(provider); + + return Array.isArray(apiResponse.headers['set-cookie']) + ? parseCookie(apiResponse.headers['set-cookie'][0])! + : undefined; + } + + async function checkSessionCookieInvalid(sessionCookie: Cookie) { + await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(401); + } + + async function getNumberOfSessionDocuments() { + await es.indices.refresh({ index: '.kibana_security_session*' }); + + const sessionDocuments = await es.search({ index: '.kibana_security_session*' }); + log.debug(`Existing sessions: ${JSON.stringify(sessionDocuments.hits)}.`); + + return (sessionDocuments.hits.total as SearchTotalHits).value; + } + + async function loginWithBasic(credentials: { username: string; password: string }) { + const authenticationResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ + providerType: basicProvider.type, + providerName: basicProvider.name, + currentURL: '/', + params: credentials, + }) + .expect(200); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function startSAMLHandshake() { + const handshakeResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ providerType: samlProvider.type, providerName: samlProvider.name, currentURL: '' }) + .expect(200); + + return { + cookie: parseCookie(handshakeResponse.headers['set-cookie'][0])!, + location: handshakeResponse.body.location, + }; + } + + async function finishSAMLHandshake(handshakeCookie: Cookie, handshakeLocation: string) { + const authenticationResponse = await supertest + .post('/api/security/saml/callback') + .set('kbn-xsrf', 'xxx') + .set('Cookie', handshakeCookie.cookieString()) + .send({ + SAMLResponse: await getSAMLResponse({ + destination: `http://localhost:${kibanaServerConfig.port}/api/security/saml/callback`, + sessionIndex: String(randomness.naturalNumber()), + inResponseTo: await getSAMLRequestId(handshakeLocation), + }), + }) + .expect(302); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function loginWithSAML() { + const { cookie, location } = await startSAMLHandshake(); + return finishSAMLHandshake(cookie, location); + } + + async function loginWithAnonymous() { + const authenticationResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ + providerType: anonymousProvider.type, + providerName: anonymousProvider.name, + currentURL: '/', + }) + .expect(200); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function toggleSessionCleanupTask(enabled: boolean) { + await supertest + .post('/session/toggle_cleanup_task') + .set('kbn-xsrf', 'xxx') + .auth(adminTestUser.username, adminTestUser.password) + .send({ enabled }) + .expect(200); + } + + // FLAKY: https://github.com/elastic/kibana/issues/149092 + // FLAKY: https://github.com/elastic/kibana/issues/149091 + // FLAKY: https://github.com/elastic/kibana/issues/149090 + describe.skip('Session Concurrent Limit cleanup', () => { + before(async () => { + await security.user.create('anonymous_user', { + password: 'changeme', + roles: [], + full_name: 'Guest', + }); + }); + + after(async () => { + await security.user.delete('anonymous_user'); + }); + + beforeEach(async function () { + this.timeout(120000); + await toggleSessionCleanupTask(false); + await es.cluster.health({ index: '.kibana_security_session*', wait_for_status: 'green' }); + await esDeleteAllIndices('.kibana_security_session*'); + }); + + it('should properly clean up sessions that exceeded concurrent session limit', async function () { + this.timeout(100000); + + log.debug(`Log in as ${testUser.username} 3 times with a 0.5s delay.`); + + const basicSessionCookieOne = await loginWithBasic(testUser); + await setTimeoutAsync(500); + const basicSessionCookieTwo = await loginWithBasic(testUser); + await setTimeoutAsync(500); + const basicSessionCookieThree = await loginWithBasic(testUser); + + expect(await getNumberOfSessionDocuments()).to.be(3); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(2); + + await checkSessionCookieInvalid(basicSessionCookieOne); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieThree, testUser.username, basicProvider); + }); + + it('should properly clean up sessions that exceeded concurrent session limit even for multiple providers', async function () { + this.timeout(100000); + + log.debug(`Log in as ${testUser.username} and SAML user 3 times each with a 0.5s delay.`); + + const basicSessionCookieOne = await loginWithBasic(testUser); + const samlSessionCookieOne = await loginWithSAML(); + await setTimeoutAsync(500); + const basicSessionCookieTwo = await loginWithBasic(testUser); + const samlSessionCookieTwo = await loginWithSAML(); + await setTimeoutAsync(500); + const basicSessionCookieThree = await loginWithBasic(testUser); + const samlSessionCookieThree = await loginWithSAML(); + + expect(await getNumberOfSessionDocuments()).to.be(6); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(4); + + await checkSessionCookieInvalid(basicSessionCookieOne); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieThree, testUser.username, basicProvider); + + await checkSessionCookieInvalid(samlSessionCookieOne); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieThree, 'a@b.c', samlProvider); + }); + + it('should properly clean up sessions that exceeded concurrent session limit when legacy sessions are present', async function () { + this.timeout(100000); + + log.debug(`Log in as ${testUser.username} and SAML user 3 times each with a 0.5s delay.`); + + const basicSessionCookieOne = await loginWithBasic(testUser); + const samlSessionCookieOne = await loginWithSAML(); + await setTimeoutAsync(500); + const basicSessionCookieTwo = await loginWithBasic(testUser); + const samlSessionCookieTwo = await loginWithSAML(); + await setTimeoutAsync(500); + const basicSessionCookieThree = await loginWithBasic(testUser); + const samlSessionCookieThree = await loginWithSAML(); + + expect(await getNumberOfSessionDocuments()).to.be(6); + + // Remove `createdAt` field from the most recent sessions to emulate legacy sessions. + // 1. Get the latest session for every unique credentials. + const aggResponse = await es.search< + unknown, + Record + >({ + index: '.kibana_security_session*', + size: 0, + filter_path: 'aggregations.sessions.buckets.top.hits.hits._id', + aggs: { + sessions: { + multi_terms: { terms: [{ field: 'usernameHash' }, { field: 'provider.type' }] }, + aggs: { top: { top_hits: { sort: [{ createdAt: { order: 'desc' } }], size: 1 } } }, + }, + }, + }); + + // 2. Extract session IDs from the nested top_hits aggregation. + const sessionIds = + (aggResponse.aggregations?.sessions.buckets as AggregationsMultiTermsBucket[]).flatMap( + (bucket) => { + const sessionId = (bucket.top as AggregationsTopHitsAggregate).hits?.hits?.[0]?._id; + return sessionId ? [sessionId] : []; + } + ) ?? []; + expect(sessionIds.length).to.be(2); + + // 3. Remove `createdAt` field for the latest sessions emulating legacy sessions. + await es.updateByQuery({ + index: '.kibana_security_session*', + body: { script: 'ctx._source.remove("createdAt")', query: { ids: { values: sessionIds } } }, + refresh: true, + }); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(4); + + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookieInvalid(basicSessionCookieThree); + + await checkSessionCookie(samlSessionCookieOne, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + await checkSessionCookieInvalid(samlSessionCookieThree); + }); + + it('should not clean up session if the limit is not exceeded', async function () { + this.timeout(100000); + + log.debug(`Log in as ${testUser.username} 2 times with a 0.5s delay.`); + + const basicSessionCookieOne = await loginWithBasic(testUser); + await setTimeoutAsync(500); + const basicSessionCookieTwo = await loginWithBasic(testUser); + + expect(await getNumberOfSessionDocuments()).to.be(2); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(2); + + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + }); + + it('should not clean up sessions of the anonymous users', async function () { + this.timeout(100000); + + log.debug(`Log in as anonymous_user 3 times.`); + + const anonymousSessionCookieOne = await loginWithAnonymous(); + const anonymousSessionCookieTwo = await loginWithAnonymous(); + const anonymousSessionCookieThree = await loginWithAnonymous(); + + expect(await getNumberOfSessionDocuments()).to.be(3); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(3); + + // All sessions should be active. + for (const anonymousSessionCookie of [ + anonymousSessionCookieOne, + anonymousSessionCookieTwo, + anonymousSessionCookieThree, + ]) { + await checkSessionCookie(anonymousSessionCookie, 'anonymous_user', anonymousProvider); + } + }); + + it('should not clean up unauthenticated sessions', async function () { + this.timeout(100000); + + log.debug(`Starting SAML handshake 3 times.`); + + const unauthenticatedSessionOne = await startSAMLHandshake(); + const unauthenticatedSessionTwo = await startSAMLHandshake(); + const unauthenticatedSessionThree = await startSAMLHandshake(); + + expect(await getNumberOfSessionDocuments()).to.be(3); + + // Let's wait for 60s to make sure cleanup routine runs after it was enabled. + log.debug('Waiting for cleanup job to run...'); + await toggleSessionCleanupTask(true); + await setTimeoutAsync(60000); + + // The oldest session should have been removed, but the rest should still be valid. + expect(await getNumberOfSessionDocuments()).to.be(3); + + // Finish SAML handshake (all should succeed since we don't enforce limit at session creation time). + const samlSessionCookieOne = await finishSAMLHandshake( + unauthenticatedSessionOne.cookie, + unauthenticatedSessionOne.location + ); + await setTimeoutAsync(500); + const samlSessionCookieTwo = await finishSAMLHandshake( + unauthenticatedSessionTwo.cookie, + unauthenticatedSessionTwo.location + ); + await setTimeoutAsync(500); + const samlSessionCookieThree = await finishSAMLHandshake( + unauthenticatedSessionThree.cookie, + unauthenticatedSessionThree.location + ); + + // For authenticated sessions limit should be enforced + await checkSessionCookieInvalid(samlSessionCookieOne); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieThree, 'a@b.c', samlProvider); + }); + }); +} diff --git a/x-pack/test/security_api_integration/tests/session_concurrent_limit/global_limit.ts b/x-pack/test/security_api_integration/tests/session_concurrent_limit/global_limit.ts new file mode 100644 index 0000000000000..3b4fecf6ee7c4 --- /dev/null +++ b/x-pack/test/security_api_integration/tests/session_concurrent_limit/global_limit.ts @@ -0,0 +1,267 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { parse as parseCookie, Cookie } from 'tough-cookie'; +import expect from '@kbn/expect'; +import { adminTestUser } from '@kbn/test'; +import type { AuthenticationProvider } from '@kbn/security-plugin/common/model'; +import { getSAMLRequestId, getSAMLResponse } from '../../fixtures/saml/saml_tools'; +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ getService }: FtrProviderContext) { + const supertest = getService('supertestWithoutAuth'); + const es = getService('es'); + const security = getService('security'); + const config = getService('config'); + const log = getService('log'); + const randomness = getService('randomness'); + const kibanaServerConfig = config.get('servers.kibana'); + const testUser = { username: 'test_user', password: 'changeme' }; + const basicProvider = { type: 'basic', name: 'basic1' }; + const samlProvider = { type: 'saml', name: 'saml1' }; + const anonymousProvider = { type: 'anonymous', name: 'anonymous1' }; + + async function checkSessionCookie( + sessionCookie: Cookie, + username: string, + provider: AuthenticationProvider + ) { + const apiResponse = await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(200); + + expect(apiResponse.body.username).to.be(username); + expect(apiResponse.body.authentication_provider).to.eql(provider); + + return Array.isArray(apiResponse.headers['set-cookie']) + ? parseCookie(apiResponse.headers['set-cookie'][0])! + : undefined; + } + + async function checkSessionCookieInvalid(sessionCookie: Cookie) { + await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', sessionCookie.cookieString()) + .expect(401); + } + + async function loginWithSAML() { + const handshakeResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ providerType: samlProvider.type, providerName: samlProvider.name, currentURL: '' }) + .expect(200); + + const authenticationResponse = await supertest + .post('/api/security/saml/callback') + .set('kbn-xsrf', 'xxx') + .set('Cookie', parseCookie(handshakeResponse.headers['set-cookie'][0])!.cookieString()) + .send({ + SAMLResponse: await getSAMLResponse({ + destination: `http://localhost:${kibanaServerConfig.port}/api/security/saml/callback`, + sessionIndex: String(randomness.naturalNumber()), + inResponseTo: await getSAMLRequestId(handshakeResponse.body.location), + }), + }) + .expect(302); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function loginWithBasic(credentials: { username: string; password: string }) { + const authenticationResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ + providerType: basicProvider.type, + providerName: basicProvider.name, + currentURL: '/', + params: credentials, + }) + .expect(200); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function loginWithAnonymous() { + const authenticationResponse = await supertest + .post('/internal/security/login') + .set('kbn-xsrf', 'xxx') + .send({ + providerType: anonymousProvider.type, + providerName: anonymousProvider.name, + currentURL: '/', + }) + .expect(200); + + return parseCookie(authenticationResponse.headers['set-cookie'][0])!; + } + + async function toggleSessionCleanupTask(enabled: boolean) { + await supertest + .post('/session/toggle_cleanup_task') + .set('kbn-xsrf', 'xxx') + .auth(adminTestUser.username, adminTestUser.password) + .send({ enabled }) + .expect(200); + } + + describe('Session Global Concurrent Limit', () => { + before(async function () { + this.timeout(120000); + // Disable cleanup task to not interfere with the tests. + await toggleSessionCleanupTask(false); + await security.user.create('anonymous_user', { + password: 'changeme', + roles: [], + full_name: 'Guest', + }); + }); + + after(async () => { + // Enable cleanup task again. + await toggleSessionCleanupTask(true); + await security.user.delete('anonymous_user'); + }); + + beforeEach(async () => { + await security.testUser.setRoles(['kibana_admin']); + await es.cluster.health({ index: '.kibana_security_session*', wait_for_status: 'green' }); + await supertest + .post('/api/security/session/_invalidate') + .set('kbn-xsrf', 'xxx') + .auth(adminTestUser.username, adminTestUser.password) + .send({ match: 'all' }) + .expect(200); + }); + + it('should properly enforce session limit with single provider', async function () { + const basicSessionCookieOne = await loginWithBasic(testUser); + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + + const basicSessionCookieTwo = await loginWithBasic(testUser); + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + + // The oldest session should be displaced. + const basicSessionCookieThree = await loginWithBasic(testUser); + await checkSessionCookieInvalid(basicSessionCookieOne); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieThree, testUser.username, basicProvider); + + // The next oldest session should be displaced as well. + const basicSessionCookieFour = await loginWithBasic(testUser); + await checkSessionCookieInvalid(basicSessionCookieTwo); + await checkSessionCookie(basicSessionCookieThree, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieFour, testUser.username, basicProvider); + }); + + it('should properly enforce session limit with single provider and multiple users', async function () { + const basicSessionCookieOne = await loginWithBasic(testUser); + const basicSessionCookieTwo = await loginWithBasic(testUser); + const basicSessionCookieThree = await loginWithBasic(adminTestUser); + const basicSessionCookieFour = await loginWithBasic(adminTestUser); + + // All sessions should be active. + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieThree, adminTestUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieFour, adminTestUser.username, basicProvider); + + // The oldest session of the admin user should be displaced. + const basicSessionCookieFive = await loginWithBasic(adminTestUser); + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookieInvalid(basicSessionCookieThree); + await checkSessionCookie(basicSessionCookieFour, adminTestUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieFive, adminTestUser.username, basicProvider); + + // The next oldest session of the admin user should be displaced as well. + const basicSessionCookieSix = await loginWithBasic(adminTestUser); + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookieInvalid(basicSessionCookieFour); + await checkSessionCookie(basicSessionCookieFive, adminTestUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieSix, adminTestUser.username, basicProvider); + + // Only the oldest session of the ordinary user should be displaced. + const basicSessionCookieSeven = await loginWithBasic(testUser); + await checkSessionCookieInvalid(basicSessionCookieOne); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieFive, adminTestUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieSix, adminTestUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieSeven, testUser.username, basicProvider); + }); + + it('should properly enforce session limit even for multiple concurrent logins', async function () { + const basicSessionCookies = await Promise.all( + Array.from({ length: 10 }).map(() => loginWithBasic(testUser)) + ); + + // Since logins were concurrent we cannot know upfront their `createdAt` timestamps and + // hence which specific sessions will be outside the limit. + const statusCodes = []; + for (const basicSessionCookie of basicSessionCookies) { + const { statusCode } = await supertest + .get('/internal/security/me') + .set('kbn-xsrf', 'xxx') + .set('Cookie', basicSessionCookie.cookieString()); + statusCodes.push(statusCode); + } + + log.debug(`Collected status codes: ${JSON.stringify(statusCodes)}.`); + + expect(statusCodes.filter((statusCode) => statusCode === 200)).to.have.length(2); + expect(statusCodes.filter((statusCode) => statusCode === 401)).to.have.length(8); + }); + + it('should properly enforce session limit with multiple providers', async function () { + const basicSessionCookieOne = await loginWithBasic(testUser); + const basicSessionCookieTwo = await loginWithBasic(testUser); + + const samlSessionCookieOne = await loginWithSAML(); + const samlSessionCookieTwo = await loginWithSAML(); + + // All sessions should be active. + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(samlSessionCookieOne, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + + // Exceed limit with SAML credentials, other sessions shouldn't be affected. + const samlSessionCookieThree = await loginWithSAML(); + await checkSessionCookie(basicSessionCookieOne, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookieInvalid(samlSessionCookieOne); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieThree, 'a@b.c', samlProvider); + + // Exceed limit with Basic credentials, other sessions shouldn't be affected. + const basicSessionCookieThree = await loginWithBasic(testUser); + await checkSessionCookieInvalid(basicSessionCookieOne); + await checkSessionCookie(basicSessionCookieTwo, testUser.username, basicProvider); + await checkSessionCookie(basicSessionCookieThree, testUser.username, basicProvider); + await checkSessionCookie(samlSessionCookieTwo, 'a@b.c', samlProvider); + await checkSessionCookie(samlSessionCookieThree, 'a@b.c', samlProvider); + }); + + it('should not enforce session limit for anonymous users', async function () { + // All sessions should be active. + for (const anonymousSessionCookie of [ + await loginWithAnonymous(), + await loginWithAnonymous(), + await loginWithAnonymous(), + await loginWithAnonymous(), + ]) { + await checkSessionCookie(anonymousSessionCookie, 'anonymous_user', anonymousProvider); + } + }); + }); +} diff --git a/x-pack/test/security_api_integration/tests/session_concurrent_limit/index.ts b/x-pack/test/security_api_integration/tests/session_concurrent_limit/index.ts new file mode 100644 index 0000000000000..61463eaccb09b --- /dev/null +++ b/x-pack/test/security_api_integration/tests/session_concurrent_limit/index.ts @@ -0,0 +1,15 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { FtrProviderContext } from '../../ftr_provider_context'; + +export default function ({ loadTestFile }: FtrProviderContext) { + describe('security APIs - Session Concurrent Limit', function () { + loadTestFile(require.resolve('./cleanup')); + loadTestFile(require.resolve('./global_limit')); + }); +} diff --git a/x-pack/test/security_functional/plugins/test_endpoints/kibana.json b/x-pack/test/security_functional/plugins/test_endpoints/kibana.json index 6546325cb2d68..4c9364e7ed218 100644 --- a/x-pack/test/security_functional/plugins/test_endpoints/kibana.json +++ b/x-pack/test/security_functional/plugins/test_endpoints/kibana.json @@ -3,7 +3,7 @@ "owner": { "name": "Platform Security", "githubTeam": "kibana-security" }, "version": "8.0.0", "kibanaVersion": "kibana", - "requiredPlugins":["security"], + "requiredPlugins":["security", "taskManager"], "server": true, "ui": true } diff --git a/x-pack/test/security_functional/plugins/test_endpoints/server/index.ts b/x-pack/test/security_functional/plugins/test_endpoints/server/index.ts index 43b634048d8cd..33ce96a3cfffa 100644 --- a/x-pack/test/security_functional/plugins/test_endpoints/server/index.ts +++ b/x-pack/test/security_functional/plugins/test_endpoints/server/index.ts @@ -5,11 +5,25 @@ * 2.0. */ -import { PluginInitializer, Plugin } from '@kbn/core/server'; +import { PluginInitializer, Plugin, CoreSetup } from '@kbn/core/server'; +import { + TaskManagerSetupContract, + TaskManagerStartContract, +} from '@kbn/task-manager-plugin/server'; import { initRoutes } from './init_routes'; -export const plugin: PluginInitializer = (initializerContext): Plugin => ({ - setup: (core) => initRoutes(initializerContext, core), +export interface PluginSetupDependencies { + taskManager: TaskManagerSetupContract; +} + +export interface PluginStartDependencies { + taskManager: TaskManagerStartContract; +} + +export const plugin: PluginInitializer = ( + initializerContext +): Plugin => ({ + setup: (core: CoreSetup) => initRoutes(initializerContext, core), start: () => {}, stop: () => {}, }); diff --git a/x-pack/test/security_functional/plugins/test_endpoints/server/init_routes.ts b/x-pack/test/security_functional/plugins/test_endpoints/server/init_routes.ts index 16db5c8242931..9ffcb635f041e 100644 --- a/x-pack/test/security_functional/plugins/test_endpoints/server/init_routes.ts +++ b/x-pack/test/security_functional/plugins/test_endpoints/server/init_routes.ts @@ -7,9 +7,20 @@ import { schema } from '@kbn/config-schema'; import { errors } from '@elastic/elasticsearch'; -import { CoreSetup, PluginInitializerContext } from '@kbn/core/server'; +import { CoreSetup, CoreStart, PluginInitializerContext } from '@kbn/core/server'; +import type { + TaskManagerStartContract, + ConcreteTaskInstance, + BulkUpdateTaskResult, +} from '@kbn/task-manager-plugin/server'; +import { PluginStartDependencies } from '.'; -export function initRoutes(initializerContext: PluginInitializerContext, core: CoreSetup) { +export const SESSION_INDEX_CLEANUP_TASK_NAME = 'session_cleanup'; + +export function initRoutes( + initializerContext: PluginInitializerContext, + core: CoreSetup +) { const logger = initializerContext.logger.get(); const authenticationAppOptions = { simulateUnauthorized: false }; @@ -96,4 +107,127 @@ export function initRoutes(initializerContext: PluginInitializerContext, core: C } } ); + + async function waitUntilTaskIsIdle(taskManager: TaskManagerStartContract) { + logger.info(`Waiting until session cleanup task is in idle.`); + + const RETRY_SCALE_DURATION = 1000; + let retriesElapsed = 0; + let taskInstance: ConcreteTaskInstance; + while (retriesElapsed < 15 /** max around ~100s **/) { + await new Promise((resolve) => setTimeout(resolve, retriesElapsed * RETRY_SCALE_DURATION)); + + try { + taskInstance = await taskManager.get(SESSION_INDEX_CLEANUP_TASK_NAME); + if (taskInstance.status === 'idle') { + logger.info(`Session cleanup task is in idle state: ${JSON.stringify(taskInstance)}.`); + return; + } + } catch (err) { + logger.error(`Failed to fetch task: ${err?.message || err}.`); + throw err; + } + + if (++retriesElapsed < 15) { + logger.warn( + `Session cleanup task is NOT in idle state (waiting for ${ + retriesElapsed * RETRY_SCALE_DURATION + }ms before retrying): ${JSON.stringify(taskInstance)}.` + ); + } else { + logger.error( + `Failed to wait until session cleanup tasks enters an idle state: ${JSON.stringify( + taskInstance + )}.` + ); + } + } + } + + async function refreshTaskManagerIndex( + enabled: boolean, + coreStart: CoreStart, + taskManager: TaskManagerStartContract + ) { + // Refresh task manager index before trying to modify a task document. + // Might not be needed once https://github.com/elastic/kibana/pull/148985 is merged. + try { + logger.info( + `Refreshing task manager index (enabled: ${enabled}), current task: ${JSON.stringify( + await taskManager.get(SESSION_INDEX_CLEANUP_TASK_NAME) + )}...` + ); + + const refreshResult = await coreStart.elasticsearch.client.asInternalUser.indices.refresh({ + index: '.kibana_task_manager', + expand_wildcards: 'all', + }); + + logger.info( + `Successfully refreshed task manager index (enabled: ${enabled}), refresh result: ${JSON.stringify( + refreshResult + )}, current task: ${JSON.stringify( + await taskManager.get(SESSION_INDEX_CLEANUP_TASK_NAME) + )}.` + ); + } catch (err) { + logger.error( + `Failed to refresh task manager index (enabled: ${enabled}): ${err?.message || err}.` + ); + } + } + + router.post( + { + path: '/session/toggle_cleanup_task', + validate: { body: schema.object({ enabled: schema.boolean() }) }, + }, + async (context, request, response) => { + const [coreStart, { taskManager }] = await core.getStartServices(); + logger.info(`Toggle session cleanup task (enabled: ${request.body.enabled}).`); + + await refreshTaskManagerIndex(request.body.enabled, coreStart, taskManager); + + let bulkEnableDisableResult: BulkUpdateTaskResult; + try { + if (request.body.enabled) { + logger.info( + `Going to enable the following task: ${JSON.stringify( + await taskManager.get(SESSION_INDEX_CLEANUP_TASK_NAME) + )}.` + ); + bulkEnableDisableResult = await taskManager.bulkEnable( + [SESSION_INDEX_CLEANUP_TASK_NAME], + true /** runSoon **/ + ); + } else { + bulkEnableDisableResult = await taskManager.bulkDisable([ + SESSION_INDEX_CLEANUP_TASK_NAME, + ]); + } + + await refreshTaskManagerIndex(request.body.enabled, coreStart, taskManager); + + // Make sure that the task enters idle state before acknowledging that task was disabled. + if (!request.body.enabled) { + await waitUntilTaskIsIdle(taskManager); + } + } catch (err) { + logger.error( + `Failed to toggle session cleanup task (enabled: ${request.body.enabled}): ${ + err?.message || err + }.` + ); + throw err; + } + + logger.info( + `Successfully toggled session cleanup task (enabled: ${ + request.body.enabled + }, enable/disable response: ${JSON.stringify(bulkEnableDisableResult)}).` + ); + + return response.ok(); + } + ); } diff --git a/x-pack/test/security_functional/plugins/test_endpoints/tsconfig.json b/x-pack/test/security_functional/plugins/test_endpoints/tsconfig.json index 2802334020ecb..43a87600f622d 100644 --- a/x-pack/test/security_functional/plugins/test_endpoints/tsconfig.json +++ b/x-pack/test/security_functional/plugins/test_endpoints/tsconfig.json @@ -13,6 +13,7 @@ "kbn_references": [ "@kbn/core", "@kbn/security-plugin", + "@kbn/task-manager-plugin", "@kbn/config-schema", ] } diff --git a/x-pack/test/security_solution_cypress/config.ts b/x-pack/test/security_solution_cypress/config.ts index 81d18ce1cab5d..c8048c0b1ba4b 100644 --- a/x-pack/test/security_solution_cypress/config.ts +++ b/x-pack/test/security_solution_cypress/config.ts @@ -52,6 +52,8 @@ export default async function ({ readConfigFile }: FtrConfigProviderContext) { // mock cloud to enable the guided onboarding tour in e2e tests '--xpack.cloud.id=test', `--home.disableWelcomeScreen=true`, + // Specify which version of the detection-rules package to install + // `--xpack.securitySolution.prebuiltRulesPackageVersion=8.3.1`, ], }, }; diff --git a/x-pack/test/security_solution_endpoint/services/endpoint_policy.ts b/x-pack/test/security_solution_endpoint/services/endpoint_policy.ts index 45d7b4226cf00..37682869ead47 100644 --- a/x-pack/test/security_solution_endpoint/services/endpoint_policy.ts +++ b/x-pack/test/security_solution_endpoint/services/endpoint_policy.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import { CreateAgentPolicyRequest, CreateAgentPolicyResponse, @@ -159,7 +159,7 @@ export function EndpointPolicyTestResourcesProvider({ getService }: FtrProviderC let agentPolicy: CreateAgentPolicyResponse['item']; try { const newAgentPolicyData: CreateAgentPolicyRequest['body'] = { - name: `East Coast ${uuid.v4()}`, + name: `East Coast ${uuidv4()}`, description: 'East Coast call center', namespace: 'default', }; @@ -180,7 +180,7 @@ export function EndpointPolicyTestResourcesProvider({ getService }: FtrProviderC let packagePolicy: CreatePackagePolicyResponse['item']; try { const newPackagePolicyData: CreatePackagePolicyRequest['body'] = { - name: `Protect East Coast ${uuid.v4()}`, + name: `Protect East Coast ${uuidv4()}`, description: 'Protect the worlds data - but in the East Coast', policy_id: agentPolicy!.id, enabled: true, diff --git a/x-pack/test/security_solution_endpoint_api_int/apis/metadata.ts b/x-pack/test/security_solution_endpoint_api_int/apis/metadata.ts index 0ee6b44952577..48b0107a599aa 100644 --- a/x-pack/test/security_solution_endpoint_api_int/apis/metadata.ts +++ b/x-pack/test/security_solution_endpoint_api_int/apis/metadata.ts @@ -5,7 +5,7 @@ * 2.0. */ -import uuid from 'uuid'; +import { v4 as uuidv4 } from 'uuid'; import expect from '@kbn/expect'; import { TransformGetTransformStatsTransformStats } from '@elastic/elasticsearch/lib/api/types'; import { @@ -25,8 +25,6 @@ import { generateAgentDocs, generateMetadataDocs } from './metadata.fixtures'; import { deleteAllDocsFromMetadataCurrentIndex, deleteAllDocsFromMetadataDatastream, - deleteMetadataStream, - deleteIndex, stopTransform, startTransform, deleteAllDocsFromFleetAgents, @@ -45,502 +43,248 @@ export default function ({ getService }: FtrProviderContext) { }); describe('list endpoints GET route', () => { - describe('with .metrics-endpoint.metadata_united_default index', () => { - const numberOfHostsInFixture = 2; - - before(async () => { - await deleteAllDocsFromFleetAgents(getService); - await deleteAllDocsFromMetadataDatastream(getService); - await deleteAllDocsFromMetadataCurrentIndex(getService); - await deleteAllDocsFromIndex(getService, METADATA_UNITED_INDEX); - - const customIndexFn = async (): Promise => { - // generate an endpoint policy and attach id to agents since - // metadata list api filters down to endpoint policies only - const policy = await indexFleetEndpointPolicy( - getService('kibanaServer'), - `Default ${uuid.v4()}`, - '1.1.1' - ); - const policyId = policy.integrationPolicies[0].policy_id; - const currentTime = new Date().getTime(); - - const agentDocs = generateAgentDocs(currentTime, policyId); - const metadataDocs = generateMetadataDocs(currentTime); - - await Promise.all([ - bulkIndex(getService, AGENTS_INDEX, agentDocs), - bulkIndex(getService, METADATA_DATASTREAM, metadataDocs), - ]); - - return { - agents: agentDocs, - hosts: metadataDocs, - } as unknown as IndexedHostsAndAlertsResponse; - }; - - await endpointTestResources.loadEndpointData({ customIndexFn }); - }); - - after(async () => { - await deleteAllDocsFromFleetAgents(getService); - await deleteAllDocsFromMetadataDatastream(getService); - await deleteAllDocsFromMetadataCurrentIndex(getService); - await deleteAllDocsFromIndex(getService, METADATA_UNITED_INDEX); - }); - - it('should return one entry for each host with default paging', async () => { - const res = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 0, - pageSize: 10, - }) - .expect(200); - const { body } = res; - expect(body.data.length).to.eql(numberOfHostsInFixture); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on paging properties passed', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 1, - pageSize: 1, - }) - .expect(200); - expect(body.data.length).to.eql(1); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(1); - expect(body.pageSize).to.eql(1); - }); - - it('metadata api should return accurate total metadata if page index produces no result', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 3, - pageSize: 10, - }) - .expect(200); - expect(body.data.length).to.eql(0); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(3); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return 400 when pagingProperties is below boundaries.', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 1, - pageSize: 0, - }) - .expect(400); - expect(body.message).to.contain('Value must be equal to or greater than [1]'); - }); - - it('metadata api should return page based on filters passed.', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: 'not (united.endpoint.host.ip:10.101.149.26)', - }) - .expect(200); - expect(body.data.length).to.eql(1); - expect(body.total).to.eql(1); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on filters and paging passed.', async () => { - const notIncludedIp = '10.101.149.26'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 0, - pageSize: 10, - kuery: `not (united.endpoint.host.ip:${notIncludedIp})`, - }) - .expect(200); - expect(body.total).to.eql(1); - const resultIps: string[] = [].concat( - ...body.data.map((hostInfo: Record) => hostInfo.metadata.host.ip) + const numberOfHostsInFixture = 2; + + before(async () => { + await deleteAllDocsFromFleetAgents(getService); + await deleteAllDocsFromMetadataDatastream(getService); + await deleteAllDocsFromMetadataCurrentIndex(getService); + await deleteAllDocsFromIndex(getService, METADATA_UNITED_INDEX); + + const customIndexFn = async (): Promise => { + // generate an endpoint policy and attach id to agents since + // metadata list api filters down to endpoint policies only + const policy = await indexFleetEndpointPolicy( + getService('kibanaServer'), + `Default ${uuidv4()}`, + '1.1.1' ); - expect(resultIps.sort()).to.eql(['10.192.213.130', '10.70.28.129'].sort()); - expect(resultIps).not.include.eql(notIncludedIp); - expect(body.data.length).to.eql(1); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on host.os.Ext.variant filter.', async () => { - const variantValue = 'Windows Pro'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `united.endpoint.host.os.Ext.variant:${variantValue}`, - }) - .expect(200); - expect(body.total).to.eql(2); - const resultOsVariantValue: Set = new Set( - body.data.map((hostInfo: Record) => hostInfo.metadata.host.os.Ext.variant) - ); - expect(Array.from(resultOsVariantValue)).to.eql([variantValue]); - expect(body.data.length).to.eql(2); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return the latest event for all the events for an endpoint', async () => { - const targetEndpointIp = '10.101.149.26'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `united.endpoint.host.ip:${targetEndpointIp}`, - }) - .expect(200); - expect(body.total).to.eql(1); - const resultIp: string = body.data[0].metadata.host.ip.filter( - (ip: string) => ip === targetEndpointIp - ); - expect(resultIp).to.eql([targetEndpointIp]); - expect(body.data.length).to.eql(1); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return the latest event for all the events where policy status is not success', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: 'not (united.endpoint.Endpoint.policy.applied.status:success)', - }) - .expect(200); - const statuses: Set = new Set( - body.data.map( - (hostInfo: Record) => hostInfo.metadata.Endpoint.policy.applied.status - ) - ); - expect(statuses.size).to.eql(1); - expect(Array.from(statuses)).to.eql(['failure']); - }); - - it('metadata api should return the endpoint based on the elastic agent id, and status should be healthy', async () => { - const targetEndpointId = 'fc0ff548-feba-41b6-8367-65e8790d0eaf'; - const targetElasticAgentId = '023fa40c-411d-4188-a941-4147bfadd095'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `united.endpoint.elastic.agent.id:${targetElasticAgentId}`, - }) - .expect(200); - expect(body.total).to.eql(1); - const resultHostId: string = body.data[0].metadata.host.id; - const resultElasticAgentId: string = body.data[0].metadata.elastic.agent.id; - expect(resultHostId).to.eql(targetEndpointId); - expect(resultElasticAgentId).to.eql(targetElasticAgentId); - expect(body.data.length).to.eql(1); - expect(body.data[0].host_status).to.eql('healthy'); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return the endpoint based on the agent hostname', async () => { - const targetEndpointId = 'fc0ff548-feba-41b6-8367-65e8790d0eaf'; - const targetAgentHostname = 'Example-host-name-XYZ'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `united.endpoint.host.hostname:${targetAgentHostname}`, - }) - .expect(200); - expect(body.total).to.eql(1); - const resultHostId: string = body.data[0].metadata.host.id; - const resultElasticAgentName: string = body.data[0].metadata.host.hostname; - expect(resultHostId).to.eql(targetEndpointId); - expect(resultElasticAgentName).to.eql(targetAgentHostname); - expect(body.data.length).to.eql(1); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return all hosts when filter is empty string', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .expect(200); - expect(body.data.length).to.eql(numberOfHostsInFixture); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); + const policyId = policy.integrationPolicies[0].policy_id; + const currentTime = new Date().getTime(); + + const agentDocs = generateAgentDocs(currentTime, policyId); + const metadataDocs = generateMetadataDocs(currentTime); + + await Promise.all([ + bulkIndex(getService, AGENTS_INDEX, agentDocs), + bulkIndex(getService, METADATA_DATASTREAM, metadataDocs), + ]); + + return { + agents: agentDocs, + hosts: metadataDocs, + } as unknown as IndexedHostsAndAlertsResponse; + }; + + await endpointTestResources.loadEndpointData({ customIndexFn }); + }); + + after(async () => { + await deleteAllDocsFromFleetAgents(getService); + await deleteAllDocsFromMetadataDatastream(getService); + await deleteAllDocsFromMetadataCurrentIndex(getService); + await deleteAllDocsFromIndex(getService, METADATA_UNITED_INDEX); + }); + + it('should return one entry for each host with default paging', async () => { + const res = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + page: 0, + pageSize: 10, + }) + .expect(200); + const { body } = res; + expect(body.data.length).to.eql(numberOfHostsInFixture); + expect(body.total).to.eql(numberOfHostsInFixture); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return page based on paging properties passed', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + page: 1, + pageSize: 1, + }) + .expect(200); + expect(body.data.length).to.eql(1); + expect(body.total).to.eql(numberOfHostsInFixture); + expect(body.page).to.eql(1); + expect(body.pageSize).to.eql(1); }); - describe('with metrics-endpoint.metadata_current_default index', () => { - /** - * The number of host documents in the es archive. - */ - const numberOfHostsInFixture = 3; - - describe('when index is empty', () => { - it('metadata api should return empty result when index is empty', async () => { - await stopTransform(getService, `${METADATA_UNITED_TRANSFORM}*`); - await deleteIndex(getService, METADATA_UNITED_INDEX); - await deleteMetadataStream(getService); - await deleteAllDocsFromMetadataDatastream(getService); - await deleteAllDocsFromMetadataCurrentIndex(getService); - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 0, - pageSize: 10, - }) - .expect(200); - expect(body.data.length).to.eql(0); - expect(body.total).to.eql(0); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - }); - - describe('when index is not empty', () => { - const timestamp = new Date().getTime(); - before(async () => { - // stop the united transform and delete the index - // otherwise it won't hit metrics-endpoint.metadata_current_default index - await stopTransform(getService, `${METADATA_UNITED_TRANSFORM}*`); - await deleteIndex(getService, METADATA_UNITED_INDEX); - - const metadataDocs = generateMetadataDocs(timestamp); - await bulkIndex(getService, METADATA_DATASTREAM, metadataDocs); - - await endpointTestResources.waitForEndpoints( - Array.from(new Set(metadataDocs.map((doc) => doc.agent.id))), - 60000 - ); - }); - // the endpoint uses data streams and es archiver does not support deleting them at the moment so we need - // to do it manually - after(async () => { - await deleteMetadataStream(getService); - await deleteAllDocsFromMetadataDatastream(getService); - await deleteAllDocsFromMetadataCurrentIndex(getService); - }); - - it('metadata api should return one entry for each host with default paging', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 0, - pageSize: 10, - }) - .expect(200); - expect(body.data.length).to.eql(numberOfHostsInFixture); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on paging properties passed.', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 1, - pageSize: 1, - }) - .expect(200); - expect(body.data.length).to.eql(1); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(1); - expect(body.pageSize).to.eql(1); - }); - - /* test that when paging properties produces no result, the total should reflect the actual number of metadata - in the index. - */ - it('metadata api should return accurate total metadata if page index produces no result', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 3, - pageSize: 10, - }) - .expect(200); - expect(body.data.length).to.eql(0); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(3); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return 400 when pagingProperties is below boundaries.', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 1, - pageSize: 0, - }) - .expect(400); - expect(body.message).to.contain('Value must be equal to or greater than [1]'); - }); - - it('metadata api should return page based on filters passed.', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: 'not (HostDetails.host.ip:10.46.229.234 or host.ip:10.46.229.234)', - }) - .expect(200); - expect(body.data.length).to.eql(2); - expect(body.total).to.eql(2); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on filters and paging passed.', async () => { - const notIncludedIp = '10.46.229.234'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - page: 0, - pageSize: 10, - kuery: `not (HostDetails.host.ip:${notIncludedIp} or host.ip:${notIncludedIp})`, - }) - .expect(200); - expect(body.data.length).to.eql(2); - expect(body.total).to.eql(2); - const resultIps: string[] = [].concat( - ...body.data.map((hostInfo: Record) => hostInfo.metadata.host.ip) - ); - expect(resultIps.sort()).to.eql( - [ - '10.192.213.130', - '10.70.28.129', - '10.101.149.26', - '2606:a000:ffc0:39:11ef:37b9:3371:578c', - ].sort() - ); - expect(resultIps).not.include.eql(notIncludedIp); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return page based on host.os.Ext.variant filter.', async () => { - const variantValue = 'Windows Pro'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `HostDetails.host.os.Ext.variant:${variantValue} or host.os.Ext.variant:${variantValue}`, - }) - .expect(200); - expect(body.data.length).to.eql(2); - expect(body.total).to.eql(2); - const resultOsVariantValue: Set = new Set( - body.data.map( - (hostInfo: Record) => hostInfo.metadata.host.os.Ext.variant - ) - ); - expect(Array.from(resultOsVariantValue)).to.eql([variantValue]); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return the latest event for all the events for an endpoint', async () => { - const targetEndpointIp = '10.46.229.234'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `HostDetails.host.ip:${targetEndpointIp} or host.ip:${targetEndpointIp}`, - }) - .expect(200); - expect(body.data.length).to.eql(1); - expect(body.total).to.eql(1); - const resultIp: string = body.data[0].metadata.host.ip.filter( - (ip: string) => ip === targetEndpointIp - ); - expect(resultIp).to.eql([targetEndpointIp]); - expect(body.data[0].metadata.event.created).to.eql(timestamp); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return the latest event for all the events where policy status is not success', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: - 'not (HostDetails.Endpoint.policy.applied.status:success or Endpoint.policy.applied.status:success)', - }) - .expect(200); - const statuses: Set = new Set( - body.data.map( - (hostInfo: Record) => hostInfo.metadata.Endpoint.policy.applied.status - ) - ); - expect(statuses.size).to.eql(1); - expect(Array.from(statuses)).to.eql(['failure']); - }); - - it('metadata api should return the endpoint based on the elastic agent id, and status should be unhealthy', async () => { - const targetEndpointId = 'fc0ff548-feba-41b6-8367-65e8790d0eaf'; - const targetElasticAgentId = '023fa40c-411d-4188-a941-4147bfadd095'; - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: `HostDetails.elastic.agent.id:${targetElasticAgentId} or elastic.agent.id:${targetElasticAgentId}`, - }) - .expect(200); - expect(body.data.length).to.eql(1); - expect(body.total).to.eql(1); - const resultHostId: string = body.data[0].metadata.host.id; - const resultElasticAgentId: string = body.data[0].metadata.elastic.agent.id; - expect(resultHostId).to.eql(targetEndpointId); - expect(resultElasticAgentId).to.eql(targetElasticAgentId); - expect(body.data[0].metadata.event.created).to.eql(timestamp); - expect(body.data[0].host_status).to.eql('unhealthy'); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - - it('metadata api should return all hosts when filter is empty string', async () => { - const { body } = await supertest - .get(HOST_METADATA_LIST_ROUTE) - .set('kbn-xsrf', 'xxx') - .query({ - kuery: '', - }) - .expect(200); - expect(body.data.length).to.eql(numberOfHostsInFixture); - expect(body.total).to.eql(numberOfHostsInFixture); - expect(body.page).to.eql(0); - expect(body.pageSize).to.eql(10); - }); - }); + it('metadata api should return accurate total metadata if page index produces no result', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + page: 3, + pageSize: 10, + }) + .expect(200); + expect(body.data.length).to.eql(0); + expect(body.total).to.eql(numberOfHostsInFixture); + expect(body.page).to.eql(3); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return 400 when pagingProperties is below boundaries.', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + page: 1, + pageSize: 0, + }) + .expect(400); + expect(body.message).to.contain('Value must be equal to or greater than [1]'); + }); + + it('metadata api should return page based on filters passed.', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: 'not (united.endpoint.host.ip:10.101.149.26)', + }) + .expect(200); + expect(body.data.length).to.eql(1); + expect(body.total).to.eql(1); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return page based on filters and paging passed.', async () => { + const notIncludedIp = '10.101.149.26'; + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + page: 0, + pageSize: 10, + kuery: `not (united.endpoint.host.ip:${notIncludedIp})`, + }) + .expect(200); + expect(body.total).to.eql(1); + const resultIps: string[] = [].concat( + ...body.data.map((hostInfo: Record) => hostInfo.metadata.host.ip) + ); + expect(resultIps.sort()).to.eql(['10.192.213.130', '10.70.28.129'].sort()); + expect(resultIps).not.include.eql(notIncludedIp); + expect(body.data.length).to.eql(1); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return page based on host.os.Ext.variant filter.', async () => { + const variantValue = 'Windows Pro'; + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: `united.endpoint.host.os.Ext.variant:${variantValue}`, + }) + .expect(200); + expect(body.total).to.eql(2); + const resultOsVariantValue: Set = new Set( + body.data.map((hostInfo: Record) => hostInfo.metadata.host.os.Ext.variant) + ); + expect(Array.from(resultOsVariantValue)).to.eql([variantValue]); + expect(body.data.length).to.eql(2); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return the latest event for all the events for an endpoint', async () => { + const targetEndpointIp = '10.101.149.26'; + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: `united.endpoint.host.ip:${targetEndpointIp}`, + }) + .expect(200); + expect(body.total).to.eql(1); + const resultIp: string = body.data[0].metadata.host.ip.filter( + (ip: string) => ip === targetEndpointIp + ); + expect(resultIp).to.eql([targetEndpointIp]); + expect(body.data.length).to.eql(1); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return the latest event for all the events where policy status is not success', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: 'not (united.endpoint.Endpoint.policy.applied.status:success)', + }) + .expect(200); + const statuses: Set = new Set( + body.data.map( + (hostInfo: Record) => hostInfo.metadata.Endpoint.policy.applied.status + ) + ); + expect(statuses.size).to.eql(1); + expect(Array.from(statuses)).to.eql(['failure']); + }); + + it('metadata api should return the endpoint based on the elastic agent id, and status should be healthy', async () => { + const targetEndpointId = 'fc0ff548-feba-41b6-8367-65e8790d0eaf'; + const targetElasticAgentId = '023fa40c-411d-4188-a941-4147bfadd095'; + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: `united.endpoint.elastic.agent.id:${targetElasticAgentId}`, + }) + .expect(200); + expect(body.total).to.eql(1); + const resultHostId: string = body.data[0].metadata.host.id; + const resultElasticAgentId: string = body.data[0].metadata.elastic.agent.id; + expect(resultHostId).to.eql(targetEndpointId); + expect(resultElasticAgentId).to.eql(targetElasticAgentId); + expect(body.data.length).to.eql(1); + expect(body.data[0].host_status).to.eql('healthy'); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return the endpoint based on the agent hostname', async () => { + const targetEndpointId = 'fc0ff548-feba-41b6-8367-65e8790d0eaf'; + const targetAgentHostname = 'Example-host-name-XYZ'; + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .query({ + kuery: `united.endpoint.host.hostname:${targetAgentHostname}`, + }) + .expect(200); + expect(body.total).to.eql(1); + const resultHostId: string = body.data[0].metadata.host.id; + const resultElasticAgentName: string = body.data[0].metadata.host.hostname; + expect(resultHostId).to.eql(targetEndpointId); + expect(resultElasticAgentName).to.eql(targetAgentHostname); + expect(body.data.length).to.eql(1); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); + }); + + it('metadata api should return all hosts when filter is empty string', async () => { + const { body } = await supertest + .get(HOST_METADATA_LIST_ROUTE) + .set('kbn-xsrf', 'xxx') + .expect(200); + expect(body.data.length).to.eql(numberOfHostsInFixture); + expect(body.total).to.eql(numberOfHostsInFixture); + expect(body.page).to.eql(0); + expect(body.pageSize).to.eql(10); }); }); diff --git a/yarn.lock b/yarn.lock index 2ef99cddb4e62..4020daf678f54 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1531,10 +1531,10 @@ resolved "https://registry.yarnpkg.com/@elastic/eslint-plugin-eui/-/eslint-plugin-eui-0.0.2.tgz#56b9ef03984a05cc213772ae3713ea8ef47b0314" integrity sha512-IoxURM5zraoQ7C8f+mJb9HYSENiZGgRVcG4tLQxE61yHNNRDXtGDWTZh8N1KIHcsqN1CEPETjuzBXkJYF/fDiQ== -"@elastic/eui@72.2.0": - version "72.2.0" - resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-72.2.0.tgz#0d89ec4c6d8a677ba41d086abd509c5a5ea09180" - integrity sha512-3JHKLWqbU1A6qMVkw0n1VZ5PaL07sd3N44tWsRCn+DEaDv9jq68ilEmY1wdYqKXw8VyFwcPbd8ZYZpdzBD2nPA== +"@elastic/eui@73.0.0": + version "73.0.0" + resolved "https://registry.yarnpkg.com/@elastic/eui/-/eui-73.0.0.tgz#e1340997e2807ef9416daeb3bff71aad14549d19" + integrity sha512-vOdZH5FE9iBRHpSpHnVOH/L8AMX2VJDXlpOQpSprE6kK32k5a0C8PtjHWVntRwWbN9t/pcdqC4oHcZsABIv9GA== dependencies: "@types/chroma-js" "^2.0.0" "@types/lodash" "^4.14.160" @@ -2825,6 +2825,10 @@ version "0.0.0" uid "" +"@kbn/cell-actions@link:packages/kbn-cell-actions": + version "0.0.0" + uid "" + "@kbn/chart-expressions-common@link:src/plugins/chart_expressions/common": version "0.0.0" uid "" @@ -4273,6 +4277,10 @@ version "0.0.0" uid "" +"@kbn/ui-actions-browser@link:packages/kbn-ui-actions-browser": + version "0.0.0" + uid "" + "@kbn/ui-framework@link:packages/kbn-ui-framework": version "0.0.0" uid "" @@ -7348,13 +7356,6 @@ resolved "https://registry.yarnpkg.com/@types/minimist/-/minimist-1.2.2.tgz#ee771e2ba4b3dc5b372935d549fd9617bf345b8c" integrity sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ== -"@types/minipass@*": - version "2.2.0" - resolved "https://registry.yarnpkg.com/@types/minipass/-/minipass-2.2.0.tgz#51ad404e8eb1fa961f75ec61205796807b6f9651" - integrity sha512-wuzZksN4w4kyfoOv/dlpov4NOunwutLA/q7uc00xU02ZyUY+aoM5PWIXEKBMnm0NHd4a+N71BMjq+x7+2Af1fg== - dependencies: - "@types/node" "*" - "@types/mock-fs@^4.13.1": version "4.13.1" resolved "https://registry.yarnpkg.com/@types/mock-fs/-/mock-fs-4.13.1.tgz#9201554ceb23671badbfa8ac3f1fa9e0706305be" @@ -7410,10 +7411,10 @@ dependencies: "@types/node" "*" -"@types/node@*", "@types/node@16.11.41", "@types/node@>= 8", "@types/node@>=12.12.47", "@types/node@>=13.7.0", "@types/node@>=8.9.0", "@types/node@^10.1.0", "@types/node@^14.0.10 || ^16.0.0", "@types/node@^14.14.20 || ^16.0.0", "@types/node@^14.14.31": - version "16.11.41" - resolved "https://registry.yarnpkg.com/@types/node/-/node-16.11.41.tgz#88eb485b1bfdb4c224d878b7832239536aa2f813" - integrity sha512-mqoYK2TnVjdkGk8qXAVGc/x9nSaTpSrFaGFm43BUH3IdoBV0nta6hYaGmdOvIMlbHJbUEVen3gvwpwovAZKNdQ== +"@types/node@*", "@types/node@18.11.18", "@types/node@>= 8", "@types/node@>=12.12.47", "@types/node@>=13.7.0", "@types/node@>=8.9.0", "@types/node@^10.1.0", "@types/node@^14.0.10 || ^16.0.0", "@types/node@^14.14.20 || ^16.0.0", "@types/node@^14.14.31": + version "18.11.18" + resolved "https://registry.yarnpkg.com/@types/node/-/node-18.11.18.tgz#8dfb97f0da23c2293e554c5a50d61ef134d7697f" + integrity sha512-DHQpWGjyQKSHj3ebjFI/wRKcqQcdR+MoFBygntYOZytCqNfkd2ZC4ARDJ2DQqhjH5p85Nnd3jhUJIXrszFX/JA== "@types/nodemailer@^6.4.0": version "6.4.0" @@ -7898,13 +7899,13 @@ resolved "https://registry.yarnpkg.com/@types/tapable/-/tapable-1.0.6.tgz#a9ca4b70a18b270ccb2bc0aaafefd1d486b7ea74" integrity sha512-W+bw9ds02rAQaMvaLYxAbJ6cvguW/iJXNT6lTssS1ps6QdrMKttqEAMEG/b5CR8TZl3/L7/lH0ZV5nNR1LXikA== -"@types/tar@^4.0.5": - version "4.0.5" - resolved "https://registry.yarnpkg.com/@types/tar/-/tar-4.0.5.tgz#5f953f183e36a15c6ce3f336568f6051b7b183f3" - integrity sha512-cgwPhNEabHaZcYIy5xeMtux2EmYBitfqEceBUi2t5+ETy4dW6kswt6WX4+HqLeiiKOo42EXbGiDmVJ2x+vi37Q== +"@types/tar@^6.1.3": + version "6.1.3" + resolved "https://registry.yarnpkg.com/@types/tar/-/tar-6.1.3.tgz#46a2ce7617950c4852dfd7e9cd41aa8161b9d750" + integrity sha512-YzDOr5kdAeqS8dcO6NTTHTMJ44MUCBDoLEIyPtwEn7PssKqUYL49R1iCVJPeiPzPlKi6DbH33eZkpeJ27e4vHg== dependencies: - "@types/minipass" "*" "@types/node" "*" + minipass "^3.3.5" "@types/tempy@^0.2.0": version "0.2.0" @@ -7986,12 +7987,10 @@ dependencies: "@types/react" "*" -"@types/uuid@^3.4.4": - version "3.4.4" - resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-3.4.4.tgz#7af69360fa65ef0decb41fd150bf4ca5c0cefdf5" - integrity sha512-tPIgT0GUmdJQNSHxp0X2jnpQfBSTfGxUMc/2CXBU2mnyTFVYVa2ojpoQ74w0U2yn2vw3jnC640+77lkFFpdVDw== - dependencies: - "@types/node" "*" +"@types/uuid@^9.0.0": + version "9.0.0" + resolved "https://registry.yarnpkg.com/@types/uuid/-/uuid-9.0.0.tgz#53ef263e5239728b56096b0a869595135b7952d2" + integrity sha512-kr90f+ERiQtKWMz5rP32ltJ/BtULDI5RVO0uavn1HQUOwjx0R1h0rnDYNL0CepF1zL5bSY6FISAfd9tOdDhU5Q== "@types/vfile-message@^2.0.0": version "2.0.0" @@ -8618,7 +8617,7 @@ abab@^2.0.3, abab@^2.0.4, abab@^2.0.5, abab@^2.0.6: resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.6.tgz#41b80f2c871d19686216b82309231cfd3cb3d291" integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== -abbrev@1: +abbrev@1, abbrev@^1.0.0: version "1.1.1" resolved "https://registry.yarnpkg.com/abbrev/-/abbrev-1.1.1.tgz#f8f2c887ad10bf67f634f005b6987fed3179aac8" integrity sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q== @@ -9479,10 +9478,10 @@ axios@^0.27.2: follow-redirects "^1.14.9" form-data "^4.0.0" -axios@^1.1.2, axios@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/axios/-/axios-1.1.3.tgz#8274250dada2edf53814ed7db644b9c2866c1e35" - integrity sha512-00tXVRwKx/FZr/IDVFt4C+f9FYairX517WoGCL6dpOntqLkZofjhu43F/Xl44UOpqa+9sLFDrG/XAnFsUYgkDA== +axios@^1.1.2, axios@^1.2.1: + version "1.2.3" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.2.3.tgz#31a3d824c0ebf754a004b585e5f04a5f87e6c4ff" + integrity sha512-pdDkMYJeuXLZ6Xj/Q5J3Phpe+jbGdsSzlQaFVkMQzRUL05+6+tetX8TV3p4HrU4kzuO9bt+io/yGQxuyxA/xcw== dependencies: follow-redirects "^1.15.0" form-data "^4.0.0" @@ -10651,13 +10650,13 @@ chrome-trace-event@^1.0.2: dependencies: tslib "^1.9.0" -chromedriver@^108.0.0: - version "108.0.0" - resolved "https://registry.yarnpkg.com/chromedriver/-/chromedriver-108.0.0.tgz#7994013f423d8b95a513bb9553a55088de81b252" - integrity sha512-/kb0rb0dlC4RfXh2BOT7RV87K6d+It3VV5YXebLzO5a8t2knNffiTE23XPJQCH+l1xmgoW8/sOX/NB9irskvOQ== +chromedriver@^109.0.0: + version "109.0.0" + resolved "https://registry.yarnpkg.com/chromedriver/-/chromedriver-109.0.0.tgz#9407af72f2a01bb19e6db1b85cfc87eb3acd4f6b" + integrity sha512-jdmBq11IUwfThLFiygGTZ89qbROSQI4bICQjvOVQy2Bqr1LwC+MFkhwyZp3YG99eehQbZuTlQmmfCZBfpewTNA== dependencies: "@testim/chrome-version" "^1.1.3" - axios "^1.1.3" + axios "^1.2.1" compare-versions "^5.0.1" extract-zip "^2.0.1" https-proxy-agent "^5.0.1" @@ -13058,45 +13057,7 @@ elastic-apm-http-client@11.0.4, elastic-apm-http-client@^11.0.1: semver "^6.3.0" stream-chopper "^3.0.1" -elastic-apm-node@^3.38.0: - version "3.41.0" - resolved "https://registry.yarnpkg.com/elastic-apm-node/-/elastic-apm-node-3.41.0.tgz#ff0b5ecf6d126a2eb312ecc936bd55bc3f1e3ce6" - integrity sha512-cX745ryAwQCFEhkYttLrdjQDO0vCHspCbKg6bCguvBURZUHkLnZcP5z5m3R20dnGfTDXGg2q6nMi65iIVMCYFA== - dependencies: - "@elastic/ecs-pino-format" "^1.2.0" - "@opentelemetry/api" "^1.1.0" - after-all-results "^2.0.0" - async-cache "^1.1.0" - async-value-promise "^1.1.1" - basic-auth "^2.0.1" - cookie "^0.5.0" - core-util-is "^1.0.2" - elastic-apm-http-client "11.0.4" - end-of-stream "^1.4.4" - error-callsites "^2.0.4" - error-stack-parser "^2.0.6" - escape-string-regexp "^4.0.0" - fast-safe-stringify "^2.0.7" - http-headers "^3.0.2" - is-native "^1.0.1" - lru-cache "^6.0.0" - measured-reporting "^1.51.1" - monitor-event-loop-delay "^1.0.0" - object-filter-sequence "^1.0.0" - object-identity-map "^1.0.2" - original-url "^1.2.3" - pino "^6.11.2" - relative-microtime "^2.0.0" - require-in-the-middle "^5.2.0" - semver "^6.3.0" - set-cookie-serde "^1.0.0" - shallow-clone-shim "^2.0.0" - source-map "^0.8.0-beta.0" - sql-summary "^1.0.1" - traverse "^0.6.6" - unicode-byte-truncate "^1.0.0" - -elastic-apm-node@^3.41.1: +elastic-apm-node@^3.38.0, elastic-apm-node@^3.41.1: version "3.41.1" resolved "https://registry.yarnpkg.com/elastic-apm-node/-/elastic-apm-node-3.41.1.tgz#e0829d69d5e8a6062ef567d0a8db0ec0e3736ea8" integrity sha512-bLCVIyAgQC+ZfY5fd/UaAId+8dh3vusaxZF2A0YtHBAwx1YGpIA3dqOt5zc1UuYmbjCdsEAiUjaUEAHOWdjTzA== @@ -16512,10 +16473,10 @@ inquirer@^8.2.3: through "^2.3.6" wrap-ansi "^7.0.0" -install-artifact-from-github@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/install-artifact-from-github/-/install-artifact-from-github-1.3.0.tgz#cab6ff821976b8a35b0c079da19a727c90381a40" - integrity sha512-iT8v1GwOAX0pPXifF/5ihnMhHOCo3OeK7z3TQa4CtSNCIg8k0UxqBEk9jRwz8OP68hHXvJ2gxRa89KYHtBkqGA== +install-artifact-from-github@^1.3.1: + version "1.3.1" + resolved "https://registry.yarnpkg.com/install-artifact-from-github/-/install-artifact-from-github-1.3.1.tgz#eefaad9af35d632e5d912ad1569c1de38c3c2462" + integrity sha512-3l3Bymg2eKDsN5wQuMfgGEj2x6l5MCAv0zPL6rxHESufFVlEAKW/6oY9F1aGgvY/EgWm5+eWGRjINveL4X7Hgg== internal-slot@^1.0.3: version "1.0.3" @@ -19271,7 +19232,7 @@ make-error@^1.1.1: resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== -make-fetch-happen@^10.0.4: +make-fetch-happen@^10.0.3, make-fetch-happen@^10.0.4: version "10.2.1" resolved "https://registry.yarnpkg.com/make-fetch-happen/-/make-fetch-happen-10.2.1.tgz#f5e3835c5e9817b617f2770870d9492d28678164" integrity sha512-NgOPbRiaQM10DYXvN3/hhGVI2M5MtITFryzBGxHM5p4wnFxsVCbxkrBrDsk+EZ5OB4jEOT7AjDxtdF+KVEFT7w== @@ -19973,10 +19934,17 @@ minipass-sized@^1.0.3: dependencies: minipass "^3.0.0" -minipass@^3.0.0, minipass@^3.1.0, minipass@^3.1.1, minipass@^3.1.3, minipass@^3.1.6: - version "3.3.4" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.3.4.tgz#ca99f95dd77c43c7a76bf51e6d200025eee0ffae" - integrity sha512-I9WPbWHCGu8W+6k1ZiGpPu0GkoKBeorkfKNuAFBNS1HNFJvke82sxvI5bzcCNpWPorkOO5QQ+zomzzwRxejXiw== +minipass@^3.0.0, minipass@^3.1.0, minipass@^3.1.1, minipass@^3.1.3, minipass@^3.1.6, minipass@^3.3.5: + version "3.3.6" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-3.3.6.tgz#7bba384db3a1520d18c9c0e5251c3444e95dd94a" + integrity sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw== + dependencies: + yallist "^4.0.0" + +minipass@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-4.0.0.tgz#7cebb0f9fa7d56f0c5b17853cbe28838a8dbbd3b" + integrity sha512-g2Uuh2jEKoht+zvO6vJqXmYpflPqzRBT+Th2h01DKh5z7wbY/AZ2gCQ78cP70YoHPyFdY30YBV5WxgLOEwOykw== dependencies: yallist "^4.0.0" @@ -20289,7 +20257,7 @@ mute-stream@0.0.8: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d" integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== -nan@^2.15.0, nan@^2.17.0: +nan@^2.16.0, nan@^2.17.0: version "2.17.0" resolved "https://registry.yarnpkg.com/nan/-/nan-2.17.0.tgz#c0150a2368a182f033e9aa5195ec76ea41a199cb" integrity sha512-2ZTgtl0nJsO0KQCjEpxcIr5D+Yv90plTitZt9JBfQvVJDS5seMl3FOvsh3+9CoYWXf/1l5OaZzzF6nDm4cagaQ== @@ -20546,6 +20514,22 @@ node-gyp@^8.4.1: tar "^6.1.2" which "^2.0.2" +node-gyp@^9.0.0: + version "9.3.0" + resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-9.3.0.tgz#f8eefe77f0ad8edb3b3b898409b53e697642b319" + integrity sha512-A6rJWfXFz7TQNjpldJ915WFb1LnhO4lIve3ANPbWreuEoLoKlFT3sxIepPBkLhM27crW8YmN+pjlgbasH6cH/Q== + dependencies: + env-paths "^2.2.0" + glob "^7.1.4" + graceful-fs "^4.2.6" + make-fetch-happen "^10.0.3" + nopt "^6.0.0" + npmlog "^6.0.0" + rimraf "^3.0.2" + semver "^7.3.5" + tar "^6.1.2" + which "^2.0.2" + node-int64@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" @@ -20647,6 +20631,13 @@ nopt@^5.0.0: dependencies: abbrev "1" +nopt@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/nopt/-/nopt-6.0.0.tgz#245801d8ebf409c6df22ab9d95b65e1309cdb16d" + integrity sha512-ZwLpbTgdhuZUnZzjd7nb1ZV+4DoiC6/sfiVKok72ym/4Tlf+DFdlHYmT2JPmcNNWV6Pi3SDf1kT+A4r9RTuT9g== + dependencies: + abbrev "^1.0.0" + normalize-package-data@^2.0.0, normalize-package-data@^2.3.2, normalize-package-data@^2.3.4, normalize-package-data@^2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.5.0.tgz#e66db1838b200c1dfc233225d12cb36520e234a8" @@ -22800,14 +22791,14 @@ re-resizable@^6.1.1: dependencies: fast-memoize "^2.5.1" -re2@1.17.4: - version "1.17.4" - resolved "https://registry.yarnpkg.com/re2/-/re2-1.17.4.tgz#7bf29290bdde963014e77bd2c2e799a6d788386e" - integrity sha512-xyZ4h5PqE8I9tAxTh3G0UttcK5ufrcUxReFjGzfX61vtanNbS1XZHjnwRSyPcLgChI4KLxVgOT/ioZXnUAdoTA== +re2@1.17.7: + version "1.17.7" + resolved "https://registry.yarnpkg.com/re2/-/re2-1.17.7.tgz#e14cab85a177a5534c7215c322d1b043c55aa1e9" + integrity sha512-X8GSuiBoVWwcjuppqSjsIkRxNUKDdjhkO9SBekQbZ2ksqWUReCy7DQPWOVpoTnpdtdz5PIpTTxTFzvJv5UMfjA== dependencies: - install-artifact-from-github "^1.3.0" - nan "^2.15.0" - node-gyp "^8.4.1" + install-artifact-from-github "^1.3.1" + nan "^2.16.0" + node-gyp "^9.0.0" react-ace@^7.0.5: version "7.0.5" @@ -25120,10 +25111,10 @@ source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.0, source-map@~0.6.1: resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== -source-map@^0.7.3: - version "0.7.3" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.3.tgz#5302f8169031735226544092e64981f751750383" - integrity sha512-CkCj6giN3S+n9qrYiBTX5gystlENnRW5jZeNLHpe6aue+SrHcG5VYwujhW9s4dY31mEGsxBDrHR6oI69fTXsaQ== +source-map@^0.7.3, source-map@^0.7.4: + version "0.7.4" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.7.4.tgz#a9bbe705c9d8846f4e08ff6765acf0f1b0898656" + integrity sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA== source-map@^0.8.0-beta.0: version "0.8.0-beta.0" @@ -26054,7 +26045,7 @@ tar-stream@^2.1.4, tar-stream@^2.2.0: inherits "^2.0.3" readable-stream "^3.1.1" -tar@6.1.11, tar@^6.0.2, tar@^6.1.11, tar@^6.1.2: +tar@6.1.11: version "6.1.11" resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.11.tgz#6760a38f003afa1b2ffd0ffe9e9abbd0eab3d621" integrity sha512-an/KZQzQUkZCkuoAA64hM92X0Urb6VpRhAFllDzz44U2mcD5scmT3zBc4VgVpkugF580+DQn8eAFSyoQt0tznA== @@ -26066,6 +26057,18 @@ tar@6.1.11, tar@^6.0.2, tar@^6.1.11, tar@^6.1.2: mkdirp "^1.0.3" yallist "^4.0.0" +tar@^6.0.2, tar@^6.1.11, tar@^6.1.13, tar@^6.1.2: + version "6.1.13" + resolved "https://registry.yarnpkg.com/tar/-/tar-6.1.13.tgz#46e22529000f612180601a6fe0680e7da508847b" + integrity sha512-jdIBIN6LTIe2jqzay/2vtYLlBHa3JF42ot3h1dW8Q0PaAG4v8rm0cvpVePtau5C6OKXGGcgO9q2AMNSWxiLqKw== + dependencies: + chownr "^2.0.0" + fs-minipass "^2.0.0" + minipass "^4.0.0" + minizlib "^2.1.1" + mkdirp "^1.0.3" + yallist "^4.0.0" + tcomb-validation@^3.3.0: version "3.4.1" resolved "https://registry.yarnpkg.com/tcomb-validation/-/tcomb-validation-3.4.1.tgz#a7696ec176ce56a081d9e019f8b732a5a8894b65" @@ -27303,10 +27306,10 @@ uuid-browser@^3.1.0: resolved "https://registry.yarnpkg.com/uuid-browser/-/uuid-browser-3.1.0.tgz#0f05a40aef74f9e5951e20efbf44b11871e56410" integrity sha1-DwWkCu90+eWVHiDvv0SxGHHlZBA= -uuid@3.3.2: - version "3.3.2" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" - integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== +uuid@9.0.0, uuid@^9: + version "9.0.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-9.0.0.tgz#592f550650024a38ceb0c562f2f6aa435761efb5" + integrity sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg== uuid@^3.3.2, uuid@^3.3.3: version "3.4.0" @@ -27318,11 +27321,6 @@ uuid@^8.3.0, uuid@^8.3.2: resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== -uuid@^9: - version "9.0.0" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-9.0.0.tgz#592f550650024a38ceb0c562f2f6aa435761efb5" - integrity sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg== - v8-compile-cache-lib@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz#6336e8d71965cb3d35a1bbb7868445a7c05264bf"